/* ==========================================================================
   educis.de: Nachbau der Anwendung educis Flow (Produktseite)
   ERZEUGT aus _build/demo/appdemo.css durch node _build/flow.mjs. Nicht von
   Hand ändern. Die Quelle beschreibt: node _build/flow.mjs schreibt assets/appdemo.css
   und setzt dabei jedem Selektor „.app“ voran: Kurze Klassennamen wie .panel
   oder .fchip gelten so nur in der Demo und nicht für die übrige Seite.
   flow.html lädt die erzeugte Datei nach home.css.

   Die Demo ist IMMER hell, auch wenn die Website dunkel dargestellt wird: Die
   Anwendung selbst kennt nur das helle Erscheinungsbild. Alle Farben stehen
   deshalb als eigene Werte auf .app und hängen nicht an den Tokens der Seite.
   Werte wie in educis-flow/src/app/globals.css (Violett #7c3aed, Radius 8px).

   Formsystem der Demo: Flächen 10px, Bedienelemente 8px, Marken 6px.
   ========================================================================== */
.appdemo {
  padding-block: var(--section);
}
.app {
  color-scheme: light;
  --f-bg: #f8f8fa;
  --f-card: #ffffff;
  --f-ink: #25232a;
  --f-text: #3f3c46;
  --f-muted: #6b6874;
  --f-line: #e8e6ed;
  --f-line-strong: #d5d2dc;
  --f-input: #8a8a93;
  --f-primary: #7c3aed;
  --f-primary-hover: #6d28d9;
  --f-soft: #f2edfb;
  --f-soft-line: #ddd0f8;
  --f-side: #fbfafd;
  --f-ok: #166534;
  --f-ok-soft: #e3f6e9;
  --f-warn: #92400e;
  --f-warn-soft: #fdf1d7;
  --f-danger: #b91c1c;
  --f-danger-soft: #fde8e8;
  --f-shadow: 0 1px 2px rgb(37 35 42 / 0.05), 0 10px 28px -14px rgb(76 29 149 / 0.22);
  --f-ease: cubic-bezier(0.22, 1, 0.36, 1);
  --f-spring: cubic-bezier(0.22, 1.2, 0.36, 1);

  position: relative;
  border: 1px solid rgb(15 23 42 / 0.14);
  border-radius: var(--r-lg);
  background: var(--f-bg);
  color: var(--f-text);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  font-size: 0.875rem;
  line-height: 1.45;
}
.app :where(h3, h4, h5, b, strong) {
  color: var(--f-ink);
}
.app :where(h5, fieldset, legend, dl, dt, dd, ol) {
  margin: 0;
}
.app :where(button, input, select, textarea) {
  font: inherit;
  color: inherit;
}
.app :where(button) {
  cursor: pointer;
}
.app :where(button:disabled) {
  cursor: not-allowed;
}
.app :where(button, input, select, textarea, a):focus-visible {
  outline: 2px solid var(--f-primary);
  outline-offset: 2px;
}
.app .ico--xs { width: 12px; height: 12px; }

/* ---------- Fensterleiste ---------- */
.app__chrome {
  display: flex;
  align-items: center;
  gap: 12px;
  height: 42px;
  padding: 0 14px;
  border-bottom: 1px solid var(--f-line);
  background: #f1f0f4;
}
.app__dots { display: flex; gap: 7px; }
.app__dots i {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: #d5d2dc;
}
.app__chrome p {
  padding: 3px 14px;
  border-radius: 999px;
  background: #fff;
  font-family: var(--mono);
  font-size: 0.74rem;
  color: var(--f-muted);
}
.app__chrome p b { font-weight: 500; }
.app__reset {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-left: auto;
  height: 28px;
  padding: 0 10px;
  border: 1px solid var(--f-line-strong);
  border-radius: 8px;
  background: #fff;
  font-size: 0.76rem;
  font-weight: 550;
  color: var(--f-text);
  transition: border-color 0.2s, color 0.2s, transform 0.2s var(--f-ease);
}
.app__reset:hover { border-color: var(--f-primary); color: var(--f-primary-hover); }
.app__reset:hover .ico { transform: rotate(-90deg); }
.app__reset .ico { transition: transform 0.4s var(--f-ease); }
.app__reset:active { transform: scale(0.97); }

/* ---------- Rahmen, Seitenleiste, Kopfzeile ---------- */
.app__frame {
  position: relative;
  display: grid;
  grid-template-columns: 15.5rem minmax(0, 1fr);
  height: 780px;
}
.app__side {
  display: flex;
  flex-direction: column;
  min-height: 0;
  border-right: 1px solid #ebe8f1;
  background: var(--f-side);
}
.app__brand {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 56px;
  flex: none;
  padding: 0 16px;
  border-bottom: 1px solid #ebe8f1;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--f-ink);
}
.app__nav {
  flex: 1;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 12px;
  display: grid;
  align-content: start;
  gap: 8px;
}
.app .ag { --g-head: #ede9fe; --g-ink: #4c1d95; --g-body: #f7f5ff; --g-on: #ddd6fe; }
.app .ag--emerald { --g-head: #d1fae5; --g-ink: #064e3b; --g-body: #f0fdf7; --g-on: #a7f3d0; }
.app .ag--sky { --g-head: #e0f2fe; --g-ink: #0c4a6e; --g-body: #f0f9ff; --g-on: #bae6fd; }
.app .ag--amber { --g-head: #fef3c7; --g-ink: #78350f; --g-body: #fffbeb; --g-on: #fde68a; }
.app .ag__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  height: 36px;
  padding: 0 12px;
  border: 0;
  border-radius: 8px;
  font-size: 0.75rem;
  font-weight: 600;
  background: var(--g-head);
  color: var(--g-ink);
  transition: border-radius 0.2s;
}
.app .ag__head[aria-expanded="true"] { border-radius: 8px 8px 0 0; }
.app .ag__chev { transition: transform 0.3s var(--f-ease); opacity: 0.7; }
.app .ag__head[aria-expanded="false"] .ag__chev { transform: rotate(-90deg); }
.app .ag__fold {
  display: grid;
  grid-template-rows: 1fr;
  transition: grid-template-rows 0.3s var(--f-ease);
}
.app .ag__fold[data-closed] { grid-template-rows: 0fr; }
.app .ag__list {
  min-height: 0;
  overflow: hidden;
  border-radius: 0 0 8px 8px;
  background: var(--g-body);
  display: grid;
  gap: 2px;
  padding: 5px;
  transition: padding 0.3s var(--f-ease), visibility 0.3s;
}
.app .ag__fold[data-closed] .ag__list { padding-block: 0; visibility: hidden; }
.app .ag__item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 36px;
  padding: 0 10px;
  border: 0;
  border-radius: 6px;
  background: none;
  font-size: 0.82rem;
  font-weight: 500;
  text-align: left;
  color: color-mix(in srgb, var(--g-ink) 82%, transparent);
  transition: background-color 0.2s, transform 0.2s var(--f-ease);
}
.app .ag__item .ico { opacity: 0.6; }
.app .ag__item:hover { background: color-mix(in srgb, var(--g-on) 55%, transparent); }
.app .ag__item:active { transform: scale(0.98); }
.app .ag__item[aria-current="page"] { background: var(--g-on); color: var(--g-ink); font-weight: 600; }
.app .ag__item[aria-current="page"] .ico { opacity: 1; }

.app__main {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
}
.app__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  height: 56px;
  flex: none;
  padding: 0 16px;
  border-bottom: 1px solid var(--f-line);
  background: var(--f-bg);
}
.app__school { font-weight: 500; color: var(--f-ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.app__tools { display: flex; align-items: center; gap: 6px; }
.app__bell {
  position: relative;
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 8px;
  background: none;
  color: var(--f-text);
}
.app__bell:hover { background: #f1f0f4; }
.app__bell i {
  position: absolute;
  top: 3px;
  right: 2px;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  border-radius: 999px;
  background: var(--f-primary);
  color: #fff;
  font-size: 0.64rem;
  font-style: normal;
  font-weight: 600;
  line-height: 16px;
  text-align: center;
}
.app__avatar {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--f-soft);
  color: var(--f-primary-hover);
  font-size: 0.74rem;
  font-weight: 600;
}
.app__content {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 24px 28px 32px;
  outline: none;
}
.app__bottom { display: none; }
.app .view { display: grid; gap: 16px; align-content: start; }
.app .view.is-entering { animation: demo-view-in 0.42s var(--f-ease); }
@keyframes demo-view-in {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}

/* ---------- Seitenkopf und Text ---------- */
.app .v-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}
.app .v-head > div:first-child { min-width: 0; flex: 1 1 18rem; }
.app .v-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.app .v-h1 { font-size: 1.5rem; font-weight: 600; letter-spacing: -0.025em; line-height: 1.2; }
.app .v-h2 {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 4px;
  font-size: 0.95rem;
  font-weight: 600;
}
.app .v-h2 em {
  padding: 0 7px;
  border-radius: 999px;
  background: #f1f0f4;
  font-size: 0.72rem;
  font-style: normal;
  font-weight: 550;
  color: var(--f-muted);
}
.app .v-sub { margin-top: 4px; max-width: 62ch; color: var(--f-muted); }
.app .v-muted { color: var(--f-muted); font-size: 0.82rem; }
.app .v-hint { font-size: 0.78rem; color: var(--f-muted); }
.app .v-foot { font-size: 0.76rem; color: var(--f-muted); max-width: 70ch; }
.app .v-fallback { display: grid; gap: 12px; justify-items: start; max-width: 46ch; }
.app .fkick { font-size: 0.72rem; font-weight: 600; color: var(--f-primary-hover); }

/* ---------- Schaltflächen ---------- */
.app .fb {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  height: 36px;
  padding: 0 14px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: none;
  font-size: 0.84rem;
  font-weight: 550;
  white-space: nowrap;
  text-decoration: none;
  transition: background-color 0.2s, border-color 0.2s, color 0.2s, box-shadow 0.2s, transform 0.18s var(--f-ease);
}
.app .fb:active:not(:disabled) { transform: scale(0.97); }
.app .fb:disabled { opacity: 0.45; }
.app .fb--sm { height: 30px; padding: 0 10px; font-size: 0.78rem; }
.app .fb--icon { width: 36px; padding: 0; }
.app .fb--icon.fb--sm { width: 30px; }
.app .fb--primary { background: var(--f-primary); color: #fff; box-shadow: 0 1px 0 rgb(255 255 255 / 0.22) inset, 0 6px 14px -8px rgb(109 40 217 / 0.7); }
.app .fb--primary:hover:not(:disabled) { background: var(--f-primary-hover); }
.app .fb--outline { border-color: var(--f-line-strong); background: #fff; color: var(--f-ink); }
.app .fb--outline:hover:not(:disabled) { border-color: var(--f-soft-line); background: var(--f-soft); color: var(--f-primary-hover); }
.app .fb--ghost { color: var(--f-text); }
.app .fb--ghost:hover:not(:disabled) { background: #f1f0f4; color: var(--f-ink); }
.app .fb--danger { background: var(--f-danger); color: #fff; }
.app .fb--danger-ghost { color: var(--f-danger); justify-self: start; }
.app .fb--danger-ghost:hover { background: var(--f-danger-soft); }

/* ---------- Marken, Zahlen, Hinweise ---------- */
.app .fbadge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  height: 22px;
  padding: 0 8px;
  border-radius: 6px;
  background: var(--f-soft);
  color: var(--f-primary-hover);
  font-size: 0.72rem;
  font-weight: 550;
  white-space: nowrap;
}
.app .fbadge--warn { background: var(--f-warn-soft); color: var(--f-warn); }
.app .fbadge--ok { background: var(--f-ok-soft); color: var(--f-ok); }
.app .fbadge--danger { background: var(--f-danger-soft); color: var(--f-danger); }
.app .fbadge--muted { background: #f1f0f4; color: var(--f-muted); }
.app .fbadge--line { background: none; box-shadow: inset 0 0 0 1px var(--f-line-strong); color: var(--f-muted); }
.app .dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-left: 6px;
  border-radius: 50%;
  background: var(--f-primary);
  vertical-align: middle;
}
.app .fstats {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 36px;
  padding: 14px 20px;
  border: 1px solid var(--f-line);
  border-radius: 10px;
  background: var(--f-card);
}
.app .fstats div { display: grid; }
.app .fstats b { font-size: 1.15rem; font-weight: 600; font-variant-numeric: tabular-nums; line-height: 1.3; }
.app .fstats b.is-accent { color: var(--f-primary); }
.app .fstats span { font-size: 0.74rem; color: var(--f-muted); }
.app .fnote {
  display: flex;
  gap: 9px;
  padding: 10px 14px;
  border: 1px solid var(--f-soft-line);
  border-radius: 10px;
  background: var(--f-soft);
  font-size: 0.82rem;
  color: #4c1d95;
}
.app .fnote .ico { flex: none; margin-top: 2px; }
.app .fnote--warn { border-color: #f1d9a4; background: var(--f-warn-soft); color: var(--f-warn); }
.app .fempty {
  display: grid;
  justify-items: center;
  gap: 6px;
  padding: 40px 20px;
  border: 1px solid var(--f-line);
  border-radius: 10px;
  background: var(--f-card);
  text-align: center;
}
.app .fempty__ico { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: #f1f0f4; color: var(--f-muted); }
.app .fempty p { max-width: 38ch; color: var(--f-muted); font-size: 0.82rem; }
.app .meter {
  display: inline-block;
  width: 56px;
  height: 6px;
  border-radius: 999px;
  background: #ebe8f1;
  overflow: hidden;
  vertical-align: middle;
}
.app .meter--wide { width: 140px; }
.app .meter i { display: block; height: 100%; border-radius: inherit; background: var(--f-primary); transition: width 0.6s var(--f-ease); }
.app .meter i.is-over { background: #d97706; }
.app .fav {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  font-size: 0.6rem;
  font-weight: 650;
  background: #ede9fe;
  color: #5b21b6;
}
.app .fav--b { background: #d1fae5; color: #065f46; }
.app .fav--c { background: #e0f2fe; color: #075985; }
.app .fav--d { background: #fef3c7; color: #92400e; }
.app .fav--e { background: #ffe4e6; color: #9f1239; }
.app .pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 28px;
  padding: 0 10px 0 3px;
  border-radius: 999px;
  background: #f1f0f4;
  font-size: 0.78rem;
  font-weight: 500;
}
.app .pill--mine { background: var(--f-soft); color: var(--f-primary-hover); font-weight: 600; }
.app .code,
.app .bigcode {
  font-family: var(--mono);
  padding: 8px 12px;
  border-radius: 8px;
  background: #f1f0f4;
  color: var(--f-ink);
  font-size: 0.8rem;
  overflow-wrap: anywhere;
}
.app .bigcode { font-size: 1.5rem; letter-spacing: 0.06em; text-align: center; padding: 18px; }
.app .fdl { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 6px 16px; font-size: 0.84rem; }
.app .fdl dt { color: var(--f-muted); }
.app .fdl dd { color: var(--f-ink); }
.app .fdl--compact { font-size: 0.78rem; gap: 3px 12px; }
.app .hintline { display: flex; align-items: center; gap: 6px; font-size: 0.76rem; color: var(--f-muted); }
.app .hintline--warn { color: var(--f-warn); }
.app .legend { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 0.74rem; color: var(--f-muted); }
.app .legend li { display: flex; align-items: center; gap: 6px; }
.app .legend i { width: 10px; height: 10px; border-radius: 3px; }

/* ---------- Reiter, Umschalter, Schalter: die Fläche gleitet ---------- */
.app .ftabs {
  display: flex;
  gap: 2px;
  padding: 3px;
  border-radius: 10px;
  background: #eeedf2;
  justify-self: start;
  max-width: 100%;
  overflow-x: auto;
  scrollbar-width: none;
}
.app .ftab {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 34px;
  padding: 0 14px;
  border: 0;
  border-radius: 8px;
  background: none;
  font-size: 0.82rem;
  font-weight: 550;
  color: var(--f-muted);
  white-space: nowrap;
  transition: color 0.25s;
}
.app .ftab:hover { color: var(--f-ink); }
.app .ftab[aria-selected="true"] { color: var(--f-ink); }
.app .ftab > span,
.app .ftab > em { position: relative; }
.app .ftab em {
  padding: 0 6px;
  border-radius: 999px;
  background: rgb(37 35 42 / 0.07);
  font-size: 0.7rem;
  font-style: normal;
  font-variant-numeric: tabular-nums;
}
.app .ftab[aria-selected="true"] em { background: var(--f-soft); color: var(--f-primary-hover); }
.app .ftab__pill,
.app .fseg__thumb {
  position: absolute;
  inset: 0;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 1px 2px rgb(37 35 42 / 0.1), 0 3px 8px -4px rgb(76 29 149 / 0.25);
  transform-origin: center;
}
.app .fseg {
  display: inline-flex;
  gap: 2px;
  padding: 3px;
  border-radius: 10px;
  background: #eeedf2;
}
.app .fseg__btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 30px;
  padding: 0 12px;
  border: 0;
  border-radius: 8px;
  background: none;
  font-size: 0.8rem;
  font-weight: 550;
  color: var(--f-muted);
  white-space: nowrap;
  transition: color 0.25s;
}
.app .fseg__btn > span,
.app .fseg__btn > .ico { position: relative; }
.app .fseg__btn[aria-pressed="true"] { color: var(--f-primary-hover); }
.app .fsw {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 0;
  border: 0;
  background: none;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--f-text);
}
.app .fsw__track {
  position: relative;
  flex: none;
  width: 38px;
  height: 22px;
  border-radius: 999px;
  background: #d5d2dc;
  transition: background-color 0.35s var(--f-ease);
}
.app .fsw__knob {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 18px;
  height: 18px;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 1px 3px rgb(37 35 42 / 0.3);
}
.app .fsw[aria-checked="true"] .fsw__track { background: var(--f-primary); }
.app .fsw[aria-checked="true"] .fsw__knob { left: 18px; }
.app .fsw:active .fsw__knob { width: 22px; }
.app .fsw[aria-checked="true"]:active .fsw__knob { left: 14px; }
.app .pills { display: flex; flex-wrap: wrap; gap: 6px; }
.app .pillbtn {
  height: 30px;
  padding: 0 12px;
  border: 1px solid var(--f-line-strong);
  border-radius: 999px;
  background: #fff;
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--f-text);
  transition: background-color 0.2s, border-color 0.2s, color 0.2s, transform 0.18s var(--f-ease);
}
.app .pillbtn:active { transform: scale(0.96); }
.app .pillbtn[aria-pressed="true"] { border-color: var(--f-primary); background: var(--f-soft); color: var(--f-primary-hover); font-weight: 600; }

/* ---------- Felder ---------- */
.app .ff { display: grid; gap: 5px; min-width: 0; margin: 0; padding: 0; border: 0; font-size: 0.8rem; font-weight: 550; color: var(--f-ink); }
.app .ff small { font-weight: 450; font-size: 0.74rem; color: var(--f-muted); }
.app .ff :where(select, input, textarea),
.app .inline-field select,
.app .fsearch input {
  width: 100%;
  min-width: 0;
  height: 36px;
  padding: 0 10px;
  border: 1px solid var(--f-input);
  border-radius: 8px;
  background: #fff;
  font-size: 0.84rem;
  font-weight: 450;
  color: var(--f-ink);
  transition: border-color 0.2s, box-shadow 0.2s;
}
.app .ff textarea { height: auto; padding: 8px 10px; resize: vertical; line-height: 1.45; }
.app .ff :where(select, input, textarea):focus,
.app .inline-field select:focus,
.app .fsearch input:focus {
  outline: none;
  border-color: var(--f-primary);
  box-shadow: 0 0 0 3px rgb(124 58 237 / 0.18);
}
.app .ff-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(9rem, 1fr)); gap: 12px; }
.app .inline-field { display: inline-flex; align-items: center; gap: 8px; font-size: 0.78rem; font-weight: 550; color: var(--f-muted); }
.app .inline-field select { width: auto; height: 32px; }
.app .inline-form { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 10px; }
.app .inline-form .ff { flex: 1 1 14rem; }
.app .fsearch { position: relative; display: block; flex: 1 1 14rem; max-width: 22rem; }
.app .fsearch .ico { position: absolute; left: 10px; top: 50%; translate: 0 -50%; color: var(--f-muted); pointer-events: none; }
.app .fsearch input { padding-left: 32px; height: 34px; }
.app .fcheck { display: flex; align-items: center; gap: 9px; font-size: 0.82rem; font-weight: 450; color: var(--f-text); cursor: pointer; }
.app .fcheck input,
.app .tick input { position: absolute; opacity: 0; width: 0; height: 0; }
.app .fcheck i,
.app .tick i {
  display: grid;
  place-items: center;
  flex: none;
  width: 20px;
  height: 20px;
  border: 1.5px solid var(--f-input);
  border-radius: 6px;
  background: #fff;
  color: #fff;
  transition: background-color 0.2s, border-color 0.2s, transform 0.3s var(--f-spring);
}
.app .fcheck i .ico,
.app .tick i .ico { width: 13px; height: 13px; stroke-width: 3; transform: scale(0); transition: transform 0.3s var(--f-spring); }
.app .fcheck input:checked + i,
.app .tick input:checked + i { border-color: var(--f-primary); background: var(--f-primary); }
.app .fcheck input:checked + i .ico,
.app .tick input:checked + i .ico { transform: scale(1); }
.app .fcheck input:focus-visible + i,
.app .tick input:focus-visible + i { outline: 2px solid var(--f-primary); outline-offset: 2px; }
.app .tick { display: inline-flex; position: relative; cursor: pointer; }
.app .tick:active i { transform: scale(0.88); }
.app .fchecks { display: grid; grid-template-columns: repeat(auto-fill, minmax(11rem, 1fr)); gap: 8px 12px; margin-top: 4px; }
.app .toolbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 14px; }
.app .filters { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.app .weeknav { display: inline-flex; align-items: center; gap: 6px; }
.app .weeknav b { margin-left: 6px; font-weight: 600; }
.app .row-actions { display: inline-flex; align-items: center; gap: 4px; }
.app .fchips { display: flex; flex-wrap: wrap; gap: 6px; }
.app .fchip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 28px;
  padding: 0 10px;
  border: 1px solid var(--f-line-strong);
  border-radius: 8px;
  background: #fff;
  font-size: 0.76rem;
  color: var(--f-text);
}
.app .fchip:hover { border-color: var(--f-soft-line); background: var(--f-soft); }

/* ---------- Fenster und Hinweise ---------- */
.app__layer:empty { display: none; }
.app__layer { position: absolute; inset: 0; z-index: 5; }
.app .dlg {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-rows: minmax(0, 1fr);
  place-items: center;
  padding: 20px;
  background: rgb(37 35 42 / 0.42);
  animation: demo-dlg-fade 0.2s ease-out;
}
.app .dlg__box {
  display: flex;
  flex-direction: column;
  gap: 14px;
  width: min(30rem, 100%);
  max-height: 100%;
  padding: 22px;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 24px 60px -20px rgb(37 35 42 / 0.55);
  animation: demo-dlg-in 0.36s var(--f-spring);
}
.app .dlg__box--wide { width: min(40rem, 100%); }
.app .dlg__box header { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.app .dlg__box h4 { font-size: 1.05rem; font-weight: 600; letter-spacing: -0.01em; }
.app .dlg__box h5 { font-size: 0.84rem; font-weight: 600; margin-top: 4px; }
.app .dlg__x { display: grid; place-items: center; flex: none; width: 30px; height: 30px; margin: -4px -6px 0 0; border: 0; border-radius: 8px; background: none; color: var(--f-muted); }
.app .dlg__x:hover { background: #f1f0f4; color: var(--f-ink); }
.app .dlg__text { margin-top: -8px; font-size: 0.82rem; color: var(--f-muted); }
.app .dlg__body { display: grid; gap: 12px; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 2px; margin: -2px; }
.app .dlg__body:empty { display: none; }
.app .dlg__err { padding: 8px 12px; border-radius: 8px; background: var(--f-danger-soft); color: var(--f-danger); font-size: 0.8rem; font-weight: 550; }
.app .dlg__box footer { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; }
@keyframes demo-dlg-fade { from { opacity: 0; } }
@keyframes demo-dlg-in { from { opacity: 0; transform: translateY(14px) scale(0.97); } }
.app__toasts {
  position: absolute;
  right: 16px;
  bottom: 16px;
  z-index: 6;
  display: grid;
  gap: 8px;
  justify-items: end;
  pointer-events: none;
}
.app .ftoast {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  max-width: min(24rem, calc(100vw - 48px));
  padding: 11px 14px;
  border: 1px solid var(--f-line);
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 14px 34px -14px rgb(37 35 42 / 0.4);
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--f-ink);
  animation: demo-toast-in 0.42s var(--f-spring);
  transition: opacity 0.25s, transform 0.25s;
}
.app .ftoast .ico { flex: none; margin-top: 2px; color: var(--f-ok); }
.app .ftoast--warn .ico { color: #d97706; }
.app .ftoast--info .ico { color: var(--f-primary); }
.app .ftoast.is-leaving { opacity: 0; transform: translateY(6px); }
@keyframes demo-toast-in { from { opacity: 0; transform: translateY(14px) scale(0.96); } }

/* ---------- Karten, Listen, Tabellen ---------- */
.app .panel {
  display: grid;
  gap: 14px;
  align-content: start;
  min-width: 0;
  padding: 16px;
  border: 1px solid var(--f-line);
  border-radius: 10px;
  background: var(--f-card);
}
.app .panel--quiet { background: #fbfafd; }
.app .panel__head { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 10px; }
.app .panel__head h4 { display: flex; align-items: center; gap: 7px; font-size: 0.98rem; font-weight: 600; }
.app .fsplit { display: grid; gap: 16px; align-items: start; }
.app .fsplit--side { grid-template-columns: 15rem minmax(0, 1fr); }
.app .lists { display: grid; gap: 4px; }
.app .lists__item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  padding: 9px 12px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: none;
  text-align: left;
  transition: background-color 0.2s, border-color 0.2s;
}
.app .lists__item span { display: grid; min-width: 0; }
.app .lists__item b { font-size: 0.84rem; font-weight: 550; }
.app .lists__item small { font-size: 0.72rem; color: var(--f-muted); }
.app .lists__item em { font-style: normal; font-size: 0.72rem; font-weight: 600; padding: 1px 7px; border-radius: 999px; background: #f1f0f4; color: var(--f-muted); }
.app .lists__item:hover { background: #f1f0f4; }
.app .lists__item[aria-current="true"] { border-color: var(--f-soft-line); background: var(--f-soft); }
.app .lists__item[aria-current="true"] b { color: var(--f-primary-hover); }
.app .lists__item[aria-current="true"] em { background: #fff; color: var(--f-primary-hover); }
.app .rows { display: grid; border: 1px solid var(--f-line); border-radius: 10px; background: var(--f-card); overflow: hidden; }
.app .rows li { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; padding: 11px 14px; }
.app .rows li + li { border-top: 1px solid var(--f-line); }
.app .rows__when { display: grid; flex: none; width: 5.2rem; }
.app .rows__when b { font-size: 0.82rem; }
.app .rows__when small,
.app .rows__main small { font-size: 0.74rem; color: var(--f-muted); }
.app .rows__main { display: grid; flex: 1 1 12rem; min-width: 0; gap: 1px; }
.app .rows__main b { font-size: 0.86rem; font-weight: 550; }
.app .answer,
.app .decision { display: flex; gap: 6px; align-items: flex-start; color: var(--f-ok) !important; }
.app .answer .ico,
.app .decision .ico { flex: none; margin-top: 2px; }
.app .cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(15.5rem, 1fr)); gap: 12px; }
.app .cards--wide { grid-template-columns: repeat(auto-fill, minmax(19rem, 1fr)); }
.app .fcard {
  display: grid;
  gap: 10px;
  align-content: start;
  padding: 14px;
  border: 1px solid var(--f-line);
  border-radius: 10px;
  background: var(--f-card);
  transition: border-color 0.25s, box-shadow 0.25s, transform 0.25s var(--f-ease);
}
.app .fcard:hover { border-color: var(--f-soft-line); box-shadow: var(--f-shadow); transform: translateY(-2px); }
.app .fcard.is-mine { border-color: var(--f-soft-line); background: linear-gradient(180deg, #fbf9ff, #fff 70%); }
.app .fcard header { display: flex; align-items: flex-start; gap: 8px; color: var(--f-primary); }
.app .fcard header h4 { flex: 1; min-width: 0; font-size: 0.92rem; font-weight: 600; line-height: 1.3; }
.app .fcard p { font-size: 0.8rem; color: var(--f-text); }
.app .fcard footer { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: auto; }
.app .cap { display: flex; align-items: center; gap: 8px; font-size: 0.76rem; color: var(--f-muted); }
.app .ftable { border: 1px solid var(--f-line); border-radius: 10px; background: var(--f-card); overflow-x: auto; }
.app .ftable__row {
  display: grid;
  gap: 12px;
  align-items: center;
  width: 100%;
  min-width: var(--min, 0);
  padding: 10px 14px;
  border: 0;
  border-top: 1px solid var(--f-line);
  background: none;
  text-align: left;
  font-size: 0.8rem;
  color: var(--f-text);
}
.app .ftable__row:first-child { border-top: 0; }
.app .ftable__row > span { min-width: 0; }
.app .ftable__row b { font-weight: 550; }
.app .ftable__row small { display: block; font-size: 0.72rem; color: var(--f-muted); }
.app .ftable__row--head { background: #f6f5f9; font-size: 0.74rem; font-weight: 600; color: var(--f-muted); }
.app .ftable__row--head small { font-weight: 450; }
.app .ftable__row--sum { background: var(--f-soft); font-weight: 600; color: var(--f-ink); }
.app .ftable__row.is-mine { background: #fbf9ff; }
.app button.ftable__row { transition: background-color 0.18s; }
.app button.ftable__row:hover { background: #f6f5f9; }
.app .ftable__row.is-fresh b { color: var(--f-primary-hover); }
.app .ftable__empty { padding: 26px 14px; text-align: center; color: var(--f-muted); font-size: 0.82rem; }
.app .ftable .num,
.app .tk-meta .num { font-family: var(--mono); font-size: 0.74rem; color: var(--f-muted); }
.app .ftable--tk .ftable__row { grid-template-columns: 6.6rem minmax(0, 1.7fr) minmax(0, 0.9fr) 4.6rem 5.4rem minmax(0, 0.9fr) 6.2rem; --min: 760px; }
.app .ftable--bk .ftable__row { grid-template-columns: 3.6rem minmax(0, 1.1fr) minmax(0, 0.9fr) minmax(0, 1.3fr); }
.app .ftable--nana .ftable__row { grid-template-columns: 8.5rem repeat(3, minmax(0, 1fr)); --min: 620px; }
.app .ftable--nana .ftable__row > span { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.app .ftable--nana .ftable__row > span:first-child,
.app .ftable--nana .ftable__row--head > span { display: block; }
.app .ftable--consult .ftable__row { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 1fr) 6rem; --min: 560px; }
.app .ftable--consult .ftable__row > span:first-child { display: flex; align-items: center; gap: 8px; }
.app .ftable--ag .ftable__row { grid-template-columns: minmax(0, 1.4fr) 5.6rem 6.6rem 5.4rem minmax(0, 1.2fr); --min: 620px; }
.app .ftable--reg .ftable__row { grid-template-columns: minmax(0, 1fr) minmax(0, 1.8fr) 4.4rem 7rem; --min: 600px; }
.app .ftable--cls .ftable__row { grid-template-columns: 2.4rem minmax(0, 1fr) minmax(0, 1.6fr) 5.4rem; --min: 560px; }
.app .ftable--books .ftable__row { grid-template-columns: minmax(0, 1.8fr) minmax(0, 0.9fr) 3.6rem 7.6rem 5.4rem 5rem; --min: 720px; }
.app .ftable--plan .ftable__row { grid-template-columns: minmax(0, 1.8fr) 4rem 5.4rem 5rem 5.6rem; --min: 520px; }
.app .ftable--order .ftable__row { grid-template-columns: minmax(0, 1.6fr) 10.5rem 4rem 5.6rem 6.4rem; --min: 640px; }
.app .ftable--files .ftable__row { grid-template-columns: minmax(0, 2fr) 4.4rem 4.6rem minmax(0, 0.9fr) 4rem 7.2rem; --min: 720px; }
.app .ftable--award .ftable__row { grid-template-columns: minmax(0, 1.2fr) 4rem minmax(0, 1fr) 7rem; --min: 480px; }
.app .ftable--sheet .ftable__row { grid-template-columns: 2.6rem minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1.2fr); padding-block: 7px; }
.app .ftable--sheet3 .ftable__row { grid-template-columns: 4rem minmax(0, 1fr) minmax(0, 1fr); padding-block: 7px; }
.app .fname { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; }
.app .fname .ico { flex: none; color: var(--f-muted); }
.app .fstep { display: inline-flex; align-items: center; gap: 4px; }
.app .fstep output { min-width: 2.4ch; text-align: center; font-weight: 600; font-variant-numeric: tabular-nums; color: var(--f-ink); }
.app .plain-list { display: grid; gap: 6px; }
.app .plain-list li { display: flex; align-items: center; gap: 8px; font-size: 0.82rem; }
.app .plain-list li span:nth-child(2) { flex: 1; }

/* ---------- Dashboard ---------- */
.app .dash { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.app .dcard {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--f-line);
  border-radius: 10px;
  background: var(--f-card);
  transition: border-color 0.25s, box-shadow 0.25s;
}
.app .dcard:hover { border-color: var(--f-soft-line); box-shadow: var(--f-shadow); }
.app .dcard header { display: flex; align-items: center; gap: 8px; padding: 12px 14px; border-bottom: 1px solid var(--f-line); color: var(--f-primary); }
.app .dcard header h4 { flex: 1; font-size: 0.86rem; font-weight: 600; }
.app .dcard header em { padding: 0 7px; border-radius: 999px; background: var(--f-soft); font-size: 0.72rem; font-style: normal; font-weight: 600; color: var(--f-primary-hover); }
.app .dcard__body { flex: 1; display: grid; align-content: start; gap: 2px; padding: 8px; }
.app .dcard__empty { padding: 10px 6px; font-size: 0.8rem; color: var(--f-muted); }
.app .drow {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  padding: 7px 8px;
  border: 0;
  border-radius: 8px;
  background: none;
  text-align: left;
  transition: background-color 0.18s;
}
.app .drow:hover { background: #f6f5f9; }
.app .drow > span:first-child { display: grid; flex: 1 1 0; min-width: 0; }
.app .drow .fbadge { flex: none; }
.app .drow b { font-size: 0.83rem; font-weight: 550; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.app .drow small { font-size: 0.74rem; color: var(--f-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.app .dcard__all {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
  padding: 0 14px 12px;
  border: 0;
  background: none;
  font-size: 0.76rem;
  font-weight: 550;
  color: var(--f-primary-hover);
}
.app .dcard__all .ico { transition: transform 0.25s var(--f-ease); }
.app .dcard__all:hover .ico { transform: translateX(3px); }

/* ---------- Infoboard, Todos, Mitteilungen ---------- */
.app .ib-posts { display: grid; gap: 12px; }
.app .ib-post { display: grid; gap: 10px; padding: 16px; border: 1px solid var(--f-line); border-radius: 10px; background: var(--f-card); }
.app .ib-post.is-pinned { border-color: var(--f-soft-line); }
.app .ib-post header { display: grid; gap: 4px; }
.app .ib-post__top { display: flex; flex-wrap: wrap; gap: 6px; }
.app .ib-post__top:empty { display: none; }
.app .ib-post h4 { font-size: 1rem; font-weight: 600; letter-spacing: -0.01em; }
.app .ib-post footer { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.app .ib-post footer .row-actions { margin-left: auto; }
.app .ib-confirm {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 11px 14px;
  border: 1px solid #f1d9a4;
  border-radius: 10px;
  background: var(--f-warn-soft);
}
.app .ib-confirm p { display: flex; gap: 8px; flex: 1 1 16rem; font-size: 0.82rem; color: var(--f-warn); }
.app .ib-confirm strong { color: inherit; }
.app .ib-confirm .ico { flex: none; margin-top: 2px; }
.app .ib-done {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border: 1px solid #b7e4c4;
  border-radius: 10px;
  background: var(--f-ok-soft);
  color: var(--f-ok);
  font-size: 0.82rem;
  font-weight: 550;
  animation: demo-pop-in 0.45s var(--f-spring);
}
@keyframes demo-pop-in { from { opacity: 0; transform: scale(0.96); } }
.app .ib-count { display: inline-flex; align-items: center; gap: 8px; padding: 4px 12px; border: 1px solid var(--f-line-strong); border-radius: 999px; font-size: 0.76rem; color: var(--f-muted); }
.app .todo { display: grid; }
.app .todo__item { display: flex; align-items: flex-start; gap: 12px; padding: 10px 2px; }
.app .todo__item + .todo__item { border-top: 1px solid var(--f-line); }
.app .todo__main { display: grid; flex: 1; min-width: 0; gap: 3px; }
.app .todo__main b { font-size: 0.86rem; font-weight: 550; transition: color 0.25s; }
.app .todo__main small { font-size: 0.76rem; color: var(--f-muted); }
.app .todo__meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.app .todo__meta:empty { display: none; }
.app .todo__item.is-done .todo__main b { color: var(--f-muted); text-decoration: line-through; text-decoration-color: rgb(107 104 116 / 0.5); }
.app .who { display: inline-flex; align-items: center; gap: 5px; font-size: 0.74rem; color: var(--f-muted); }
.app .inbox { display: grid; border: 1px solid var(--f-line); border-radius: 10px; background: var(--f-card); overflow: hidden; }
.app .inbox__item { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 8px 12px; padding: 12px 14px; }
.app .inbox__item + .inbox__item { border-top: 1px solid var(--f-line); }
.app .inbox__item > div { flex: 1 1 14rem; min-width: 0; display: grid; gap: 2px; }
.app .inbox__item b { font-size: 0.86rem; font-weight: 550; }
.app .inbox__item p { font-size: 0.8rem; }
.app .inbox__item small { font-size: 0.72rem; color: var(--f-muted); }
.app .inbox__dot { flex: none; width: 8px; height: 8px; margin-top: 6px; border-radius: 50%; background: transparent; }
.app .inbox__item.is-unread { background: #fbf9ff; }
.app .inbox__item.is-unread .inbox__dot { background: var(--f-primary); }
.app .more { display: grid; grid-template-columns: repeat(auto-fill, minmax(9.5rem, 1fr)); gap: 8px; }
.app .more__item { display: flex; align-items: center; gap: 9px; min-height: 44px; padding: 0 12px; border: 1px solid var(--f-line); border-radius: 10px; background: var(--f-card); font-size: 0.84rem; font-weight: 550; color: var(--f-ink); text-align: left; }

/* ---------- Fachfarben ---------- */
.app .hue-rose { --h-bg: #fff1f2; --h-line: #fecdd3; --h-ink: #9f1239; --h-dot: #f43f5e; }
.app .hue-blue { --h-bg: #eff6ff; --h-line: #bfdbfe; --h-ink: #1e40af; --h-dot: #3b82f6; }
.app .hue-amber { --h-bg: #fffbeb; --h-line: #fde68a; --h-ink: #92400e; --h-dot: #f59e0b; }
.app .hue-violet { --h-bg: #f5f3ff; --h-line: #ddd6fe; --h-ink: #5b21b6; --h-dot: #8b5cf6; }
.app .hue-emerald { --h-bg: #ecfdf5; --h-line: #a7f3d0; --h-ink: #065f46; --h-dot: #10b981; }
.app .hue-sky { --h-bg: #f0f9ff; --h-line: #bae6fd; --h-ink: #075985; --h-dot: #0ea5e9; }
.app .hue-orange { --h-bg: #fff7ed; --h-line: #fed7aa; --h-ink: #9a3412; --h-dot: #f97316; }
.app .hue-slate { --h-bg: #f8fafc; --h-line: #cbd5e1; --h-ink: #334155; --h-dot: #64748b; }

/* ---------- Buchungen ---------- */
.app .bk { display: grid; grid-template-columns: minmax(0, 1fr) 16rem; gap: 14px; align-items: start; }
.app .bk__grid,
.app .tt,
.app .sv,
.app .pa__grid,
.app .cal {
  display: grid;
  border: 1px solid var(--f-line);
  border-radius: 10px;
  background: var(--f-card);
  overflow: hidden;
  font-size: 0.74rem;
}
.app .bk__grid { grid-template-columns: 3.2rem repeat(5, minmax(0, 1fr)); }
.app .bk__th,
.app .tt__th,
.app .sv__th,
.app .pa__th,
.app .cal__th { padding: 7px 8px; border-bottom: 1px solid var(--f-line); background: #f6f5f9; font-weight: 600; color: var(--f-ink); }
.app .bk__th span { font-weight: 450; color: var(--f-muted); }
.app .bk__th.is-today,
.app .tt__th.is-today,
.app .sv__th.is-today { color: var(--f-primary-hover); box-shadow: inset 0 -2px 0 var(--f-primary); }
.app .bk__p,
.app .tt__p { padding: 6px 8px; border-top: 1px solid var(--f-line); color: var(--f-muted); }
.app .bk__p b,
.app .tt__p b { display: block; }
.app .bk__c,
.app .tt__c,
.app .pa__c { padding: 3px; border-top: 1px solid var(--f-line); }
.app .bk__cell {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1px;
  width: 100%;
  height: 100%;
  min-height: 54px;
  padding: 5px 7px;
  border: 1px dashed var(--f-line-strong);
  border-radius: 7px;
  background: none;
  text-align: left;
  line-height: 1.25;
  transition: box-shadow 0.2s, transform 0.2s var(--f-ease), background-color 0.2s;
}
.app .bk__cell:hover:not(:disabled) { box-shadow: 0 0 0 2px var(--f-soft-line); }
.app .bk__cell:active:not(:disabled) { transform: scale(0.97); }
.app .bk__cell.has-lesson { border-style: solid; background: var(--h-bg); border-color: var(--h-line); color: var(--h-ink); }
.app .bk__cell[aria-pressed="true"] { border-style: solid; border-color: var(--f-primary); box-shadow: 0 0 0 2px var(--f-primary); }
.app .bk__cell.is-closed { opacity: 0.5; background: repeating-linear-gradient(135deg, #f1f0f4 0 6px, transparent 6px 12px); }
/* Schmale Zellen im Raster: Text kürzen statt überlaufen */
.app .bk__cell,
.app .pa__day { overflow: hidden; }
.app .bk__cell > span,
.app .pa__day > small { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.app .bk__cell .sub { font-weight: 600; }
.app .bk__cell .meta { font-size: 0.68rem; opacity: 0.85; }
.app .bk__cell .free { color: var(--f-ok); font-weight: 600; font-size: 0.7rem; }
.app .bk__cell .none,
.app .bk__cell .full { color: var(--f-muted); font-size: 0.7rem; }
.app .bk__cell .full { color: var(--f-warn); font-weight: 550; }
.app .bk__cell .mine { margin-top: 2px; padding: 0 5px; border-radius: 4px; background: var(--f-primary); color: #fff; font-size: 0.64rem; font-weight: 600; animation: demo-pop-in 0.4s var(--f-spring); }
.app .bk__panel { position: sticky; top: 0; padding: 14px; border: 1px solid var(--f-line); border-radius: 10px; background: var(--f-card); }
.app .bk__panel form { display: grid; gap: 12px; }
.app .bk__panel h4 { font-size: 0.95rem; font-weight: 600; }
.app .bk__panel .fb--primary { width: 100%; }
.app .bk__list { display: grid; gap: 8px; padding-top: 12px; border-top: 1px solid var(--f-line); }
.app .bk__list > b { font-size: 0.76rem; }
.app .bk__list > span { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 0 6px; }
.app .bk__list > span b { font-size: 0.8rem; font-weight: 550; }
.app .bk__list small { grid-column: 1; font-size: 0.72rem; color: var(--f-muted); }
.app .bk__list .fb { grid-column: 2; grid-row: 1 / span 2; }

/* ---------- Stundenplan ---------- */
.app .tt { grid-template-columns: 5.4rem repeat(5, minmax(0, 1fr)); }
.app .tt__p small { display: block; font-size: 0.66rem; line-height: 1.3; }
.app .tt__lesson,
.app .tt__add {
  display: grid;
  align-content: start;
  gap: 1px;
  width: 100%;
  height: 100%;
  min-height: 50px;
  padding: 6px 8px;
  border-radius: 7px;
  text-align: left;
  transition: transform 0.2s var(--f-ease), box-shadow 0.2s, background-color 0.4s, border-color 0.4s, color 0.4s;
}
.app .tt__lesson { border: 1px solid var(--h-line); background: var(--h-bg); color: var(--h-ink); }
.app .tt__lesson b { color: inherit; font-weight: 600; }
.app .tt__lesson span,
.app .tt__lesson small { font-size: 0.68rem; opacity: 0.85; }
.app .tt__lesson:hover { transform: translateY(-1px); box-shadow: 0 6px 14px -8px rgb(37 35 42 / 0.35); }
.app .tt__add { place-items: center; align-content: center; border: 1px dashed transparent; background: none; color: transparent; }
.app .tt__add:hover,
.app .tt__add:focus-visible { border-color: var(--f-line-strong); color: var(--f-muted); background: #faf9fc; }
.app .hues { display: grid; gap: 8px; }
.app .hues__row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; }
.app .hues__row > b { width: 7.5rem; font-size: 0.84rem; font-weight: 550; }
.app .hues__row > span { display: flex; gap: 6px; }
.app .hues__dot { width: 26px; height: 26px; border: 2px solid #fff; border-radius: 50%; background: var(--h-dot); box-shadow: 0 0 0 1px var(--f-line-strong); transition: transform 0.25s var(--f-spring), box-shadow 0.2s; }
.app .hues__dot:hover { transform: scale(1.12); }
.app .hues__dot[aria-pressed="true"] { box-shadow: 0 0 0 2px var(--h-dot); transform: scale(1.12); }

/* ---------- Kalender und KA-Planung ---------- */
.app .cal { grid-template-columns: repeat(7, minmax(0, 1fr)); }
.app .cal__th { text-align: center; }
.app .cal__day { display: grid; align-content: start; gap: 2px; min-height: 84px; padding: 4px; border-top: 1px solid var(--f-line); border-left: 1px solid var(--f-line); }
.app .cal__day:nth-child(7n + 1) { border-left: 0; }
.app .cal__day.is-out { background: #faf9fc; }
.app .cal__day.is-out .cal__num { color: #b4b1bd; }
.app .cal__day.is-we { background: #fbfafd; }
.app .cal__day.is-hol { background: repeating-linear-gradient(135deg, #f4f3f7 0 6px, #fbfafd 6px 12px); }
.app .cal__day.is-sel { box-shadow: inset 0 0 0 2px var(--f-primary); }
.app .cal__num { justify-self: start; min-width: 24px; height: 24px; padding: 0 4px; border: 0; border-radius: 999px; background: none; font-size: 0.74rem; font-weight: 600; color: var(--f-ink); }
.app .cal__num:hover { background: #eeedf2; }
.app .cal__day.is-today .cal__num { background: var(--f-primary); color: #fff; }
.app .cal__more { border: 0; background: none; padding: 0 4px; font-size: 0.66rem; font-weight: 550; color: var(--f-muted); text-align: left; }
.app .ev {
  display: block;
  width: 100%;
  padding: 2px 6px;
  border: 0;
  border-left: 3px solid var(--e-line);
  border-radius: 4px;
  background: var(--e-bg);
  color: var(--e-ink);
  font-size: 0.68rem;
  font-weight: 550;
  text-align: left;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  transition: filter 0.2s;
}
.app .ev:hover { filter: brightness(0.96); }
.app .ev i { font-style: normal; font-weight: 450; margin-right: 4px; opacity: 0.8; }
.app .ev--school { --e-bg: #f2edfb; --e-line: #7c3aed; --e-ink: #5b21b6; }
.app .ev--exam { --e-bg: #fdf1d7; --e-line: #d97706; --e-ink: #92400e; }
.app .ev--personal { --e-bg: #e3f6e9; --e-line: #16a34a; --e-ink: #166534; }
.app .ev--holiday { --e-bg: #eeedf2; --e-line: #8a8a93; --e-ink: #4b4853; }
.app .legend i.ev--school,
.app .legend i.ev--exam,
.app .legend i.ev--personal,
.app .legend i.ev--holiday { background: var(--e-line); }
.app .evlist { display: grid; gap: 6px; }
.app .evline { display: flex; align-items: center; gap: 12px; width: 100%; padding: 9px 12px; border: 1px solid var(--f-line); border-radius: 10px; background: var(--f-card); text-align: left; transition: border-color 0.2s, transform 0.2s var(--f-ease); }
.app .evline:hover { border-color: var(--f-soft-line); transform: translateX(2px); }
.app .evline > span:nth-child(2) { display: grid; flex: 1; min-width: 0; }
.app .evline b { font-size: 0.86rem; font-weight: 550; }
.app .evline small { font-size: 0.74rem; color: var(--f-muted); }
.app .evline__bar { flex: none; width: 4px; align-self: stretch; border-radius: 4px; background: var(--e-line); }
.app .evgroup { display: grid; gap: 6px; }
.app .evgroup__day { display: flex; align-items: center; gap: 8px; font-size: 0.8rem; }
.app .wk { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; }
.app .wk__day { display: grid; align-content: start; gap: 4px; min-height: 180px; padding: 8px; border: 1px solid var(--f-line); border-radius: 10px; background: var(--f-card); }
.app .wk__day header { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 4px; font-size: 0.8rem; }
.app .wk__day header span { color: var(--f-muted); font-size: 0.74rem; }
.app .wk__day.is-today { border-color: var(--f-primary); }
.app .wk__day.is-today header b { color: var(--f-primary-hover); }
.app .pa { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 0.8fr); gap: 16px; align-items: start; }
.app .pa__main { display: grid; gap: 12px; }
.app .pa__grid { grid-template-columns: 4.2rem repeat(5, minmax(0, 1fr)); }
.app .pa__kw { display: grid; align-content: center; padding: 6px 8px; border-top: 1px solid var(--f-line); }
.app .pa__kw b { font-size: 0.74rem; font-weight: 600; }
.app .pa__kw small { font-size: 0.66rem; color: var(--f-warn); }
.app .pa__day {
  position: relative;
  display: grid;
  align-content: start;
  gap: 1px;
  width: 100%;
  height: 100%;
  min-height: 54px;
  padding: 5px 7px;
  border: 1px solid var(--f-line);
  border-radius: 7px;
  background: #fff;
  text-align: left;
  font-size: 0.72rem;
  color: var(--f-ink);
  transition: box-shadow 0.2s, transform 0.2s var(--f-ease), background-color 0.3s, border-color 0.3s, color 0.3s;
}
.app .pa__day b { font-weight: 600; color: inherit; }
.app .pa__day small { font-size: 0.66rem; line-height: 1.2; }
.app .pa__day em { font-size: 0.6rem; font-style: normal; font-weight: 600; color: var(--f-primary-hover); }
.app .pa__day.has-lesson::after { content: ""; position: absolute; top: 7px; right: 7px; width: 6px; height: 6px; border-radius: 50%; background: var(--f-primary); }
.app .pa__test { position: absolute; right: 6px; bottom: 6px; width: 7px; height: 7px; border: 1.5px solid #d97706; border-radius: 50%; }
.app .pa__day.is-other { background: var(--f-warn-soft); border-color: #f1d9a4; color: var(--f-warn); }
.app .pa__day.is-away { background: #e0f2fe; border-color: #bae6fd; color: #075985; }
.app .pa__day.is-own { background: var(--f-primary); border-color: var(--f-primary); color: #fff; animation: demo-pop-in 0.4s var(--f-spring); }
.app .pa__day.is-own em { color: #ede9fe; }
.app .pa__day.is-own::after { background: #fff; }
.app .pa__day.is-hol,
.app .pa__day.is-past { background: repeating-linear-gradient(135deg, #f1f0f4 0 6px, transparent 6px 12px); color: var(--f-muted); }
.app .pa__day:not(:disabled):hover { box-shadow: 0 0 0 2px var(--f-soft-line); }
.app .pa__day:not(:disabled):active { transform: scale(0.96); }
.app .lg { border: 1px solid var(--f-line-strong); }
.app .lg--free { background: #fff; }
.app .lg--own { background: var(--f-primary); border-color: var(--f-primary); }
.app .lg--other { background: var(--f-warn-soft); border-color: #f1d9a4; }
.app .lg--away { background: #e0f2fe; border-color: #bae6fd; }
.app .lg--hol { background: repeating-linear-gradient(135deg, #d5d2dc 0 3px, transparent 3px 6px); }
.app .legend .lg--dot { width: 6px; height: 6px; border: 0; border-radius: 50%; background: var(--f-primary); }
.app .legend .lg--test { width: 8px; height: 8px; border: 1.5px solid #d97706; border-radius: 50%; }
.app .pa__side { display: grid; gap: 8px; padding: 14px; border: 1px solid var(--f-line); border-radius: 10px; background: var(--f-card); }
.app .pa__side h4 { font-size: 0.86rem; font-weight: 600; }
.app .pa__list { display: grid; gap: 6px; margin-bottom: 8px; }
.app .pa__list button { display: flex; align-items: center; justify-content: space-between; gap: 8px; width: 100%; padding: 7px 10px; border: 1px solid var(--f-line); border-radius: 8px; background: #fff; font-size: 0.8rem; font-weight: 550; color: var(--f-ink); transition: border-color 0.2s, transform 0.2s var(--f-ease); }
.app .pa__list button:hover { border-color: var(--f-primary); transform: translateX(2px); }
.app .pa__plain { display: grid; gap: 6px; }
.app .pa__plain li { display: grid; font-size: 0.8rem; }
.app .pa__plain b { font-weight: 550; }
.app .pa__plain small { font-size: 0.72rem; color: var(--f-muted); }

/* ---------- Aufsichten ---------- */
.app .sv { grid-template-columns: 7rem repeat(5, minmax(0, 1fr)); }
.app .sv__band { padding: 8px; border-top: 1px solid var(--f-line); }
.app .sv__band b { display: block; font-size: 0.76rem; }
.app .sv__band small { font-size: 0.68rem; color: var(--f-muted); }
.app .sv__c { display: grid; align-content: start; gap: 4px; padding: 4px; border-top: 1px solid var(--f-line); border-left: 1px solid var(--f-line); }
.app .sv__slot { display: grid; gap: 3px; padding: 6px 7px; border: 1px solid var(--f-line); border-radius: 7px; background: #fff; transition: border-color 0.3s, background-color 0.3s; }
.app .sv__slot > b { font-size: 0.7rem; font-weight: 600; }
.app .sv__slot.is-open { border-style: dashed; border-color: #f1d9a4; background: #fffcf3; }
.app .sv__slot.is-mine { border-color: var(--f-primary); background: var(--f-soft); }
.app .sv__who { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; font-size: 0.7rem; }
.app .sv__who .fav { width: 18px; height: 18px; font-size: 0.52rem; }
.app .sv__who small { flex-basis: 100%; font-size: 0.64rem; color: var(--f-muted); }
.app .sv__free { font-size: 0.68rem; font-weight: 600; color: var(--f-warn); }
.app .sv__slot .fb { height: 24px; padding: 0 7px; font-size: 0.68rem; justify-self: start; }
.app .bars { display: grid; gap: 6px; }
.app .bars li { display: grid; grid-template-columns: 13rem minmax(0, 1fr) 2rem; align-items: center; gap: 12px; padding: 4px 8px; border-radius: 8px; font-size: 0.8rem; }
.app .bars li > span:first-child { display: flex; align-items: center; gap: 8px; }
.app .bars li.is-mine { background: var(--f-soft); }
.app .bars__track { height: 8px; border-radius: 999px; background: #ebe8f1; overflow: hidden; }
.app .bars__track i { display: block; height: 100%; border-radius: inherit; background: var(--f-primary); transition: width 0.6s var(--f-ease); }
.app .bars b { text-align: right; font-variant-numeric: tabular-nums; }

/* ---------- Sprechstunden ---------- */
.app .slotrows { display: grid; gap: 8px; }
.app .slotrow { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; }
.app .slotrow__day { display: grid; width: 5.4rem; }
.app .slotrow__day b { font-size: 0.82rem; }
.app .slotrow__day small { font-size: 0.72rem; color: var(--f-muted); }
.app .slots { display: flex; flex-wrap: wrap; gap: 6px; }
.app .slots--wide { display: grid; grid-template-columns: repeat(auto-fill, minmax(6.4rem, 1fr)); }
.app .slot {
  display: grid;
  gap: 0;
  min-width: 6.2rem;
  padding: 6px 10px;
  border: 1px solid #b7e4c4;
  border-radius: 8px;
  background: var(--f-ok-soft);
  color: var(--f-ok);
  text-align: left;
  transition: transform 0.2s var(--f-ease), box-shadow 0.2s, background-color 0.3s, border-color 0.3s, color 0.3s;
}
.app .slot:hover { transform: translateY(-1px); box-shadow: 0 6px 14px -8px rgb(37 35 42 / 0.35); }
.app .slot:active { transform: scale(0.96); }
.app .slot b { font-size: 0.82rem; font-weight: 600; color: inherit; font-variant-numeric: tabular-nums; }
.app .slot small { font-size: 0.68rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 9rem; }
.app .slot--booked { border-color: var(--f-soft-line); background: var(--f-soft); color: var(--f-primary-hover); }
.app .slot--blocked { border-color: var(--f-line-strong); background: repeating-linear-gradient(135deg, #f1f0f4 0 6px, #fff 6px 12px); color: var(--f-muted); }
.app .legend .slot-dot--free { background: #16a34a; }
.app .legend .slot-dot--booked { background: var(--f-primary); }
.app .legend .slot-dot--blocked { background: #8a8a93; }

/* ---------- Lehrmittel, Klassen, Dateien, Tickets, Protokolle ---------- */
.app .grades { display: grid; grid-template-columns: repeat(auto-fit, minmax(5.6rem, 1fr)); gap: 10px; }
.app .sheet { display: grid; gap: 12px; padding: 20px; border-radius: 10px; background: #fff; box-shadow: 0 1px 2px rgb(0 0 0 / 0.06), 0 8px 24px rgb(0 0 0 / 0.08); }
.app .sheet > header { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 10px; padding-bottom: 12px; border-bottom: 2px solid var(--f-primary); font-size: 0.8rem; color: var(--f-muted); }
.app .sheet > header h4 { font-size: 1.1rem; font-weight: 600; }
.app .sheetgrid { border: 1px solid var(--f-line); border-radius: 10px; background: var(--f-card); overflow-x: auto; }
.app .sheetgrid__row { display: grid; grid-template-columns: minmax(10rem, 1.3fr) repeat(var(--cols), minmax(6.4rem, 1fr)); align-items: center; min-width: calc(10rem + var(--cols) * 6.4rem); border-top: 1px solid var(--f-line); font-size: 0.8rem; }
.app .sheetgrid__row:first-child { border-top: 0; }
.app .sheetgrid__row > span { display: flex; align-items: center; gap: 6px; padding: 6px 12px; min-height: 36px; }
.app .sheetgrid__row > span + span { justify-content: center; border-left: 1px solid var(--f-line); }
.app .sheetgrid__row > span b { font-weight: 550; margin-right: 0; }
.app .sheetgrid__row--head { background: #f6f5f9; }
.app .sheetgrid__row--head > span + span { display: grid; justify-items: center; text-align: center; gap: 0; }
.app .sheetgrid__row--head b { font-size: 0.74rem; line-height: 1.25; }
.app .sheetgrid__row--head small { font-size: 0.66rem; color: var(--f-muted); }
.app .sheetgrid__row:hover:not(.sheetgrid__row--head) { background: #fbfafd; }
.app .storage { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; padding: 10px 14px; border: 1px solid var(--f-line); border-radius: 10px; background: var(--f-card); font-size: 0.8rem; }
.app .storage span:first-child { display: inline-flex; align-items: center; gap: 7px; color: var(--f-muted); }
.app .fcrumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; font-size: 0.84rem; }
.app .fcrumbs button { border: 0; background: none; padding: 2px 4px; border-radius: 6px; color: var(--f-primary-hover); font-weight: 550; }
.app .fcrumbs button:hover { background: var(--f-soft); }
.app .fcrumbs .ico { color: var(--f-muted); }
.app .folders { display: grid; grid-template-columns: repeat(auto-fill, minmax(12rem, 1fr)); gap: 8px; }
.app .folder { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid var(--f-line); border-radius: 10px; background: var(--f-card); text-align: left; color: var(--f-primary); transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s var(--f-ease); }
.app .folder:hover { border-color: var(--f-soft-line); box-shadow: var(--f-shadow); transform: translateY(-1px); }
.app .folder span { display: grid; min-width: 0; }
.app .folder b { font-size: 0.84rem; font-weight: 550; }
.app .folder small { font-size: 0.72rem; color: var(--f-muted); }
.app .tk-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 0.8rem; color: var(--f-muted); }
.app .tk-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.app .comments { display: grid; gap: 10px; }
.app .comments li { display: flex; gap: 10px; }
.app .comments li > div { display: grid; flex: 1; gap: 1px; padding: 8px 12px; border-radius: 10px; background: #f6f5f9; }
.app .comments b { font-size: 0.8rem; }
.app .comments small { font-size: 0.7rem; color: var(--f-muted); }
.app .comments p { font-size: 0.82rem; margin-top: 2px; }
.app .tops { display: grid; gap: 14px; padding-left: 20px; list-style: decimal; }
.app .tops li { padding-left: 4px; }
.app .tops li > b { font-size: 0.9rem; }
.app .tops p { margin-top: 4px; font-size: 0.84rem; }
.app .tops .decision { padding: 8px 12px; border-radius: 8px; background: var(--f-ok-soft); }
.app .tops .decision strong { color: inherit; }
.app .top-edit { display: grid; gap: 10px; margin: 0; padding: 12px; border: 1px solid var(--f-line); border-radius: 10px; }
.app .top-edit legend { padding: 0 6px; font-size: 0.8rem; font-weight: 600; color: var(--f-ink); }

/* ---------- Schmale Bildschirme ---------- */
/* Die Seitenleiste wird zur unteren Leiste wie in der Anwendung. Der Rahmen
   wächst mit dem Inhalt, damit keine Wischgeste in einer Scrollfläche hängen
   bleibt; Fenster und Hinweise stehen dann über der ganzen Seite. */
@media (max-width: 960px) {
  .app { overflow: clip; }
  .app__frame { grid-template-columns: minmax(0, 1fr); height: auto; }
  .app__side { display: none; }
  .app__content { overflow: visible; min-height: 460px; padding: 18px 16px 24px; }
  .app__bottom {
    position: sticky;
    bottom: 0;
    z-index: 4;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    border-top: 1px solid var(--f-line);
    background: #fff;
    box-shadow: 0 -8px 20px -12px rgb(37 35 42 / 0.25);
  }
  .app__bottom button {
    display: grid;
    justify-items: center;
    gap: 2px;
    padding: 8px 2px;
    border: 0;
    background: none;
    font-size: 0.66rem;
    font-weight: 550;
    color: var(--f-muted);
  }
  .app__bottom button[aria-current="page"] { color: var(--f-primary-hover); }
  .app__layer { position: fixed; z-index: 60; }
  .app__toasts { position: fixed; z-index: 61; right: 12px; bottom: 76px; }
  html.demo-lock { overflow: hidden; }
  .app .dash { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .app .bk,
  .app .pa,
  .app .fsplit--side { grid-template-columns: minmax(0, 1fr); }
  .app .bk__panel { position: static; }
  .app .lists { grid-auto-flow: column; grid-auto-columns: minmax(11rem, 1fr); overflow-x: auto; padding-bottom: 4px; }
  .app .sv,
  .app .tt,
  .app .cal { overflow-x: auto; }
  .app .sv > *,
  .app .tt > * { min-width: 0; }
  .app .sv { grid-template-columns: 6rem repeat(5, minmax(8.6rem, 1fr)); }
  .app .tt { grid-template-columns: 4.4rem repeat(5, minmax(6.4rem, 1fr)); }
}
@media (max-width: 767px) {
  .app__school { font-size: 0.8rem; }
  .app__reset span { display: none; }
  .app__chrome p { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
  .app .dash,
  .app .filters { grid-template-columns: minmax(0, 1fr); }
  .app .bk__grid,
  .app .pa__grid { font-size: 0.66rem; }
  .app .bk__grid { grid-template-columns: 2.5rem repeat(5, minmax(0, 1fr)); }
  .app .pa__grid { grid-template-columns: 3.2rem repeat(5, minmax(0, 1fr)); }
  .app .bk__cell { min-height: 48px; padding: 4px; }
  .app .bk__cell .meta,
  .app .bk__th span,
  .app .pa__day em { display: none; }
  .app .cal__day { min-height: 62px; padding: 2px; }
  .app .ev { padding: 1px 3px; font-size: 0.6rem; border-left-width: 2px; }
  .app .ev i { display: none; }
  .app .wk { grid-template-columns: minmax(0, 1fr); }
  .app .wk__day { min-height: 0; }
  .app .bars li { grid-template-columns: minmax(0, 1fr) 5rem 1.6rem; }
  .app .ftabs { justify-self: stretch; }
  .app .dlg { padding: 10px; align-items: end; }
  .app .dlg__box { padding: 18px; }
}
@media (prefers-reduced-motion: reduce) {
  .app *,
  .app *::before,
  .app *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
