/* Shared Styles - Used by both Lobby and Game apps */

/* Global Reset & Base */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Arial', sans-serif;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  min-height: 100vh;
  color: #333;
}

#app {
  width: 100%;
  height: 100vh;
}

.screen {
  display: none;
  width: 100%;
  height: 100%;
}

.screen.active {
  display: flex;
}

/* Input Styles */
input[type="text"] {
  padding: 12px;
  border: 2px solid #ddd;
  border-radius: 8px;
  font-size: 16px;
  transition: border-color 0.3s;
}

input[type="text"]:focus {
  outline: none;
  border-color: #667eea;
}

/* Button Base Styles */
.btn {
  padding: 12px 24px;
  border: none;
  border-radius: 8px;
  font-size: 16px;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
  font-weight: bold;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.btn-primary {
  background: #667eea;
  color: white;
}

.btn-secondary {
  background: #764ba2;
  color: white;
}

/* Color classes */
.color-red { background-color: #ff6b6b; }
.color-blue { background-color: #4dabf7; }
.color-white { background-color: #f8f9fa; border: 2px solid #333; }
.color-orange { background-color: #ff922b; }
.color-green { background-color: #51cf66; }
.color-brown { background-color: #a0522d; }

/* Connection Status Indicator */
.connection-status {
  position: fixed;
  top: 20px;
  right: 20px;
  padding: 12px 24px;
  border-radius: 8px;
  font-weight: bold;
  font-size: 14px;
  z-index: 10000;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  transition: all 0.3s ease;
  display: none;
}

.connection-status.status-connected {
  background-color: #51cf66;
  color: white;
  animation: slideInRight 0.3s ease;
}

.connection-status.status-disconnected {
  background-color: #ff6b6b;
  color: white;
  animation: slideInRight 0.3s ease, pulse 1.5s ease-in-out infinite;
}

.connection-status.status-reconnecting {
  background-color: #ffa94d;
  color: white;
  animation: slideInRight 0.3s ease, pulse 1.5s ease-in-out infinite;
}

.connection-status.status-failed {
  background-color: #c92a2a;
  color: white;
  animation: slideInRight 0.3s ease;
}

@keyframes slideInRight {
  from {
    transform: translateX(400px);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

@keyframes pulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.7;
  }
}
