/* mjOS · Bridge — Kalender (KA-1 bis KA-5), nach Bridge-Kalender.dc.html. */
.kalender { display: flex; flex-direction: column; gap: 14px; }
.kalender[hidden], .ka-problem[hidden], .ka-list[hidden], .ka-empty[hidden] { display: none; }
.ka-todo.overdue .ka-when .t { color: var(--attention-text); }

/* KA-1 Kopf: Monat, Woche oder Tag, „+ Termin“ (öffnet das Blatt „Neuer Termin“) */
.ka-head { display: flex; align-items: flex-end; gap: 12px; }
.ka-title { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.ka-add { min-height: var(--touch-min); padding: 0 16px; border-radius: var(--radius-pill); border: none; background: var(--blue); color: var(--surface);
  text-decoration: none; font: 500 14px var(--font-body); display: flex; align-items: center; gap: 6px; flex: none; cursor: pointer; }
.ka-add svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* KA-2 Wochenleiste ab heute; Blättern (31.10.2026): ‹ › und Wischen wochenweise, „Heute“ nur in einer anderen Woche */
.ka-weeknav { display: flex; align-items: center; gap: 8px; margin-bottom: -6px; }
.ka-step { width: var(--touch-min); height: var(--touch-min); padding: 0; border-radius: var(--radius-pill); border: 1px solid var(--line);
  background: var(--surface); color: var(--text); display: flex; align-items: center; justify-content: center; flex: none; cursor: pointer; }
.ka-step:last-child { margin-left: auto; }
.ka-step svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.ka-step:disabled { opacity: .35; cursor: default; }
.ka-today { min-height: var(--touch-min); padding: 0 16px; margin: 0 auto; border-radius: var(--radius-pill); border: 1px solid var(--blue-line);
  background: var(--surface); color: var(--accent); font: 500 14px var(--font-body); cursor: pointer; }
.ka-today[hidden] { display: none; }
.ka-step:focus-visible, .ka-today:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.ka-days { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; touch-action: pan-y; }   /* waagrecht wischt die App */
.ka-days[aria-busy="true"] .dot { visibility: hidden; }
.ka-day { height: 66px; min-width: 0; padding: 0; border-radius: var(--r-control); background: var(--surface); border: 1px solid var(--line);
  color: var(--text); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; cursor: pointer; font: inherit; }
.ka-day.today { border-color: var(--blue-line); }
.ka-day[aria-selected="true"] { background: var(--ink); border-color: var(--ink); }   /* gewählt: schwarz */
.ka-day .wd { font-size: var(--text-micro); font-weight: 500; color: var(--ink-3); }
.ka-day.today .wd { color: var(--accent); }
.ka-day .n { font-family: var(--font-sans); font-size: 18px; font-weight: 600; }
.ka-day[aria-selected="true"] .n, .ka-day[aria-selected="true"] .wd { color: var(--surface); }
.ka-day[aria-selected="true"] .dot.plain { background: var(--line-strong); }
.ka-day[aria-selected="true"] .dot.zora { background: var(--blue-line); }
.ka-day .dot { width: 5px; height: 5px; border-radius: 3px; border: none; background: transparent; }
.ka-day .dot.plain { background: var(--muted); }
.ka-day .dot.zora { background: var(--accent); }

/* KA-3 Nachfrage zu vergangenen Terminen ohne Eintrag */
.ka-checkins { display: flex; flex-direction: column; gap: 8px; }
.ka-checkins:empty { display: none; }
.ka-checkin { padding: 12px 14px; border-radius: var(--radius-card); background: var(--amber-soft); border: 1px solid var(--amber-line);
  display: flex; align-items: center; gap: 12px; }
.ka-checkin svg { width: 20px; height: 20px; flex: none; fill: none; stroke: var(--attention); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.ka-checkin-text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.ka-checkin-text .t { font-size: 14px; font-weight: 500; overflow-wrap: anywhere; }
.ka-checkin-text .s { font-size: 12px; color: var(--amber-text); }

/* KA-4 Liste; Termine von Zora gestrichelt mit „NEU · ZORA“ */
.ka-list { display: flex; flex-direction: column; gap: 8px; }
.ka-events { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.ka-events:empty { display: none; }
.ka-event { display: flex; gap: 12px; align-items: center; padding: 8px 12px; min-height: var(--touch-min); border-radius: var(--r-control);
  background: var(--surface); border: 1px solid var(--line); min-width: 0; box-shadow: var(--shadow-card); }
.ka-event.zora { background: var(--blue-soft); border: 1px dashed var(--blue); box-shadow: none; }
.ka-when { width: 64px; flex: none; display: flex; flex-direction: column; gap: 1px; font-family: var(--font-mono); }
.ka-when .d { font-size: var(--text-micro); color: var(--ink-3); }
.ka-when .t { font-size: 13px; color: var(--ink); font-weight: 500; }
.ka-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.ka-body .title { font-size: 15px; font-weight: 500; overflow-wrap: anywhere; }
.ka-body .sub { font-size: 12px; color: var(--muted); overflow-wrap: anywhere; }
.ka-new { height: 22px; padding: 0 8px; border-radius: var(--radius-pill); background: var(--surface); border: 1px solid var(--blue-line); font-family: var(--font-mono); font-size: 10px;
  letter-spacing: .06em; color: var(--accent); display: flex; align-items: center; flex: none; white-space: nowrap; }
.ka-empty, .ka-problem { margin: 0; padding: 14px 12px; border-radius: var(--r-control); border: 1px solid var(--line-1); font-size: 14px; color: var(--muted); }
.ka-problem { display: flex; flex-direction: column; gap: 4px; }
.ka-problem .t { color: var(--text); font-weight: 500; }
.ka-problem .s { font-size: 12px; }


/* Termine von Hand (Besitzerauftrag 26.10.2026): eigene Termine antippbar, Blatt „Neuer Termin“ (Grundform .sheet aus heute.css) */
.ka-event.editable { cursor: pointer; }
.ka-event.editable:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.ka-sheet .sheet-head .save { min-height: var(--touch-min); }
.ka-sheet [hidden] { display: none !important; }
.ka-field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.ka-field-label { font-size: var(--text-small); color: var(--muted); }
.ka-input { min-height: 48px; width: 100%; box-sizing: border-box; padding: 0 12px; border-radius: var(--r-control); border: 1px solid var(--line-strong);
  background: var(--surface); color: var(--text); font: 16px var(--font-body); }
.ka-input:focus { outline: 2px solid var(--accent); outline-offset: 1px; }
.ka-input::placeholder { color: var(--ink-3); }
.ka-times { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.ka-allday { display: flex; align-items: center; gap: 10px; min-height: var(--touch-min); font-size: 15px; }
.ka-check { width: 20px; height: 20px; accent-color: var(--accent); margin: 0; }
.ka-repeat button { min-height: 44px; }
.ka-sheet-error { margin: 0; padding: 10px 12px; border-radius: var(--r-control); background: var(--amber-soft); border: 1px solid var(--amber-line);
  color: var(--amber-text); font-size: 13px; }
.ka-remove { border-top: 1px solid var(--line); padding-top: 12px; }
.ka-remove-ask { min-height: var(--touch-min); padding: 0; border: none; background: none; color: var(--red); font: 500 15px var(--font-body); cursor: pointer; }
.ka-remove-confirm { display: flex; align-items: center; gap: 10px; font-size: 15px; }
.ka-remove-confirm span { flex: 1; }
.ka-remove-yes { min-height: 44px; padding: 0 16px; border: none; border-radius: var(--r-control); background: var(--red); color: var(--on-accent);
  font: 600 15px var(--font-body); cursor: pointer; }
.ka-remove-yes:disabled { opacity: .4; }

/* Rechenzeiten für Daniel (docs/kalender.md): Fenster schraffiert über den Terminen; blau = rechnet immer, grau gestrichelt =
   nur bei Arbeit, durchgestrichen = pausiert. Im Blatt der Umschalter „Termin | Rechenzeit Daniel“. */
.ka-runs:empty { display: none; }
.ka-run { box-shadow: none; border: 1px solid var(--blue-line);
  background: repeating-linear-gradient(135deg, var(--blue-soft) 0 6px, var(--surface) 6px 12px); }
.ka-run.tone-work { border: 1px dashed var(--line-strong);
  background: repeating-linear-gradient(135deg, var(--ground, #F3F4F6) 0 6px, var(--surface) 6px 12px); }
.ka-run.tone-paused { border: 1px dashed var(--line-strong); background: var(--surface); }
.ka-run.tone-paused .ka-when .t, .ka-run.tone-paused .ka-body .title { text-decoration: line-through; color: var(--muted); }
.ka-paused { color: var(--muted); border-color: var(--line-strong); }
.ka-runs-note { margin: 0; font-size: 12px; color: var(--muted); }
.ka-runs-note[hidden] { display: none; }
.ka-group { display: flex; flex-direction: column; gap: 14px; }
.ka-kind button { min-height: 44px; }
.ka-jobs { display: flex; flex-direction: column; }
.ka-run-hint { margin: 0; font-size: 12px; color: var(--muted); line-height: 1.4; }
.ka-pause { min-height: var(--touch-min); padding: 0 16px; border-radius: var(--r-control); border: 1px solid var(--line-strong); background: var(--surface);
  color: var(--text); font: 500 15px var(--font-body); cursor: pointer; align-self: flex-start; }
