:root {
  color-scheme: light;
  font-family:
    Inter, "Noto Sans Devanagari", "Noto Sans", ui-sans-serif,
    system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --yl-crimson: #c0233a;
  --yl-crimson-deep: #8f1528;
  --yl-ink: #251f21;
  --yl-muted: #675d60;
  --yl-surface: #fffaf8;
  --yl-panel: #ffffff;
  --yl-border: #eadadd;
  --yl-focus: #1f5faa;
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
  margin: 0;
  background: var(--yl-surface);
}

body {
  min-width: 320px;
  color: var(--yl-ink);
}

#yl-web-shell {
  position: fixed;
  inset: 0;
  z-index: 2147483647;
  display: grid;
  place-items: center;
  min-height: 100dvh;
  overflow: auto;
  padding:
    max(1.5rem, env(safe-area-inset-top))
    max(1rem, env(safe-area-inset-right))
    max(1.5rem, env(safe-area-inset-bottom))
    max(1rem, env(safe-area-inset-left));
  background:
    linear-gradient(180deg, #fffaf8 0%, #fff5f2 58%, #f9eff0 100%);
  opacity: 1;
  transition: opacity 160ms ease-out;
}

#yl-web-shell.is-ready {
  pointer-events: none;
  opacity: 0;
}

.yl-shell-panel {
  width: min(100%, 28rem);
  padding: clamp(1.25rem, 5vw, 2.5rem);
  border: 1px solid var(--yl-border);
  border-radius: 1.5rem;
  background: var(--yl-panel);
  background: color-mix(in srgb, var(--yl-panel) 94%, transparent);
  box-shadow: 0 1.5rem 4rem rgb(73 22 32 / 10%);
  text-align: center;
}

.yl-logo {
  display: block;
  width: clamp(5.5rem, 24vw, 7.5rem);
  height: auto;
  margin: 0 auto 1.5rem;
  filter: drop-shadow(0 0.75rem 1rem rgb(143 21 40 / 16%));
}

.yl-kicker {
  margin: 0 0 0.5rem;
  color: var(--yl-crimson-deep);
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  line-height: 1.5;
  text-transform: uppercase;
}

.yl-title {
  margin: 0;
  font-size: clamp(1.5rem, 7vw, 2rem);
  font-weight: 800;
  letter-spacing: -0.025em;
  line-height: 1.15;
}

.yl-message {
  max-width: 23rem;
  margin: 0.75rem auto 0;
  color: var(--yl-muted);
  font-size: 1rem;
  line-height: 1.6;
}

.yl-progress {
  position: relative;
  width: min(100%, 11rem);
  height: 0.25rem;
  margin: 1.75rem auto 0;
  overflow: hidden;
  border-radius: 999px;
  background: #f0dadd;
}

.yl-progress::after {
  position: absolute;
  inset: 0;
  width: 42%;
  border-radius: inherit;
  background: var(--yl-crimson);
  content: "";
  animation: yl-progress 1.2s ease-in-out infinite alternate;
}

.yl-retry {
  display: none;
  min-width: 8rem;
  min-height: 3rem;
  margin: 1.5rem auto 0;
  padding: 0.75rem 1.25rem;
  border: 0;
  border-radius: 0.75rem;
  background: var(--yl-crimson);
  color: #ffffff;
  font: inherit;
  font-weight: 800;
  line-height: 1.2;
  cursor: pointer;
}

.yl-retry:hover {
  background: var(--yl-crimson-deep);
}

.yl-retry:focus-visible {
  outline: 0.2rem solid var(--yl-focus);
  outline-offset: 0.2rem;
}

#yl-web-shell[data-state="offline"] .yl-progress,
#yl-web-shell[data-state="transient"] .yl-progress,
#yl-web-shell[data-state="deterministic"] .yl-progress,
#yl-web-shell[data-state="unsupported"] .yl-progress {
  display: none;
}

#yl-web-shell[data-state="offline"] .yl-retry,
#yl-web-shell[data-state="transient"] .yl-retry {
  display: block;
}

#yl-web-shell[data-state="offline"] .yl-kicker,
#yl-web-shell[data-state="transient"] .yl-kicker,
#yl-web-shell[data-state="deterministic"] .yl-kicker,
#yl-web-shell[data-state="unsupported"] .yl-kicker {
  letter-spacing: 0.06em;
  text-transform: none;
}

.yl-noscript {
  margin: 1rem auto 0;
  color: var(--yl-crimson-deep);
  font-weight: 700;
  line-height: 1.5;
}

@keyframes yl-progress {
  from {
    transform: translateX(-115%);
  }

  to {
    transform: translateX(255%);
  }
}

@media (max-width: 390px) {
  .yl-shell-panel {
    border-radius: 1.125rem;
    box-shadow: 0 1rem 2.5rem rgb(73 22 32 / 9%);
  }
}

@media (prefers-reduced-motion: reduce) {
  #yl-web-shell {
    transition: none;
  }

  .yl-progress::after {
    width: 55%;
    animation: none;
  }
}

@media (forced-colors: active) {
  .yl-shell-panel,
  .yl-retry {
    border: 2px solid ButtonText;
  }

  .yl-progress::after {
    background: Highlight;
  }
}
