:root {
  --bg: #000000;
  --green: #33ff33;
  --green-glow: 0 0 8px rgba(51, 255, 51, 0.8);
  --mono: 'Courier New', Courier, monospace;
}

body {
  margin: 0;
  padding: 0;
  overflow: hidden;
  background-color: var(--bg);
  color: var(--green);
  font-family: var(--mono);
  font-size: 20px;
}

#root {
  width: 100vw;
  height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: relative;
}

/* Retro Scanlines */
#root::before {
  content: " ";
  display: block;
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  right: 0;
  background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.25) 50%), linear-gradient(90deg, rgba(255, 0, 0, 0.06), rgba(0, 255, 0, 0.02), rgba(0, 0, 255, 0.06));
  z-index: 1000;
  background-size: 100% 4px, 3px 100%;
  pointer-events: none;
}

h1, h2, h3, p, div, button, span {
  text-shadow: var(--green-glow);
  text-transform: uppercase;
}

button {
  background: transparent;
  color: var(--green);
  border: 4px solid var(--green);
  padding: 20px;
  font-family: var(--mono);
  font-size: 32px;
  cursor: pointer;
  margin: 10px;
  transition: all 0.1s;
  box-shadow: var(--green-glow);
  white-space: nowrap;
  -webkit-user-select: none;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

button:active {
  background: var(--green);
  color: var(--bg);
}

.box-border {
  border: 2px solid var(--green);
  padding: 20px;
  box-shadow: var(--green-glow);
  margin-bottom: 20px;
}

.container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  text-align: center;
  z-index: 10;
}

.menu {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 10px;
  overflow-y: auto;
  max-height: 100vh;
}

.menu h1 {
  font-size: 28px;
  margin: 5px 0;
}

.menu .line {
  margin-bottom: 5px;
}

.menu button {
  font-size: 24px;
  padding: 15px;
  margin: 0;
}

.line {
  color: var(--green);
  font-weight: bold;
  margin-bottom: 20px;
}

.game-screen {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 90%;
  max-width: 800px;
}

.display-text {
  font-size: 80px;
  margin: 20px 0;
  letter-spacing: 10px;
}

.controls {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-top: 15px;
}

.big-letter-btn {
  width: 100px;
  height: 100px;
  font-size: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.controls button {
  min-width: 80px;
  min-height: 80px;
  font-size: 36px;
}

.items-display {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: center;
  font-size: 60px;
  margin: 40px 0;
}

.math-visual {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 20px;
  margin: 20px 0;
  flex-wrap: wrap;
}

.addend-group {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.addend-number {
  font-size: 80px;
  line-height: 1;
}

.addend-circles {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  font-size: 50px;
  max-width: 200px;
}

.math-operator {
  font-size: 80px;
  line-height: 1;
  padding-top: 5px;
}

.word-emoji {
  font-size: 100px;
  text-shadow: none;
  margin: 10px 0;
  line-height: 1.1;
}

.back-btn {
  margin-top: 30px;
  font-size: 18px;
  border-width: 2px;
}

.success-overlay {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: var(--bg);
  border: 4px solid var(--green);
  padding: 40px;
  box-shadow: var(--green-glow);
  z-index: 2000;
}

.success-overlay h1 {
  color: var(--green);
  font-size: 80px;
  margin: 0;
}

button.cooldown {
  opacity: 0.2;
  cursor: not-allowed;
  border-color: #888;
  color: #888;
  text-shadow: 0 0 8px rgba(136, 136, 136, 0.5);
  box-shadow: 0 0 8px rgba(136, 136, 136, 0.5);
}

#root.wrong-screen {
  --green: #888888;
  --green-glow: 0 0 8px rgba(136, 136, 136, 0.5);
}

#root.wrong-screen .box-border {
  border-color: #888888;
  box-shadow: 0 0 8px rgba(136, 136, 136, 0.5);
}

#root.wrong-screen button {
  color: #888888;
  border-color: #888888;
  box-shadow: 0 0 8px rgba(136, 136, 136, 0.5);
}

#root.wrong-screen button.cooldown {
  opacity: 0.2;
}

.wrong-overlay {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: var(--bg);
  border: 4px solid #888888;
  padding: 40px;
  box-shadow: 0 0 8px rgba(136, 136, 136, 0.5);
  z-index: 2000;
  text-align: center;
}

.wrong-overlay h1 {
  color: #888888;
  font-size: 80px;
  margin: 0 0 20px 0;
  text-shadow: 0 0 8px rgba(136, 136, 136, 0.5);
}

.wrong-progress-track {
  width: 300px;
  height: 16px;
  border: 2px solid #888888;
  box-shadow: 0 0 8px rgba(136, 136, 136, 0.5);
}

.wrong-progress-bar {
  height: 100%;
  width: 0%;
  background: #888888;
  box-shadow: 0 0 8px rgba(136, 136, 136, 0.5);
  transition: width 5s linear;
}

.menu-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
}

.difficulty-badge {
  font-size: 14px;
  opacity: 0.6;
  text-shadow: none;
}

.shape-display {
  font-size: 100px;
  margin: 10px 0;
  line-height: 1.1;
}

.comparison-display {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  margin: 20px 0;
}

.compare-group {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  font-size: 50px;
  max-width: 200px;
  min-width: 100px;
}

.compare-vs {
  font-size: 80px;
  opacity: 0.4;
}

.hidden {
  display: none !important;
}
