* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Segoe UI', system-ui, sans-serif;
  background: #1a1a2e;
  color: #eee;
  min-height: 100vh;
  overflow: hidden;
}

.hidden {
  display: none !important;
}

/* Join screen */
#join-screen {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.join-card {
  background: linear-gradient(145deg, #16213e 0%, #1a1a2e 100%);
  border: 1px solid #0f3460;
  border-radius: 16px;
  padding: 2.5rem;
  max-width: 360px;
  width: 100%;
}

.join-card h1 {
  font-size: 1.8rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 0.25rem;
  background: linear-gradient(90deg, #e94560, #ff6b6b);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.tagline {
  color: #8892a6;
  font-size: 0.9rem;
  text-align: center;
  margin-bottom: 1.5rem;
}

#join-form {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

#join-form input {
  padding: 0.9rem 1rem;
  border: 1px solid #0f3460;
  border-radius: 10px;
  background: #0f3460;
  color: #eee;
  font-size: 1rem;
  transition: border-color 0.2s, box-shadow 0.2s;
}

#join-form input::placeholder {
  color: #5a6a8a;
}

#join-form input:focus {
  outline: none;
  border-color: #e94560;
  box-shadow: 0 0 0 3px rgba(233, 69, 96, 0.2);
}

#join-form button {
  padding: 1rem;
  border: none;
  border-radius: 10px;
  background: linear-gradient(135deg, #e94560, #c73e54);
  color: white;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.2s;
}

#join-form button:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 24px rgba(233, 69, 96, 0.35);
}

#join-form button:active {
  transform: translateY(0);
}

.hint {
  margin-top: 1rem;
  color: #5a6a8a;
  font-size: 0.8rem;
  text-align: center;
}

/* Game screen */
#game-screen {
  position: relative;
  width: 100vw;
  height: 100vh;
  background: #0f0f1a;
}

#canvas {
  display: block;
  width: 100%;
  height: 100%;
}

.ui-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  background: linear-gradient(transparent, rgba(0,0,0,0.7));
}

.chat-input-wrapper {
  flex: 1;
  max-width: 400px;
}

#chat-input {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid #333;
  border-radius: 10px;
  background: rgba(26, 26, 46, 0.9);
  color: #eee;
  font-size: 0.95rem;
}

#chat-input::placeholder {
  color: #5a6a8a;
}

#chat-input:focus {
  outline: none;
  border-color: #e94560;
}

.room-label {
  color: #8892a6;
  font-size: 0.85rem;
}

.online-count {
  color: #5a6a8a;
  font-size: 0.85rem;
}
