/* Lailix Learn. Tokens from the Lailix brand (lailix-brand skill, video-brand pack). */

@font-face {
  font-family: "DM Sans";
  src: url("/static/fonts/DMSans-latin-var.woff2") format("woff2");
  font-weight: 100 1000;
  font-style: normal;
  font-display: swap;
}

:root {
  --navy: #0d1f2d;
  --navy-2: #1a3448;
  --gold: #c5a95a;
  --gold-soft: #efe4c6;
  --gold-text: #7d6628;
  --beige: #e8d7bd;
  --beige-soft: #f6eedf;
  --cream: #f0ede4;
  --cover-paper: #ece8dd; /* background of the generated blueprint covers and the agent poster */
  --purple: #e7a4e7;
  --grey: #5a6a7a;
  --line: #e0d9c9;
  --white: #ffffff;
  --good: #2f7d4f;
  --good-soft: #e5f1e9;
  --bad: #a8412f;
  --bad-soft: #f8e7e2;
  --note: #fff3bf;
  --note-line: #d9ad00;
  --radius: 14px;
  --radius-small: 8px;
  --shadow: 0 1px 2px rgba(13, 31, 45, 0.06), 0 4px 16px rgba(13, 31, 45, 0.04);
  --header-h: 3.6rem; /* app.js sets the real height */
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  /* Anchors (#weiter, #frage-q1, table of contents) stop below the sticky header. */
  scroll-padding-top: calc(var(--header-h) + 1rem);
}

body {
  margin: 0;
  background: var(--cream);
  color: var(--navy);
  font-family: "DM Sans", Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 17px;
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a {
  color: var(--navy);
  text-decoration-color: var(--gold);
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}

a:hover {
  color: var(--navy-2);
}

:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 2px;
  border-radius: 4px;
}

h1,
h2,
h3 {
  line-height: 1.25;
  letter-spacing: -0.01em;
  margin: 0 0 0.5em;
}

h1 {
  font-size: clamp(1.75rem, 4.5vw, 2.35rem);
  font-weight: 650;
}

h2 {
  font-size: 1.35rem;
  font-weight: 650;
}

h3 {
  font-size: 1.1rem;
  font-weight: 650;
}

p {
  margin: 0 0 0.9em;
}

code {
  font-family: var(--mono);
  font-size: 0.9em;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.muted {
  color: var(--grey);
}

.small {
  font-size: 0.85rem;
}

.center {
  text-align: center;
}

.nowrap {
  white-space: nowrap;
}

.eyebrow {
  display: block;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold-text);
  margin: 0 0 0.35rem;
}

/* Header and footer */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--white);
  border-bottom: 1px solid var(--line);
  transition: box-shadow 0.2s ease, border-color 0.2s ease;
}

/* app.js adds .is-scrolled once the page has moved. */
.site-header.is-scrolled {
  border-bottom-color: var(--beige);
  box-shadow: 0 2px 14px rgba(13, 31, 45, 0.12);
}

/* Thin line along the bottom edge of the header on module pages: share of ticked boxes and answered questions. */
.header-progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 3px;
  background: rgba(197, 169, 90, 0.2);
}

.header-progress-fill {
  display: block;
  height: 100%;
  background: var(--gold);
}

.site-header-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0.8rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  text-decoration: none;
}

.brand img {
  display: block;
  height: 22px;
  width: auto;
}

.brand-product {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--grey);
  border-left: 1px solid var(--line);
  padding-left: 0.55rem;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 1.1rem;
  font-size: 0.95rem;
}

.site-nav a {
  text-decoration: none;
  font-weight: 500;
}

.site-nav a:hover {
  text-decoration: underline;
  text-decoration-color: var(--gold);
}

.site-nav form {
  margin: 0;
}

.link-button {
  background: none;
  border: 0;
  padding: 0;
  font: inherit;
  color: var(--grey);
  cursor: pointer;
}

.link-button:hover {
  color: var(--navy);
  text-decoration: underline;
}

.lang-switch {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin: 0;
  font-size: 0.85rem;
  color: var(--grey);
}

.lang-switch .link-button {
  font-weight: 500;
}

.lang-switch .lang-active {
  color: var(--navy);
  font-weight: 700;
  text-decoration: underline;
  text-decoration-color: var(--gold);
  cursor: default;
}

.header-tools {
  display: flex;
  align-items: center;
  gap: 1.1rem;
}

.container {
  width: 100%;
  max-width: 760px;
  margin: 0 auto;
  padding: 2rem 1rem 4rem;
  flex: 1;
}

.container.wide {
  max-width: 1180px;
}

.site-footer {
  text-align: center;
  font-size: 0.8rem;
  color: var(--grey);
  padding: 1.5rem 1rem 2rem;
}

/* Buttons and forms */

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  min-height: 44px;
  padding: 0.55rem 1.1rem;
  border-radius: 999px;
  border: 1.5px solid var(--navy);
  background: var(--white);
  color: var(--navy);
  font: inherit;
  font-weight: 600;
  font-size: 0.95rem;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s ease, transform 0.15s ease;
}

.button:hover {
  background: var(--beige-soft);
  color: var(--navy);
}

.button:active {
  transform: translateY(1px);
}

.button.primary {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--navy);
}

.button.primary:hover {
  background: #b8994a;
  border-color: #b8994a;
}

.button.large {
  min-height: 52px;
  padding: 0.75rem 1.4rem;
  font-size: 1rem;
}

.button.small {
  min-height: 36px;
  padding: 0.35rem 0.85rem;
  font-size: 0.85rem;
}

.button.danger {
  border-color: var(--bad);
  color: var(--bad);
}

.button.danger:hover {
  background: var(--bad-soft);
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  align-items: center;
}

.button-row form {
  margin: 0;
}

.stack {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
  margin: 1.25rem 0;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  font-size: 0.9rem;
  font-weight: 600;
}

input[type="email"],
input[type="text"],
input[type="url"],
input[type="date"],
select,
textarea {
  font: inherit;
  font-weight: 400;
  font-size: 1rem;
  color: var(--navy);
  background: var(--white);
  border: 1.5px solid var(--line);
  border-radius: var(--radius-small);
  padding: 0.65rem 0.8rem;
  width: 100%;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--navy);
  outline: none;
  box-shadow: 0 0 0 3px var(--gold-soft);
}

textarea {
  resize: vertical;
  min-height: 8rem;
  line-height: 1.5;
}

.form-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.8rem;
}

.inline-check {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}

.hint {
  font-size: 0.85rem;
  color: var(--grey);
  margin: 0.5rem 0 0.8rem;
}

.field-error {
  color: var(--bad);
  font-weight: 600;
  font-size: 0.9rem;
}

.flash {
  padding: 0.8rem 1rem;
  border-radius: var(--radius-small);
  margin: 0 0 1.25rem;
  font-weight: 500;
}

.flash-ok {
  background: var(--good-soft);
  color: var(--good);
}

.flash-error {
  background: var(--bad-soft);
  color: var(--bad);
}

.notice {
  background: var(--beige-soft);
  border-radius: var(--radius-small);
  padding: 0.8rem 1rem;
}

/* Shared page without an account: what needs access, and the way to it. */
.guest-cta {
  background: var(--beige-soft);
  border-left: 4px solid var(--gold);
  border-radius: var(--radius-small);
  padding: 0.9rem 1rem;
  margin: 1rem 0;
}

.guest-cta p {
  margin: 0 0 0.7rem;
}

/* Honeypot on «Zugang anfragen»: off screen for people, still in the form for bots. */
.hp-field {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.share-toggle {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem;
  margin: 0.4rem 0;
}

.share-toggle p {
  margin: 0;
  overflow-wrap: anywhere;
}

.notice-done {
  background: var(--good-soft);
  color: var(--good);
  font-weight: 600;
}

.dev-hint {
  font-size: 0.85rem;
  background: var(--note);
  border-left: 4px solid var(--note-line);
  padding: 0.6rem 0.8rem;
  border-radius: 4px;
  margin-top: 1.25rem;
}

.card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.25rem 1.35rem;
  margin: 0 0 1.25rem;
  box-shadow: var(--shadow);
}

/* Auth */

.auth-card {
  max-width: 440px;
  margin: 2rem auto;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 2rem 1.75rem;
  box-shadow: var(--shadow);
}

.auth-card h1 {
  font-size: 1.6rem;
}

/* Badges */

.badge {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  white-space: nowrap;
  border: 1px solid transparent;
  vertical-align: middle;
}

.badge-done {
  background: var(--good-soft);
  color: var(--good);
}

.badge-started {
  background: var(--gold-soft);
  color: var(--gold-text);
}

.badge-open {
  border-color: var(--line);
  color: var(--grey);
}

.badge-planned {
  background: #ebe7dd;
  color: var(--grey);
}

/* Chips and progress bars */

.chip {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1.4;
  padding: 0.12rem 0.6rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--white);
  color: var(--navy);
  white-space: nowrap;
}

.chip-icon {
  font-size: 0.65rem;
  color: var(--gold-text);
}

.chip-video {
  background: var(--cream);
}

.chip-part {
  background: var(--gold-soft);
  border-color: var(--gold);
  color: #5c4a14;
}

.lang-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin: 0;
}

.progress-bar {
  height: 8px;
  background: var(--beige);
  border-radius: 999px;
  overflow: hidden;
}

.progress-bar-fill {
  display: block;
  height: 100%;
  background: var(--gold);
  border-radius: 999px;
  min-width: 8px;
}

/* Covers: an image, or a generated navy card with a faint gold blueprint grid */

.cover {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--navy);
}

.cover img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cover-generated {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1.25rem 1.4rem;
  color: var(--white);
  background:
    radial-gradient(110% 90% at 88% 8%, rgba(197, 169, 90, 0.24), transparent 55%),
    linear-gradient(rgba(197, 169, 90, 0.13) 1px, transparent 1px) 0 0 / 24px 24px,
    linear-gradient(90deg, rgba(197, 169, 90, 0.13) 1px, transparent 1px) 0 0 / 24px 24px,
    linear-gradient(rgba(197, 169, 90, 0.24) 1px, transparent 1px) 0 0 / 120px 120px,
    linear-gradient(90deg, rgba(197, 169, 90, 0.24) 1px, transparent 1px) 0 0 / 120px 120px,
    var(--navy);
}

.cover-generated::before {
  content: "";
  position: absolute;
  inset: 0.7rem;
  border: 1px solid rgba(197, 169, 90, 0.35);
  pointer-events: none;
}

.cover-brand {
  position: absolute;
  top: 1.15rem;
  left: 1.4rem;
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.2em;
  color: var(--gold);
}

.cover-title {
  position: relative;
  font-weight: 650;
  font-size: clamp(1.1rem, 2.2vw, 1.45rem);
  line-height: 1.2;
  text-wrap: balance;
  max-width: 92%;
}

/* «Lernpfade» overview */

.paths-header {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.paths-header h1,
.paths-header p {
  margin-bottom: 0;
}

.view-switch {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 0;
}

.view-switch p {
  margin: 0;
}

.paths-grid {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}

@media (min-width: 720px) {
  .paths-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1080px) {
  .paths-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.path-card {
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100%;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.path-card:hover {
  border-color: var(--gold);
  box-shadow: 0 2px 4px rgba(13, 31, 45, 0.06), 0 10px 28px rgba(13, 31, 45, 0.1);
}

/* The whole card is the link. */
.path-card-title a {
  text-decoration: none;
}

.path-card-next {
  border-color: var(--gold);
  box-shadow: 0 0 0 2px var(--gold), var(--shadow);
}

/* Above the whole-card link, so the button is a real button. */
.path-card-next-action {
  position: relative;
  z-index: 1;
  margin: 0.4rem 0 0;
}

.path-back {
  margin: 0 0 0.5rem;
}

.path-card-title a::after {
  content: "";
  position: absolute;
  inset: 0;
}

.path-card-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 0.6rem;
  padding: 1.1rem 1.25rem 1.3rem;
}

.path-card-title {
  font-size: 1.2rem;
  margin: 0;
}

.path-card-desc {
  margin: 0;
  font-size: 0.92rem;
  color: var(--grey);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.path-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.15rem 0;
  margin: 0;
  font-size: 0.88rem;
  color: var(--grey);
}

.path-card-meta span + span::before {
  content: "·";
  margin: 0 0.5rem;
}

.path-status {
  margin: auto 0 0;
  padding-top: 0.6rem;
  font-size: 0.9rem;
}

.path-status-text {
  margin: 0.45rem 0 0;
}

.status-new,
.status-done {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
}

.status-new {
  color: var(--grey);
}

.status-dot {
  width: 0.7rem;
  height: 0.7rem;
  border-radius: 50%;
  border: 2px solid #9aa6b2;
}

.status-done {
  color: var(--good);
}

.icon-check {
  width: 1.3rem;
  height: 1.3rem;
  padding: 2px;
  border-radius: 50%;
  background: var(--gold);
  color: var(--navy);
}

/* Tools for admins stay secondary and clickable above the card link. */
.path-card-tools {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  padding: 0.7rem 1.25rem;
  border-top: 1px solid var(--line);
  background: var(--beige-soft);
}

.path-card-tools p,
.path-card-tools form {
  margin: 0;
}

.path-card-tools .link-button {
  font-size: 0.85rem;
  text-align: left;
  text-decoration: underline;
  text-decoration-color: var(--line);
}

/* Path page */

.path-hero {
  display: grid;
  grid-template-columns: minmax(0, 11fr) minmax(0, 10fr);
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 18px;
  overflow: hidden;
  box-shadow: var(--shadow);
  margin-bottom: 1.75rem;
}

.hero-cover {
  aspect-ratio: auto;
  min-height: 100%;
}

/* The hero column is as tall as the text beside it, so a cropped 16:9 cover lost its edges (the card of the
   partner cover, the agent poster's list). Show the whole image on its own paper colour instead. */
.hero-cover:not(.cover-generated) {
  background: var(--cover-paper);
}

.hero-cover img {
  object-fit: contain;
}

.path-hero-body {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 2rem 2.25rem 2.1rem;
}

.path-hero-body h1 {
  margin-bottom: 0.4rem;
}

.path-hero-desc {
  color: var(--grey);
  margin-bottom: 0.6rem;
}

.progress {
  width: 100%;
  margin: 1.1rem 0 1.4rem;
}

.progress-text {
  margin: 0.45rem 0 0;
  font-size: 0.9rem;
  color: var(--grey);
}

.path-hero-body .notice {
  margin: 1rem 0 0;
}

.path-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 1.5rem;
  align-items: start;
}

.side-card {
  background: var(--navy);
  color: var(--white);
  border-radius: 18px;
  padding: 1.3rem 1.3rem 1.4rem;
}

.side-cta {
  margin-top: 1.2rem;
}

.side-cta .button {
  width: 100%;
  justify-content: center;
  text-align: center;
}

.side-stat-number {
  margin: 0;
  font-size: 2.2rem;
  font-weight: 700;
  line-height: 1.1;
}

.side-stat .muted {
  color: #b9c3cc;
  margin: 0.2rem 0 0;
}

/* «Dein Agent» tracker */

.tracker-title {
  font-size: 1.2rem;
  margin: 0 0 0.2rem;
  color: var(--white);
}

.tracker-intro {
  margin: 0 0 1rem;
  font-size: 0.9rem;
  color: #b9c3cc;
}

.tracker-body {
  display: flex;
  align-items: center;
  gap: 1.1rem;
}

.agent-robot {
  display: block;
  flex: none;
  width: 118px;
  height: auto;
  overflow: visible;
}

.agent-robot.agent-robot-mini {
  width: 46px;
}

.agent-robot * {
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.5px;
  vector-effect: non-scaling-stroke;
}

.agent-robot-mini * {
  stroke-width: 1.2px;
}

.rb-chassis * {
  stroke: #36556f;
}

.rb-part * {
  stroke: #5b7f9e;
}

.rb-gear {
  stroke-dasharray: 5 4;
}

.rb-partial * {
  stroke: var(--gold);
}

.rb-full * {
  stroke: #e6c96b;
}

.rb-full {
  filter: drop-shadow(0 0 3px rgba(230, 201, 107, 0.55));
}

.rb-full .rb-core,
.rb-partial .rb-core {
  fill: #fff6d8;
}

/* A finished part gets a faint gold fill; the dashed shield outline and the gears stay open. */
.agent-robot .rb-full:not(.rb-shield) path,
.agent-robot .rb-full:not(.rb-shield) circle:not(.rb-gear),
.agent-robot .rb-full:not(.rb-shield) rect,
.agent-robot .rb-full:not(.rb-shield) ellipse {
  fill: rgba(197, 169, 90, 0.12);
}

.agent-robot .rb-full circle.rb-core,
.agent-robot .rb-partial circle.rb-core {
  fill: #fff6d8;
}

.tracker-legend {
  flex: 1;
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.45rem;
}

.legend-item {
  display: grid;
  grid-template-columns: 0.8rem 1fr auto;
  align-items: center;
  gap: 0.55rem;
  font-size: 0.9rem;
}

.legend-dot {
  width: 0.75rem;
  height: 0.75rem;
  border-radius: 50%;
  border: 1.5px solid #7f9bb4;
}

.legend-partial .legend-dot {
  border-color: var(--gold);
  background: linear-gradient(90deg, var(--gold) 50%, transparent 50%);
}

.legend-full .legend-dot {
  border-color: var(--gold);
  background: var(--gold);
}

.legend-name {
  font-weight: 600;
}

.legend-state {
  min-width: 1.6rem;
  text-align: right;
  font-size: 0.8rem;
  color: var(--gold);
  white-space: nowrap;
}

/* Timeline of modules */

.module-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}

.module-item {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}

/* The line runs from one node to the next. */
.module-item::before {
  content: "";
  position: absolute;
  left: 1.2rem;
  top: 2.5rem;
  bottom: -1rem;
  width: 2px;
  margin-left: -1px;
  background: var(--beige);
}

.module-item:last-child::before {
  display: none;
}

.module-item.state-done::before {
  background: var(--gold);
}

.module-num {
  position: relative;
  z-index: 1;
  flex: none;
  width: 2.4rem;
  height: 2.4rem;
  margin-top: 0.55rem;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-weight: 700;
  background: var(--white);
  border: 2px solid var(--navy);
  color: var(--navy);
}

.module-item.state-done .module-num {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--navy);
}

/* The module to continue with: highlighted ring. */
.module-item.module-current .module-num {
  background: var(--navy);
  border-color: var(--gold);
  color: var(--white);
  box-shadow: 0 0 0 4px var(--gold-soft);
}

.module-item.state-planned .module-num {
  background: #e3ded2;
  border: 2px dashed #b5aea0;
  color: var(--grey);
}

.module-card {
  position: relative;
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0.95rem 1.1rem;
  box-shadow: var(--shadow);
}

.module-card:has(a.module-title):hover {
  border-color: var(--gold);
}

.module-item.module-current .module-card {
  border-color: var(--gold);
  box-shadow: 0 0 0 1px var(--gold), var(--shadow);
}

.module-item.state-planned .module-card {
  background: transparent;
  box-shadow: none;
  border-style: dashed;
}

.module-item.state-planned .module-title {
  color: var(--grey);
}

.module-body {
  flex: 1 1 12rem;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.module-kicker {
  font-size: 0.78rem;
  color: var(--grey);
  font-weight: 600;
}

.module-title {
  font-weight: 650;
  font-size: 1.05rem;
  text-decoration: none;
}

/* The whole card is clickable. */
a.module-title::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: var(--radius);
}

.module-meta {
  font-size: 0.85rem;
  color: var(--grey);
}

.module-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0.4rem;
}

@media (min-width: 960px) {
  .path-layout {
    grid-template-columns: minmax(0, 1fr) 350px;
    gap: 2rem;
  }

  .path-main {
    order: 1;
  }

  .path-side {
    order: 2;
    position: sticky;
    top: calc(var(--header-h) + 1.25rem);
  }
}

@media (max-width: 959px) {
  /* The hero already has the button. */
  .side-cta {
    display: none;
  }

  .agent-robot {
    width: 96px;
  }

  .agent-robot.agent-robot-mini {
    width: 46px;
  }
}

@media (max-width: 719px) {
  .path-hero {
    grid-template-columns: 1fr;
  }

  .hero-cover {
    aspect-ratio: 16 / 8;
    min-height: 0;
  }

  .path-hero-body {
    padding: 1.25rem 1.25rem 1.4rem;
  }

  .module-card {
    flex-wrap: wrap;
    padding: 0.85rem 0.95rem;
  }

  .module-item {
    gap: 0.7rem;
  }
}

/* Module page */

.crumb {
  font-size: 0.9rem;
  margin-bottom: 1.25rem;
}

.crumb a {
  text-decoration: none;
  color: var(--grey);
}

.crumb a:hover {
  color: var(--navy);
}

.module-header {
  margin-bottom: 1.5rem;
}

.admin-hint {
  font-size: 0.85rem;
  background: var(--note);
  border-left: 4px solid var(--note-line);
  padding: 0.5rem 0.8rem;
  border-radius: 4px;
  margin-top: 0.8rem;
}

.intro {
  font-size: 1.05rem;
}

.intro strong {
  color: var(--navy);
}

.part {
  margin-top: 2.75rem;
}

.part > h2 {
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--beige);
  margin-bottom: 1.1rem;
}

.prose > :last-child {
  margin-bottom: 0;
}

.prose ul,
.prose ol {
  padding-left: 1.3rem;
  margin: 0 0 0.9em;
}

.prose li {
  margin-bottom: 0.3em;
}

.prose a {
  word-break: break-word;
}

.segment-gap,
.prose + *,
* + .prose {
  margin-top: 0.9rem;
}

.step {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.2rem 1.35rem 1.25rem;
  margin: 0 0 1rem;
  box-shadow: var(--shadow);
}

.step > * + * {
  margin-top: 0.9rem;
}

.step-head {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.step-head h3 {
  margin: 0;
}

.step-num {
  flex: none;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--navy);
  color: var(--white);
  font-weight: 700;
  font-size: 0.95rem;
  transition: background 0.2s ease;
}

.step.step-done .step-num {
  background: var(--gold);
  color: var(--navy);
}

.concept {
  margin-top: 2.75rem;
  background: var(--beige-soft);
  border: 1px solid var(--beige);
  border-radius: var(--radius);
  padding: 1.35rem 1.4rem;
}

.concept h2 {
  font-size: 1.15rem;
}

/* Prompts */

.prompt {
  background: var(--navy);
  color: #f3efe4;
  border-radius: var(--radius-small);
  overflow: hidden;
  margin: 0.9rem 0;
}

.prompt-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 0.5rem 0.6rem 0.5rem 1rem;
  background: var(--navy-2);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--gold);
}

.copy-button {
  font: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0;
  min-height: 36px;
  padding: 0.3rem 0.9rem;
  border-radius: 999px;
  border: 0;
  background: var(--gold);
  color: var(--navy);
  cursor: pointer;
}

.copy-button:hover {
  background: #d4bb74;
}

.copy-button.copied {
  background: var(--good-soft);
  color: var(--good);
}

.prompt pre {
  margin: 0;
  padding: 1rem;
  white-space: pre-wrap;
  word-break: break-word;
  font-family: var(--mono);
  font-size: 0.9rem;
  line-height: 1.55;
}

/* Checkboxes */

.checks {
  list-style: none;
  padding: 0;
  margin: 0.9rem 0 0;
}

.checks li + li {
  margin-top: 0.4rem;
}

.checks label {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  padding: 0.6rem 0.75rem;
  background: var(--beige-soft);
  border-radius: var(--radius-small);
  cursor: pointer;
  font-weight: 500;
}

.checks input {
  flex: none;
  width: 1.3rem;
  height: 1.3rem;
  margin: 0.15rem 0 0;
  accent-color: var(--navy);
  cursor: pointer;
}

.checks input:checked + span {
  color: var(--grey);
}

.checks .save-error {
  color: var(--bad);
  font-size: 0.8rem;
  margin-left: auto;
}

/* Screenshots */

.shot {
  margin: 0.9rem 0;
}

.shot img {
  display: block;
  max-width: 100%;
  height: auto;
  border-radius: var(--radius-small);
  border: 1px solid var(--line);
}

.shot figcaption {
  font-size: 0.82rem;
  color: var(--grey);
  margin-top: 0.4rem;
}

.shot-date {
  white-space: nowrap;
}

.shot-box {
  border: 2px dashed var(--beige);
  border-radius: var(--radius-small);
  background: repeating-linear-gradient(-45deg, var(--beige-soft), var(--beige-soft) 12px, #fbf7ee 12px, #fbf7ee 24px);
  padding: 1.5rem 1rem;
  text-align: center;
  color: var(--grey);
  font-size: 0.9rem;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.shot-box-label {
  font-weight: 700;
  color: var(--navy);
}

/* Media and download cards */

.media-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1rem 1.1rem;
  margin: 0.9rem 0;
  box-shadow: var(--shadow);
}

.step .media-card {
  box-shadow: none;
  background: var(--beige-soft);
  border-color: var(--beige);
}

.media-icon {
  flex: none;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--navy);
  color: var(--gold);
  font-size: 1.2rem;
}

.media-body {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.media-body .eyebrow {
  margin: 0;
}

.media-title {
  font-weight: 650;
}

/* Embedded video (files on the volume) */

.video-player {
  margin: 0.9rem 0;
  background: var(--navy);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.video-player video {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
}

.video-player figcaption {
  padding: 0.6rem 1rem;
  color: var(--white);
  font-size: 0.9rem;
  font-weight: 600;
}

/* Optional entries (Zusatzübung) */

.badge-optional {
  background: var(--beige-soft);
  border-color: var(--beige);
  color: var(--navy);
}

.list-heading {
  font-size: 1.05rem;
  margin: 2rem 0 0.75rem;
}

.module-item.module-optional .module-num {
  background: transparent;
  border: 1.5px dashed var(--grey);
  color: var(--grey);
}

.module-item.module-optional.state-done .module-num {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--navy);
}

.next-extra {
  margin: 0.5rem 0 1rem;
}

/* Admin media upload */

.media-upload {
  display: grid;
  grid-template-columns: 1.5fr 2fr auto;
  gap: 0.8rem;
  align-items: end;
}

@media (max-width: 640px) {
  .media-upload {
    grid-template-columns: 1fr;
  }
}

/* Author notes (admins only) */

.author-note {
  background: var(--note);
  color: #5c4a00;
  font-size: 0.8rem;
  padding: 0.1rem 0.4rem;
  border-radius: 4px;
}

.author-note.block {
  display: block;
  border-left: 4px solid var(--note-line);
  padding: 0.75rem 1rem;
  margin: 0.9rem 0;
  font-size: 0.85rem;
}

.author-note.block > :last-child {
  margin-bottom: 0;
}

.author-note-label {
  display: block;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: 0.7rem;
  margin-bottom: 0.3rem;
}

/* Questions */

.question-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.question {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.25rem 1.35rem;
  box-shadow: var(--shadow);
  scroll-margin-top: 1rem;
}

.question-text {
  font-weight: 650;
  font-size: 1.08rem;
}

.choice-form {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  align-items: stretch;
}

.choice-form .button {
  align-self: flex-start;
  margin-top: 0.4rem;
}

.option {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  padding: 0.7rem 0.85rem;
  border: 1.5px solid var(--line);
  border-radius: var(--radius-small);
  background: var(--white);
}

label.option {
  cursor: pointer;
}

label.option:hover {
  border-color: var(--gold);
}

label.option:has(input:checked) {
  border-color: var(--navy);
  background: var(--beige-soft);
}

.option input {
  flex: none;
  width: 1.2rem;
  height: 1.2rem;
  margin: 0.2rem 0 0;
  accent-color: var(--navy);
}

.options-answered {
  list-style: none;
  padding: 0;
  margin: 0 0 0.9rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.options-answered .option {
  color: var(--grey);
}

.options-answered .option.correct {
  border-color: var(--good);
  color: var(--navy);
}

.options-answered .option.wrong {
  border-color: var(--bad);
  color: var(--navy);
}

.option-mark {
  flex: none;
  width: 1.2rem;
  font-weight: 700;
  text-align: center;
}

.option.correct .option-mark {
  color: var(--good);
}

.option.wrong .option-mark {
  color: var(--bad);
}

.chosen-label {
  margin-left: auto;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--grey);
  white-space: nowrap;
  padding-left: 0.5rem;
}

.feedback {
  border-radius: var(--radius-small);
  padding: 0.8rem 1rem;
}

.feedback-good {
  background: var(--good-soft);
}

.feedback-good strong {
  color: var(--good);
}

.feedback-bad {
  background: var(--bad-soft);
}

.feedback-bad strong {
  color: var(--bad);
}

.saved {
  font-size: 0.85rem;
  color: var(--good);
}

/* Next card */

.next-card {
  background: var(--navy);
  color: var(--white);
  border-radius: var(--radius);
  padding: 1.4rem 1.5rem;
  margin-bottom: 1rem;
}

.next-card .eyebrow {
  color: var(--gold);
}

.next-card .muted,
.next-card .hint {
  color: #b9c3cc;
}

.next-title {
  font-size: 1.2rem;
  font-weight: 650;
  margin-bottom: 1rem;
}

.next-card .button:not(.primary) {
  background: transparent;
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.6);
}

.next-card .hint {
  margin: 1rem 0 0;
}

.next {
  scroll-margin-top: 1rem;
}

/* Admin */

.tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
  border-bottom: 2px solid var(--line);
  margin-bottom: 1.5rem;
}

.tabs a {
  padding: 0.55rem 1rem;
  text-decoration: none;
  font-weight: 600;
  color: var(--grey);
  border-bottom: 3px solid transparent;
  margin-bottom: -2px;
}

.tabs a.active {
  color: var(--navy);
  border-bottom-color: var(--gold);
}

.invite-form {
  display: grid;
  grid-template-columns: 2fr 1.3fr 1.3fr auto;
  gap: 0.8rem;
  align-items: end;
}

.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.8rem 1.2rem;
  margin: 1.75rem 0 0.9rem;
}

.card .section-head {
  margin-top: 0;
}

.section-head h2 {
  margin: 0;
  margin-right: auto;
}

.group-filter {
  margin: 0;
}

.group-filter label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  font-weight: 600;
}

.group-filter select {
  width: auto;
  padding: 0.4rem 0.6rem;
}

.table-wrap {
  overflow-x: auto;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-small);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

th,
td {
  text-align: left;
  padding: 0.6rem 0.75rem;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}

th {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--grey);
  background: #faf8f3;
  white-space: nowrap;
}

tr:last-child td {
  border-bottom: 0;
}

tr.inactive td {
  color: var(--grey);
}

td.center,
th.center {
  text-align: center;
}

.state-dot {
  display: inline-grid;
  place-items: center;
  width: 1.6rem;
  height: 1.6rem;
  border-radius: 50%;
  font-weight: 700;
  font-size: 0.85rem;
}

.state-dot.state-done {
  background: var(--good-soft);
  color: var(--good);
}

.state-dot.state-started {
  background: var(--gold-soft);
  color: var(--gold-text);
}

.state-dot.state-open {
  color: #b4b0a6;
}

.answer-text {
  white-space: pre-wrap;
}

.verdict {
  font-weight: 600;
  font-size: 0.85rem;
  margin-left: 0.5rem;
  white-space: nowrap;
}

.verdict.good {
  color: var(--good);
}

.verdict.bad {
  color: var(--bad);
}

.facts {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 2rem;
  margin: 0 0 1.25rem;
}

.facts dt {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--grey);
  font-weight: 600;
}

.facts dd {
  margin: 0;
}

.answer-list {
  margin: 0.75rem 0 0;
}

.answer-list > div {
  padding: 0.7rem 0;
  border-top: 1px solid var(--line);
}

.answer-list dt {
  font-weight: 600;
  margin-bottom: 0.2rem;
}

.answer-list dd {
  margin: 0;
}

.question-block + .question-block {
  margin-top: 1.5rem;
}

.question-block h3 {
  margin-bottom: 0.2rem;
}

.danger-zone {
  border-color: var(--bad-soft);
  margin-top: 2rem;
}

.mail h2 {
  font-size: 1.1rem;
}

.mail-text p {
  margin: 0;
  font-size: 0.95rem;
  overflow-wrap: anywhere;
}

/* Content pages (Datenschutz) */

.page h2 {
  margin-top: 2rem;
  font-size: 1.2rem;
}

.privacy-note {
  margin-top: 1.25rem;
}

.site-footer a {
  color: var(--grey);
}

/* Onboarding */

.lead {
  font-size: 1.25rem;
  font-weight: 600;
}

.interview-meta {
  font-weight: 650;
}

.event-line {
  display: inline-block;
  margin: 0 0 1.25rem;
  padding: 0.35rem 0.75rem;
  background: var(--gold-soft);
  border-radius: 999px;
  font-weight: 650;
}

.optional-card {
  margin: 1.5rem 0;
  border-style: dashed;
  background: transparent;
}

.optional-card p {
  margin-bottom: 1rem;
}

.mic-test {
  margin: 1.25rem 0 0.5rem;
}

.mic-meter {
  height: 10px;
  max-width: 16rem;
  margin: 0.7rem 0;
  background: var(--beige);
  border-radius: 999px;
  overflow: hidden;
}

.mic-meter-fill {
  height: 100%;
  width: 0%;
  background: var(--gold);
  border-radius: 999px;
}

.mic-status:empty {
  display: none;
}

.turns {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  margin-top: 0.4rem;
}

.turn {
  border-radius: var(--radius-small);
  padding: 0.55rem 0.75rem;
  background: var(--beige-soft);
}

.turn-assistant {
  background: var(--white);
  border: 1px solid var(--line);
}

.turn-speaker {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--grey);
  margin-bottom: 0.15rem;
}

.turn-text,
.transcript-plain {
  white-space: pre-wrap;
  margin: 0;
}

.session-block + .session-block {
  margin-top: 1.25rem;
  padding-top: 1rem;
  border-top: 1px solid var(--line);
}

/* Small screens */

@media (max-width: 640px) {
  body {
    font-size: 16px;
  }

  .container {
    padding-top: 1.25rem;
  }

  .site-nav {
    gap: 0.8rem;
    font-size: 0.9rem;
  }

  .brand-product {
    display: none;
  }

  .step,
  .question,
  .card,
  .concept {
    padding: 1rem;
  }

  .media-card {
    flex-wrap: wrap;
  }

  .media-card .button {
    width: 100%;
  }

  .invite-form {
    grid-template-columns: 1fr;
  }

  .options-answered .option {
    flex-wrap: wrap;
  }

  .chosen-label {
    order: -1;
    width: 100%;
    margin: 0 0 0.1rem 1.85rem;
    padding-left: 0;
  }

  /* Keep the ✓/✗ mark and the answer text on one line under the label. */
  .options-answered .option > span:not(.option-mark):not(.chosen-label) {
    flex: 1 1 0;
    min-width: 0;
  }

  .button.large {
    width: 100%;
  }

  .auth-card {
    margin: 0.5rem auto;
    padding: 1.5rem 1.25rem;
  }
}


/* Module page: sticky table of contents on wide screens */

.toc {
  display: none;
}

.toc-title {
  margin: 0 0 0.6rem;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold-text);
}

.toc-list,
.toc-steps {
  list-style: none;
  margin: 0;
  padding: 0;
}

.toc-steps {
  margin: 0.1rem 0 0.5rem 0.95rem;
  padding-left: 0.2rem;
  border-left: 2px solid var(--beige);
}

.toc-item > a {
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
  padding: 0.3rem 0.5rem;
  border-radius: 6px;
  font-size: 0.9rem;
  line-height: 1.35;
  color: var(--grey);
  text-decoration: none;
}

.toc-item > a:hover {
  background: var(--beige-soft);
  color: var(--navy);
}

.toc-part > a {
  font-weight: 650;
  color: var(--navy);
}

.toc-item.is-current > a {
  background: var(--beige-soft);
  color: var(--navy);
}

.toc-mark {
  flex: none;
  width: 1rem;
  height: 1rem;
  margin-top: 0.12rem;
  border-radius: 50%;
  border: 1.5px solid #9aa6b2;
  background-position: center;
  background-repeat: no-repeat;
  background-size: 0.7rem;
}

.toc-done .toc-mark {
  border-color: var(--gold);
  background-color: var(--gold);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M4.5 10.5l3.5 3.5 7.5-8' fill='none' stroke='%230d1f2d' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}

@media (min-width: 1000px) {
  .module-layout {
    display: grid;
    grid-template-columns: 250px minmax(0, 760px);
    gap: 3rem;
    justify-content: center;
    align-items: start;
  }

  .toc {
    display: block;
    position: sticky;
    top: calc(var(--header-h) + 1.5rem);
    max-height: calc(100vh - var(--header-h) - 3rem);
    overflow-y: auto;
    padding-top: 0.4rem;
  }
}

/* Completion card: shown at the top of «Wie weiter» once the module is done */

.completion-card {
  border: 2px solid var(--gold);
  background: linear-gradient(180deg, #15293a 0%, var(--navy) 100%);
}

.completion-head {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.1rem;
}

.completion-check {
  flex: none;
  display: grid;
  place-items: center;
  width: 3.4rem;
  height: 3.4rem;
  border-radius: 50%;
  background: var(--gold);
  color: var(--navy);
}

.completion-check svg {
  width: 2rem;
  height: 2rem;
}

.completion-title {
  margin: 0;
  font-size: 1.5rem;
  color: var(--white);
}

.completion-thanks {
  margin: 0;
  color: #d4dbe2;
}

.completion-parts {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem 1rem;
  border: 1px solid rgba(197, 169, 90, 0.4);
  border-radius: var(--radius-small);
  background: rgba(197, 169, 90, 0.1);
}

.completion-parts p {
  margin: 0;
  font-weight: 600;
  color: var(--gold-soft);
}

.completion-rule {
  border: 0;
  border-top: 1px solid rgba(255, 255, 255, 0.18);
  margin: 1.2rem 0;
}

@media (prefers-reduced-motion: no-preference) {
  .completion-card {
    animation: completion-rise 0.45s ease-out both;
  }

  .completion-check {
    animation: completion-pop 0.6s cubic-bezier(0.2, 1.4, 0.4, 1) 0.15s both;
  }

  .rb-part *,
  .legend-dot {
    transition: stroke 0.4s ease, fill 0.4s ease;
  }
}

@keyframes completion-rise {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
}

@keyframes completion-pop {
  from {
    opacity: 0;
    transform: scale(0.4);
  }
}

/* Compact sticky header on narrow screens */

@media (max-width: 719px) {
  .site-header-inner {
    padding: 0.5rem 0.75rem;
    gap: 0.5rem;
  }

  .header-tools {
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 0.2rem 0.75rem;
  }

  .site-nav {
    gap: 0.65rem;
    font-size: 0.85rem;
    flex-wrap: wrap;
    justify-content: flex-end;
  }

  .brand img {
    height: 20px;
  }
}

@media print {
  .site-header {
    position: static;
    box-shadow: none;
  }

  .header-progress,
  .toc,
  .side-cta,
  .view-switch,
  .path-card-tools {
    display: none;
  }

  .module-layout,
  .path-layout,
  .path-hero {
    display: block;
  }

  .cover {
    display: none;
  }

  .side-card,
  .completion-card {
    background: none;
    color: inherit;
    border: 1px solid #999;
  }
}

/* Admin: «Arbeitsalltag: Gruppe» */
.aa-admin-heat {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
}
.aa-admin-q {
  border-radius: 12px;
  padding: 0.75rem 1rem;
  background: var(--cream);
}
.aa-admin-q-abgeben,
.aa-admin-q-entlasten {
  background: var(--beige-soft);
}
.aa-admin-q h3 {
  margin: 0 0 0.4rem;
  font-size: 1rem;
}
.aa-admin-q ul {
  margin: 0;
  padding-left: 1.1rem;
}
.aa-admin-two {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}
.aa-admin-bars {
  list-style: none;
  padding: 0;
  margin: 0 0 0.5rem;
  display: grid;
  gap: 0.3rem;
}
.aa-admin-bars li {
  display: grid;
  grid-template-columns: 11rem 1fr 2rem;
  gap: 0.5rem;
  align-items: center;
  font-size: 0.9rem;
}
.aa-admin-bar {
  display: block;
  height: 10px;
  min-width: 2px;
  border-radius: 5px;
  background: var(--gold);
}
@media (max-width: 719px) {
  .aa-admin-heat,
  .aa-admin-two {
    grid-template-columns: 1fr;
  }
}

/* Read aloud (Vorlesen): play button per heading, «Modul vorlesen» bar with speed choice, highlight of the block being read */

.heading-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 0 0 0.5em;
}

.heading-row > h1,
.heading-row > h2 {
  margin: 0;
  min-width: 0;
}

.part > .heading-row {
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--beige);
  margin-bottom: 1.1rem;
}

.listen {
  flex: none;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 50%;
  border: 1.5px solid var(--navy);
  background: var(--white);
  color: var(--navy);
  display: inline-grid;
  place-items: center;
  padding: 0;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.step-head .listen {
  margin-left: auto;
}

/* 44px touch target without making the button look big */
@media (pointer: coarse) {
  .listen {
    width: 2.75rem;
    height: 2.75rem;
  }
}

.listen:hover {
  background: var(--beige-soft);
}

.listen[aria-pressed="true"] {
  background: var(--navy);
  color: var(--white);
}

.listen svg,
.listen-all svg {
  width: 1.1rem;
  height: 1.1rem;
  fill: currentColor;
}

.listen-pause {
  display: none;
}

[aria-pressed="true"] > .listen-pause {
  display: block;
}

[aria-pressed="true"] > .listen-play {
  display: none;
}

.listen-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem 1rem;
  margin: 0 0 1.5rem;
  padding: 0.5rem 0.75rem;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

/* Once reading has started the bar stays in view, just below the sticky header. */
.listen-bar.is-active {
  position: sticky;
  top: calc(var(--header-h) + 0.5rem);
  z-index: 40;
  box-shadow: var(--shadow);
}

.listen-speeds {
  display: inline-flex;
  gap: 0.25rem;
}

.listen-speed {
  min-height: 36px;
  min-width: 2.6rem;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  border: 1.5px solid var(--line);
  background: var(--white);
  color: var(--navy);
  font: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
}

.listen-skip[hidden] {
  display: none;
}

.listen-speed:hover {
  background: var(--beige-soft);
}

.listen-speed[aria-pressed="true"] {
  background: var(--gold-soft);
  border-color: var(--gold);
}

.listen-status {
  font-size: 0.85rem;
  color: var(--grey);
}

.is-reading {
  background: var(--gold-soft);
  box-shadow: 0 0 0 0.4rem var(--gold-soft);
  border-radius: 6px;
}

.step.is-reading {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px var(--gold), var(--shadow);
}

@media (max-width: 719px) {
  /* One compact row while reading: pause and speed. The progress text stays for screen readers. */
  .listen-bar {
    gap: 0.4rem 0.6rem;
    padding: 0.4rem 0.5rem;
  }

  .listen-bar.is-active .listen-status {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
  }

  .listen-speeds {
    gap: 0.2rem;
  }

  .listen-speed {
    min-width: 2.35rem;
    padding: 0.2rem 0.4rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .listen {
    transition: none;
  }
}

@media print {
  .listen,
  .listen-bar {
    display: none;
  }
}

.group-paths-form {
  display: grid;
  gap: 0.9rem;
}

.group-paths-list {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0.6rem 1rem 0.9rem;
  display: grid;
  gap: 0.5rem;
}

.group-path-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.group-path-pos {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.group-path-pos input {
  width: 4.5rem;
}

.group-workshop {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0.6rem 1rem;
}

.group-workshop summary {
  cursor: pointer;
  font-weight: 600;
}

.group-workshop[open] summary {
  margin-bottom: 0.8rem;
}

.invite-form-group {
  grid-template-columns: 2fr 1.3fr auto;
}

@media (max-width: 640px) {
  .invite-form-group {
    grid-template-columns: 1fr;
  }
}

.field input[type="number"] {
  font: inherit;
  font-weight: 400;
  color: var(--navy);
  background: var(--white);
  border: 1.5px solid var(--line);
  border-radius: var(--radius-small);
  padding: 0.65rem 0.8rem;
  width: 100%;
}

.group-path-pos {
  gap: 0.6rem;
}

.group-path-row label:first-child {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.container > section + section.card,
.container > section + section {
  margin-top: 1.5rem;
}

.group-block {
  margin: 1.5rem 0;
}

.mail-preview {
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  padding: 0.8rem 1rem;
  background: var(--white);
}

textarea[name="body"] {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.9rem;
  line-height: 1.5;
}

.pp {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin: 0.5rem 0;
}

.pp-col {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0.6rem 0.8rem 0.8rem;
  min-height: 7rem;
}

.pp-head {
  margin: 0 0 0.5rem;
  font-size: 1rem;
}

.pp-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.4rem;
}

.pp .pp-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 0.5rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-small);
  background: var(--white);
}

.pp-selected {
  border-color: var(--gold);
}

.pp-dragging {
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.18);
  opacity: 0.9;
}

.pp .pp-handle {
  cursor: grab;
  touch-action: none;
  user-select: none;
  padding: 0.3rem 0.4rem;
  color: var(--grey);
  letter-spacing: -0.15em;
  font-weight: 700;
}

.pp-n {
  min-width: 1.4rem;
  font-weight: 700;
  color: var(--navy);
}

.pp-title {
  flex: 1;
  min-width: 0;
}

.pp-btn {
  font: inherit;
  font-size: 0.9rem;
  min-width: 2.2rem;
  min-height: 2.2rem;
  padding: 0 0.5rem;
  border: 1.5px solid var(--line);
  border-radius: var(--radius-small);
  background: var(--white);
  color: var(--navy);
  cursor: pointer;
}

.pp-btn:disabled {
  opacity: 0.35;
  cursor: default;
}

.pp-item:not(.pp-selected) .pp-up,
.pp-item:not(.pp-selected) .pp-down,
.pp-item:not(.pp-selected) .pp-remove,
.pp-item.pp-selected .pp-add,
.pp-item:not(.pp-selected) .pp-n {
  display: none;
}

.pp-item:not(.pp-selected) .pp-add {
  display: inline-block;
}

@media (max-width: 640px) {
  .pp {
    grid-template-columns: 1fr;
  }

  .pp-item {
    flex-wrap: wrap;
  }

  .pp-title {
    flex-basis: 40%;
  }
}

.path-section-head {
  margin: 0 0 0.3rem;
  font-size: 1rem;
}

.group-paths-list[hidden] {
  display: none;
}

/* The boundary between paths: completed work above a gold rule, the next starting point below. */
.learning-location { display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; justify-content: space-between; font-size: .85rem; color: var(--grey); margin: -.5rem 0 1.5rem; }
.path-handoff { padding: clamp(1.25rem, 3vw, 2rem); border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); color: var(--navy); margin: 1.5rem 0; }
.path-handoff-finished { display: flex; align-items: flex-start; gap: 1rem; }
.path-handoff-finished h2 { font-size: 1.15rem; margin: .25rem 0; }
.path-handoff-finished p { margin: .25rem 0; }
.path-handoff .eyebrow, .path-arrival .eyebrow { color: var(--gold-text); }
.journey-check { color: var(--good); font-size: 1.5rem; line-height: 1.4; }
.path-handoff-next { border-top: 2px solid var(--gold); margin-top: 1.25rem; padding-top: 1.25rem; }
.path-handoff-next h3 { font-size: clamp(1.35rem, 3vw, 1.7rem); margin: .3rem 0 .6rem; }
.path-handoff .handoff-overview { display: inline-block; margin: .75rem 0 .75rem 1rem; }
.path-handoff-home { font-size: .85rem; color: var(--grey); margin: 1.25rem 0 0; }
.path-arrival { border-left: 4px solid var(--gold); background: var(--beige-soft); padding: 1rem 1.25rem; margin-bottom: 2rem; border-radius: 0 var(--radius-small) var(--radius-small) 0; }
.path-arrival h2 { margin: .25rem 0; font-size: 1.35rem; }
.path-arrival p { margin: .4rem 0; }
.path-arrival a { font-size: .9rem; }
@media (max-width: 600px) {
  .path-handoff .button { display: block; width: 100%; text-align: center; white-space: normal; }
  .path-handoff .handoff-overview { display: block; margin: 1rem 0; }
}

/* Link from a module to its 3D room (room.yaml). */
.room-cta {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 4px 0 22px;
  padding: 14px 18px;
  border-radius: 16px;
  background: var(--navy);
  color: var(--white);
  text-decoration: none;
  box-shadow: 0 8px 22px rgba(13, 31, 45, 0.14);
}
.room-cta:hover { background: var(--navy-2); }
.room-cta:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }
.room-cta-icon {
  flex: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--gold);
  color: var(--navy);
  font-size: 18px;
}
.room-cta-text { flex: 1; display: grid; gap: 2px; }
.room-cta-text small { color: var(--beige); font-size: 14px; line-height: 1.35; }
.room-cta-arrow { color: var(--gold); font-size: 22px; font-weight: 700; }

/* Admin «Ansicht als»: a loud strip in the sticky header, in a colour the learner pages never use, so it is never mistaken for the normal view. */
.view-as-bar {
  background: var(--purple);
  color: var(--navy);
  border-bottom: 2px solid var(--navy);
  font-size: 0.92rem;
}
.view-as-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  flex-wrap: wrap;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0.4rem 1rem;
}
.view-as-note {
  color: var(--navy-2);
}
.view-as-exit {
  background: var(--navy);
  color: var(--white);
  border-color: var(--navy);
}
.inline-form {
  display: inline;
  margin: 0;
}
.view-as-picker select {
  min-width: min(28rem, 100%);
}
.view-as-cell {
  margin-top: 0.35rem;
}
.inline-form .button {
  white-space: nowrap;
}

/* Module page, short view (src/views/module-view.tsx, public/module-view.js): video, one goal sentence and the steps;
   the rest sits behind buttons. Phone first: chips and a bottom bar; from 700px a top bar and side column; from 1000px two columns. */

.mv {
  --mv-radius: 16px;
}

.mv-top {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.mv-back {
  flex: none;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--white);
  border: 1px solid var(--line);
  color: var(--navy);
  text-decoration: none;
}

.mv-back:hover {
  background: var(--beige-soft);
}

.mv-back-text {
  display: none;
}

.mv-pos {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.mv-pos-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--grey);
  line-height: 1.2;
}

.mv-track {
  display: block;
  height: 6px;
  border-radius: 3px;
  background: var(--line);
  overflow: hidden;
}

.mv-track-fill {
  display: block;
  height: 100%;
  background: var(--gold);
}

.mv-main {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  min-width: 0;
}

.mv-main > * {
  margin-top: 0;
  margin-bottom: 0;
}

.mv-main > .part,
.mv-main > .concept {
  margin-top: 1rem;
}

.mv-main .learning-location {
  margin: 0;
}

.mv-head {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  align-items: flex-start;
}

.mv-head h1 {
  margin: 0;
  font-size: 1.75rem;
  line-height: 1.15;
  letter-spacing: -0.01em;
}

.mv-meta {
  margin: 0;
  font-size: 0.9rem;
  color: var(--grey);
}

.mv .video-player {
  margin: 0;
  border-radius: 18px;
}

.mv .media-card {
  margin: 0;
}

.mv-goal {
  margin: 0;
  font-size: 1rem;
  line-height: 1.45;
}

/* Buttons that open text in place */

.mv-discs {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.mv-disc {
  display: contents;
}

.mv-toggle,
.mv-step-btn {
  font: inherit;
  cursor: pointer;
  color: var(--navy);
  text-align: left;
}

.mv-toggle {
  min-height: 48px;
  padding: 0 14px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: var(--white);
  font-size: 0.95rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.mv-toggle:hover,
.mv-step-btn:hover {
  background: var(--beige-soft);
}

.mv-chevron {
  flex: none;
  transition: transform 0.15s ease;
}

[aria-expanded="true"] > .mv-chevron {
  transform: rotate(180deg);
}

.mv-panel {
  padding: 0.25rem 14px 0.5rem;
  font-size: 0.92rem;
  line-height: 1.5;
  color: var(--navy-2);
}

.mv-panel > * + *,
.mv-step-body > * + * {
  margin-top: 0.85rem;
}

.mv-panel .prose p {
  margin: 0.5rem 0;
}

.mv-panel-listen {
  display: flex;
  justify-content: flex-end;
}

/* Part chips (phone) */

.mv-chips {
  display: none;
}

.mv-chip {
  flex: none;
  min-height: 44px;
  padding: 0 16px;
  border-radius: 22px;
  border: 1px solid var(--beige);
  background: var(--white);
  color: var(--navy);
  font: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  white-space: nowrap;
  cursor: pointer;
}

.mv-chip[aria-pressed="true"] {
  background: var(--navy);
  border-color: var(--navy);
  color: var(--white);
}

/* Parts and steps */

.mv-stepper {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.mv-part {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.mv-part-head {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.mv-part-title {
  margin: 0;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--gold-text);
}

.mv-part-lead {
  font-size: 0.95rem;
  color: var(--navy-2);
}

.mv-steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.mv-step {
  border-radius: var(--mv-radius);
  background: var(--white);
  border: 1px solid var(--line);
  overflow: hidden;
}

.mv-step.is-open {
  border-color: var(--navy);
  box-shadow: 0 0 0 1px var(--navy);
}

.mv-step-h {
  margin: 0;
  font-size: inherit;
}

.mv-step-btn {
  width: 100%;
  min-height: 60px;
  padding: 10px 14px;
  border: 0;
  background: var(--white);
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.mv-step-title {
  flex: 1;
  min-width: 0;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.3;
}

.mv-step-mark {
  flex: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1.5px solid var(--navy);
  display: grid;
  place-items: center;
  font-size: 0.875rem;
  font-weight: 700;
}

.mv-step-check {
  display: none;
}

.mv-step.is-done .mv-step-mark {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--navy);
}

.mv-step.is-done .mv-step-num {
  display: none;
}

.mv-step.is-done .mv-step-check {
  display: grid;
}

.mv-step-body {
  padding: 0 14px 14px;
  font-size: 0.95rem;
  line-height: 1.5;
}

.mv-step-body .prose {
  color: var(--navy-2);
}

.mv-step-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.mv-mark {
  min-height: 44px;
  padding: 0 22px;
  border-radius: 12px;
  border: 0;
  background: var(--navy);
  color: var(--white);
  font: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
}

.mv-mark:hover {
  background: var(--navy-2);
}

.mv-mark[hidden] {
  display: none;
}

.mv-mark-undo {
  background: var(--white);
  color: var(--navy);
  border: 1px solid var(--beige);
}

.mv-mark-undo:hover {
  background: var(--beige-soft);
}

/* Side column and bottom bar */

.mv-side {
  display: none;
}

.mv-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 1.1rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.mv-card-title {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
}

.mv-side-total {
  margin: 0;
  font-size: 0.85rem;
  color: var(--grey);
}

.mv-side-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.mv-side-item > a {
  min-height: 44px;
  padding: 6px 12px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  font-size: 0.92rem;
  font-weight: 500;
  line-height: 1.3;
  text-decoration: none;
  color: var(--navy);
}

.mv-side-item > a:hover {
  background: var(--beige-soft);
}

.mv-side-item.is-current > a {
  background: var(--navy);
  color: var(--white);
  font-weight: 600;
}

.mv-count {
  flex: none;
  font-size: 0.85rem;
  color: var(--grey);
  white-space: nowrap;
}

.mv-side-item.is-current .mv-count {
  color: #d4dbe2;
}

.mv-side-mark {
  flex: none;
  width: 1rem;
  height: 1rem;
  margin-right: -0.2rem;
  border-radius: 50%;
  border: 1.5px solid #9aa6b2;
}

.mv-side-item > a:has(.mv-side-mark) {
  justify-content: flex-start;
}

.mv-side-item.is-done .mv-side-mark {
  border-color: var(--gold);
  background-color: var(--gold);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M4.5 10.5l3.5 3.5 7.5-8' fill='none' stroke='%230d1f2d' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-position: center;
  background-repeat: no-repeat;
  background-size: 0.7rem;
}

.mv-card-dark {
  background: var(--navy);
  border-color: var(--navy);
  color: var(--white);
}

.mv-tags {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.mv-tags li {
  padding: 6px 12px;
  border-radius: 16px;
  background: var(--navy-2);
  font-size: 0.875rem;
  font-weight: 600;
}

.mv-bar {
  display: none;
}

.mv-bar-text {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.mv-bar-label {
  font-size: 0.8rem;
  color: var(--grey);
}

.mv-next {
  min-height: 48px;
  padding: 0 22px;
  border-radius: 24px;
  border: 0;
  background: var(--gold);
  color: var(--navy);
  font: inherit;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
}

/* Phone */
@media (max-width: 699px) {
  .mv-js .mv-chips {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 2px;
    scrollbar-width: thin;
  }

  .mv-js .mv-part.is-off {
    display: none;
  }

  .mv-js .mv-has-steps {
    padding-bottom: 5.5rem;
  }

  .mv-js .mv-bar {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 20;
    padding: 12px 16px calc(14px + env(safe-area-inset-bottom));
    background: var(--white);
    border-top: 1px solid var(--line);
  }
}

/* Tablet and up: the top bar is a card, the buttons are pills, the side column shows (under the content until 1000px) */
@media (min-width: 700px) {
  .mv-top {
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: var(--mv-radius);
    padding: 0.35rem 1rem;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 1.75rem;
  }

  .mv-back {
    width: auto;
    height: auto;
    min-height: 44px;
    border: 0;
    border-radius: 12px;
    background: transparent;
    padding: 0 0.5rem 0 0;
    gap: 0.4rem;
    display: flex;
    align-items: center;
    font-weight: 600;
  }

  .mv-back-text {
    display: inline;
    font-size: 0.95rem;
  }

  span.mv-back-text {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    font-weight: 600;
  }

  .mv-pos {
    flex: 1 1 200px;
    flex-direction: row-reverse;
    align-items: center;
    gap: 0.75rem;
  }

  .mv-pos-label {
    font-size: 0.9rem;
    white-space: nowrap;
  }

  .mv-track {
    flex: 1;
  }

  .mv-main {
    gap: 1.25rem;
  }

  .mv-head h1 {
    font-size: 2.25rem;
    letter-spacing: -0.02em;
  }

  .mv-meta {
    font-size: 1rem;
  }

  .mv .video-player {
    border-radius: 22px;
  }

  .mv-goal {
    font-size: 1.15rem;
    max-width: 40rem;
  }

  .mv-discs {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 0.6rem;
  }

  .mv-disc {
    display: contents;
  }

  .mv-toggle {
    min-height: 44px;
    padding: 0 16px;
    border-radius: 22px;
    border-color: var(--beige);
    font-size: 0.95rem;
    gap: 0.5rem;
  }

  .mv-panel {
    flex: 0 0 100%;
    max-width: 44rem;
    font-size: 0.97rem;
  }

  .mv-step-btn {
    padding: 12px 20px;
    gap: 1rem;
  }

  .mv-step-title {
    font-size: 1.1rem;
  }

  .mv-step-mark {
    width: 36px;
    height: 36px;
    font-size: 0.95rem;
  }

  .mv-step-body {
    padding: 0 20px 20px 72px;
    font-size: 1rem;
  }

  .mv-mark {
    border-radius: 22px;
  }

  .mv-side {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 2rem;
  }
}

@media (min-width: 1000px) {
  .mv-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: 2rem;
    align-items: start;
  }

  .mv-side {
    margin-top: 0;
    position: sticky;
    top: calc(var(--header-h) + 1.5rem);
  }
}

/* Without JavaScript everything shows, open: the buttons are plain headings. */
html:not(.mv-js) .mv-panel[hidden],
html:not(.mv-js) .mv-step-body[hidden] {
  display: block;
}

html:not(.mv-js) .mv-toggle {
  pointer-events: none;
}

html:not(.mv-js) .mv-chevron,
html:not(.mv-js) .mv-step-actions {
  display: none;
}

@media print {
  .mv-bar,
  .mv-chips,
  .mv-chevron,
  .mv-step-actions {
    display: none !important;
  }

  .mv-panel[hidden],
  .mv-step-body[hidden] {
    display: block !important;
  }

  .mv-part.is-off {
    display: flex !important;
  }
}

/* Listen («Anhören»): one control next to the title, a small listen button per step and opened block, one clearly marked block at a time */

.mv-title-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem 1rem;
}

.listen-seq {
  position: relative;
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
}

.listen-main,
.listen-speed-toggle {
  min-height: 44px;
  font: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  border: 1.5px solid var(--navy);
}

.listen-main {
  padding: 0 16px 0 14px;
  border-radius: 22px 0 0 22px;
  background: var(--navy);
  color: var(--white);
}

.listen-main:hover {
  background: var(--navy-2);
}

.listen-main svg {
  width: 1.1rem;
  height: 1.1rem;
  fill: currentColor;
}

.listen-main.is-running {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--navy);
}

.listen-speed-toggle {
  padding: 0 12px;
  border-radius: 0 22px 22px 0;
  border-left: 0;
  background: var(--white);
  color: var(--navy);
  font-size: 0.85rem;
}

.listen-speed-toggle:hover {
  background: var(--beige-soft);
}

.listen-speed-menu {
  position: absolute;
  z-index: 30;
  top: calc(100% + 6px);
  right: 0;
  min-width: 9rem;
  padding: 6px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: 0 8px 24px rgba(13, 31, 45, 0.16);
}

.listen-speed-menu[hidden] {
  display: none;
}

.listen-speed-choice {
  min-height: 44px;
  padding: 0 12px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--navy);
  font: inherit;
  font-size: 0.95rem;
  text-align: left;
  cursor: pointer;
}

.listen-speed-choice:hover {
  background: var(--beige-soft);
}

.listen-speed-choice[aria-pressed="true"] {
  background: var(--navy);
  color: var(--white);
  font-weight: 600;
}

.listen-hint {
  flex-basis: 100%;
  margin: 0.5rem 0 0;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--navy);
}

.listen-hint[hidden] {
  display: none;
}

.mv-step-head {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.mv-step-head > .mv-step-h {
  flex: 1;
  min-width: 0;
}

.mv-step-head > .listen {
  width: 44px;
  height: 44px;
  margin-right: 10px;
}

.mv-panel-listen .listen {
  width: 44px;
  height: 44px;
}

.mv-part-head .listen {
  width: 44px;
  height: 44px;
}

.mv-goal {
  padding: 0.6rem 0.8rem;
  margin: -0.6rem -0.8rem;
}

/* The block being read: gold ground and a ring, stronger than the beige of the long layout. */
.mv .is-reading {
  background: var(--gold-soft);
  box-shadow: 0 0 0 4px var(--gold);
  border-radius: var(--mv-radius);
}

.mv .mv-step.is-reading .mv-step-btn {
  background: transparent;
}

.mv .video-player.is-reading {
  background: var(--navy);
  box-shadow: 0 0 0 5px var(--gold);
}

.mv .mv-part-head.is-reading,
.mv .mv-part-lead.is-reading {
  border-radius: 8px;
}

@media print {
  .listen-seq {
    display: none;
  }
}
