* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  width: 100%;
  height: 100%;
  height: 100dvh;
  overflow: hidden;
  background: #050505;
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  color: #ccc;
  touch-action: none;
  overscroll-behavior: none;
  -webkit-overflow-scrolling: none;
}

#game-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  height: 100dvh;
  touch-action: none;
}

#world-map {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  height: 100dvh;
  background: #050505;
  display: none;
  z-index: 1;
  touch-action: none;
}

#overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  height: 100dvh;
  pointer-events: none;
  z-index: 10;
}

.overlay-room-name {
  position: absolute;
  bottom: 24px;
  left: 24px;
  font-size: 28px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.8);
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);
}

.overlay-server-name {
  position: absolute;
  bottom: 60px;
  left: 24px;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.5);
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.6);
}

.overlay-status {
  position: absolute;
  top: 16px;
  right: 16px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.4);
}

.overlay-status.connected {
  color: rgba(100, 200, 100, 0.6);
}

.overlay-status.disconnected {
  color: rgba(200, 100, 100, 0.6);
}

.overlay-status.loading {
  color: rgba(200, 200, 100, 0.6);
}

#transition-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  height: 100dvh;
  background: #050505;
  opacity: 0;
  pointer-events: none;
  z-index: 5;
  transition: opacity 0.4s ease;
}

#transition-overlay.fading {
  opacity: 1;
}

#loading-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #050505;
  z-index: 20;
  transition: opacity 0.5s ease;
}

#loading-screen.hidden {
  opacity: 0;
  pointer-events: none;
}

.loading-text {
  font-size: 18px;
  color: rgba(255, 255, 255, 0.5);
}
