:root {
  color-scheme: light;
  --blue: #2f459f;
  --blue-dark: #24377e;
  --cyan: #08a4df;
  --cyan-text: #066f91;
  --cyan-soft: #e8f7fd;
  --ink: #182033;
  --muted: #697487;
  --line: #dfe5ee;
  --canvas: #eef2f7;
  --white: #fff;
  --danger: #d94b5b;
  --danger-soft: #fff0f2;
  --warning: #d99817;
  --warning-soft: #fff7df;
  --success: #188b67;
  --success-soft: #e8f7f1;
  --shadow: 0 22px 55px rgba(24, 32, 51, .16);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }

html, body { min-height: 100%; }

body {
  margin: 0;
  overflow: hidden;
  color: var(--ink);
  background: #e8edf4;
}

button, input, select, textarea { font: inherit; }
button { cursor: pointer; }

.studio-toolbar {
  min-height: 68px;
  padding: 10px 18px;
  display: grid;
  grid-template-columns: minmax(280px, 1fr) auto minmax(230px, 1fr);
  align-items: center;
  gap: 16px;
  border-bottom: 1px solid #d5dce6;
  background: rgba(255, 255, 255, .97);
  box-shadow: 0 2px 14px rgba(24, 32, 51, .08);
  position: relative;
  z-index: 10;
}

.studio-brand { display: flex; align-items: center; gap: 11px; min-width: 0; }
.studio-brand img { width: 42px; height: 42px; object-fit: contain; border-radius: 11px; }
.studio-brand div { display: grid; gap: 1px; min-width: 0; }
.studio-brand span {
  color: var(--cyan-text);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .13em;
  text-transform: uppercase;
}
.studio-brand strong { overflow: hidden; font-size: 15px; text-overflow: ellipsis; white-space: nowrap; }

.studio-controls { display: flex; align-items: center; justify-content: center; gap: 8px; flex-wrap: wrap; }
.segmented {
  padding: 3px;
  display: inline-flex;
  gap: 3px;
  border: 1px solid #d7dfe9;
  border-radius: 11px;
  background: #f3f6fa;
}
.segmented button, .studio-reset {
  min-height: 34px;
  padding: 7px 13px;
  color: #4c596d;
  border: 0;
  border-radius: 8px;
  background: transparent;
  font-size: 12px;
  font-weight: 800;
}
.segmented button.active {
  color: #fff;
  background: var(--blue);
  box-shadow: 0 3px 8px rgba(47, 69, 159, .25);
}
.studio-reset { border: 1px solid #d7dfe9; background: #fff; }
.studio-reset:hover { border-color: var(--blue); color: var(--blue); }
.studio-rights {
  display: grid;
  gap: 2px;
  color: #68758a;
  font-size: 8px;
  font-weight: 900;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.studio-rights select {
  min-height: 34px;
  padding: 6px 28px 6px 10px;
  color: #344157;
  border: 1px solid #d7dfe9;
  border-radius: 9px;
  background: #fff;
  font-size: 11px;
  font-weight: 800;
  text-transform: none;
}

.mobile-kpi-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 9px;
  margin-bottom: 13px;
}
.mobile-kpi-grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.mobile-kpi-grid button {
  min-width: 0;
  padding: 12px;
  display: grid;
  gap: 3px;
  text-align: left;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: #fff;
}
.mobile-kpi-grid span, .mobile-kpi-grid small { color: var(--muted); font-size: 10px; }
.mobile-kpi-grid strong { color: var(--blue-dark); font-size: 19px; line-height: 1.05; }
.mobile-panel {
  margin-bottom: 13px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
}
.mobile-panel .section-header { padding: 11px 13px; border-bottom: 1px solid var(--line); }
.mobile-row {
  width: 100%;
  min-height: 58px;
  padding: 9px 12px;
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr) auto;
  align-items: center;
  gap: 9px;
  text-align: left;
  color: var(--ink);
  border: 0;
  border-bottom: 1px solid #edf0f5;
  background: #fff;
}
.mobile-row:last-child { border-bottom: 0; }
.mobile-row.high { background: #fff8f2; }
.mobile-row > span:nth-child(2) { min-width: 0; display: grid; gap: 3px; }
.mobile-row strong { overflow: hidden; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.mobile-row small { color: var(--muted); font-size: 9px; line-height: 1.35; }
.mobile-row > b { color: #8a95a7; font-size: 18px; }
.mobile-row-icon {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  color: var(--blue);
  border-radius: 9px;
  background: var(--cyan-soft);
  font-size: 11px;
  font-weight: 900;
}
.task-check { width: 22px; height: 22px; border: 2px solid #bac3d0; border-radius: 7px; }
.presence-strip { padding: 12px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.presence-strip span { padding: 8px 3px; display: grid; place-items: center; gap: 3px; border-radius: 10px; background: var(--success-soft); }
.presence-strip span.away { background: var(--warning-soft); }
.presence-strip b { color: var(--blue-dark); font-size: 12px; }
.presence-strip small { color: var(--muted); font-size: 8px; }
.compact-action {
  padding: 8px 11px;
  color: #fff;
  border: 0;
  border-radius: 9px;
  background: var(--blue);
  font-size: 10px;
  font-weight: 900;
}
.mobile-week-list { display: grid; gap: 8px; margin-bottom: 12px; }
.mobile-week-list article {
  padding: 10px 12px;
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
}
.mobile-week-list article.today { border-color: var(--cyan); box-shadow: inset 4px 0 var(--cyan); }
.mobile-week-list strong { font-size: 11px; }
.mobile-week-list span { color: var(--muted); font-size: 9px; }
.mobile-week-list button { padding: 6px 8px; color: var(--blue); border: 0; border-radius: 7px; background: #eef1ff; font-size: 9px; font-weight: 800; }
.segmented-filter, .track-switch { margin-bottom: 12px; padding: 3px; display: flex; gap: 3px; overflow-x: auto; border-radius: 10px; background: #e8edf4; }
.segmented-filter button, .track-switch button { flex: 1; min-width: max-content; padding: 8px 11px; border: 0; border-radius: 8px; background: transparent; color: #58667a; font-size: 10px; font-weight: 800; }
.segmented-filter .active, .track-switch .active { color: #fff; background: var(--blue); }
.vehicle-hero {
  margin-bottom: 12px;
  padding: 14px;
  display: flex;
  align-items: center;
  gap: 13px;
  border-radius: 15px;
  color: #fff;
  background: linear-gradient(135deg, var(--blue-dark), var(--blue));
}
.vehicle-symbol { width: 64px; height: 42px; display: grid; place-items: center; border-radius: 10px; background: rgba(255,255,255,.16); font-size: 13px; font-weight: 900; }
.vehicle-hero > div:last-child { min-width: 0; display: grid; gap: 3px; }
.vehicle-hero strong { font-size: 14px; }
.vehicle-hero span, .vehicle-hero small { color: rgba(255,255,255,.78); font-size: 9px; }
.compact-hero { margin-bottom: 12px; padding: 14px; }
.compact-hero h3 { margin: 4px 0; }
.teaching-row { min-height: 55px; padding: 9px 12px; display: grid; grid-template-columns: 76px minmax(0, 1fr); gap: 10px; align-items: center; border-bottom: 1px solid #edf0f5; }
.teaching-row:last-child { border-bottom: 0; }
.teaching-row time { color: var(--blue); font-size: 10px; font-weight: 900; }
.teaching-row span { display: grid; gap: 2px; }
.teaching-row strong { font-size: 11px; }
.teaching-row small { color: var(--muted); font-size: 9px; }
.lecturer-week-grid { display: grid; grid-template-columns: repeat(7, minmax(128px, 1fr)); gap: 7px; overflow-x: auto; padding-bottom: 8px; margin-bottom: 11px; scroll-snap-type: x proximity; }
.lecturer-week-grid article { min-height: 155px; padding: 8px; display: grid; align-content: start; gap: 7px; border: 1px solid var(--line); border-radius: 12px; background: #fff; scroll-snap-align: start; }
.lecturer-week-grid article.today { border-color: var(--cyan); background: var(--cyan-soft); }
.lecturer-week-grid article.empty { background: #f7f8fa; }
.lecturer-week-grid article > header { display: flex; align-items: start; justify-content: space-between; gap: 6px; }
.lecturer-week-grid article > header span { display: grid; gap: 1px; }
.lecturer-week-grid strong { font-size: 10px; }.lecturer-week-grid b { color: var(--blue); font-size: 13px; }
.lecturer-week-grid span, .lecturer-week-grid small { color: var(--muted); font-size: 9px; }
.lecturer-app-block { width: 100%; padding: 7px; display: grid; gap: 2px; color: var(--ink); border: 0; border-left: 4px solid var(--blue); border-radius: 8px; background: #edf2ff; text-align: left; }
.lecturer-app-block time { color: var(--blue); font-size: 8px; font-weight: 900; }
.lecturer-app-block strong { font-size: 9px; }
.lecturer-app-block span { font-size: 8px; }
.lecturer-app-free { min-height: 70px; display: grid; place-items: center; color: #9ba4b2; font-size: 8px; }
.calendar-toolbar.compact { margin-bottom: 9px; padding: 4px; display: grid; grid-template-columns: 32px 48px 1fr 32px; gap: 4px; align-items: center; border-radius: 10px; background: #eef2f8; }
.calendar-toolbar.compact button { min-height: 28px; border: 0; border-radius: 7px; color: var(--blue); background: #fff; font-size: 9px; font-weight: 900; }
.calendar-toolbar.compact strong { text-align: center; font-size: 9px; }
.course-mobile-card { margin-bottom: 10px; padding: 13px; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.course-mobile-card header { display: flex; justify-content: space-between; gap: 8px; }
.course-mobile-card header span { color: var(--blue); font-size: 15px; font-weight: 900; }
.course-mobile-card header b { padding: 4px 7px; border-radius: 7px; background: var(--success-soft); color: var(--success); font-size: 8px; }
.course-mobile-card h3 { margin: 8px 0 2px; font-size: 12px; }.course-mobile-card p, .course-mobile-card small { color: var(--muted); font-size: 9px; }
.course-mobile-card > div { height: 6px; margin: 9px 0 5px; overflow: hidden; border-radius: 99px; background: #e8edf4; }
.course-mobile-card > div span { height: 100%; display: block; border-radius: inherit; background: var(--cyan); }
.track-pills { padding: 11px; display: flex; flex-wrap: wrap; gap: 7px; }
.track-pills span { padding: 7px 9px; border-radius: 8px; background: #eef1ff; color: var(--blue); font-size: 9px; font-weight: 800; }
.empty-area { padding: 30px 18px; display: grid; gap: 7px; text-align: center; border: 1px dashed #bac5d4; border-radius: 14px; background: #fff; }
.empty-area strong { color: var(--blue-dark); font-size: 14px; }.empty-area span { color: var(--muted); font-size: 10px; line-height: 1.5; }
.fleet-upload-button { display: grid; place-items: center; cursor: pointer; }
.fleet-upload-button input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }

.studio-state {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 7px;
  color: #617086;
  font-size: 11px;
  font-weight: 700;
}
.studio-state span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 0 4px rgba(24, 139, 103, .12);
}

.preview-workspace {
  height: calc(100vh - 68px);
  display: grid;
  grid-template-columns: minmax(520px, 54%) minmax(480px, 46%);
  gap: 1px;
  background: #cfd7e2;
}
.preview-tablet .preview-workspace { grid-template-columns: minmax(720px, 62%) minmax(480px, 38%); }
.preview-landscape .preview-workspace { grid-template-columns: minmax(820px, 72%) minmax(390px, 28%); }

.device-column, .desktop-column {
  min-width: 0;
  display: grid;
  grid-template-rows: 64px minmax(0, 1fr);
  background: #f4f6f9;
}

.preview-caption, .desktop-caption {
  padding: 11px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, .96);
}
.preview-caption > div, .desktop-caption > div { display: grid; gap: 2px; }
.preview-caption > div { min-width: 170px; }
.preview-caption span, .desktop-caption span {
  color: var(--cyan-text);
  font-size: 9px;
  font-weight: 900;
  letter-spacing: .11em;
  text-transform: uppercase;
}
.preview-caption strong, .desktop-caption strong { font-size: 14px; }
.preview-caption p {
  max-width: 220px;
  margin: 0;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.35;
  text-align: right;
}
.desktop-caption a {
  color: var(--blue);
  font-size: 11px;
  font-weight: 800;
  text-decoration: none;
}

.device-stage {
  min-height: 0;
  padding: 16px;
  display: grid;
  place-items: center;
  overflow: auto;
  background:
    radial-gradient(circle at 24% 18%, rgba(8, 164, 223, .12), transparent 32%),
    linear-gradient(145deg, #e8edf4, #f7f9fc 55%, #e9eef5);
}

.device-shell {
  position: relative;
  overflow: hidden;
  border: 8px solid #182033;
  background: #182033;
  box-shadow: var(--shadow);
  transition: width .24s ease, height .24s ease, border-radius .24s ease;
}
.device-shell.phone { width: min(430px, calc(54vw - 40px)); height: min(860px, calc(100vh - 164px)); border-radius: 38px; }
.device-shell.tablet { width: min(820px, calc(62vw - 40px)); height: min(1020px, calc(100vh - 164px)); border-radius: 26px; }
.device-shell.phone.landscape { width: min(900px, calc(72vw - 34px)); height: min(480px, calc(100vh - 164px)); border-radius: 28px; }
.device-shell.tablet.landscape { width: min(1020px, calc(72vw - 34px)); height: min(700px, calc(100vh - 164px)); border-radius: 24px; }
.device-shell.landscape .device-camera { width: 8px; height: 8px; top: 7px; border-radius: 50%; }
.device-shell.landscape .device-screen { border-radius: 19px; }
.device-camera {
  position: absolute;
  top: 6px;
  left: 50%;
  z-index: 20;
  width: 88px;
  height: 20px;
  border-radius: 0 0 12px 12px;
  background: #182033;
  transform: translateX(-50%);
}
.device-shell.tablet .device-camera { width: 8px; height: 8px; top: 7px; border-radius: 50%; }

.device-screen {
  height: 100%;
  overflow: hidden;
  border-radius: 30px;
  background: #f4f6f9;
}
.device-shell.tablet .device-screen { border-radius: 18px; }

body.installed-app { overflow: hidden; background: #f4f6f9; }
body.installed-app .studio-toolbar,
body.installed-app .preview-caption,
body.installed-app .desktop-column,
body.installed-app .device-camera { display: none; }
body.installed-app .preview-workspace {
  width: 100vw;
  height: 100vh;
  display: block;
  background: #f4f6f9;
}
body.installed-app .device-column { width: 100%; height: 100%; display: block; }
body.installed-app .device-stage { width: 100%; height: 100%; padding: 0; overflow: hidden; background: #f4f6f9; }
body.installed-app .device-shell,
body.installed-app .device-shell.phone,
body.installed-app .device-shell.phone.landscape,
body.installed-app .device-shell.tablet,
body.installed-app .device-shell.tablet.landscape {
  width: 100vw;
  height: 100vh;
  max-width: none;
  max-height: none;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}
body.installed-app .device-screen,
body.installed-app .device-shell.landscape .device-screen,
body.installed-app .device-shell.tablet .device-screen { border-radius: 0; }

.desktop-column iframe {
  width: 100%;
  height: 100%;
  border: 0;
  background: #fff;
}

.app {
  height: 100%;
  display: grid;
  grid-template-rows: 24px auto minmax(0, 1fr) 64px;
  background: #f3f6fa;
}
.app.login-mode { display: block; overflow: auto; }
.status-bar {
  padding: 4px 18px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: #fff;
  background: var(--blue-dark);
  font-size: 9px;
  font-weight: 800;
}
.status-icons { letter-spacing: 2px; }

.app-header {
  min-height: 60px;
  padding: 10px 15px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: #fff;
  background: var(--blue);
}
.app-header-main { min-width: 0; display: flex; align-items: center; gap: 10px; }
.app-header-logo { width: 34px; height: 34px; padding: 2px; object-fit: contain; border-radius: 9px; background: #fff; }
.app-header-copy { min-width: 0; display: grid; gap: 1px; }
.app-header-copy span { font-size: 9px; font-weight: 800; opacity: .82; }
.app-header-copy strong { overflow: hidden; font-size: 16px; text-overflow: ellipsis; white-space: nowrap; }
.icon-button {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  color: inherit;
  border: 0;
  border-radius: 10px;
  background: rgba(255,255,255,.13);
  font-size: 18px;
}

.app-content {
  min-height: 0;
  padding: 13px;
  overflow-y: auto;
  overscroll-behavior: contain;
}
.app-header-actions { display: flex; align-items: center; gap: 4px; }
.app-content::-webkit-scrollbar { width: 4px; }
.app-content::-webkit-scrollbar-thumb { border-radius: 99px; background: #c2cbd8; }

.app-bottom-nav {
  padding: 7px 8px calc(7px + env(safe-area-inset-bottom));
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 3px;
  border-top: 1px solid var(--line);
  background: rgba(255,255,255,.98);
  box-shadow: 0 -4px 15px rgba(24,32,51,.05);
}
.nav-button {
  min-width: 0;
  padding: 4px 2px;
  display: grid;
  place-items: center;
  gap: 2px;
  color: #778297;
  border: 0;
  border-radius: 9px;
  background: transparent;
  font-size: 9px;
  font-weight: 800;
}
.nav-button .nav-icon { font-size: 18px; line-height: 1; }
.nav-button.active { color: var(--blue); background: #edf1ff; }

.login-screen {
  min-height: 100%;
  padding: 34px 22px 24px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  color: var(--ink);
  background:
    radial-gradient(circle at 88% 8%, rgba(8,164,223,.24), transparent 28%),
    linear-gradient(160deg, #24377e 0 31%, #f5f7fb 31% 100%);
}
.login-brand { margin-bottom: 28px; color: #fff; }
.login-brand img {
  width: 78px;
  height: 78px;
  padding: 6px;
  border-radius: 20px;
  object-fit: contain;
  background: #fff;
  box-shadow: 0 12px 30px rgba(0,0,0,.18);
}
.login-brand h1 { margin: 13px 0 2px; font-size: 25px; letter-spacing: -.03em; }
.login-brand p { margin: 0; font-size: 12px; opacity: .82; }
.login-card {
  padding: 19px;
  border: 1px solid rgba(255,255,255,.7);
  border-radius: 20px;
  background: rgba(255,255,255,.97);
  box-shadow: 0 18px 45px rgba(24,32,51,.18);
}
.login-card h2 { margin: 0 0 4px; font-size: 20px; }
.login-card > p { margin: 0 0 17px; color: var(--muted); font-size: 11px; line-height: 1.45; }
.field { display: grid; gap: 5px; margin-bottom: 12px; }
.field label {
  color: #536177;
  font-size: 9px;
  font-weight: 900;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.field input, .field select, .field textarea {
  width: 100%;
  min-height: 43px;
  padding: 10px 12px;
  border: 1px solid #ccd5e1;
  border-radius: 11px;
  color: var(--ink);
  background: #fff;
  outline: none;
}
.field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--cyan);
  box-shadow: 0 0 0 3px rgba(8,164,223,.12);
}
.password-wrap { position: relative; }
.password-wrap input { padding-right: 44px; }
.password-toggle {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 35px;
  height: 35px;
  border: 0;
  border-radius: 9px;
  color: var(--blue);
  background: #f0f3fa;
}
.check-line {
  margin: 1px 0 15px;
  display: flex;
  align-items: center;
  gap: 8px;
  color: #4f5c6f;
  font-size: 11px;
}
.check-line input { width: 16px; height: 16px; accent-color: var(--blue); }

.primary-button, .secondary-button, .danger-button {
  min-height: 43px;
  padding: 10px 14px;
  border-radius: 11px;
  font-weight: 900;
}
.primary-button { color: #fff; border: 1px solid var(--blue); background: var(--blue); }
.primary-button:hover { background: var(--blue-dark); }
.secondary-button { color: var(--blue); border: 1px solid #c7d0e0; background: #fff; }
.danger-button { color: var(--danger); border: 1px solid #f0bcc3; background: #fff; }
.wide { width: 100%; }
.button-row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }

.login-footer {
  margin: 17px 0 0;
  color: #697487;
  font-size: 9px;
  line-height: 1.5;
  text-align: center;
}
.login-footer strong { color: var(--success); }

.eyebrow {
  margin: 0;
  color: var(--cyan);
  font-size: 9px;
  font-weight: 900;
  letter-spacing: .1em;
  text-transform: uppercase;
}
.screen-title-row { margin-bottom: 11px; display: flex; justify-content: space-between; align-items: end; gap: 10px; }
.screen-title-row h2 { margin: 2px 0 0; font-size: 21px; letter-spacing: -.025em; }
.screen-title-row small { color: var(--muted); font-size: 9px; }
.unit-badge {
  padding: 5px 8px;
  border: 1px solid #d5deeb;
  border-radius: 8px;
  color: #536177;
  background: #fff;
  font-size: 9px;
  font-weight: 900;
  white-space: nowrap;
}

.sync-banner {
  margin-bottom: 11px;
  padding: 8px 10px;
  display: flex;
  align-items: center;
  gap: 7px;
  border: 1px solid #bfe7d8;
  border-radius: 10px;
  color: #146b52;
  background: var(--success-soft);
  font-size: 9px;
  font-weight: 800;
}
.sync-banner::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--success);
}

.hero-card {
  padding: 15px;
  color: #fff;
  border-radius: 18px;
  background:
    linear-gradient(135deg, rgba(255,255,255,.12), transparent 38%),
    linear-gradient(135deg, var(--blue-dark), var(--blue));
  box-shadow: 0 10px 23px rgba(47,69,159,.22);
}
.hero-card-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.hero-card .eyebrow { color: #83d8f6; }
.hero-card h3 { margin: 3px 0 2px; font-size: 20px; }
.hero-card p { margin: 0; font-size: 10px; opacity: .8; }
.time-pill {
  padding: 5px 8px;
  border-radius: 9px;
  background: rgba(255,255,255,.14);
  font-size: 10px;
  font-weight: 900;
}
.hero-meta {
  margin: 13px 0;
  padding: 9px 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  border-top: 1px solid rgba(255,255,255,.16);
  border-bottom: 1px solid rgba(255,255,255,.16);
}
.hero-meta span { display: grid; gap: 2px; font-size: 9px; opacity: .82; }
.hero-meta strong { font-size: 11px; opacity: 1; }
.hero-actions { display: grid; grid-template-columns: 1fr auto; gap: 8px; }
.hero-actions button {
  min-height: 38px;
  padding: 8px 10px;
  border: 0;
  border-radius: 10px;
  font-weight: 900;
}
.hero-actions button:first-child { color: var(--blue); background: #fff; }
.hero-actions button:last-child { color: #fff; background: rgba(255,255,255,.15); }

.section { margin-top: 15px; }
.section-header { margin-bottom: 8px; display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.section-header h3 { margin: 0; font-size: 13px; }
.mobile-inline-filter {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-size: 9px;
  font-weight: 800;
}
.mobile-inline-filter select {
  min-height: 30px;
  padding: 4px 24px 4px 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  background: #fff;
  font: inherit;
}
.section-header button {
  color: var(--blue);
  border: 0;
  background: transparent;
  font-size: 9px;
  font-weight: 900;
}

/* In der installierten Mitarbeiter-App bleiben auch die kompakten
   Abschnittsfilter sichere Touchziele. Die Studiovorschau darf weiterhin
   dichter sein, solange kein echtes Telefonschema aktiv ist. */
.installed-app .section-header button {
  min-width: 44px;
  min-height: 44px;
  padding: 8px 10px;
  border-radius: 8px;
  font-size: 10px;
}

.metric-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 7px; }
.metric-card {
  min-width: 0;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: #fff;
}
.metric-card span { display: block; color: var(--muted); font-size: 8px; font-weight: 800; }
.metric-card strong { display: block; margin-top: 3px; font-size: 18px; }
.metric-card.warning { border-color: #f0d18a; background: var(--warning-soft); }
.metric-card.danger { border-color: #f2b9c1; background: var(--danger-soft); }

.task-list, .timeline-list, .student-list, .audit-list { display: grid; gap: 7px; }
.task-card, .timeline-card, .student-card, .audit-card {
  width: 100%;
  padding: 10px;
  display: grid;
  grid-template-columns: auto minmax(0,1fr) auto;
  align-items: center;
  gap: 9px;
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 13px;
  background: #fff;
  text-align: left;
}
.task-icon, .student-avatar {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  color: var(--blue);
  background: #edf1ff;
  font-size: 15px;
  font-weight: 900;
}
.task-card.warning .task-icon { color: #996a00; background: var(--warning-soft); }
.task-card.danger .task-icon { color: var(--danger); background: var(--danger-soft); }
.task-copy, .timeline-copy, .student-copy { min-width: 0; display: grid; gap: 2px; }
.task-copy strong, .timeline-copy strong, .student-copy strong {
  overflow: hidden;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.task-copy span, .timeline-copy span, .student-copy span { color: var(--muted); font-size: 9px; line-height: 1.35; }
.chevron { color: #8893a3; font-size: 17px; }

.week-strip {
  margin-bottom: 12px;
  padding: 5px;
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 3px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: #fff;
}
.day-button {
  min-width: 0;
  padding: 6px 2px;
  display: grid;
  place-items: center;
  gap: 2px;
  color: #6a7587;
  border: 0;
  border-radius: 9px;
  background: transparent;
  font-size: 8px;
  font-weight: 800;
}
.day-button strong { font-size: 13px; }
.day-button.active { color: #fff; background: var(--blue); }
.day-button.has-event::after {
  content: "";
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--cyan);
}
.day-button.active::after { background: #fff; }

.calendar-summary {
  margin-bottom: 9px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.calendar-summary strong { font-size: 13px; }
.calendar-summary span { color: var(--muted); font-size: 9px; }
.timeline-card { padding: 0; overflow: hidden; align-items: stretch; grid-template-columns: 52px 5px minmax(0,1fr) auto; }
.timeline-time {
  padding: 11px 3px 11px 9px;
  display: grid;
  align-content: start;
  color: #47546a;
  font-size: 9px;
  font-weight: 900;
}
.timeline-time small { display: block; margin-top: 2px; color: #8a95a6; font-size: 7px; }
.timeline-color { background: #75de83; }
.timeline-color.blue { background: #9ab9ee; }
.timeline-color.yellow { background: #f4df6c; }
.timeline-color.dark { background: #404040; }
.timeline-color.orange { background: #ffba64; }
.timeline-color.exam { background: #d94b5b; }
.timeline-copy { padding: 10px 3px; }
.timeline-actions { padding: 8px; display: flex; align-items: center; gap: 5px; }
.timeline-actions > b { color: #8792a2; font-size: 14px; }
.timeline-card.read-only { cursor: default; }
.status-chip {
  padding: 4px 6px;
  border-radius: 7px;
  color: #5c6678;
  background: #edf0f4;
  font-size: 7px;
  font-weight: 900;
  text-transform: uppercase;
}
.status-chip.booked { color: #11684e; background: #ddf3ea; }
.status-chip.missing { color: #a16b00; background: #fff1c9; }

.search-box {
  margin-bottom: 10px;
  position: relative;
}
.search-box::before {
  content: "⌕";
  position: absolute;
  left: 11px;
  top: 8px;
  color: #8490a2;
  font-size: 19px;
}
.search-box input {
  width: 100%;
  min-height: 40px;
  padding: 9px 12px 9px 36px;
  border: 1px solid #ccd5e1;
  border-radius: 11px;
  background: #fff;
}
.student-card { grid-template-columns: auto minmax(0,1fr) auto; }
.student-avatar { color: #fff; background: linear-gradient(135deg, var(--blue), var(--cyan)); }
.student-progress {
  min-width: 60px;
  display: grid;
  gap: 3px;
  text-align: right;
}
.student-progress strong { font-size: 9px; }
.progress-bar { height: 4px; overflow: hidden; border-radius: 99px; background: #e7eaf0; }
.progress-bar span { display: block; height: 100%; border-radius: inherit; background: var(--success); }

.back-row { margin-bottom: 9px; }
.back-button {
  padding: 5px 8px;
  color: var(--blue);
  border: 0;
  border-radius: 8px;
  background: #e9edfb;
  font-size: 10px;
  font-weight: 900;
}
.profile-head {
  margin-bottom: 10px;
  padding: 13px;
  display: grid;
  grid-template-columns: auto minmax(0,1fr);
  gap: 11px;
  border: 1px solid var(--line);
  border-radius: 15px;
  background: #fff;
}
.profile-head .student-avatar { width: 48px; height: 48px; font-size: 18px; }
.profile-head h2 { margin: 0 0 2px; font-size: 18px; }
.profile-head p { margin: 0; color: var(--muted); font-size: 9px; }
.profile-tags { margin-top: 6px; display: flex; gap: 5px; flex-wrap: wrap; }
.tag {
  padding: 3px 6px;
  border-radius: 7px;
  color: #4a5870;
  background: #eef1f5;
  font-size: 8px;
  font-weight: 900;
}
.tag.ok { color: #11684e; background: #ddf3ea; }
.tag.warn { color: #9a6800; background: #fff2cb; }
.info-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; }
.info-card {
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
}
.info-card span { display: block; color: var(--muted); font-size: 8px; }
.info-card strong { display: block; margin-top: 3px; font-size: 10px; }

.performance-list { display: grid; gap: 6px; }
.performance-row {
  padding: 8px 9px;
  display: grid;
  grid-template-columns: minmax(82px, 1.3fr) repeat(3, minmax(36px, .55fr));
  align-items: center;
  gap: 5px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
}
.performance-row.header { padding: 1px 9px 3px; border: 0; color: var(--muted); background: transparent; font-size: 7px; font-weight: 900; }
.performance-row strong { overflow: hidden; font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.performance-row span { font-size: 9px; font-weight: 800; text-align: right; }
.performance-row .open { color: var(--danger); }

.detail-card {
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 15px;
  background: #fff;
}
.detail-card + .detail-card { margin-top: 9px; }
.detail-card-head { display: flex; justify-content: space-between; gap: 10px; }
.detail-card h2, .detail-card h3 { margin: 0; }
.detail-card h2 { font-size: 18px; }
.detail-card h3 { font-size: 12px; }
.detail-card p { margin: 3px 0 0; color: var(--muted); font-size: 9px; line-height: 1.45; }
.detail-list { margin-top: 10px; display: grid; gap: 7px; }
.detail-row {
  padding: 7px 0;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid #edf0f4;
  font-size: 9px;
}
.detail-row:last-child { border-bottom: 0; }
.detail-row span { color: var(--muted); }
.detail-row strong { text-align: right; }
.notice {
  margin-top: 9px;
  padding: 9px 10px;
  border: 1px solid #f0d18a;
  border-radius: 10px;
  color: #775300;
  background: var(--warning-soft);
  font-size: 9px;
  line-height: 1.4;
}
.notice.success { border-color: #bfe7d8; color: #11684e; background: var(--success-soft); }
.notice[data-vehicle-occupancy] { font-size: 13px; line-height: 1.5; overflow-wrap: anywhere; }

.sticky-actions {
  margin-top: 11px;
  display: grid;
  gap: 7px;
}

.signature-summary {
  padding: 11px;
  border-radius: 13px;
  color: #fff;
  background: linear-gradient(135deg, var(--blue-dark), var(--blue));
}
.signature-summary strong { display: block; margin-bottom: 4px; font-size: 14px; }
.signature-summary span { display: block; font-size: 9px; opacity: .82; }
.signature-pad-wrap { margin-top: 10px; }
.signature-pad-label { margin-bottom: 6px; display: flex; justify-content: space-between; gap: 10px; font-size: 9px; font-weight: 900; }
.signature-pad-label button { color: var(--blue); border: 0; background: transparent; font-size: 9px; font-weight: 900; }
#signature-pad {
  width: 100%;
  height: 150px;
  display: block;
  touch-action: none;
  border: 1px dashed #aeb9c9;
  border-radius: 12px;
  background:
    linear-gradient(#fff, #fff) padding-box,
    repeating-linear-gradient(0deg, #fff 0 29px, #e7ebf0 30px) border-box;
}
.signature-hint { margin-top: 5px; color: var(--muted); font-size: 8px; text-align: center; }
.legal-check {
  margin: 10px 0;
  padding: 9px;
  display: flex;
  align-items: flex-start;
  gap: 8px;
  border-radius: 10px;
  background: #f0f3f8;
  font-size: 9px;
  line-height: 1.4;
}
.legal-check input { width: 16px; height: 16px; flex: 0 0 auto; accent-color: var(--blue); }

.success-screen { min-height: 100%; display: grid; align-content: center; gap: 12px; text-align: center; }
.success-icon {
  width: 72px;
  height: 72px;
  margin: 0 auto;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: var(--success);
  box-shadow: 0 10px 24px rgba(24,139,103,.25);
  font-size: 34px;
}
.success-screen h2 { margin: 0; font-size: 21px; }
.success-screen > p { margin: -5px 0 0; color: var(--muted); font-size: 10px; line-height: 1.45; }
.receipt {
  padding: 11px;
  display: grid;
  gap: 7px;
  border: 1px solid #bfe7d8;
  border-radius: 13px;
  background: var(--success-soft);
  text-align: left;
}
.receipt div { display: flex; justify-content: space-between; gap: 10px; font-size: 9px; }
.receipt span { color: #467064; }

.office-hero {
  padding: 14px;
  border: 1px solid #c8d4ea;
  border-radius: 16px;
  background: linear-gradient(135deg, #fff, #edf1ff);
}
.office-hero h2 { margin: 2px 0 3px; font-size: 20px; }
.office-hero p { margin: 0; color: var(--muted); font-size: 9px; }
.office-metrics { margin-top: 11px; display: grid; grid-template-columns: repeat(3,1fr); gap: 7px; }
.office-metrics div { padding: 8px; border-radius: 10px; background: #fff; }
.office-metrics strong { display: block; font-size: 17px; }
.office-metrics span { color: var(--muted); font-size: 7px; font-weight: 800; }
.signature-card {
  width: 100%;
  padding: 10px;
  display: grid;
  grid-template-columns: auto minmax(0,1fr) auto;
  align-items: center;
  gap: 9px;
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 13px;
  background: #fff;
  text-align: left;
}
.signature-state {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  color: var(--success);
  background: var(--success-soft);
  font-weight: 900;
}
.signature-state.pending { color: var(--warning); background: var(--warning-soft); }
.signature-card-copy { min-width: 0; display: grid; gap: 2px; }
.signature-card-copy strong { overflow: hidden; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.signature-card-copy span { color: var(--muted); font-size: 8px; }
.signature-card time { color: #566277; font-size: 8px; font-weight: 900; }
.audit-card { grid-template-columns: 10px minmax(0,1fr); align-items: start; }
.audit-dot { width: 8px; height: 8px; margin-top: 3px; border-radius: 50%; background: var(--success); box-shadow: 0 0 0 4px var(--success-soft); }
.audit-copy strong { display: block; font-size: 10px; }
.audit-copy span { display: block; margin-top: 2px; color: var(--muted); font-size: 8px; line-height: 1.4; }
.audit-proof {
  margin-top: 9px;
  padding: 9px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: #f7f9fb;
}
.audit-proof div { display: grid; gap: 2px; }
.audit-proof span { color: var(--muted); font-size: 7px; text-transform: uppercase; }
.audit-proof strong { font-size: 9px; }
.mock-signature {
  height: 68px;
  margin-top: 9px;
  display: grid;
  place-items: center;
  border: 1px dashed #bcc5d2;
  border-radius: 11px;
  color: #253a81;
  background: #fff;
  font-family: "Segoe Script", "Comic Sans MS", cursive;
  font-size: 24px;
  transform: rotate(-3deg);
}

.mock-signature img {
  display: block;
  width: 100%;
  max-height: 150px;
  object-fit: contain;
}

.more-list { display: grid; gap: 8px; }
.mobile-account-hero {
  margin-bottom: 10px;
  overflow: hidden;
  border: 1px solid #cbd8eb;
  border-radius: 16px;
  background: linear-gradient(145deg, #fff 0%, #f1f6ff 100%);
  box-shadow: 0 8px 20px rgba(28, 55, 105, .08);
}
.mobile-account-button {
  width: 100%;
  min-width: 0;
  padding: 13px;
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  border: 0;
  color: inherit;
  background: transparent;
  text-align: left;
  cursor: pointer;
}
.mobile-account-avatar,
.mobile-profile-avatar {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 13px;
  color: #fff;
  background: linear-gradient(145deg, var(--blue), #087da9);
  box-shadow: 0 6px 14px rgba(47, 69, 159, .22);
  font-size: 13px;
  font-weight: 900;
}
.mobile-account-copy { min-width: 0; display: grid; gap: 2px; }
.mobile-account-copy small { color: var(--muted); font-size: 7px; font-weight: 850; text-transform: uppercase; letter-spacing: .04em; }
.mobile-account-copy strong { overflow: hidden; font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }
.mobile-account-copy > span { overflow: hidden; color: var(--muted); font-size: 8px; text-overflow: ellipsis; white-space: nowrap; }
.mobile-system-strip {
  min-width: 0;
  padding: 7px 12px;
  display: flex;
  align-items: center;
  gap: 7px;
  border-top: 1px solid #dbe4f2;
  color: #53657a;
  background: rgba(255,255,255,.72);
  font-size: 7px;
  font-weight: 750;
}
.mobile-system-strip > span { min-width: 0; }
.mobile-system-strip > span:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mobile-system-strip .online,
.mobile-system-strip .offline { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 4px; font-weight: 900; }
.mobile-system-strip i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.mobile-system-strip .online { color: #147755; }
.mobile-system-strip .offline { color: #b26a0a; }
.more-action-grid {
  margin-bottom: 10px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.more-action-grid button {
  min-width: 0;
  min-height: 82px;
  padding: 10px;
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr);
  grid-template-rows: auto auto;
  align-content: center;
  align-items: center;
  gap: 2px 8px;
  border: 1px solid #d7e0ed;
  border-radius: 14px;
  color: #18344e;
  background: #fff;
  box-shadow: 0 4px 12px rgba(31, 53, 86, .05);
  text-align: left;
  cursor: pointer;
}
.more-action-grid button:hover { border-color: #91b5e4; background: #f7faff; }
.more-action-icon { width: 30px; height: 30px; grid-row: 1 / span 2; display: grid; place-items: center; border-radius: 10px; color: var(--blue); background: #e9efff; font-size: 12px; font-weight: 900; }
.more-action-grid strong { min-width: 0; font-size: 10px; overflow-wrap: anywhere; }
.more-action-grid small { min-width: 0; color: var(--muted); font-size: 7px; line-height: 1.3; overflow-wrap: anywhere; }
.app-rights-disclosure {
  margin-bottom: 10px;
  border: 1px solid #d7e0ed;
  border-radius: 14px;
  background: #fff;
}
.app-rights-disclosure summary { min-height: 46px; padding: 9px 11px; display: flex; align-items: center; justify-content: space-between; gap: 10px; list-style: none; cursor: pointer; }
.app-rights-disclosure summary::-webkit-details-marker { display: none; }
.app-rights-disclosure summary > span:first-child { min-width: 0; display: grid; gap: 2px; }
.app-rights-disclosure summary strong { font-size: 10px; }
.app-rights-disclosure summary small { color: var(--muted); font-size: 7px; }
.app-rights-disclosure[open] summary { border-bottom: 1px solid #e1e7f0; }
.app-rights-disclosure ul { margin: 0; padding: 9px 11px 4px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 5px; list-style: none; }
.app-rights-disclosure li { min-width: 0; padding: 5px 6px; display: flex; align-items: center; gap: 5px; border-radius: 8px; color: #6d7889; background: #f0f3f7; font-size: 7px; font-weight: 800; overflow-wrap: anywhere; }
.app-rights-disclosure li.active { color: #11684e; background: var(--success-soft); }
.app-rights-disclosure li span { flex: 0 0 auto; color: inherit; }
.app-rights-disclosure p { margin: 0; padding: 5px 11px 10px; color: var(--muted); font-size: 7px; line-height: 1.4; }
.mobile-logout-button {
  width: 100%;
  min-height: 44px;
  border: 1px solid #efb6bf;
  border-radius: 13px;
  color: #ae3042;
  background: #fff8f9;
  font-size: 10px;
  font-weight: 900;
  cursor: pointer;
}
.mobile-profile-card { margin-bottom: 10px; padding: 14px; display: grid; grid-template-columns: 48px minmax(0, 1fr); align-items: center; gap: 11px; border-radius: 16px; color: #fff; background: linear-gradient(145deg, #243a88, #087da9); box-shadow: 0 8px 20px rgba(36, 58, 136, .2); }
.mobile-profile-card .mobile-profile-avatar { width: 48px; height: 48px; color: #223b7f; background: #fff; box-shadow: none; }
.mobile-profile-card > div { min-width: 0; display: grid; gap: 2px; }
.mobile-profile-card .eyebrow { color: rgba(255,255,255,.78); }
.mobile-profile-card h2 { margin: 0; overflow: hidden; font-size: 18px; text-overflow: ellipsis; white-space: nowrap; }
.mobile-profile-card > div > span { font-size: 9px; opacity: .86; }
.profile-quick-actions { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 7px; }
.display-choice-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.display-choice { min-width: 0; min-height: 86px; padding: 10px; display: grid; align-content: center; gap: 3px; border: 1px solid #d7e0ed; border-radius: 12px; color: #31455d; background: #fff; text-align: left; cursor: pointer; }
.display-choice > span { color: var(--blue); font-size: 17px; font-weight: 900; }
.display-choice .large-letter { font-size: 22px; line-height: .9; }
.display-choice strong { font-size: 10px; }
.display-choice small { color: var(--muted); font-size: 7px; line-height: 1.35; }
.display-choice.active { border-color: #587bd1; background: #eef3ff; box-shadow: inset 0 0 0 1px #587bd1; }
.has-header-back .back-row { display: none; }
.mobile-page-intro { margin: 0 0 10px; color: var(--muted); font-size: 9px; line-height: 1.45; }
.display-settings-panel { display: grid; gap: 0; padding-block: 2px; overflow: hidden; }
.display-setting-block { padding: 12px; }
.display-setting-block + .display-setting-block { border-top: 1px solid var(--line); }
.display-setting-block h3 { margin: 0 0 8px; color: var(--blue-dark); font-size: 11px; }
.display-choice-grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.display-choice-grid.three .display-choice { min-height: 74px; text-align: center; }
.display-reset-button { margin-top: 9px; }
.help-panel { overflow: hidden; }
.help-status-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; margin-bottom: 9px; }
.help-status-grid > div { padding: 9px; display: grid; gap: 3px; border: 1px solid var(--line); border-radius: 10px; background: #f7f9fc; }
.help-status-grid span { color: var(--muted); font-size: 7px; font-weight: 800; text-transform: uppercase; }
.help-status-grid strong { color: var(--blue-dark); font-size: 12px; }
.help-actions { display: grid; gap: 7px; }
.vacation-balance-card {
  margin-bottom: 10px;
  padding: 11px;
  display: grid;
  grid-template-columns: repeat(3,1fr);
  gap: 7px;
  border-radius: 14px;
  color: #fff;
  background: linear-gradient(135deg,#293e8e,#08a4df);
  box-shadow: 0 8px 18px rgba(47,69,159,.18);
}
.vacation-balance-card > div { min-width:0; display:grid; gap:2px; }
.vacation-balance-card > div + div { padding-left:8px; border-left:1px solid rgba(255,255,255,.25); }
.vacation-balance-card span { font-size:7px; font-weight:800; text-transform:uppercase; }
.vacation-balance-card strong { font-size:19px; line-height:1; }
.vacation-balance-card small { font-size:7px; opacity:.84; }
.vacation-new-button { margin-bottom:9px; }
.vacation-flow-note {
  margin-bottom:10px;
  padding:8px;
  display:flex;
  align-items:center;
  justify-content:center;
  gap:4px;
  border:1px solid #dce3ef;
  border-radius:11px;
  background:#fff;
  color:#536078;
}
.vacation-flow-note span { width:18px; height:18px; display:grid; place-items:center; border-radius:50%; color:#fff; background:var(--blue); font-size:7px; font-weight:900; }
.vacation-flow-note b { font-size:7px; }
.vacation-flow-note i { color:#a0aabc; font-style:normal; }
.vacation-request-list { display:grid; gap:7px; }
.vacation-request-card {
  padding:10px;
  display:grid;
  gap:7px;
  border:1px solid #dce3ed;
  border-left:5px solid #8f9bb0;
  border-radius:12px;
  background:#fff;
}
.vacation-request-card.pending { border-left-color:#dfa51e; background:#fffdf6; }
.vacation-request-card.approved { border-left-color:#188b67; background:#f6fffb; }
.vacation-request-card.rejected { border-left-color:#d94b5b; background:#fff8f9; }
.vacation-request-card.cancelled { opacity:.68; }
.vacation-request-head { min-width:0; display:grid; grid-template-columns:auto minmax(0,1fr) auto; align-items:center; gap:7px; }
.vacation-request-icon { width:25px; height:25px; display:grid; place-items:center; border-radius:8px; color:#fff; background:#78849a; font-size:11px; font-weight:900; }
.vacation-request-card.pending .vacation-request-icon { background:#dfa51e; }
.vacation-request-card.approved .vacation-request-icon { background:#188b67; }
.vacation-request-card.rejected .vacation-request-icon { background:#d94b5b; }
.vacation-request-head div { min-width:0; display:grid; gap:1px; }
.vacation-request-head strong { overflow:hidden; font-size:10px; text-overflow:ellipsis; white-space:nowrap; }
.vacation-request-head div span { color:var(--muted); font-size:7px; }
.vacation-state { padding:4px 6px; border-radius:999px; color:#6d4d08; background:#fff0bb; font-size:7px; font-weight:900; white-space:nowrap; }
.vacation-request-card.approved .vacation-state { color:#0e6248; background:#d9f4e9; }
.vacation-request-card.rejected .vacation-state { color:#9a2638; background:#ffe0e5; }
.vacation-request-card > p { margin:0; color:#526078; font-size:8px; line-height:1.4; }
.vacation-request-foot { display:flex; align-items:center; justify-content:space-between; gap:8px; }
.vacation-request-foot small { color:var(--muted); font-size:7px; }
.vacation-request-foot button { padding:5px 7px; color:var(--blue); border:1px solid #ccd5e5; border-radius:7px; background:#fff; font-size:7px; font-weight:900; }
.vacation-request-form { max-width:620px; margin:0 auto; }
.vacation-days-preview { margin:9px 0; padding:9px 11px; display:flex; align-items:center; justify-content:space-between; border-radius:10px; color:#145f48; background:#e3f6ee; }
.vacation-days-preview span { font-size:8px; font-weight:750; }
.vacation-days-preview strong { font-size:13px; }
.more-card {
  width: 100%;
  padding: 12px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 10px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: #fff;
  color: inherit;
  text-align: left;
}
button.more-card { cursor:pointer; }
button.more-card:hover { border-color:#8eb5e8; background:#f5f9ff; }
.more-card .task-icon { font-size: 14px; }
.more-card strong { display: block; font-size: 11px; }
.more-card span { display: block; margin-top: 2px; color: var(--muted); font-size: 8px; }

.floating-action {
  position: absolute;
  right: 15px;
  bottom: 73px;
  width: auto;
  min-width: 45px;
  height: 45px;
  padding: 0 13px;
  display: flex;
  gap: 6px;
  display: grid;
  place-items: center;
  color: #fff;
  border: 0;
  border-radius: 15px;
  background: var(--blue);
  box-shadow: 0 9px 20px rgba(47,69,159,.32);
  font-size: 23px;
}
.floating-action b { font-size: 10px; }

.calendar-toolbar {
  margin-bottom: 9px;
  display: grid;
  grid-template-columns: auto minmax(0,1fr) auto;
  align-items: center;
  gap: 8px;
}
.calendar-toolbar h2 { margin: 0; font-size: 13px; line-height: 1.2; }
.calendar-view-tools { display: flex; align-items: center; gap: 5px; }
.calendar-zoom-control {
  display: flex;
  align-items: stretch;
  overflow: hidden;
  border: 1px solid #d9dfeb;
  border-radius: 9px;
  background: #fff;
}
.calendar-zoom-control > button {
  min-width: 24px;
  padding: 0 6px;
  color: var(--blue);
  border: 0;
  background: #fff;
  font-size: 12px;
  font-weight: 900;
}
.calendar-zoom-control > button + button { border-left: 1px solid #e3e7ef; }
.calendar-zoom-indicator {
  display: grid;
  justify-items: center;
  gap: 1px;
  min-width: 48px;
  padding: 4px 7px;
  color: #32405a;
  border-radius: 0;
  background: #fff;
}
.calendar-zoom-indicator span { color: var(--muted); font-size: 6px; font-weight: 800; }
.calendar-zoom-indicator b { color: var(--blue); font-size: 9px; }
.calendar-nav { display: flex; gap: 3px; }
.calendar-nav button {
  min-width: 28px;
  height: 30px;
  padding: 0 7px;
  color: var(--blue);
  border: 1px solid #d6ddeb;
  border-radius: 8px;
  background: #fff;
  font-size: 10px;
  font-weight: 900;
}
.calendar-instructor-wrap { position: relative; margin-bottom: 9px; }
.calendar-instructor-button, .calendar-instructor-static {
  width: 100%;
  padding: 8px 10px;
  display: grid;
  grid-template-columns: auto minmax(0,1fr) auto;
  align-items: center;
  gap: 8px;
  color: var(--ink);
  border: 1px solid #c9d6ee;
  border-radius: 13px;
  background: linear-gradient(135deg, #fff, #f2f6ff);
  text-align: left;
}
.calendar-instructor-button > span:nth-child(2),
.calendar-instructor-static > span:nth-child(2) { min-width: 0; display: grid; gap: 1px; }
.calendar-instructor-button small, .calendar-instructor-static small { color: var(--muted); font-size: 7px; }
.calendar-instructor-button strong, .calendar-instructor-static strong { overflow: hidden; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.calendar-instructor-button em, .calendar-instructor-static em { overflow: hidden; color: #5e6a7c; font-size: 8px; font-style: normal; text-overflow: ellipsis; white-space: nowrap; }
.calendar-instructor-button > b { color: var(--blue); font-size: 15px; }
.instructor-avatar {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  color: #fff;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  font-size: 10px;
  font-weight: 900;
}
.rights-lock {
  padding: 4px 6px;
  border-radius: 7px;
  color: #4b6175;
  background: #e9eef5;
  font-size: 7px;
  font-weight: 900;
  text-transform: uppercase;
}
.instructor-picker {
  position: absolute;
  inset: calc(100% + 5px) 0 auto;
  z-index: 25;
  padding: 6px;
  display: grid;
  gap: 4px;
  border: 1px solid #ccd6e5;
  border-radius: 13px;
  background: #fff;
  box-shadow: 0 14px 35px rgba(24,32,51,.18);
}
.picker-head { padding: 4px 5px 6px; display: flex; justify-content: space-between; gap: 10px; }
.picker-head strong { font-size: 9px; }
.picker-head span { color: var(--muted); font-size: 7px; }
.instructor-picker > button {
  width: 100%;
  padding: 7px;
  display: grid;
  grid-template-columns: auto minmax(0,1fr) auto;
  align-items: center;
  gap: 7px;
  color: var(--ink);
  border: 1px solid transparent;
  border-radius: 10px;
  background: #f7f9fc;
  text-align: left;
}
.instructor-picker > button.active { border-color: #9cb2e7; background: #edf2ff; }
.instructor-picker > button > span:nth-child(2) { min-width: 0; display: grid; gap: 1px; }
.instructor-picker strong { font-size: 9px; }
.instructor-picker small { overflow: hidden; color: var(--muted); font-size: 7px; text-overflow: ellipsis; white-space: nowrap; }
.instructor-picker b { color: var(--blue); }
.read-only-note {
  margin: -2px 0 8px;
  padding: 7px 9px;
  border-radius: 9px;
  color: #694f16;
  background: #fff5d9;
  font-size: 8px;
  line-height: 1.35;
}
.calendar-summary > div { min-width: 0; display: grid; gap: 1px; }
.calendar-summary > div span { display: block; }
.calendar-summary > b { color: var(--blue); font-size: 10px; }
.tablet-week { display: none; }
.empty-day {
  min-height: 160px;
  padding: 18px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 5px;
  border: 1px dashed #c9d2df;
  border-radius: 13px;
  color: var(--muted);
  background: rgba(255,255,255,.72);
  text-align: center;
}
.empty-day > span { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 50%; color: var(--success); background: var(--success-soft); font-weight: 900; }
.empty-day strong { color: var(--ink); font-size: 11px; }
.empty-day small { font-size: 8px; }
.appointment-editor-heading { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.appointment-owner {
  margin: 10px 0;
  padding: 8px 10px;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 1px 8px;
  border-radius: 10px;
  background: #eef2ff;
}
.appointment-owner span { grid-row: 1 / span 2; align-self: center; color: var(--blue); font-size: 8px; font-weight: 900; text-transform: uppercase; }
.appointment-owner strong { font-size: 10px; }
.appointment-owner small { color: var(--muted); font-size: 7px; }
.app-rights-card {
  padding: 11px;
  display: grid;
  gap: 9px;
  border: 1px solid #c9d6ee;
  border-radius: 13px;
  background: linear-gradient(135deg, #fff, #f1f5ff);
}
.app-rights-card > div { display: grid; gap: 2px; }
.app-rights-card strong { font-size: 11px; }
.app-rights-card span { color: var(--muted); font-size: 8px; }
.app-rights-card ul { margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 5px; list-style: none; }
.app-rights-card li { padding: 5px 6px; display: flex; gap: 5px; border-radius: 7px; color: #8993a2; background: #edf0f4; font-size: 7px; font-weight: 800; }
.app-rights-card li.active { color: #11684e; background: var(--success-soft); }
.app-rights-card li span { color: inherit; font-weight: 900; }

.device-shell.tablet .app { grid-template-rows: 27px auto minmax(0,1fr) 68px; }
.device-shell.tablet .app-content { padding: 18px; }
.device-shell.tablet .app-header { padding: 11px 18px; }
.device-shell.tablet .app-header-copy strong { font-size: 18px; }
.device-shell.tablet .home-layout,
.device-shell.tablet .office-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(260px, .9fr);
  gap: 14px;
  align-items: start;
}
.device-shell.tablet .section { margin-top: 0; }
.device-shell.tablet .home-right,
.device-shell.tablet .office-right { display: grid; gap: 14px; }
.device-shell.tablet .student-list { grid-template-columns: 1fr 1fr; }
.device-shell.tablet .performance-list { grid-template-columns: 1fr 1fr; }
.device-shell.tablet .performance-row.header { display: none; }
.device-shell.tablet .signature-layout {
  display: grid;
  grid-template-columns: minmax(260px,.8fr) minmax(360px,1.2fr);
  gap: 14px;
  align-items: start;
}
.device-shell.tablet #signature-pad { height: 240px; }
.device-shell.tablet .login-screen { padding: 42px 15%; }
.device-shell.tablet .login-card { max-width: 480px; width: 100%; align-self: center; }
.device-shell.tablet .login-brand { max-width: 480px; width: 100%; align-self: center; }
.device-shell.tablet .phone-week-strip { display: none; }
.device-shell.tablet .responsive-calendar-layout {
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(0,1.35fr) minmax(245px,.65fr);
  gap: 12px;
}
.calendar-zoom-viewport {
  position: relative;
  min-width: 0;
  min-height: 0;
  overflow: auto;
  overscroll-behavior: contain;
  touch-action: none;
  scrollbar-width: thin;
  scrollbar-color: #aeb8ca transparent;
}
.calendar-zoom-viewport::after {
  position: sticky;
  right: 8px;
  bottom: 8px;
  z-index: 4;
  float: right;
  padding: 3px 7px;
  color: #4b5870;
  border: 1px solid rgba(202,210,224,.9);
  border-radius: 999px;
  background: rgba(255,255,255,.9);
  box-shadow: 0 3px 10px rgba(27,43,75,.08);
  content: "Mit 2 Fingern zoomen";
  font-size: 6px;
  font-weight: 800;
  pointer-events: none;
}
.calendar-zoom-viewport.is-pinching { cursor: grabbing; }
.calendar-zoom-sizer { position: relative; min-width: 100%; min-height: 100%; }
.calendar-zoom-surface {
  position: absolute;
  inset: 0 auto auto 0;
  transform: scale(1);
  transform-origin: 0 0;
  will-change: transform;
}
.device-shell.tablet .calendar-zoom-viewport {
  min-height: 480px;
  border-radius: 14px;
}
.device-shell.tablet .tablet-week {
  min-height: 480px;
  height: 100%;
  display: grid;
  grid-template-rows: 42px minmax(0,1fr);
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
}
.tablet-week-head { display: grid; grid-template-columns: 44px repeat(7,1fr); border-bottom: 1px solid var(--line); }
.tablet-week-head > span { display: grid; place-items: center; color: var(--muted); font-size: 7px; font-weight: 900; }
.tablet-week-head button { display: grid; place-items: center; gap: 1px; color: #68758a; border: 0; border-left: 1px solid #edf0f4; background: #fff; font-size: 7px; font-weight: 800; }
.tablet-week-head button b { font-size: 10px; }
.tablet-week-head button.active { color: var(--blue); background: #eef2ff; }
.tablet-week-body { min-height: 0; display: grid; grid-template-columns: 44px repeat(7,1fr); }
.tablet-hours { display: grid; grid-template-rows: repeat(8,1fr); color: #7e8999; background: #f7f9fc; font-size: 7px; }
.tablet-hours span { padding: 4px; border-bottom: 1px solid #e7ebf1; }
.tablet-day-column {
  position: relative;
  min-width: 0;
  display: grid;
  grid-template-rows: repeat(8,1fr);
  gap: 2px;
  padding: 2px;
  border-left: 1px solid #edf0f4;
  background: repeating-linear-gradient(to bottom, transparent 0, transparent calc(12.5% - 1px), #edf0f4 12.5%);
}
.tablet-day-column.active { background-color: #f7f9ff; }
.tablet-event {
  grid-row: var(--event-row);
  min-width: 0;
  padding: 4px;
  overflow: hidden;
  color: #193c2c;
  border: 0;
  border-left: 3px solid #188b67;
  border-radius: 6px;
  background: #dff4e8;
  text-align: left;
}
.tablet-event.blue { color: #213c6e; border-color: #5c88d0; background: #e1eaf9; }
.tablet-event.yellow { color: #5f5100; border-color: #d2ae00; background: #fff5bd; }
.tablet-event.dark { color: #fff; border-color: #111; background: #414141; }
.tablet-event.orange { color: #704000; border-color: #dc8c22; background: #fff0dc; }
.tablet-event.exam { color: #812333; border-color: #d94b5b; background: #ffe4e8; }
.tablet-event b, .tablet-event span, .tablet-event small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tablet-event b { font-size: 7px; }
.tablet-event span { margin-top: 2px; font-size: 7px; font-weight: 900; }
.tablet-event small { margin-top: 1px; font-size: 6px; }
.device-shell.tablet .day-agenda { min-width: 0; }
.device-shell.landscape .app { grid-template-rows: 22px auto minmax(0,1fr) 54px; }
.device-shell.landscape .status-bar { padding-top: 2px; }
.device-shell.landscape .app-header { padding: 7px 14px; }
.device-shell.landscape .app-header-logo { width: 31px; height: 31px; }
.device-shell.landscape .app-content { padding: 9px 13px; }
.device-shell.landscape .phone-week-strip { display: none; }
.device-shell.landscape .responsive-calendar-layout {
  height: calc(100% - 1px);
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(0,1.55fr) minmax(255px,.65fr);
  gap: 10px;
}
.device-shell.landscape .tablet-week {
  min-height: 0;
  height: 100%;
  display: grid;
  grid-template-rows: 38px minmax(0,1fr);
}
.device-shell.landscape .calendar-zoom-viewport {
  min-height: 0;
  height: 100%;
  border-radius: 14px;
}
.device-shell.landscape .day-agenda {
  min-height: 0;
  overflow: auto;
  padding-right: 2px;
}
.device-shell.landscape .timeline-list { gap: 5px; }
.device-shell.landscape .timeline-card { grid-template-columns: 47px 5px minmax(0,1fr) auto; }
.device-shell.landscape .timeline-time { padding: 8px 3px 8px 7px; }
.device-shell.landscape .timeline-copy { padding: 7px 3px; }
.device-shell.landscape .timeline-actions { padding: 5px; }
.device-shell.landscape .app-bottom-nav { padding: 4px 12%; }
.device-shell.landscape .vacation-request-list { grid-template-columns:repeat(2,minmax(0,1fr)); }
.device-shell.landscape .vacation-request-form { max-width:760px; }
.device-shell.landscape .floating-action { bottom: 61px; }

.studio-toast {
  position: fixed;
  left: 50%;
  bottom: 20px;
  z-index: 100;
  max-width: min(420px, calc(100vw - 30px));
  padding: 10px 14px;
  color: #fff;
  border-radius: 10px;
  background: #182033;
  box-shadow: 0 10px 28px rgba(24,32,51,.28);
  font-size: 11px;
  font-weight: 800;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 12px);
  transition: .2s ease;
}
.studio-toast.show { opacity: 1; transform: translate(-50%, 0); }

@media (max-width: 1220px) {
  .studio-toolbar { grid-template-columns: minmax(220px, 1fr) auto; }
  .studio-state { display: none; }
  .preview-workspace { grid-template-columns: minmax(410px, 48%) minmax(470px, 52%); }
  .preview-tablet .preview-workspace { grid-template-columns: minmax(660px, 60%) minmax(440px, 40%); }
  .device-shell.tablet { width: min(760px, calc(60vw - 40px)); }
}

@media (max-width: 1500px) {
  .preview-caption p { display: none; }
}

@media (max-width: 900px) {
  body { overflow: auto; }
  .studio-toolbar { position: sticky; top: 0; grid-template-columns: 1fr; }
  .studio-brand { justify-content: center; }
  .preview-workspace { height: auto; min-height: calc(100vh - 120px); grid-template-columns: 1fr; }
  .desktop-column { display: none; }
  .device-column { min-height: calc(100vh - 120px); }
  .device-shell.phone { width: min(390px, calc(100vw - 42px)); height: 760px; }
  .device-shell.tablet { width: min(820px, calc(100vw - 42px)); height: 900px; }
}

@media (max-width: 500px) {
  .studio-toolbar { padding: 8px; }
  .studio-brand strong { font-size: 13px; }
  .studio-controls { gap: 5px; }
  .segmented button, .studio-reset { padding-inline: 9px; font-size: 10px; }
  .preview-caption p { display: none; }
  .device-stage { padding: 8px; place-items: start center; }
  .device-shell.phone { width: calc(100vw - 18px); height: calc(100vh - 188px); min-height: 610px; }
}
.mobile-version-badge {
  display: inline-flex;
  margin: 2px auto 10px;
  padding: 4px 8px;
  border: 1px solid rgba(255, 255, 255, .32);
  border-radius: 999px;
  font-size: 9px;
  font-weight: 900;
  letter-spacing: .04em;
}

.notification-center-list .task-card.ok .task-icon {
  color: var(--success);
  background: var(--success-soft);
}

.notification-center-list .task-card.info .task-icon {
  color: var(--blue);
  background: #edf1ff;
}

.offline-operation { margin-bottom: 10px; }
.offline-operation.auth_required,
.offline-operation.rejected { border-color: #e0a4a9; }
.offline-operation .section-header > div { display: grid; gap: 3px; min-width: 0; }
.offline-operation .section-header strong { overflow-wrap: anywhere; }

@media (max-width: 820px) {
  .device-shell.tablet.landscape { width: min(100%, 1024px); }
  .calendar-week-grid { min-width: 690px; }
  .lecturer-week-grid { min-width: 680px; }
}

@media (pointer: coarse) {
  .app-screen button, .app-screen select, .app-screen input, .app-screen textarea { min-height: 44px; }
  .calendar-zoom-surface { touch-action: none; }
}
body.mobile-density-compact .mobile-panel,
body.mobile-density-compact .detail-card { padding-block: 10px; }
body.mobile-density-compact .mobile-row,
body.mobile-density-compact .task-card { min-height: 52px; }
body.mobile-density-compact .more-action-grid button { min-height: 70px; padding: 8px; }
body.mobile-text-large .app-content { font-size: 112%; }
body.mobile-text-large .app-header-copy span,
body.mobile-text-large .more-action-grid small,
body.mobile-text-large .app-rights-disclosure small,
body.mobile-text-large .app-rights-disclosure li,
body.mobile-text-large .mobile-account-copy small,
body.mobile-text-large .mobile-account-copy > span { font-size: 9px; }
body.mobile-text-large .more-action-grid strong,
body.mobile-text-large .app-rights-disclosure summary strong { font-size: 12px; }
body.mobile-contrast-high .app { --line: #6b778a; }
body.mobile-contrast-high .app :is(button, input, select, textarea, .mobile-panel, .detail-card) { border-width: 2px; }
body.mobile-motion-reduced .app *,
body.mobile-motion-reduced .app *::before,
body.mobile-motion-reduced .app *::after { scroll-behavior: auto !important; animation: none !important; transition: none !important; }
body.mobile-theme-dark { background: #0a1020; }
body.mobile-theme-dark .app {
  --ink: #f1f5fb;
  --muted: #aab7c9;
  --line: #34445c;
  --canvas: #101827;
  --white: #182438;
  color: var(--ink);
  background: var(--canvas);
}
body.mobile-theme-dark .app-content { color: var(--ink); background: #101827; }
body.mobile-theme-dark :is(.mobile-panel, .detail-card, .app-rights-disclosure, .display-choice, .more-action-grid button, .mobile-row, .help-status-grid > div, .summary-grid > div) { color: var(--ink); border-color: #34445c; background: #192438; }
body.mobile-theme-dark :is(.display-setting-block h3, .help-status-grid strong, .summary-grid strong, .mobile-panel h3, .detail-card h2, .mobile-row strong) { color: #f1f5fb; }
body.mobile-theme-dark :is(.display-choice small, .mobile-page-intro, .help-status-grid span, .mobile-row small, .section-header span, .detail-row span) { color: #aab7c9; }
body.mobile-theme-dark .display-choice.active { border-color: #86a6ff; color: #fff; background: #243762; box-shadow: inset 0 0 0 1px #86a6ff; }
body.mobile-theme-dark :is(input, select, textarea) { color: #f1f5fb; border-color: #40516b; background: #121d30; color-scheme: dark; }
body.mobile-theme-dark .bottom-nav { border-color: #34445c; background: #182438; }
body.mobile-theme-dark .bottom-nav button { color: #aab7c9; background: transparent; }
body.mobile-theme-dark .bottom-nav button.active { color: #fff; background: #263b67; }
body.mobile-theme-dark .secondary-button { color: #dce7ff; border-color: #526785; background: #1d2b42; }

/* Flexible card layout for phone, tablet and the side-by-side preview. */
.preview-workspace { grid-template-columns: minmax(360px, 54%) minmax(0, 46%); }
.preview-tablet .preview-workspace { grid-template-columns: minmax(480px, 62%) minmax(0, 38%); }
.preview-landscape .preview-workspace { grid-template-columns: minmax(560px, 72%) minmax(0, 28%); }
.preview-caption > div,
.desktop-caption > div,
.app,
.app-screen,
.app-content,
.home-layout,
.home-right,
.office-layout,
.office-right,
.mobile-panel,
.detail-card,
.detail-card-head,
.section-header,
.screen-title-row,
.hero-card-top,
.mobile-kpi-grid > *,
.presence-strip > *,
.task-card > *,
.timeline-card > *,
.student-card > *,
.audit-card > *,
.mobile-row > *,
.mobile-week-list article > *,
.summary-grid > *,
.list-row > * { min-width: 0; max-width: 100%; }
.app-content { overflow-x: hidden; }
.app-screen :is(h1, h2, h3, h4, p, strong, small, span, label),
.preview-caption :is(strong, p),
.desktop-caption :is(strong, p) { overflow-wrap: anywhere; }
.screen-title-row,
.section-header,
.detail-card-head,
.hero-card-top { align-items: flex-start; flex-wrap: wrap; }
.unit-badge,
.status-chip,
.time-pill {
  flex: 0 1 auto;
  max-width: 100%;
  white-space: normal;
  text-align: center;
}
.task-copy strong,
.timeline-copy strong,
.student-copy strong,
.signature-card-copy strong,
.mobile-row strong {
  overflow: visible;
  text-overflow: clip;
  white-space: normal;
}
.summary-grid {
  margin: 10px 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(92px, 1fr));
  gap: 7px;
}
.summary-grid > div {
  padding: 9px;
  display: grid;
  gap: 3px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #f6f8fb;
}
.summary-grid span { color: var(--muted); font-size: 8px; font-weight: 800; text-transform: uppercase; }
.summary-grid strong { color: var(--blue-dark); font-size: 13px; }
.list-row {
  min-width: 0;
  padding: 9px 12px;
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr);
  align-items: center;
  gap: 9px;
  border-bottom: 1px solid var(--line);
}
.list-row:last-child { border-bottom: 0; }
.list-row > div { min-width: 0; display: grid; gap: 2px; }
.list-row strong { font-size: 11px; overflow-wrap: anywhere; }
.list-row small { color: var(--muted); font-size: 9px; overflow-wrap: anywhere; }
.mobile-time-card .primary-button,
.mobile-time-card .secondary-button { margin-top: 8px; }
.mobile-kpi-grid { grid-template-columns: repeat(auto-fit, minmax(104px, 1fr)); }
.presence-strip { grid-template-columns: repeat(auto-fit, minmax(68px, 1fr)); }
.office-metrics { grid-template-columns: repeat(auto-fit, minmax(82px, 1fr)); }
.field,
.field input,
.field select,
.field textarea,
.app-screen button { min-width: 0; max-width: 100%; }

@media (max-width: 1220px) and (min-width: 901px) {
  .preview-workspace,
  .preview-tablet .preview-workspace,
  .preview-landscape .preview-workspace { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .device-shell.phone,
  .device-shell.tablet,
  .device-shell.phone.landscape,
  .device-shell.tablet.landscape { width: min(calc(50vw - 28px), 100%); }
}

@media (max-width: 420px) {
  .app-content { padding: 10px; }
  .screen-title-row h2 { font-size: 18px; }
  .mobile-kpi-grid,
  .mobile-kpi-grid.two,
  .info-grid,
  .office-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .mobile-week-list article { grid-template-columns: 62px minmax(0, 1fr); gap: 7px; }
  .mobile-week-list article button { grid-column: 2; justify-self: start; }
  .timeline-card { grid-template-columns: 48px 5px minmax(0, 1fr); }
  .timeline-actions { grid-column: 3; padding: 0 7px 7px 3px; justify-content: flex-start; }
  .detail-row,
  .receipt div { flex-wrap: wrap; }
  .detail-row strong { text-align: left; }
  .button-row { grid-template-columns: 1fr; }
  .more-action-grid { gap: 7px; }
  .more-action-grid button { min-height: 76px; padding: 8px; }
  .display-choice-grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .display-choice-grid.three .display-choice { min-height: 70px; padding: 7px 4px; }
}

@media (max-width: 340px) {
  .more-action-grid,
  .display-choice-grid,
  .app-rights-disclosure ul { grid-template-columns: 1fr; }
  .mobile-account-button { grid-template-columns: 38px minmax(0, 1fr) auto; padding: 10px; }
  .mobile-account-avatar { width: 38px; height: 38px; }
}

/* Task access: scoped to the employee inbox/editor; existing navigation stays intact. */
.app-header .mobile-task-header-button { width:auto; min-width:72px; min-height:40px; padding:6px 9px; display:flex; gap:5px; font-size:14px; white-space:nowrap; }
.app-header .mobile-task-header-button span { font-size:11px; font-weight:800; }
.mobile-task-workspace { min-width:0; }
.mobile-task-workspace .screen-title-row { gap:10px; flex-wrap:wrap; }
.mobile-task-workspace .mobile-task-card { align-items:start; min-height:80px; }
.mobile-task-workspace .mobile-task-copy { min-width:0; display:grid; gap:5px; text-align:left; }
.mobile-task-workspace .mobile-task-copy strong { font-size:14px; line-height:1.4; }
.mobile-task-workspace .mobile-task-copy > small { font-size:11px; line-height:1.45; }
.mobile-task-workspace .mobile-task-board-picker select { width:100%; min-width:0; min-height:44px; font-size:14px; }
.mobile-task-workspace .mobile-task-board-context { padding:9px 11px; border-radius:10px; background:var(--cyan-soft); color:var(--ink); }
.mobile-task-workspace .mobile-task-meta { display:block; color:var(--muted); font-size:11px; line-height:1.45; }
.mobile-task-workspace .mobile-task-tags { display:flex; flex-wrap:wrap; gap:5px; min-width:0; }
.mobile-task-workspace .mobile-task-tags:empty { display:none; }
.mobile-task-workspace .mobile-task-tags span { padding:3px 7px; border-radius:8px; background:var(--cyan-soft); color:var(--cyan-text); font-size:11px; font-weight:750; }
.mobile-task-workspace :is(h2,h3,legend,p,small,dd,.mobile-task-tags span,.mobile-task-check span) { overflow-wrap:anywhere; }
.mobile-task-workspace .mobile-task-detail dl { margin:16px 0; display:grid; grid-template-columns:90px minmax(0,1fr); gap:8px; font-size:13px; line-height:1.45; }
.mobile-task-workspace .mobile-task-detail dt { font-weight:750; }
.mobile-task-workspace .mobile-task-detail dd { margin:0; min-width:0; }
.mobile-task-workspace .mobile-task-description { white-space:pre-wrap; font-size:13px; line-height:1.6; margin-top:15px; }
.mobile-task-workspace .mobile-task-editor { display:grid; gap:14px; }
.mobile-task-workspace .mobile-task-editor .field { min-width:0; margin:0; }
.mobile-task-workspace .mobile-task-editor .field :is(input,select,textarea) { min-width:0; width:100%; font-size:14px; min-height:44px; }
.mobile-task-workspace .mobile-task-editor p { font-size:12px; }
.mobile-task-workspace .mobile-task-editor h3 { font-size:14px; }
.mobile-task-workspace .mobile-task-assignee-group,
.mobile-task-workspace .mobile-task-visibility { min-width:0; padding:10px; border:1px solid var(--line); border-radius:12px; margin:10px 0 0; }
.mobile-task-workspace .mobile-task-assignee-group legend,
.mobile-task-workspace .mobile-task-visibility legend { max-width:100%; padding:0 5px; font-size:12px; font-weight:800; }
.mobile-task-workspace .mobile-task-check { min-height:44px; display:flex; align-items:center; gap:10px; padding:7px 5px; font-size:13px; line-height:1.45; cursor:pointer; }
.mobile-task-workspace .mobile-task-check input { flex:0 0 20px; width:20px; height:20px; accent-color:var(--blue); }
.mobile-task-workspace .mobile-task-audience { padding-top:8px; }
.mobile-task-workspace .mobile-task-audience[hidden] { display:none; }
.mobile-task-workspace .sticky-actions { display:flex; flex-wrap:wrap; gap:8px; }
.mobile-task-workspace .sticky-actions button { min-height:44px; }
.mobile-task-workspace .sticky-actions .wide { flex:1; min-width:120px; width:auto; }
.mobile-task-workspace :is(button,input,select,textarea):focus-visible,
.app-header .mobile-task-header-button:focus-visible { outline:3px solid #f3c345; outline-offset:2px; }
@media (max-width:420px) {
  .mobile-task-workspace .button-row { grid-template-columns:minmax(0,1fr); }
  .mobile-task-workspace .mobile-task-editor { padding:12px; }
}
.mobile-personal-shifts { min-width:0; }
.mobile-personal-shifts .mobile-week-list article { grid-template-columns:minmax(90px,120px) minmax(0,1fr); }
.mobile-personal-shifts .mobile-week-list article > strong { font-size:12px; line-height:1.5; }
.mobile-personal-shifts .mobile-week-list article > div { min-width:0; }
.mobile-personal-shifts .mobile-personal-shift { display:grid; gap:5px; padding:10px; border-radius:10px; background:var(--cyan-soft); }
.mobile-personal-shifts .mobile-personal-shift + .mobile-personal-shift { margin-top:7px; }
.mobile-personal-shifts .mobile-personal-shift.cancelled { opacity:.75; background:var(--danger-soft); }
.mobile-personal-shifts .mobile-personal-shift b { font-size:15px; }
.mobile-personal-shifts .mobile-personal-shift span { font-size:12px; }
.mobile-personal-shifts .mobile-personal-shift small,
.mobile-personal-shifts .mobile-personal-shift-empty { font-size:11px; }
.mobile-personal-shifts :is(strong,span,p,small) { overflow-wrap:anywhere; }
.mobile-personal-shifts .mobile-personal-shift p { margin:0; font-size:12px; white-space:pre-wrap; }
.mobile-personal-shifts .calendar-toolbar.compact { grid-template-columns:40px 48px minmax(0,1fr) 40px; }
.mobile-personal-shifts .calendar-toolbar.compact button { min-height:40px; font-size:12px; }
@media (max-width:360px) {
  .mobile-personal-shifts .mobile-week-list article { grid-template-columns:minmax(0,1fr); }
  .app-header .mobile-task-header-button { min-width:60px; padding-inline:5px; }
  .app-header.has-personal-shifts { flex-wrap:wrap; gap:6px; }
  .app-header.has-personal-shifts .app-header-main { flex:1 1 100%; }
  .app-header.has-personal-shifts .app-header-actions { margin-left:auto; }
}
