body {
  margin: 0;
}

html {
  overflow-x: hidden;
  overflow-y: auto;
}

#loading-bg {
  position: fixed;
  inset: 0;
  z-index: 2147483000;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: #f4f8ff;
  gap: 0;
}

body.app-ready #loading-bg {
  display: none !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

.weven-loader-logo {
  height: 36px;
  width: auto;
  filter: brightness(0);
}

.weven-loader-bar {
  position: relative;
  margin-top: 28px;
  height: 4px;
  width: 144px;
  border-radius: 9999px;
  background: #e2e8f0;
  overflow: hidden;
}

.weven-loader-bar::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  width: 50%;
  border-radius: 9999px;
  background: #185df1;
  animation: weven-loader-slide 0.85s ease-in-out infinite;
}

.weven-loader-text {
  margin: 16px 0 0;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 14px;
  line-height: 1.4;
  color: #64748b;
}

@keyframes weven-loader-slide {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(200%); }
}

#weven7-fatal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 2147483646;
  padding: 24px;
  background: #0b1b3d;
  color: #e8eef9;
  font-family: system-ui, sans-serif;
  overflow: auto;
}
#weven7-fatal.show { display: block; }
#weven7-fatal h1 { font-size: 18px; margin: 0 0 12px; }
#weven7-fatal pre {
  white-space: pre-wrap;
  word-break: break-word;
  background: #15233d;
  border: 1px solid #2a3a55;
  border-radius: 12px;
  padding: 14px;
  font-size: 12px;
  color: #fca5a5;
}
#weven7-fatal button {
  margin-top: 16px;
  border: 0;
  border-radius: 10px;
  padding: 10px 16px;
  background: #185df1;
  color: #fff;
  font-weight: 700;
  cursor: pointer;
}
