/* ── BOOT-KÉPERNYŐ — KRITIKUS CSS (09-25: az index.html inline <style>-jából KIEMELVE) ─────────────────────────────────
 * A saját CSP-nk (`public/_headers`: style-src 'self', hash és unsafe-inline nélkül) az inline blokkot 07-30 óta LETILTOTTA:
 * a nyitó- és a hiba-képernyő stílus nélkül villant fel, a hiba-képernyő szövege a boot alatt is látszott. Külső fájlként
 * a <head>-ben render-blokkoló — a „fehér képernyő tilos” elv (spike-lecke) így is teljesül. Tartalom: bájtra a régi blokk. */
/* Kritikus INLINE CSS: a nyitó- és a hiba-képernyő a bundle betöltése ELŐTT is
   teljes értékű (fehér képernyő tilos — spike-lecke), ezért nem hivatkozhat
   külső stíluslapra és nem használhat CSS-változókat a design-rendszerből.
   A színek itt a TENK-tokenek szó szerinti értékei.
   A háttér = a manifest background_color → az iOS indítóképernyőjéből az
   app-héjba VILLANÁS NÉLKÜL folytatódik a kép. */
html, body {
  margin: 0; height: 100%; background: #f4f6f8; color: #1a1f24;
  font-family: -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}
#boot-screen, #fatal-screen {
  position: fixed; inset: 0; display: flex;
  align-items: center; justify-content: center;
  padding: calc(24px + env(safe-area-inset-top)) 24px calc(24px + env(safe-area-inset-bottom));
  background: #f4f6f8; text-align: center; z-index: 100;
}
#fatal-screen { display: none; }

.boot-inner {
  display: flex; flex-direction: column; align-items: center;
  gap: 18px; max-width: 320px;
  animation: boot-enter .45s cubic-bezier(.22, .61, .36, 1) both;
}
@keyframes boot-enter {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: none; }
}

.boot-logo { width: 84px; height: auto; }

.boot-wordmark {
  font-size: 19px; font-weight: 600; letter-spacing: .01em; color: #1a1f24;
  margin-top: -4px;
}

/* Határozatlan folyamatjelző: a chat „Gondolkodik…" pötty rokona, TENK-kékben */
.boot-progress {
  width: 132px; height: 3px; border-radius: 999px;
  background: #e5e8eb; overflow: hidden;
}
.boot-progress span {
  display: block; width: 40%; height: 100%; border-radius: 999px;
  background: #1f4e8c; animation: boot-slide 1.25s ease-in-out infinite;
}
@keyframes boot-slide {
  0%   { transform: translateX(-105%); }
  100% { transform: translateX(355%); }
}

#boot-status, #fatal-detail {
  font-size: 13px; line-height: 19px; color: #7a848d;
}

/* Kivezetés: az app már a réteg ALATT van, a takarítás nem ugrik (main.ts) */
#boot-screen.boot-hide {
  opacity: 0; transition: opacity .2s ease-out; pointer-events: none;
}

#fatal-screen strong { font-size: 17px; font-weight: 600; }
#fatal-screen button {
  border: 0; border-radius: 8px; background: #1f4e8c; color: #fff;
  font-family: inherit; font-size: 16px; font-weight: 600;
  padding: 12px 24px; min-height: 44px; margin-top: 4px;
}

@media (prefers-reduced-motion: reduce) {
  .boot-inner { animation: none; }
  .boot-progress span { animation: none; width: 100%; opacity: .5; }
  #boot-screen.boot-hide { transition: none; }
}

/* a <noscript> üzenete (a régi inline style="" attribútum helyett — a CSP azt is tiltja) */
.noscript-uzenet { position: fixed; inset: 0; display: flex; align-items: center; justify-content: center; padding: 24px; background: #f4f6f8; }
