body {
  margin: 0;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background-color: #121212;
  color: #e0e0e0;
  overflow-x: hidden;
}

header {
  text-align: center;
  padding: 20px 0 10px;
  background-color: #1e1e1e;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
}

header h1 {
  margin: 0;
  font-size: 32px;
  color: #ffffff;
  font-weight: 600;
}

header p {
  margin-top: 5px;
  font-size: 16px;
  color: #ccc;
}

#container {
  display: flex;
  height: calc(100vh - 100px);
}

#canvas-container {
  flex: 3;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

#control-panel {
  flex: 1;
  padding: 30px 25px;
  background-color: #1e1e1e;
  display: flex;
  flex-direction: column;
  gap: 20px;
  box-shadow: -2px 0 10px rgba(0, 0, 0, 0.4);
}

#control-panel h2 {
  margin: 0;
  font-size: 22px;
  color: #90caf9;
}

.control-group {
  display: flex;
  flex-direction: column;
}

.control-group label {
  font-size: 1rem;
  font-weight: bold;
  color: #bbb;
  margin-bottom: 6px;
}

input[type="range"] {
  width: 100%;
  margin-bottom: 5px;
  accent-color: #64b5f6;
  background-color: #333;
  border-radius: 4px;
}

input[type="checkbox"] {
  margin-right: 8px;
  accent-color: #64b5f6;
}

span {
  font-size: 14px;
  color: #ccc;
}

.button-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

button {
  padding: 10px 20px;
  background-color: #64b5f6;
  border: none;
  border-radius: 6px;
  color: #121212;
  font-weight: bold;
  cursor: pointer;
  transition: background-color 0.2s ease-in-out;
}

button:hover {
  background-color: #90caf9;
}

.hint {
  font-size: 13px;
  color: #aaa;
  text-align: center;
}

#stats-panel {
  position: absolute;
  top: 10px;
  right: 10px;
  background-color: rgba(100, 181, 246, 0.1);
  border: 1px solid #64b5f6;
  border-radius: 8px;
  padding: 10px 15px;
  font-size: 14px;
  line-height: 1.5;
  color: #e0e0e0;
  pointer-events: none;
  width: 220px;
  box-sizing: border-box;
}

/* Info Toggle Button */
#infoToggle {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 10;
  padding: 8px 14px;
  font-size: 14px;
  font-weight: bold;
  border: none;
  background-color: #64b5f6;
  color: #121212;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.2s ease-in-out;
}

#infoToggle:hover {
  background-color: #90caf9;
}

/* Info Panel */
#infoPanel {
  position: fixed;
  top: 80px;
  left: 20px;
  max-width: 400px;
  background: #1e1e1e;
  border: none;
  box-shadow: 0 0 20px rgba(0, 100, 255, 0.3);
  padding: 20px;
  border-radius: 12px;
  color: #ccc;
  z-index: 20;
  overflow-y: auto;
  max-height: 80vh;
}

#infoPanel h2 {
  color: #90caf9;
  margin-top: 0;
}

#infoPanel h3 {
  color: #90caf9;
  margin-top: 1em;
}

#infoPanel code {
  background-color: #2a2a2a;
  padding: 2px 5px;
  border-radius: 4px;
  font-family: 'Courier New', monospace;
  color: #90caf9;
}

#infoPanel #infoClose {
  position: absolute;
  top: 10px;
  right: 10px;
  background: none;
  color: #bbb;
  border: none;
  font-size: 14px;
  padding: 4px 8px;
  cursor: pointer;
  transition: color 0.2s ease-in-out;
}

#infoPanel #infoClose:hover {
  background: none;
  color: #fff;
}

.hidden {
  display: none;
}
