.bq-bg-layer {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
  background: linear-gradient(180deg, #f3faf1 0%, #e7f5e3 100%);
}
.bq-page-wrap {
  position: relative;
  min-height: 100vh;
  box-sizing: border-box;
  padding: 32px 16px 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  overflow-x: hidden;
  /* Aus dem (oft schmaleren) Inhaltsbereich des WordPress-Themes
     ausbrechen -- sonst zwingt das Theme diese Seite auf seine eigene
     Content-Breite, waehrend die App selbst (die das Theme komplett
     umgeht) immer die volle, beabsichtigte Breite bekommt. */
  width: 100vw;
  min-width: 100vw;
  max-width: 100vw;
  flex: none;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
}
.bq-vine {
  position: fixed;
  top: -6px;
  height: auto;
  filter: drop-shadow(0 6px 10px rgba(20,60,30,0.12));
  opacity: 1;
}
.bq-leaf {
  position: fixed;
  height: auto;
  filter: drop-shadow(0 6px 10px rgba(20,60,30,0.12));
  opacity: 1;
}
.bq-legal-footer {
  text-align: center;
  padding: 18px 16px 6px;
  font-size: 11px;
  color: #3d5a3d;
  opacity: 0.75;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, sans-serif;
}
.bq-brand-line { margin-bottom: 6px; }
.bq-legal-footer a { color: inherit; text-decoration: underline; }
.bq-legal-footer a:hover { opacity: 0.8; }
.bq-page-root {
  position: relative;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Rounded", "SF Pro Text", "Segoe UI", Roboto, sans-serif;
  background: #ffffff;
  color: #20242b;
  max-width: 920px;
  width: 100%;
  box-sizing: border-box;
  margin: 0 auto;
  border-radius: 26px;
  overflow: hidden;
  border: 1px solid #e4e7ec;
  box-shadow: 0 10px 30px rgba(32,36,43,0.12), 0 2px 6px rgba(32,36,43,0.06);
}
.bq-page-header {
  padding: 26px 30px 22px;
  border-bottom: 1px solid #e4e7ec;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.bq-page-brand { display: inline-flex; flex-direction: column; align-items: center; gap: 4px; text-decoration: none; color: inherit; cursor: pointer; }
.bq-page-brand, .bq-page-brand:hover, .bq-page-brand:focus, .bq-page-brand * { text-decoration: none !important; border-bottom: none !important; box-shadow: none !important; }
.bq-page-brand-row { display: flex; align-items: center; gap: 16px; }
.bq-page-mascot {
  width: 64px;
  height: 40px;
  flex: none;
}
.bq-page-mascot svg { width: 100%; height: 100%; display: block; overflow: visible; }
.bq-page-tongue-out {
  transform-box: fill-box;
  transform-origin: left center;
  transform: scaleX(0.25);
  opacity: 0;
  transition: transform 0.22s cubic-bezier(.4,0,.2,1.4), opacity 0.15s ease;
}
.bq-page-mascot:hover .bq-page-tongue-out { opacity: 1; transform: scaleX(1); }
.bq-page-mascot.flick .bq-page-tongue-out { opacity: 1; transform: scaleX(1); }
.bq-cham-imgwrap { position: relative; width: 100%; height: 100%; display: block; }
.bq-cham-img { width: 100%; height: 100%; display: block; object-fit: contain; }
.bq-cham-imgwrap svg.bq-cham-tongue {
  position: absolute; top: 38%; left: 82%;
  width: 26% !important; height: 16% !important;
}
.bq-cham-accessory {
  position: absolute; top: -14%; left: 50%;
  font-size: 26px; line-height: 1; transform: rotate(-8deg);
  pointer-events: none; user-select: none;
}
.bq-page-mascot .bq-cham-accessory { font-size: 24px; }
.bq-student-table .bq-cham-accessory { font-size: 11px; }
.bq-acc-cap { left: 44%; top: -13%; transform: rotate(-4deg); }
.bq-acc-crown { left: 42%; top: -22%; }
.bq-acc-tophat { left: 40%; top: -22%; }
.bq-acc-hat { left: 43%; top: -17%; }
.bq-acc-grad { left: 43%; top: -19%; }
/* Kinderliste: sehr klein (28x18px). Apple-Emojis (Mac/iPad) sitzen
   darin sichtbar tiefer als auf anderen Systemen -- daher deutlich
   angehoben, damit der Hut auf dem Kopf sitzt statt ueber dem Auge. */
.bq-student-table .bq-acc-cap { left: 32%; top: -26%; }
.bq-student-table .bq-acc-hat { left: 24%; top: -28%; }
.bq-student-table .bq-acc-crown { left: 28%; top: -38%; }
.bq-student-table .bq-acc-grad { left: 26%; top: -34%; }
.bq-student-table .bq-acc-tophat { left: 28%; top: -40%; }
.bq-page-title {
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -0.01em;
  margin: 0;
  text-transform: lowercase;
  display: flex;
}
.bq-page-title span { display: inline-block; transition: transform 0.15s ease; }
.bq-page-title span:nth-child(odd) { color: #20242b; transform: translateY(-1px) rotate(-4deg); }
.bq-page-title span:nth-child(even) { color: #16659E; transform: translateY(2px) rotate(4deg); }
.bq-page-title:hover span:nth-child(odd) { transform: translateY(-3px) rotate(-7deg); }
.bq-page-title:hover span:nth-child(even) { transform: translateY(3px) rotate(7deg); }
.bq-page-subtitle {
  font-size: 12.5px;
  color: #838993;
  margin: 3px 0 0;
  font-weight: 600;
  text-align: center;
  width: 100%;
  text-decoration: none !important;
  border-bottom: none !important;
  box-shadow: none !important;
}
.bq-page-main { padding: 26px 30px 32px; }

.bq-license-form,
.bq-dashboard,
.bq-gate {
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, sans-serif;
  max-width: 100%;
  text-align: center;
}
.bq-dashboard table,
.bq-dashboard th,
.bq-dashboard td {
  font-family: inherit;
}

.bq-license-form label,
.bq-gate label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: #20242b;
  margin-bottom: 12px;
}

.bq-license-form input,
.bq-add-student-form input,
.bq-gate input {
  font-family: inherit;
  font-size: 14px;
  padding: 10px 14px;
  border: 1px solid #e4e7ec;
  border-radius: 12px;
  margin-top: 4px;
  width: 100%;
  max-width: 420px;
  box-sizing: border-box;
}

.bq-gate input {
  display: block;
  margin-left: auto;
  margin-right: auto;
}

.bq-license-form button,
.bq-add-student-form button,
.bq-gate button {
  font-family: inherit;
  background: #1F7CC0;
  color: #fff;
  border: none;
  padding: 10px 20px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  margin-top: 6px;
}

.bq-gate-hint {
  font-size: 12.5px;
  color: #838993;
  margin-top: 6px;
}
.bq-gate form + .bq-gate-hint {
  margin-top: 18px;
}
.bq-gate-hint + form {
  margin-top: 14px;
}

.bq-add-student-form {
  display: flex;
  gap: 8px;
  align-items: center;
  margin: 16px auto;
  flex-wrap: wrap;
  max-width: 560px;
}
.bq-add-student-form input {
  flex: 1;
  min-width: 200px;
}

.bq-form-error {
  color: #c8123a;
  font-weight: 600;
  font-size: 13px;
}

.bq-form-success {
  color: #0a8a3a;
  font-weight: 600;
  font-size: 13px;
  background: #eafbea;
  border-radius: 12px;
  padding: 10px 14px;
}

.bq-dashboard {
  max-width: 100%;
  padding: 0 20px;
  box-sizing: border-box;
}

.bq-table-scroll {
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border: 1px solid #e4e7ec;
  border-radius: 16px;
  margin-top: 16px;
}

.bq-student-table {
  width: 100%;
  min-width: 680px;
  border-collapse: collapse;
  font-size: 13.5px;
}

.bq-student-table th {
  text-align: left;
  padding: 12px 14px;
  background: #f7f9fa;
  color: #6b7178;
  font-size: 11.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  border-bottom: 1px solid #e4e7ec;
}

.bq-student-table td {
  text-align: left;
  padding: 12px 14px;
  border-bottom: 1px solid #eef1f3;
  color: #20242b;
  vertical-align: middle;
}

.bq-student-table tbody tr:last-child td {
  border-bottom: none;
}

.bq-student-table tbody tr:hover {
  background: #fafbfc;
}

.bq-student-table code {
  background: #eef2f6;
  padding: 3px 7px;
  border-radius: 6px;
  font-size: 12.5px;
}

.bq-progress-pill {
  display: inline-block;
  background: #eaf7ff;
  color: #16659E;
  border-radius: 999px;
  padding: 4px 11px;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.bq-student-table .bq-remove-link {
  color: #aab0b8;
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
}
.bq-student-table .bq-remove-link:hover {
  color: #e5484d;
  text-decoration: underline;
}

.bq-student-row {
  cursor: pointer;
}

.bq-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(32,36,43,0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.bq-modal {
  background: #ffffff;
  border-radius: 22px;
  padding: 26px 28px;
  max-width: 760px;
  width: 100%;
  max-height: 86vh;
  overflow-y: auto;
  box-shadow: 0 20px 60px rgba(32,36,43,0.25);
}
.bq-level-name {
  font-size: 19px;
  font-weight: 800;
  margin: 0;
}
.bq-metric {
  background: #ffffff;
  border: 1px solid #e4e7ec;
  border-radius: 14px;
  padding: 12px 16px;
  min-width: 110px;
}
.bq-metric b {
  display: block;
  font-size: 20px;
  font-weight: 800;
  color: #20242b;
}
.bq-metric span {
  font-size: 12px;
  color: #6b7178;
}
.bq-btn {
  border: none;
  border-radius: 999px;
  padding: 11px 22px;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
}
.bq-btn-blue {
  background: #1F7CC0;
  color: #fff;
}
.bq-btn-blue:hover {
  background: #0b8fd0;
}
.bq-btn-outline {
  background: #eef2f6;
  color: #20242b;
  border: 1px solid #e4e7ec;
}
.bq-btn-outline:hover {
  background: #e2e7ed;
}

/* Zweite Lehrperson im Dashboard */
.bq-teacher-check {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 13.5px; font-weight: 600; color: #20242b; white-space: nowrap; cursor: pointer;
}
.bq-add-student-form .bq-teacher-check input { flex: none; width: 16px; height: 16px; min-width: 0; margin: 0; padding: 0; accent-color: #1F7CC0; }
.bq-teacher-email { flex-basis: 100%; }
.bq-add-student-form .bq-teacher-email input { width: 100%; box-sizing: border-box; }
.bq-teachers-line { text-align: center; font-size: 13.5px; color: #4a5059; margin: 0 0 6px; }
.bq-muted { color: #838993; font-weight: 400; }
.bq-link-btn {
  background: none; border: none; padding: 0; margin-left: 6px;
  color: #c8123a; font-size: 12.5px; text-decoration: underline; cursor: pointer;
}



/* Anmeldeseite: bytequest als Lesezeichen speichern */
.bq-bookmark { margin: 24px auto 0; padding: 18px 18px 14px; background: #eaf7ff; border: 1.5px solid #bfe6fb; border-radius: 18px; text-align: center; max-width: 420px; }
.bq-bookmark-title { margin: 0 0 12px; font-weight: 800; font-size: 16px; color: #20242b; }
.bq-bookmark-keys { display: flex; align-items: center; justify-content: center; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.bq-keycap { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-width: 54px; height: 50px; padding: 0 14px; box-sizing: border-box;
  background: #fff; border: 1px solid #d8dde3; border-bottom-width: 4px; border-radius: 12px; font-size: 22px; font-weight: 800; color: #20242b; box-shadow: 0 2px 6px rgba(32,36,43,0.08); }
.bq-keycap-wide { font-size: 14px; font-weight: 700; height: 44px; }
.bq-keyplus { font-size: 20px; font-weight: 800; color: #16659E; }
.bq-bookmark-hint { margin: 0; font-size: 13px; color: #4a5059; line-height: 1.5; }
.bq-bookmark-url { margin: 8px 0 0; font-size: 12.5px; font-weight: 700; color: #16659E; word-break: break-all; }

/* Schülertabelle kompakter: Logins/Passwörter nie umbrechen,
   Aktionen untereinander statt nebeneinander (passt auch in die App) */
.bq-student-table code { white-space: nowrap; }
.bq-student-table td:last-child { white-space: nowrap; }
.bq-student-table td:last-child .bq-remove-link { display: block; margin: 0 0 3px !important; line-height: 1.35; }
.bq-student-table td:last-child .bq-remove-link:last-child { margin-bottom: 0 !important; }
.bq-student-table th, .bq-student-table td { padding-left: 9px; padding-right: 9px; }

.bq-contact-link { color: inherit; text-decoration: underline; }

/* Kein seitliches Verschieben/Scrollen auf Seiten mit bytequest-Rahmen */
html:has(body.bq-has-wrap), body.bq-has-wrap { overflow-x: hidden; }

/* Schülertabelle: eigene weisse, abgerundete Karte; die drei
   Fortschrittsspalten schmal und gleich breit, dadurch mehr Platz links */
.bq-table-scroll { background: #fff; }
.bq-student-table th:nth-child(4), .bq-student-table td:nth-child(4),
.bq-student-table th:nth-child(5), .bq-student-table td:nth-child(5),
.bq-student-table th:nth-child(6), .bq-student-table td:nth-child(6) { width: 96px; min-width: 96px; max-width: 96px; }
.bq-student-table td:nth-child(4) .bq-progress-pill,
.bq-student-table td:nth-child(5) .bq-progress-pill,
.bq-student-table td:nth-child(6) .bq-progress-pill { white-space: nowrap; }
.bq-student-table th:nth-child(2), .bq-student-table td:nth-child(2),
.bq-student-table th:nth-child(3), .bq-student-table td:nth-child(3),
.bq-student-table th:nth-child(7), .bq-student-table td:nth-child(7) { width: 1%; white-space: nowrap; }
.bq-student-table td:first-child { font-weight: 600; }

/* Aktionshinweis über dem Testphasen-Formular (z. B. ?aktion=arbeitsheft) */
.bq-campaign-badge { margin: 4px auto 14px; max-width: 420px; padding: 14px 16px; background: #eaf7ff; border: 1.5px solid #9fd8f6; border-radius: 16px; text-align: center; }
.bq-campaign-days { display: block; font-size: 22px; font-weight: 800; color: #16659E; }
.bq-campaign-days s { position: relative; display: inline-block; text-decoration: none; color: #9aa3ad; font-weight: 800; margin-right: 6px; }
.bq-campaign-days s::after { content: ""; position: absolute; left: -16%; right: -16%; top: 8%; bottom: 4%; background: url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 120 40%22 preserveAspectRatio=%22none%22%3E   %3Cg fill=%22%23ff3b5c%22 stroke-linecap=%22round%22%3E     %3Cpath d=%22M5 27.5 C 24 22.5, 50 16, 78 10 C 92 7, 104 4.6, 113 3.4 C 116.5 3, 118 5.6, 116 7.4 C 113.5 9.6, 112 10.2, 108 11.6 C 92 16, 70 21.4, 48 26.6 C 32 30.4, 18 33.6, 9 35.6 C 4.4 36.6, 1.6 30.4, 5 27.5 Z%22/%3E     %3Cpath d=%22M3 33.5 C 16 30.6, 30 27.4, 44 24.2%22 stroke=%22%23ff3b5c%22 stroke-width=%221.4%22 fill=%22none%22 opacity=%22.6%22/%3E     %3Cpath d=%22M2.4 29.8 C 10 28, 18 26.2, 26 24.4%22 stroke=%22%23ff3b5c%22 stroke-width=%221%22 fill=%22none%22 opacity=%22.5%22/%3E     %3Cpath d=%22M100 6.2 L 118.6 2.6%22 stroke=%22%23ff3b5c%22 stroke-width=%221.1%22 fill=%22none%22 opacity=%22.6%22/%3E     %3Cpath d=%22M102 9.4 L 119 6.6%22 stroke=%22%23ff3b5c%22 stroke-width=%22.9%22 fill=%22none%22 opacity=%22.5%22/%3E     %3Cpath d=%22M98 12.4 L 112.5 10.2%22 stroke=%22%23ff3b5c%22 stroke-width=%22.8%22 fill=%22none%22 opacity=%22.45%22/%3E   %3C/g%3E %3C/svg%3E ") no-repeat center / 100% 100%; }
.bq-campaign-label { display: block; margin-top: 4px; font-size: 13px; color: #4a5059; }

/* ===== bytequest: Marke, Hintergrund, Bruno ===== */
.bq-bg-layer { background: linear-gradient(180deg, #EAF6FD 0%, #DDEFE6 100%); }
.bq-legal-footer { color: #2C4A60; }
.bq-page-root { color: #12324A; border-color: #D3E6F3; }
.bq-page-header { border-bottom-color: #D3E6F3; }
.bq-page-brand { gap: 6px; }
.bq-page-mascot { width: 56px; height: 56px; }
.bq-page-mascot svg { width: 100%; height: 100%; display: block; overflow: visible; transform-origin: 50% 90%; }
.bq-pupil { transform-box: view-box; }
.bq-pl { transform-origin: 40px 44px; } .bq-pr { transform-origin: 81px 43px; }
.bq-page-mascot.spin .bq-pl, .bq-page-brand:hover .bq-pl { animation: bqEyeL 1.3s ease-in-out; }
.bq-page-mascot.spin .bq-pr, .bq-page-brand:hover .bq-pr { animation: bqEyeR 1.3s ease-in-out; }
.bq-page-mascot.spin svg { animation: bqShake .55s ease-in-out 1.3s; }
@keyframes bqEyeL { to { transform: rotate(360deg); } }
@keyframes bqEyeR { to { transform: rotate(-360deg); } }
@keyframes bqShake { 20% { transform: rotate(-8deg); } 40% { transform: rotate(7deg); } 60% { transform: rotate(-5deg); } 80% { transform: rotate(3deg); } }
@media (prefers-reduced-motion: reduce) { .bq-page-mascot svg, .bq-pupil { animation: none !important; } }
.bq-brand-row { display: inline-flex; align-items: center; gap: 12px; }
.bq-word { display: inline-flex; align-items: flex-end; gap: 3px; line-height: 1; }
.bq-byte { display: block; margin-bottom: 5px; }
.bq-quest { display: inline-flex; font-size: 30px; font-weight: 800; letter-spacing: -0.01em; text-transform: lowercase; font-family: -apple-system, BlinkMacSystemFont, "SF Pro Rounded", "SF Pro Text", "Segoe UI", Roboto, sans-serif; }
.bq-quest span { display: inline-block; transition: transform .15s ease; }
.bq-quest span:nth-child(odd) { color: #F2A900; transform: translateY(-1px) rotate(-4deg); }
.bq-quest span:nth-child(even) { color: #E07B00; transform: translateY(2px) rotate(4deg); }
.bq-page-brand:hover .bq-quest span:nth-child(odd) { transform: translateY(-3px) rotate(-7deg); }
.bq-page-brand:hover .bq-quest span:nth-child(even) { transform: translateY(3px) rotate(7deg); }
.bq-page-subtitle { color: #587286; }

/* ===== bytequest: Lehrpersonen-Dashboard ===== */
.bq-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin: 14px 0 6px; }
.bq-kpi { background: #F2F9FE; border: 1px solid #D3E6F3; border-radius: 14px; padding: 12px 14px; }
.bq-kpi b { display: block; font-size: 24px; font-family: ui-monospace, "SF Mono", Consolas, monospace; }
.bq-kpi span { font-size: 13px; color: #587286; }
.bq-dash-h { font-size: 17px; margin: 26px 0 8px; }
.bq-dot { display: inline-block; width: 16px; height: 16px; border-radius: 50%; vertical-align: middle; background: #D3E6F3; }
.bq-dot-g { background: #23915F; } .bq-dot-y { background: #E3A800; } .bq-dot-r { background: #C3433B; } .bq-dot-n { background: #D3E6F3; }
.bq-dot-flag { box-shadow: 0 0 0 3px #fff, 0 0 0 5px #E07B00; }
.bq-ampel th small { display: block; font-weight: 500; font-size: 10px; color: #587286; }
.bq-ampel td, .bq-ampel th { text-align: center; }
.bq-ampel td:first-child, .bq-ampel th:first-child { text-align: left; }
.bq-legend { display: flex; flex-wrap: wrap; gap: 14px; font-size: 13px; color: #587286; margin: 8px 0 4px; }
.bq-dash-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 12px; margin-top: 18px; }
.bq-dash-card { border: 1px solid #D3E6F3; border-radius: 14px; padding: 14px 16px; }
.bq-dash-card h4 { margin: 0 0 8px; font-size: 15px; }
.bq-dash-card ul { margin: 0; padding-left: 18px; }
.bq-answers { display: grid; gap: 8px; }
.bq-answer { border: 1px solid #D3E6F3; border-radius: 12px; padding: 10px 14px; margin-bottom: 6px; background: #fff; }
.bq-answer-meta { font-size: 12px; color: #587286; margin-bottom: 4px; }
.bq-actions { white-space: nowrap; }
.bq-actions a { margin-right: 12px; }
.bq-muted { color: #587286; }
