:root {
  --edge-top: #12344d;
  --edge-bottom: #d6e5ff;
  --inset-top: env(safe-area-inset-top, 0px);
  --inset-right: env(safe-area-inset-right, 0px);
  --inset-bottom: env(safe-area-inset-bottom, 0px);
  --inset-left: env(safe-area-inset-left, 0px);
  --toolbar-top: var(--inset-top);
  --toolbar-bottom: var(--inset-bottom);
}
@media (prefers-color-scheme: dark) {
  :root { --edge-top: #152e44; --edge-bottom: #101821; }
}
html, body { margin: 0; width: 100%; height: 100%; overflow: hidden; }
html { background-color: var(--edge-bottom); }
body {
  background-color: var(--edge-bottom);
  background-image: linear-gradient(var(--edge-top) var(--toolbar-top), var(--edge-bottom) calc(100% - var(--toolbar-bottom)));
}
body::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: var(--inset-top);
  pointer-events: none;
  background: var(--edge-top);
}
@media (orientation: portrait) {
  html.iphone-home { --toolbar-top: calc(var(--inset-top) + min(12px, var(--inset-top))); }
  html.iphone-bottom-reserved { --toolbar-bottom: 0px; }
}
#frame {
  position: fixed;
  top: var(--toolbar-top);
  right: var(--inset-right);
  bottom: var(--toolbar-bottom);
  left: var(--inset-left);
}
#flutter-host { position: relative; width: 100%; height: 100%; overflow: hidden; }
#frame.editing {
  top: calc(var(--visible-top) + var(--inset-top));
  bottom: auto;
  height: max(0px, calc(var(--visible-height) - var(--inset-top)));
}
