/* feat-home: Ladebildschirm, Begrüssung, Profile, Startseite, Einstellungen, Ziele. Masse wie in Flutter. */

.home-screen { position: relative; height: 100%; min-height: 100%; overflow: hidden; }
.home-scroll { position: relative; z-index: 1; height: 100%; overflow-y: auto; padding-top: env(safe-area-inset-top); box-sizing: border-box; }
.home-narrow { margin: 0 auto; box-sizing: border-box; width: 100%; }
.home-empty { display: flex; align-items: center; justify-content: center; min-height: 240px; text-align: center; padding: 24px; }
.home-eyebrow { font-size: 10.5px; letter-spacing: 1.3px; font-weight: 800; }
.home-emoji { font-family: var(--lern-emoji, "LernEmoji", sans-serif); line-height: 1; }
.home-error { margin-top: 10px; color: #d9485a; font-weight: 700; font-size: 13px; }
.home-flag { display: inline-block; overflow: hidden; flex: none; }
.home-worldpic { position: relative; }

/* Auftritte */
.home-reveal--on {
  animation: home-reveal-fade 620ms cubic-bezier(0.215, 0.61, 0.355, 1) both, home-reveal-pop 620ms cubic-bezier(0.175, 0.885, 0.32, 1.275) both;
}
@keyframes home-reveal-fade { from { opacity: 0; translate: var(--hr-x) var(--hr-y); } to { opacity: 1; translate: 0 0; } }
@keyframes home-reveal-pop { from { scale: var(--hr-s); } to { scale: 1; } }
.home-appear { animation: home-appear 520ms cubic-bezier(0.215, 0.61, 0.355, 1) both; }
@keyframes home-appear { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }

/* ------------------------------------------------------------ Ladebildschirm */
.home-loading { position: relative; height: 100%; overflow: hidden; outline: none; color: #fff; }
.home-load-center { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; padding: env(safe-area-inset-top) 24px env(safe-area-inset-bottom); box-sizing: border-box; overflow-y: auto; }
.home-load-col { width: 100%; max-width: 900px; display: flex; flex-direction: column; align-items: center; }
.home-load-by { margin-top: 28px; font-family: "BlowBrush", "Fredoka", sans-serif; font-size: 24px; color: #c9cef0; letter-spacing: 1px; line-height: 1.2; }
.home-load-company { margin-top: 6px; width: 100%; cursor: pointer; outline: none; position: relative; display: flex; justify-content: center; align-items: center; }
.home-load-logo { height: 100%; width: auto; max-width: 100%; object-fit: contain; transition: opacity 600ms ease; pointer-events: none; }
.home-load-letters { position: absolute; inset: 0; pointer-events: none; transition: opacity 600ms ease; }
.home-load-company:focus-visible { outline: 2px solid #ffd31a; outline-offset: 4px; border-radius: 8px; }
.home-load-dots { margin-top: 40px; display: flex; align-items: center; }
.home-load-link { width: 18px; height: 3px; flex: none; }
.home-load-dot { flex: none; cursor: default; }
.home-load-status { margin-top: 18px; font-family: "BlowBrush", "Fredoka", sans-serif; font-size: 26px; color: #fff; line-height: 1.2; }
.home-load-bar { margin-top: 14px; position: relative; width: min(560px, 100%); height: 24px; }
.home-load-track { position: absolute; left: 0; right: 0; top: 5px; height: 14px; box-sizing: border-box; background: #1e2550; border-radius: 7px; border: 1.5px solid #2e3566; }
.home-load-fill { position: absolute; left: 0; top: 5px; height: 14px; border-radius: 7px; background: linear-gradient(90deg, #ffb800, #ffd31a); max-width: 100%; }
.home-load-knob {
  position: absolute; top: 0; width: 24px; height: 24px; box-sizing: border-box; border-radius: 50%;
  background: #fff4b0; border: 3px solid #ffd31a; box-shadow: 0 0 19.5px 2px rgba(255, 211, 26, 0.6);
}
.home-load-pct { margin-top: 8px; font-family: "Fredoka", sans-serif; font-weight: 700; color: #8d97c7; font-size: 13px; }
.home-load-music { position: absolute; top: calc(8px + env(safe-area-inset-top)); right: 8px; }
.home-load-skip {
  position: absolute; right: 20px; bottom: calc(20px + env(safe-area-inset-bottom));
  opacity: 0; transform: translateY(60%); pointer-events: none;
  transition: opacity 520ms, transform 520ms cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
.home-load-skip--on { opacity: 1; transform: none; pointer-events: auto; }
.home-load-skip button {
  appearance: none; border: 0; cursor: pointer; display: inline-flex; align-items: center; gap: 8px;
  background: #ffd31a; color: #1b1f33; padding: 12px 16px 12px 20px; border-radius: 999px;
  font-family: "BlowBrush", "Fredoka", sans-serif; font-size: 22px; line-height: 1;
}
.home-load-skip button:focus-visible { outline: 3px solid #fff; outline-offset: 3px; }

/* ------------------------------------------------------------ Begrüssung */
.home-welcome { position: relative; height: 100%; background: #0b1022; overflow: hidden; outline: none; color: #fff; }
.home-welcome-bg, .home-welcome-layer, .home-welcome-veil { position: absolute; inset: 0; }
.home-welcome-layer--in { animation: lw-fade 1200ms ease both; }
.home-welcome-safe { position: absolute; inset: 0; padding: env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left); display: flex; justify-content: center; }
.home-welcome-col { width: 100%; max-width: 760px; padding: 14px 22px 18px; box-sizing: border-box; display: flex; flex-direction: column; align-items: center; }
.home-welcome-head { align-self: stretch; display: flex; justify-content: flex-end; }
.home-welcome-area { flex: 1; min-height: 0; align-self: stretch; display: flex; justify-content: center; align-items: flex-start; overflow: visible; }
.home-welcome-fit { flex: none; display: flex; flex-direction: column; align-items: center; transform-origin: top center; }
.home-welcome-motto {
  font-size: 13.5px; font-weight: 700; color: #fff; text-shadow: 0 1px 0 rgba(0, 0, 0, 0.8); text-align: center;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; animation: lw-fade 600ms ease both;
}
.home-welcome-dots { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 8px 10px; }
.home-welcome-dot { appearance: none; border: 0; cursor: pointer; display: block; overflow: hidden; }
.home-welcome-dot:focus-visible { outline: 3px solid #fff; outline-offset: 2px; }
.home-welcome-foot { font-size: 12px; color: rgba(255, 255, 255, 0.867); text-align: center; }
.home-stage { position: relative; flex: none; }
.home-stage-fig { position: absolute; }
.home-start { appearance: none; background: none; border: 0; padding: 0; cursor: pointer; width: min(440px, calc(100vw - 44px)); display: block; }
.home-start:focus-visible { outline: 3px solid #fff; outline-offset: 6px; border-radius: 40px; }
.home-start-shell { will-change: transform; }
.home-start-play { width: 38px; height: 38px; border-radius: 50%; background: #2a1a12; color: #ffd34d; display: inline-flex; align-items: center; justify-content: center; }

/* ------------------------------------------------------------ Profile */
.home-pcard {
  appearance: none; font: inherit; text-align: left; cursor: pointer; padding: 0; width: 100%;
  display: flex; align-items: stretch; overflow: hidden; box-sizing: border-box;
}
.home-pcard:focus-visible, .home-newcard:focus-visible, .home-tile:focus-visible, .home-row:focus-visible, .home-quest:focus-visible, .home-medal:focus-visible {
  outline: 3px solid var(--lern-primary); outline-offset: 2px;
}
.home-pcard-world { position: relative; width: 132px; flex: none; min-height: 120px; }
.home-pcard-world > .home-worldpic { position: absolute; inset: 0; }
.home-pcard-fig { position: absolute; inset: 0; display: flex; justify-content: center; align-items: center; padding-top: 12%; pointer-events: none; }
.home-pcard-text { flex: 1; min-width: 0; padding: 14px 12px 14px 16px; display: flex; flex-direction: column; justify-content: center; }
.home-pcard-name { margin-top: 2px; font-size: 22px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; line-height: 1.25; }
.home-pcard-sub { font-size: 13px; font-weight: 700; }
.home-pcard-go { padding-right: 14px; display: flex; align-items: center; }
.home-pcard-plate { width: 38px; height: 38px; display: flex; align-items: center; justify-content: center; }
.home-newcard {
  appearance: none; font: inherit; cursor: pointer; width: 100%; box-sizing: border-box; padding: 14px;
  display: flex; align-items: center; gap: 14px; text-align: left;
}
.home-newcard-icon { width: 56px; height: 56px; display: flex; align-items: center; justify-content: center; flex: none; }
.home-newcard-text { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.home-newcard-title { font-size: 17px; }
.home-newcard-sub { margin-top: 2px; font-size: 13px; }
.home-step { padding: 16px; display: flex; flex-direction: column; }
.home-step-head { display: flex; align-items: center; gap: 10px; }
.home-step-num { width: 30px; height: 30px; flex: none; display: flex; align-items: center; justify-content: center; font-size: 14px; font-weight: 900; }
.home-step-text { flex: 1; min-width: 0; }
.home-step-title { font-size: 17px; }
.home-step-hint { font-size: 12.5px; }
.home-options { display: flex; gap: 10px; }
.home-tile {
  appearance: none; font: inherit; flex: 1 1 0; min-width: 0; cursor: pointer; padding: 14px 8px;
  display: flex; flex-direction: column; align-items: center; gap: 0; transition: background 160ms, border-color 160ms;
}
.home-tile > :first-child { margin-bottom: 6px; }
.home-tile-label { font-weight: 800; color: var(--tile-ink); text-align: center; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; }
.home-tile-sub { font-size: 11.5px; }
.home-privacy { display: flex; align-items: center; gap: 6px; font-size: 12.5px; }

/* ------------------------------------------------------------ Startseite */
.home-home { position: relative; height: 100%; overflow-y: auto; overflow-x: hidden; }
.home-hero { position: relative; z-index: 1; }
.home-hero-clip { position: absolute; inset: 0; overflow: hidden; }
.home-hero-veil { position: absolute; inset: 0; }
.home-hero-content {
  position: absolute; inset: 0; margin: 0 auto; max-width: 980px; padding: calc(14px + env(safe-area-inset-top)) 20px 0;
  box-sizing: border-box; display: flex; flex-direction: column; align-items: stretch;
}
.home-hero-figure { flex: 1; min-height: 0; display: flex; align-items: center; justify-content: center; }
.home-hero-figure > div { transform-origin: center; }
.home-figstage { position: relative; width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; }
.home-figstage-ring { position: relative; display: flex; align-items: center; justify-content: center; }
.home-playful--spin { animation: home-spin 900ms cubic-bezier(0.68, -0.6, 0.32, 1.6) both; }
@keyframes home-spin { from { transform: rotate(0); } to { transform: rotate(360deg); } }
.home-glass {
  background: linear-gradient(135deg, rgba(11, 16, 34, 0.5), rgba(11, 16, 34, 0.32));
  border: 1px solid rgba(255, 255, 255, 0.3); box-sizing: border-box; color: #fff; overflow: hidden;
}
.home-greet { display: flex; align-items: center; }
.home-greet-logo { padding: 8px 12px; background: rgba(12, 18, 38, 0.902); border-radius: 18px; border: 1.5px solid rgba(69, 195, 247, 0.333); }
.home-greet-hello { color: rgba(255, 255, 255, 0.9); font-size: 14px; font-weight: 700; }
.home-greet-name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.home-greet-title { display: inline-block; margin-top: 4px; padding: 3px 10px; color: #1b1f33; font-size: 12px; font-weight: 900; }
.home-stats { color: #fff; }
.home-stats--wide { display: flex; align-items: center; }
.home-stats-row { display: flex; justify-content: space-between; }
.home-stats-sep { width: 1px; height: 38px; margin: 0 14px; background: rgba(255, 255, 255, 0.24); flex: none; }
.home-stat { display: flex; align-items: center; flex: none; }
.home-stat-icon { width: 32px; height: 32px; border-radius: 50%; color: #1b1f33; display: flex; align-items: center; justify-content: center; flex: none; }
.home-stat-text { margin-left: 8px; display: flex; flex-direction: column; }
.home-stat-num { color: #fff; font-size: 18px; font-weight: 900; line-height: 1.05; }
.home-stat-label { color: rgba(255, 255, 255, 0.8); font-size: 11px; font-weight: 700; }
.home-levelbox-eyebrow { font-size: 10.5px; font-weight: 900; letter-spacing: 1.3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.home-levelbox-level { margin-top: 2px; color: #fff; font-size: 20px; font-weight: 900; line-height: 1.05; }
.home-levelbox-bar { margin-top: 6px; height: 7px; border-radius: 4px; overflow: hidden; background: rgba(255, 255, 255, 0.18); }
.home-levelbox-bar > div { height: 100%; }
.home-levelbox-hint { margin-top: 3px; color: rgba(255, 255, 255, 0.8); font-size: 11px; font-weight: 700; }
.home-quest-slot { position: absolute; left: 20px; right: 20px; bottom: -58px; display: flex; justify-content: center; z-index: 2; }
.home-quest-wrap { width: 100%; }
.home-quest {
  appearance: none; font: inherit; width: 100%; box-sizing: border-box; padding: 12px; cursor: pointer; text-align: left;
  display: flex; align-items: center;
}
.home-quest-pic { position: relative; width: 92px; height: 92px; flex: none; overflow: hidden; }
.home-quest-pic > .home-worldpic { position: absolute; inset: 0; }
.home-quest-badge {
  position: absolute; left: 50%; top: 50%; width: 44px; height: 44px; margin: -22px 0 0 -22px; border-radius: 50%;
  background: rgba(255, 255, 255, 0.92); display: flex; align-items: center; justify-content: center; font-weight: 900;
  font-family: var(--lern-font, inherit);
}
.home-quest-text { flex: 1; min-width: 0; margin-left: 14px; display: flex; flex-direction: column; }
.home-quest-label { font-size: 10.5px; font-weight: 900; letter-spacing: 1.5px; }
.home-quest-title { margin-top: 3px; }
.home-quest-segs { margin-top: 10px; display: flex; }
.home-quest-seg { flex: 1; height: 6px; margin-right: 4px; border-radius: 3px; }
.home-quest-sub { margin-top: 4px; font-size: 11.5px; font-weight: 700; }
.home-quest-go { position: relative; width: 74px; height: 74px; margin: 0 6px 0 14px; display: flex; align-items: center; justify-content: center; flex: none; }
.home-quest-pulse { position: absolute; box-sizing: border-box; }
.home-quest-play { width: 56px; height: 56px; display: flex; align-items: center; justify-content: center; color: #fff; position: relative; }
.home-sections { max-width: 920px; margin: 0 auto; padding: 84px 20px 36px; box-sizing: border-box; }
.home-heading { margin: 0; line-height: 1.25; }
/* Luft ringsum, damit Leuchtschein und Rahmen der ersten und letzten Medaille
   nicht am Rand der Scrollleiste abgeschnitten werden; der negative Rand hält
   das Layout unverändert. */
.home-hscroll { overflow-x: auto; overflow-y: hidden; scrollbar-width: none; padding: 24px 20px; margin: -24px -20px; }
.home-hscroll::-webkit-scrollbar { display: none; }
.home-hscroll-inner { position: relative; height: 100%; }
.home-medals { position: relative; display: flex; justify-content: space-between; }
.home-medal { appearance: none; background: none; border: 0; padding: 0; font: inherit; cursor: pointer; width: 112px; flex: none; display: flex; flex-direction: column; align-items: center; }
.home-medal-stage { height: 104px; display: flex; align-items: center; justify-content: center; }
.home-medal-disc { position: relative; display: block; }
.home-medal-disc > .home-worldpic { position: absolute; inset: 0; }
.home-medal-glow { position: absolute; inset: 0; border-radius: 50%; }
.home-medal-lock {
  position: absolute; left: 50%; top: 50%; width: 30px; height: 30px; margin: -15px 0 0 -15px; border-radius: 50%;
  background: rgba(0, 0, 0, 0.45); color: #fff; display: flex; align-items: center; justify-content: center;
}
.home-medal-check {
  position: absolute; right: 0; top: 0; width: 26px; height: 26px; box-sizing: border-box; border-radius: 50%;
  border: 2px solid #fff; color: #1b1f33; display: flex; align-items: center; justify-content: center;
}
.home-medal-name { margin-top: 6px; font-size: 13px; max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.home-medal-sub { font-size: 11px; font-weight: 800; max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.home-medal-sub2 { font-size: 10.5px; font-weight: 700; }
.home-fmedal { position: relative; display: block; }
.home-fmedal > .home-worldpic { position: absolute; inset: 0; }
.home-fmedal-fig { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; pointer-events: none; }
.home-coll-head { display: flex; align-items: center; }
.home-textbtn {
  appearance: none; background: none; border: 0; cursor: pointer; font: inherit; font-size: 12.5px; font-weight: 800;
  display: inline-flex; align-items: center; gap: 4px; padding: 8px 12px; border-radius: 12px;
}
.home-textbtn:hover { background: color-mix(in srgb, currentColor 8%, transparent); }

/* ------------------------------------------------------------ Einstellungen */
.home-scenechip {
  appearance: none; background: transparent; font: inherit; cursor: pointer; align-self: flex-start;
  display: inline-flex; align-items: center; gap: 6px; padding: 7px 12px; font-size: 13px; font-weight: 800; max-width: 100%;
}
.home-group-title { margin: 0 0 10px 4px; }
.home-group-body { overflow: hidden; }
.home-row {
  appearance: none; background: none; border: 0; font: inherit; width: 100%; cursor: pointer; text-align: left;
  display: flex; align-items: center; padding: 14px 16px; position: relative;
}
.home-row:hover { background: color-mix(in srgb, currentColor 4%, transparent); }
.home-row + .home-row::before { content: ""; position: absolute; left: 70px; right: 0; top: 0; height: 1px; background: var(--home-rule); }
.home-plate { width: 40px; height: 40px; display: flex; align-items: center; justify-content: center; flex: none; }
.home-row-text { flex: 1; min-width: 0; margin-left: 14px; display: flex; flex-direction: column; }
.home-row-title { font-size: 15.5px; font-weight: 700; }
.home-row-sub { margin-top: 2px; font-size: 12.5px; }
.home-switch { width: 52px; height: 30px; padding: 3px; box-sizing: border-box; border-radius: 15px; flex: none; margin-left: 10px; transition: background 280ms cubic-bezier(0.215, 0.61, 0.355, 1); position: relative; }
.home-switch-knob {
  position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 50%; background: #fff;
  box-shadow: 0 1px 5.6px rgba(0, 0, 0, 0.12); transition: left 280ms cubic-bezier(0.215, 0.61, 0.355, 1);
}
.home-switch--on .home-switch-knob { left: 25px; }
.home-settings-foot { text-align: center; font-size: 12px; line-height: 1.5; }
.home-region {
  appearance: none; font: inherit; width: 100%; cursor: pointer; text-align: left; margin-bottom: 8px;
  display: flex; align-items: center; gap: 12px; padding: 12px 14px; box-sizing: border-box;
}
.home-region-text { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.home-region-name { font-weight: 700; font-size: 14px; }
.home-region-sub { font-size: 12px; }

/* ------------------------------------------------------------ Ziele */
.home-meter { height: 8px; border-radius: 4px; overflow: hidden; }
.home-meter-fill { height: 100%; transition: width 520ms cubic-bezier(0.215, 0.61, 0.355, 1); }
.home-seclabel { display: flex; align-items: center; gap: 10px; }
.home-seclabel-count { font-size: 12px; font-weight: 800; }
.home-seclabel-rule { flex: 1; height: 1px; }
.home-goal { padding: 16px; box-sizing: border-box; }
.home-goal-row { display: flex; align-items: flex-start; }
.home-goal-plate { width: 46px; height: 46px; flex: none; display: flex; align-items: center; justify-content: center; }
.home-goal-text { flex: 1; min-width: 0; margin: 0 10px 0 14px; }
.home-goal-title { font-size: 16px; }
.home-goal-desc { margin-top: 3px; font-size: 13px; line-height: 1.35; }
.home-xptag { padding: 4px 9px; border-radius: 10px; font-size: 12.5px; font-weight: 900; flex: none; }
.home-goal-bar { margin-top: 14px; height: 5px; overflow: hidden; }
.home-goal-bar > div { height: 100%; }
.home-goal-claim { margin-top: 14px; display: flex; justify-content: flex-end; }

@media (prefers-reduced-motion: reduce) {
  .home-reveal--on, .home-appear, .home-welcome-layer--in, .home-playful--spin, .home-welcome-motto { animation: none; }
}

/* ------------------------------------------------------------ Eltern (parents.rs) */
.home-parent-fields { display: flex; flex-direction: column; }
.home-field-error { margin-top: 6px; color: #D7263D; font-size: 13.5px; font-weight: 600; line-height: 1.35; }
.home-check { display: flex; align-items: flex-start; gap: 10px; padding: 10px 12px; }
.home-check-box { flex: none; border: 0; background: transparent; padding: 0; margin: -2px 0 0 -2px; cursor: pointer; display: flex; }
.home-check-box:focus-visible { outline: 3px solid var(--lern-primary, #FF6B4A); outline-offset: 2px; border-radius: 6px; }
.home-check-text { font-size: 14px; line-height: 1.45; font-weight: 500; display: flex; flex-direction: column; gap: 4px; }
.home-check-text > span { cursor: pointer; }
.home-check-link { font-weight: 700; text-decoration: underline; width: fit-content; }
.home-group-note { padding: 12px 16px; font-size: 13.5px; line-height: 1.45; }
.home-parents-hero { display: flex; justify-content: center; }
.home-support { padding: 16px 18px 18px; }
.home-support-head { display: flex; align-items: center; gap: 8px; font-weight: 800; font-size: 17px; margin-bottom: 6px; }
.home-support-heart { color: #D52B1E; font-family: "LernSymbole", var(--lern-font, sans-serif); font-size: 18px; }
.home-support-text { margin: 8px 0 0; font-size: 14.5px; line-height: 1.55; }
.home-support-actions { margin-top: 16px; }
.home-support-note { margin-top: 10px; font-size: 12.5px; line-height: 1.45; }
.home-about { padding: 16px 18px 6px; display: flex; flex-direction: column; gap: 16px; }
.home-about-logos { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.home-about-item { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.home-about-item p { margin: 0; font-size: 14px; line-height: 1.5; }
.home-about .home-group-note { padding: 0 0 10px; }
.home-title-center { text-align: center; }
.home-title-center .lw-jtitle { justify-content: center; }
.home-privacy-doc { padding: 6px 20px 18px; }
.home-privacy-doc h2 { font-size: 17px; margin: 18px 0 6px; font-weight: 800; }
.home-privacy-doc p { margin: 10px 0; font-size: 14.5px; line-height: 1.6; white-space: pre-line; }
.home-privacy-quote { padding: 8px 12px; border-left: 3px solid var(--lern-primary, #FF6B4A); opacity: .9; }
