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

body {
  background: #1a1a1a;
  font-family: 'IBM Plex Mono', 'Courier New', monospace;
  color: #c8b898;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-height: 100vh;
  overflow-x: hidden;
  user-select: none;
}

#monitor-frame {
  margin-top: 20px;
  perspective: 800px;
}

#crt-bezel {
  background: linear-gradient(145deg, #d4c4a0, #b0a080);
  border-radius: 20px;
  padding: 24px 28px 12px 28px;
  box-shadow: 
    0 8px 32px rgba(0,0,0,0.6),
    inset 0 1px 0 rgba(255,255,255,0.3),
    inset 0 -2px 4px rgba(0,0,0,0.2);
  position: relative;
}

#screen-area {
  position: relative;
  background: #000;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 
    inset 0 0 40px rgba(0,0,0,0.8),
    inset 0 0 8px rgba(0,0,0,1),
    0 0 2px rgba(0,0,0,0.5);
  border: 3px solid #2a2a2a;
}

#canvas {
  display: block;
  width: 720px;
  height: 400px;
  image-rendering: pixelated;
  image-rendering: crisp-edges;
}

#scanlines {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 1px,
    rgba(0,0,0,0.15) 1px,
    rgba(0,0,0,0.15) 2px
  );
  pointer-events: none;
  z-index: 2;
}

#focus-overlay {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #55ff55;
  font-size: 24px;
  font-weight: 700;
  z-index: 3;
  cursor: pointer;
  text-shadow: 0 0 10px #55ff55;
  transition: opacity 0.3s;
}

#focus-overlay.hidden {
  opacity: 0;
  pointer-events: none;
}

#bezel-bottom {
  display: flex;
  align-items: center;
  padding: 8px 10px 2px 10px;
  gap: 12px;
}

.ibm-logo {
  font-weight: 700;
  font-size: 18px;
  color: #3366cc;
  letter-spacing: 3px;
  text-shadow: 0 1px 0 rgba(255,255,255,0.5);
}

.monitor-model {
  font-size: 10px;
  color: #888070;
  flex: 1;
}

.power-led-monitor {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #333;
  box-shadow: inset 0 1px 2px rgba(0,0,0,0.5);
}

.power-led-monitor.on {
  background: #55ff55;
  box-shadow: 0 0 6px #55ff55, inset 0 1px 2px rgba(255,255,255,0.3);
}

/* Control Panel */
#control-panel {
  width: 776px;
  background: linear-gradient(180deg, #d4c4a0, #c0b090);
  border-radius: 0 0 8px 8px;
  padding: 4px 16px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.4);
}

.panel-groove {
  height: 2px;
  background: linear-gradient(180deg, #a09070, #e0d0b0);
  margin: 4px 0;
  border-radius: 1px;
}

.controls-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 0;
  gap: 16px;
}

.control-group {
  display: flex;
  align-items: center;
  gap: 8px;
}

.chunky-btn {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  font-weight: 700;
  padding: 6px 14px;
  border: 2px solid #8a7a60;
  border-radius: 4px;
  background: linear-gradient(180deg, #e0d0b0, #b0a080);
  color: #3a3020;
  cursor: pointer;
  box-shadow: 
    0 2px 4px rgba(0,0,0,0.3),
    inset 0 1px 0 rgba(255,255,255,0.4);
  text-transform: uppercase;
  letter-spacing: 1px;
  transition: all 0.1s;
}

.chunky-btn:active {
  transform: translateY(1px);
  box-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

.power-btn {
  display: flex;
  align-items: center;
  gap: 6px;
}

.power-btn.on {
  background: linear-gradient(180deg, #c0b090, #a09070);
  box-shadow: inset 0 2px 4px rgba(0,0,0,0.3);
}

.small-btn {
  font-size: 9px;
  padding: 4px 8px;
}

.led {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
  box-shadow: inset 0 1px 2px rgba(0,0,0,0.5);
}

.red-led { background: #440000; }
.red-led.on { background: #ff2200; box-shadow: 0 0 6px #ff2200; }
.amber-led { background: #442200; }
.amber-led.on { background: #ffaa00; box-shadow: 0 0 6px #ffaa00; }

.floppy-group { flex: 1; justify-content: center; }

.floppy-drive {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.drive-slot {
  display: flex;
  align-items: center;
  gap: 8px;
}

.slot-opening {
  width: 200px;
  height: 28px;
  background: linear-gradient(180deg, #2a2a2a, #1a1a1a);
  border: 2px solid #555;
  border-radius: 3px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  color: #888;
  cursor: pointer;
  transition: border-color 0.2s;
}

.slot-opening.drag-over {
  border-color: #ffaa00;
  background: linear-gradient(180deg, #3a3a2a, #2a2a1a);
}

.slot-opening.has-disk {
  color: #ffaa00;
}

.drive-buttons {
  display: flex;
  gap: 6px;
}

.speed-display {
  text-align: center;
}

.lcd-readout {
  background: #1a2a1a;
  color: #55ff55;
  padding: 4px 12px;
  font-size: 13px;
  font-weight: 700;
  border: 2px inset #555;
  border-radius: 3px;
  min-width: 100px;
  text-align: center;
  text-shadow: 0 0 6px #55ff55;
}

.lcd-label {
  font-size: 8px;
  color: #6a5a40;
  margin-top: 2px;
  text-align: center;
}

.volume-control {
  display: flex;
  align-items: center;
  gap: 6px;
}

.speaker-icon {
  font-size: 16px;
  cursor: pointer;
}

.retro-slider {
  width: 60px;
  height: 6px;
  -webkit-appearance: none;
  appearance: none;
  background: #555;
  border-radius: 3px;
  outline: none;
}

.retro-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 14px;
  height: 14px;
  background: linear-gradient(180deg, #e0d0b0, #b0a080);
  border: 2px solid #8a7a60;
  border-radius: 50%;
  cursor: pointer;
}

/* Status Bar */
#status-bar {
  width: 776px;
  background: #111;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 4px 16px;
  font-size: 10px;
  color: #777;
  border-radius: 0 0 4px 4px;
  gap: 8px;
}

#status-bar span {
  white-space: nowrap;
}

/* Footer */
#footer {
  margin-top: 16px;
  margin-bottom: 12px;
}

#footer a {
  color: #8a7a60;
  text-decoration: none;
  font-size: 11px;
  transition: color 0.2s;
}

#footer a:hover {
  color: #c8b898;
}

/* Responsive */
@media (max-width: 800px) {
  #crt-bezel {
    padding: 12px 14px 8px 14px;
    border-radius: 12px;
  }
  #canvas {
    width: 360px;
    height: 200px;
  }
  #control-panel, #status-bar {
    width: calc(100vw - 16px);
  }
  .controls-row {
    flex-wrap: wrap;
    justify-content: center;
  }
  .slot-opening {
    width: 140px;
  }
}