:root {
  --primary-color: #4ec0ca;
  --accent-color: #f4ce10;
  --dark-bg: #2c3e50;
  --panel-bg: rgba(0, 0, 0, 0.85);
  --text-color: #ffffff;
  --font-main: 'Roboto', sans-serif;
  --font-pixel: 'Press Start 2P', monospace;
}

body {
  font-family: var(--font-main);
  text-align: center;
  margin: 0;
  padding: 0;
  background: #0e1a49;
  color: var(--text-color);
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
}

.game-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  padding: 20px;
}

.game-content {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: flex-start;
}

.header h1 {
  font-family: var(--font-pixel);
  font-size: 2rem;
  color: var(--accent-color);
  text-shadow: 4px 4px 0px #000;
  margin: 0;
}

.canvas-wrapper {
  position: relative;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  border-radius: 4px;
  overflow: hidden;
  border: 4px solid #fff;
  flex-shrink: 0;
}

#board {
  display: block;
  background-image: url("./assets/images/flappybirdbg.png");
}

#overlay-controls {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none; /* Let clicks pass through to canvas usually */
  display: flex;
  justify-content: center;
  align-items: center;
}

#overlay-controls button {
  pointer-events: auto; /* Re-enable clicks for buttons */
}

.controls-area {
  position: absolute;
  left: 100%;
  top: 0;
  margin-left: 20px;
  width: 300px;
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.left-sidebar {
  position: absolute;
  right: 100%;
  top: 0;
  margin-right: 20px;
  width: 300px;
  text-align: left;
  /* background: var(--panel-bg); Removed background */
  padding: 15px;
  /* border: 2px solid #555; Removed border */
  color: #fff;
  font-size: 0.85rem;
  max-height: 640px;
  overflow-y: auto;
  scrollbar-width: none; /* Firefox */
  -ms-overflow-style: none; /* IE/Edge */
}

/* Hide scrollbar for Chrome, Safari and Opera */
.left-sidebar::-webkit-scrollbar {
  display: none;
}

.left-sidebar h3 {
  font-family: var(--font-pixel);
  font-size: 0.9rem;
  color: var(--accent-color);
  margin-top: 0;
  margin-bottom: 10px;
  text-align: center;
  line-height: 1.4;
}

.left-sidebar p {
  margin-bottom: 10px;
  line-height: 1.4;
}

.left-sidebar ul {
  padding-left: 20px;
  margin: 5px 0 10px 0;
}

.left-sidebar li {
  margin-bottom: 4px;
}

.left-sidebar img {
  width: 100%;
  border-radius: 4px;
  /* border: 1px solid #555; Removed border */
  margin-bottom: 15px;
  display: block;
}

button {
  font-family: var(--font-pixel);
  border: none;
  cursor: pointer;
  transition: transform 0.1s, filter 0.2s;
}

button:active {
  transform: scale(0.95);
}

.primary-btn {
  background-color: var(--accent-color);
  color: #000;
  padding: 15px;
  font-size: 1rem;
  border-radius: 8px;
  box-shadow: 0 4px 0 #c49b00;
  width: 100%;
  text-transform: uppercase;
  font-weight: bold;
}

.primary-btn:hover {
  filter: brightness(1.1);
}

#restartButton, #playButton {
  font-family: var(--font-pixel);
  font-size: 1.5rem;
  padding: 15px 30px;
  border: none;
  color: #fff;
  cursor: pointer;
  border-radius: 4px;
  transition: transform 0.1s, box-shadow 0.1s;
  text-transform: uppercase;
}

#restartButton {
  background: #ff5252;
  box-shadow: 0 4px 0 #b71c1c;
}

#playButton {
  background: #000000; /* Green/Blueish to match theme */
  box-shadow: 0 4px 0 #ffffff;
}

#restartButton:active, #playButton:active {
  transform: translateY(4px);
  box-shadow: 0 0 0;
}

.panel {
  background: var(--panel-bg);
  padding: 15px;
  border-radius: 8px;
  border: 2px solid #555;
}

.panel h3 {
  margin: 0 0 15px 0;
  font-family: var(--font-pixel);
  font-size: 0.8rem;
  color: var(--primary-color);
  text-align: center;
}

.slider-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
  font-size: 0.9rem;
}

.slider-container label {
  flex-basis: 60px;
  text-align: left;
  font-weight: bold;
}

.slider-container input[type="range"] {
  flex-grow: 1;
  margin: 0 10px;
  cursor: pointer;
}

.slider-container span {
  flex-basis: 40px;
  text-align: right;
  font-family: monospace;
}

.stats {
  margin-top: 10px;
  border-top: 1px solid #555;
  padding-top: 10px;
  text-align: center;
  font-size: 0.9rem;
}

.instructions {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.8rem;
}

kbd {
  background: #444;
  padding: 2px 6px;
  border-radius: 4px;
  border-bottom: 2px solid #222;
  font-family: monospace;
}

.hidden {
  display: none !important;
}

.about {
  position: fixed;
  bottom: 20px;
  right: 20px;
  padding: 15px 20px;
  background: rgba(0, 0, 0, 0.7);
  border-radius: 8px;
  border: 2px solid rgba(78, 192, 202, 0.3);
  font-family: var(--font-main);
  font-size: 0.7rem;
  color: rgba(255, 255, 255, 0.9);
  line-height: 1.8;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  z-index: 1000;
}

.about p {
  margin: 5px 0;
}

.about a {
  color: var(--accent-color);
  text-decoration: none;
  transition: color 0.2s, text-shadow 0.2s;
  font-weight: 600;
}

.about a:hover {
  color: var(--primary-color);
  text-shadow: 0 0 5px rgba(78, 192, 202, 0.5);
}
