[hidden] { display: none !important; }

:root {
  color-scheme: dark;
  font-family: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #f8fafb;
  background: #062431;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

* {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  height: 100%;
  margin: 0;
  overflow: hidden;
}

.island-shell {
  position: relative;
  width: 100vw;
  height: 100dvh;
  overflow: hidden;
  background:
    radial-gradient(ellipse at 50% 35%, #0d4356 0%, transparent 55%),
    linear-gradient(180deg, #0a3344 0%, #041923 100%);
}

.island-frame {
  position: absolute;
  inset: 0;
  width: calc(100% * var(--oriel-player-layout-scale, 1));
  height: calc(100% * var(--oriel-player-layout-scale, 1));
  border: 0;
  opacity: 0;
  transform: scale(var(--oriel-player-presentation-scale, 1));
  transform-origin: 0 0;
  transition: opacity 420ms ease;
}

.island-shell[data-phase="ready"] .island-frame {
  opacity: 1;
}

.island-status {
  position: absolute;
  top: 50%;
  left: 50%;
  width: min(540px, calc(100vw - 48px));
  transform: translate(-50%, -50%);
  text-align: center;
}

.island-status h1 {
  margin: 0 0 14px;
  color: #ecfff9;
  font-size: clamp(40px, 7vw, 64px);
  font-weight: 600;
  line-height: 1.06;
  letter-spacing: -0.055em;
}

.island-status p {
  margin: 0;
  color: rgb(221 247 244 / 72%);
  font-size: 13px;
  line-height: 1.55;
}

.island-status .island-tagline {
  color: #b6d9d9;
  font-size: 16px;
  letter-spacing: 0.01em;
}

.island-loading-note {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 34px;
}

.island-shell[data-phase="error"] .island-status h1 {
  font-size: clamp(28px, 5vw, 40px);
  letter-spacing: -0.04em;
}

.island-shell[data-phase="error"] .island-loading-note p {
  overflow-wrap: anywhere;
}

.island-shell[data-phase="error"] .island-status {
  max-height: calc(100dvh - 48px);
  overflow-y: auto;
}

.island-spinner {
  display: inline-block;
  flex: 0 0 16px;
  width: 16px;
  height: 16px;
  border: 2px solid rgb(124 223 195 / 22%);
  border-top-color: #7cdfc3;
  border-radius: 50%;
  animation: island-spin 800ms linear infinite;
}

@media (max-width: 420px) {
  .island-status .island-tagline { font-size: 14px; }
  .island-loading-note { margin-top: 28px; }
}

.island-status button {
  padding: 10px 15px;
  border: 1px solid rgb(255 255 255 / 18%);
  border-radius: 999px;
  background: rgb(6 21 28 / 62%);
  color: #f8fafb;
  font: inherit;
  font-size: 13px;
  cursor: pointer;
  backdrop-filter: blur(20px);
}

.island-status button {
  margin-top: 22px;
}

.island-status button:hover {
  background: rgb(18 49 60 / 80%);
}

@keyframes island-spin {
  to {
    transform: rotate(360deg);
  }
}

@media (prefers-reduced-motion: reduce) {
  .island-spinner {
    animation: none;
  }

  .island-frame {
    transition: none;
  }
}
