@font-face {
  font-family: "IM Fell English";
  src: url("IMFellEnglish-Regular.ttf") format("truetype");
}

:root {
  --bg: #0a0c0b;
  --text: #ece8dc;
  --dim: rgba(236, 232, 220, 0.55);
  --accent: #e8b04a;
}

html, body {
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: var(--bg);
  color: var(--text);
  font-family: Georgia, "Times New Roman", serif;
}

#game { position: fixed; inset: 0; }

#unity-canvas {
  width: 100%;
  height: 100%;
  display: block;
  background: var(--bg);
  outline: none;
}

#loader {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: radial-gradient(ellipse at 50% 60%, #1a1d18 0%, var(--bg) 70%);
  opacity: 1;
  transition: opacity 1.1s ease;
  text-align: center;
}

#loader.done { opacity: 0; pointer-events: none; }

.kicker { font-size: 13px; letter-spacing: 6px; color: var(--accent); }

#loader h1 {
  margin: 8px 0 34px 0;
  font-family: "IM Fell English", Georgia, serif;
  font-weight: normal;
  font-size: clamp(40px, 7vw, 84px);
}

.bar {
  width: min(360px, 80vw);
  height: 3px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 2px;
  overflow: hidden;
}

#bar-fill {
  width: 0%;
  height: 100%;
  background: var(--accent);
  transition: width 0.3s ease;
}

#status { margin-top: 14px; font-size: 16px; color: var(--dim); font-style: italic; }
#loader.failed #status { color: #e08070; font-style: normal; }

.fine { position: relative; margin-top: 40px; font-size: 12px; letter-spacing: 1px; color: rgba(236, 232, 220, 0.35); }
#mobile-note { margin-top: 10px; color: var(--accent); }
.hidden { display: none; }

#fullscreen {
  position: absolute;
  right: 12px;
  bottom: 12px;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 6px;
  background: rgba(10, 12, 11, 0.5);
  color: var(--dim);
  font-size: 18px;
  cursor: pointer;
}

#fullscreen:hover { color: var(--accent); background: rgba(10, 12, 11, 0.8); }

#banner { position: absolute; top: 0; left: 0; right: 0; }
#banner div { padding: 10px; text-align: center; font-family: sans-serif; }
#banner .warning { background: rgba(232, 176, 74, 0.9); color: #1e160a; }
#banner .error { background: #a33; color: white; }
