* { box-sizing: border-box; touch-action: manipulation; }
html, body { margin: 0; height: 100%; background: #D9DBE0; overscroll-behavior: none; }
body {
  font-family: Roboto, system-ui, -apple-system, "Segoe UI", sans-serif;
  color: #1E232B; -webkit-tap-highlight-color: transparent; -webkit-text-size-adjust: 100%;
}
#app {
  position: fixed; inset: 0; max-width: 480px; margin: 0 auto; background: #fff; overflow: hidden;
  user-select: none; -webkit-user-select: none; box-shadow: 0 0 30px rgba(0,0,0,.15);
}
#datepick { position: fixed; left: 50%; bottom: 50%; width: 1px; height: 1px; opacity: 0; pointer-events: none; border: 0; padding: 0; }
input, textarea, select { user-select: text; -webkit-user-select: text; font: inherit; }
.ic { display: inline-flex; flex: none; align-items: center; justify-content: center; }
.ic svg { display: block; }
.tap { cursor: pointer; }
.tap:active { background: rgba(0,0,0,.06); }

/* Grundgerüst */
.main { position: absolute; inset: 0; display: flex; flex-direction: column; padding-top: env(safe-area-inset-top); background: #fff; }
.pages { position: relative; flex: 1; min-height: 0; }
.page { position: absolute; inset: 0; }
.scroll { overflow-y: auto; -webkit-overflow-scrolling: touch; background: #F2F3F6; }
.column { padding: 18px 16px 24px; display: flex; flex-direction: column; }
.nav { display: flex; height: calc(66px + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom); border-top: .7px solid #E3E5EA; background: #fff; flex: none; }
.nav-i { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; cursor: pointer; color: #8A919C; }
.nav-i .lbl { font-size: 13px; line-height: 15px; margin-top: 3px; white-space: nowrap; }
.nav-i.on { color: #2B323C; }
.nav-i.on .lbl { font-weight: 700; }
.cal { position: relative; width: 28px; height: 28px; }
.cal .day { position: absolute; inset: 0; padding-top: 9px; text-align: center; font-size: 10px; line-height: 12px; font-weight: 700; }

/* Stundenplan */
.plan { display: flex; flex-direction: column; background: #fff; }
.bar { height: 64px; display: flex; align-items: center; padding: 0 4px 0 10px; flex: none; }
.cls { display: flex; align-items: center; gap: 8px; color: #6A717D; font-size: 26px; cursor: pointer; padding: 4px 4px; border-radius: 6px; }
.bar .sp { flex: 1; }
.ibtn { width: 48px; height: 48px; padding: 10px; border-radius: 50%; color: #6A717D; cursor: pointer; }
.ibtn:active { background: rgba(0,0,0,.08); }
.head { height: 62px; display: flex; flex: none; background: #fff; }
.hd { display: flex; flex-direction: column; align-items: center; padding-top: 9px; cursor: pointer; flex: 1; min-width: 0; color: #6A717D; }
.hd.left { flex: none; width: 64px; align-items: flex-start; padding-left: 5px; }
.hd .s { font-size: 14px; line-height: 18px; }
.hd .b { font-size: 19px; line-height: 26px; font-weight: 700; color: #555D6A; }
.hd.today, .hd.today .b { color: #E8673C; }
.gscroll { flex: 1; min-height: 0; overflow-y: auto; overflow-x: hidden; background: #DEDFE5; touch-action: pan-y; scrollbar-width: none; }
.gscroll::-webkit-scrollbar { display: none; }
.grid { position: relative; }
.gl { position: absolute; left: 64px; right: 0; height: .8px; background: #CBCED6; pointer-events: none; }
.gt { position: absolute; left: 15px; font-size: 12.5px; line-height: 14px; color: #6A717D; pointer-events: none; }
.now { position: absolute; background: #E8673C; pointer-events: none; }
.les { position: absolute; border-radius: 4px; overflow: hidden; padding: 4px 3px 0 12px; cursor: pointer; }
.les-bar { position: absolute; left: 5px; top: 6px; bottom: 6px; width: 3.5px; border-radius: 1.75px; }
.les-t { font-size: 14px; line-height: 17px; color: #2A3038; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.les-t.b { font-weight: 700; color: #1E232B; }
.les-room { background: #2B6B4E; color: #fff; padding: 0 2.5px 1px 1.5px; border-radius: 2px; margin-left: -1px; }
.les-i { position: absolute; right: 4px; bottom: 4px; width: 14px; height: 14px; border-radius: 50%; background: #7C838E; color: #fff; font-size: 10px; line-height: 14px; font-weight: 700; text-align: center; }

/* Karten und Listen */
.title { font-size: 26px; font-weight: 700; color: #6A717D; }
.lcard { margin-top: 26px; background: #fff; border-radius: 14px; padding: 4px 14px; box-shadow: 0 1px 3px rgba(0,0,0,.12); }
.lrow { display: flex; align-items: center; padding: 16px 0; cursor: pointer; color: #7E8794; }
.lrow .lbl { flex: 1; padding-left: 30px; font-size: 19px; color: #1E232B; }
.div { height: 1px; background: #E1E3E7; margin-left: 50px; }
.vrow { display: flex; align-items: center; padding: 18px 0 18px 16px; }
.vrow .lbl { flex: 1; font-size: 19px; }
.vrow .val { font-size: 18px; color: #6A717D; }
.news { position: relative; margin-top: 26px; }
.news-card { display: flex; background: #fff; border-radius: 10px; box-shadow: 0 1px 4px rgba(0,0,0,.14); }
.news-side { width: 76px; flex: none; display: flex; align-items: center; justify-content: center; background: #E6F2F8; border-radius: 10px 0 0 10px; color: #22305A; }
.news-txt { padding: 18px 30px 24px 18px; flex: 1; }
.news-txt .h { font-size: 19px; font-weight: 700; color: #22305A; }
.news-txt .t { font-size: 17px; color: #4A5260; padding-top: 4px; line-height: 1.3; }
.news-x { position: absolute; top: 10px; right: 10px; width: 28px; height: 28px; padding: 5px; border-radius: 50%; background: #B3B8C0; color: #fff; cursor: pointer; box-shadow: 0 1px 3px rgba(0,0,0,.2); }
.prow { display: flex; align-items: center; padding: 10px 0 10px 4px; cursor: pointer; }
.avatar { width: 56px; height: 56px; border-radius: 50%; background: #7E8794; color: #fff; display: flex; align-items: center; justify-content: center; font-size: 24px; flex: none; }
.ptxt { flex: 1; min-width: 0; padding: 0 8px 0 14px; }
.ptxt .n { font-size: 22px; color: #4A5260; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.anon { display: inline-block; margin-top: 2px; padding: 1px 10px 2px; border-radius: 11px; background: #7E8794; color: #fff; font-size: 15px; }
.adm-h { padding: 22px 0 0 4px; font-size: 15px; font-weight: 700; color: #E8673C; }
.card { margin-top: 14px; background: #fff; border-radius: 12px; padding: 14px 16px 10px; box-shadow: 0 1px 2px rgba(0,0,0,.1); }
.card > .ct { font-size: 15px; font-weight: 700; color: #6A717D; padding-bottom: 6px; }
.srow { display: flex; align-items: center; padding: 13px 0; font-size: 16px; cursor: pointer; }
.srow .lbl { flex: 1; }
.srow .ar { font-size: 22px; color: #A0A6AF; line-height: 16px; }
.lsn { display: flex; align-items: center; padding: 8px 0; cursor: pointer; }
.lsn .bar4 { width: 4px; height: 38px; border-radius: 2px; flex: none; }
.lsn .tx { flex: 1; min-width: 0; padding-left: 12px; }
.lsn .w { font-size: 13px; color: #6A717D; }
.lsn .m { font-size: 16px; font-weight: 700; }
.lsn .m.off { text-decoration: line-through; color: #6A717D; }
.lsn .nt { font-size: 13.5px; color: #6A717D; }
.chip { color: #fff; font-size: 12.5px; font-weight: 700; padding: 3px 8px; border-radius: 4px; flex: none; }
.muted { font-size: 15px; color: #6A717D; }

/* Unterseiten */
.sub { position: absolute; inset: 0; display: flex; flex-direction: column; padding-top: env(safe-area-inset-top); animation: slidein .2s ease-out; z-index: 10; }
.sub.out { animation: slideout .18s ease-in forwards; }
@keyframes slidein { from { transform: translateX(100%); } }
@keyframes slideout { to { transform: translateX(100%); } }
.sbar { display: flex; align-items: center; padding: 12px 16px 12px 10px; flex: none; }
.sbar .back { width: 48px; height: 48px; padding: 8px; border-radius: 50%; color: #7E8794; cursor: pointer; }
.sbar .back:active { background: rgba(0,0,0,.08); }
.sbar .tt { flex: 1; padding-left: 14px; min-width: 0; }
.sbar .t1 { font-size: 21px; color: #6A717D; }
.sbar .t1.big { font-size: 26px; font-weight: 700; }
.sbar .t2 { font-size: 17px; color: #9AA0A9; }
.sbody { flex: 1; min-height: 0; overflow-y: auto; }
.tag { display: inline-block; margin-left: 10px; padding: 2px 9px 3px; border-radius: 12px; color: #fff; font-size: 14px; font-weight: 700; vertical-align: middle; }
.strike { text-decoration: line-through; }
.tcard { display: flex; align-items: center; background: #fff; border-radius: 2px; box-shadow: 0 1px 4px rgba(0,0,0,.16); padding: 18px 12px 18px 0; margin: 2px 4px 6px; cursor: pointer; }
.tline { display: flex; align-items: center; gap: 8px; padding-top: 3px; font-size: 17px; color: #6A717D; }

/* Dialoge */
.dlg-back { position: absolute; inset: 0; background: rgba(0,0,0,.32); display: flex; align-items: center; justify-content: center; z-index: 30; animation: fade .15s; padding: 24px 0; }
.dlg-back.bottom { align-items: flex-end; padding: 0 0 env(safe-area-inset-bottom); }
@keyframes fade { from { opacity: 0; } }
.dlg { background: #fff; border-radius: 8px; width: calc(100% - 48px); max-width: 400px; max-height: 100%; display: flex; flex-direction: column; box-shadow: 0 10px 30px rgba(0,0,0,.3); }
.dlg .d-title { font-size: 20px; font-weight: 500; padding: 22px 24px 0; }
.dlg .d-body { overflow-y: auto; min-height: 0; flex: 1; }
.dlg .d-msg { padding: 16px 24px 4px; font-size: 16px; color: #5B6370; line-height: 1.4; white-space: pre-line; }
.d-btns { display: flex; padding: 8px 8px 8px; gap: 4px; flex: none; }
.d-btns .sp { flex: 1; }
.d-btn { padding: 10px 12px; font-size: 14px; font-weight: 600; text-transform: uppercase; letter-spacing: .5px; color: #E8673C; border-radius: 4px; cursor: pointer; }
.d-btn:active { background: rgba(232,103,60,.12); }
.menu { padding: 20px 0 8px; }
.m-title { font-size: 22px; font-weight: 700; padding: 0 24px 4px; }
.m-sub { font-size: 14.5px; color: #6A717D; padding: 0 24px 10px; line-height: 1.15; white-space: pre-line; }
.m-row { font-size: 16.5px; padding: 14px 24px; cursor: pointer; }
.m-row:active { background: rgba(0,0,0,.06); }
.form { padding: 12px 24px 4px; display: flex; flex-direction: column; }
.f-label { font-size: 13px; color: #6A717D; padding-top: 10px; }
.f-in { font-size: 17px; border: 0; border-bottom: 1.5px solid #9AA0A9; padding: 8px 2px; outline: none; background: transparent; color: #1E232B; width: 100%; border-radius: 0; }
.f-in:focus { border-bottom-color: #E8673C; }
textarea.f-in { resize: vertical; }
.f-hint { font-size: 14px; color: #6A717D; white-space: pre-line; }
.dots { display: flex; gap: 8px; flex-wrap: wrap; }
.dot { width: 32px; height: 32px; border-radius: 50%; cursor: pointer; }
.dot.sel { box-shadow: inset 0 0 0 3px #1E232B; }
.lg { display: flex; align-items: center; padding: 6px 0; font-size: 15px; }
.lg .sw { width: 34px; height: 26px; border-radius: 4px; margin-right: 12px; flex: none; }
.sheet { width: 100%; padding: 0 16px 16px; animation: up .2s ease-out; }
@keyframes up { from { transform: translateY(100%); } }
.sheet .box { background: #fff; border-radius: 18px; padding: 0 22px; }
.sheet .opt { text-align: center; padding: 17px 0; font-size: 18px; color: #3A414C; cursor: pointer; }
.sheet .opt.h { padding: 20px 0; font-size: 20px; font-weight: 700; cursor: default; }
.sheet .opt + .opt { border-top: 1px solid #E1E3E7; }
.sheet .cancel { margin-top: 14px; background: #fff; border-radius: 18px; text-align: center; padding: 18px 0; font-size: 18px; color: #3A414C; cursor: pointer; }

/* Popup-Menü */
.pop-back { position: absolute; inset: 0; z-index: 25; }
.pop { position: absolute; background: #fff; border-radius: 4px; box-shadow: 0 4px 16px rgba(0,0,0,.25); padding: 8px 0; min-width: 200px; animation: fade .12s; }
.pop-i { display: flex; align-items: center; gap: 24px; height: 48px; padding: 0 16px; font-size: 16px; cursor: pointer; }
.pop-i span:first-child { flex: 1; }
.pop-i:active { background: rgba(0,0,0,.06); }
.pop-i.dis { color: #9AA0A9; cursor: default; }
.pop-i.dis:active { background: none; }
.chk { width: 18px; height: 18px; border: 2px solid #6A717D; border-radius: 2px; }
.chk.on { background: #E8673C; border-color: #E8673C; position: relative; }
.chk.on::after { content: ""; position: absolute; left: 4px; top: 0; width: 5px; height: 10px; border: solid #fff; border-width: 0 2px 2px 0; transform: rotate(45deg); }

/* Meldungen */
.snack { position: absolute; left: 16px; right: 16px; bottom: calc(84px + env(safe-area-inset-bottom)); background: #33373D; color: #fff; font-size: 15px; padding: 14px 16px; border-radius: 8px; box-shadow: 0 4px 12px rgba(0,0,0,.3); z-index: 40; transition: opacity .25s; animation: fade .15s; }
.toast { position: absolute; left: 50%; transform: translateX(-50%); bottom: calc(110px + env(safe-area-inset-bottom)); background: rgba(50,52,56,.92); color: #fff; font-size: 14px; padding: 10px 16px; border-radius: 20px; z-index: 40; white-space: nowrap; transition: opacity .25s; }
.splash { position: absolute; inset: 0; background: linear-gradient(#F4F5F7, #E2E3E8); z-index: 50; transition: opacity .25s; }
.splash .c { position: absolute; left: 50%; top: calc(50% - 20px); }
.splash svg { position: absolute; left: -60px; top: -60px; }
.splash .t { position: absolute; top: 60px; transform: translateX(-50%); white-space: nowrap; font-size: 17px; font-weight: 700; color: #6B7380; }
