/* ===== MALWARE GAME CSS ===== */

/* Boot Screen Styles */
#boot-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: #000000;
  z-index: 10000;
  display: flex;
  justify-content: center;
  align-items: center;
}

.boot-content {
  text-align: center;
  font-family: 'Courier New', monospace;
}

.enter-text {
  color: #ff0000;
  font-size: 24px;
  font-weight: bold;
  margin-bottom: 30px;
  text-shadow: 0 0 10px #ff0000;
  animation: glow 2s ease-in-out infinite alternate;
  image-rendering: pixelated;
  text-rendering: optimizeSpeed;
}

.begin-btn {
  background: #000000;
  border: 3px solid #ff0000;
  color: #ff0000;
  font-family: 'Courier New', monospace;
  font-size: 36px;
  font-weight: bold;
  padding: 20px 40px;
  cursor: pointer;
  text-shadow: 0 0 10px #ff0000;
  box-shadow: 0 0 20px #ff0000;
  animation: pulse 2s ease-in-out infinite;
  image-rendering: pixelated;
  text-rendering: optimizeSpeed;
  transition: all 0.3s ease;
}

.begin-btn:hover {
  background: #ff0000;
  color: #000000;
  text-shadow: none;
  box-shadow: 0 0 30px #ff0000;
}

@keyframes glow {
  from { text-shadow: 0 0 10px #ff0000; }
  to { text-shadow: 0 0 20px #ff0000, 0 0 30px #ff0000; }
}

@keyframes pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.05); }
  100% { transform: scale(1); }
}

/* Game Screen Styles */
#game-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: #000000;
  z-index: 9999;
  overflow: hidden;
}

#game-background {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #000000;
  animation: static-noise 0.1s infinite;
}

@keyframes static-noise {
  0% { background: #000000; }
  25% { background: #111111; }
  50% { background: #000000; }
  75% { background: #0a0a0a; }
  100% { background: #000000; }
}

#game-ui {
  position: fixed;
  top: 20px;
  left: 20px;
  z-index: 10001;
  font-family: 'Courier New', monospace;
  color: #ff0000;
  font-size: 18px;
  font-weight: bold;
  text-shadow: 0 0 10px #ff0000;
}

#virus-counter, #game-timer {
  margin-bottom: 10px;
  padding: 10px;
  background: rgba(0, 0, 0, 0.8);
  border: 2px solid #ff0000;
  border-radius: 5px;
}

/* Malware Popup Styles */
.malware-popup {
  position: absolute;
  border: 2px solid #000080;
  background: #c0c0c0;
  box-shadow: 3px 3px 0 #000;
  z-index: 10000;
  min-width: 280px;
  max-width: 450px;
  font-family: Tahoma, sans-serif;
  animation: popup-spawn 0.5s ease-out;
}

.malware-popup.large-popup {
  min-width: 350px;
  max-width: 500px;
}

.malware-popup.very-large-popup {
  min-width: 400px;
  max-width: 550px;
}

@keyframes popup-spawn {
  0% {
    transform: scale(0) rotate(360deg);
    opacity: 0;
  }
  100% {
    transform: scale(1) rotate(0deg);
    opacity: 1;
  }
}

.malware-popup.virus-alert {
  border-color: #ff0000;
  animation: flash-border 0.5s infinite;
}

@keyframes flash-border {
  0% { border-color: #ff0000; box-shadow: 0 0 10px #ff0000; }
  50% { border-color: #ffff00; box-shadow: 0 0 10px #ffff00; }
  100% { border-color: #ff0000; box-shadow: 0 0 10px #ff0000; }
}

.malware-popup.moving {
  transition: all 0.3s ease;
}

.malware-title-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 4px;
  background: linear-gradient(to right, #000080, #0000cd);
  color: #fff;
  font-weight: bold;
  cursor: move;
  font-size: 12px;
}

.malware-title-bar.virus-title {
  background: linear-gradient(to right, #ff0000, #cc0000);
  animation: flash-title 0.3s infinite;
}

@keyframes flash-title {
  0% { background: linear-gradient(to right, #ff0000, #cc0000); }
  50% { background: linear-gradient(to right, #ffff00, #cccc00); }
  100% { background: linear-gradient(to right, #ff0000, #cc0000); }
}

.malware-buttons {
  display: flex;
}

.malware-buttons button {
  width: 20px;
  height: 20px;
  margin-left: 2px;
  font-size: 10px;
  cursor: pointer;
  border: 1px solid #000;
  background: #c0c0c0;
}

.malware-buttons .close-btn {
  background: #ff6b6b;
}

.malware-buttons .fake-close-btn {
  background: #c0c0c0;
}

.malware-content {
  padding: 15px;
  background: #fff;
  font-size: 12px;
  line-height: 1.4;
  min-height: 120px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.malware-content.large-image {
  min-height: 180px;
  padding: 20px;
}

.malware-content.very-large-image {
  min-height: 280px;
  padding: 20px;
}

.malware-image {
  max-width: 120px;
  max-height: 120px;
  float: left;
  margin-right: 15px;
  margin-bottom: 10px;
  image-rendering: auto;
  border: 1px solid #000;
  object-fit: contain;
}

/* Specific image size adjustments */
.malware-image.large-text {
  max-width: 150px;
  max-height: 150px;
}

.malware-image.very-large {
  max-width: 200px;
  max-height: 250px;
}

.malware-image.small {
  max-width: 80px;
  max-height: 80px;
}

.malware-text {
  font-weight: bold;
  color: #000;
}

.malware-text.warning {
  color: #ff0000;
  animation: text-flash 0.5s infinite;
}

@keyframes text-flash {
  0% { color: #ff0000; }
  50% { color: #000000; }
  100% { color: #ff0000; }
}

.malware-button {
  background: #e6e6e6;
  border: 2px outset #e6e6e6;
  padding: 5px 15px;
  margin: 10px 5px 0 0;
  cursor: pointer;
  font-size: 11px;
  font-family: Tahoma, sans-serif;
}

.malware-button:hover {
  background: #d4d4d4;
}

.malware-button:active {
  border: 2px inset #e6e6e6;
}

/* Special popup types */
.popup-crypto {
  background: linear-gradient(45deg, #000000, #333333);
  color: #00ff00;
}

.popup-crypto .malware-content {
  background: #000000;
  color: #00ff00;
}

.popup-dating {
  background: linear-gradient(45deg, #ff69b4, #ffb6c1);
}

.popup-dating .malware-content {
  background: #ffe4e1;
}

.popup-toolbar {
  height: auto;
  min-height: 200px;
}

.popup-final-boss {
  border: 5px solid #ff0000;
  background: #000000;
  color: #ff0000;
  animation: boss-shake 0.1s infinite;
  z-index: 10002;
}

@keyframes boss-shake {
  0% { transform: translate(0px, 0px); }
  25% { transform: translate(-2px, -2px); }
  50% { transform: translate(2px, -2px); }
  75% { transform: translate(-2px, 2px); }
  100% { transform: translate(2px, 2px); }
}

.popup-final-boss .malware-content {
  background: #000000;
  color: #ff0000;
  font-weight: bold;
  text-align: center;
  animation: text-glow 0.5s infinite alternate;
}

@keyframes text-glow {
  from { text-shadow: 0 0 5px #ff0000; }
  to { text-shadow: 0 0 15px #ff0000, 0 0 25px #ff0000; }
}

/* Task Manager Fake */
.fake-task-manager {
  width: 500px;
  height: 400px;
  background: #c0c0c0;
  border: 2px outset #c0c0c0;
}

.fake-task-manager .malware-content {
  background: #c0c0c0;
  padding: 0;
}

.task-list {
  background: #ffffff;
  margin: 10px;
  height: 300px;
  border: 1px inset #c0c0c0;
  overflow: hidden;
  font-family: 'Courier New', monospace;
  font-size: 10px;
}

.task-item {
  padding: 2px 5px;
  border-bottom: 1px solid #e0e0e0;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .malware-popup {
    min-width: 250px;
    max-width: 350px;
  }
  
  .malware-popup.large-popup {
    min-width: 280px;
    max-width: 380px;
  }
  
  .malware-popup.very-large-popup {
    min-width: 300px;
    max-width: 400px;
  }
  
  .malware-image.large-text {
    max-width: 120px;
    max-height: 120px;
  }
  
  .malware-image.very-large {
    max-width: 150px;
    max-height: 180px;
  }
  
  .begin-btn {
    font-size: 24px;
    padding: 15px 30px;
  }
  
  #game-ui {
    font-size: 14px;
  }
}

@media (max-width: 480px) {
  .malware-popup {
    min-width: 200px;
    max-width: 280px;
  }
  
  .malware-image {
    max-width: 60px;
    max-height: 60px;
  }
  
  .malware-image.large-text {
    max-width: 80px;
    max-height: 80px;
  }
  
  .malware-image.very-large {
    max-width: 100px;
    max-height: 120px;
  }
  
  .malware-content {
    font-size: 11px;
    padding: 10px;
  }
}

/* Success screen */
.game-complete {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: #000000;
  color: #00ff00;
  display: flex;
  justify-content: center;
  align-items: center;
  font-family: 'Courier New', monospace;
  font-size: 24px;
  z-index: 10003;
  text-align: center;
  animation: success-glow 2s ease-in-out infinite alternate;
}

@keyframes success-glow {
  from { text-shadow: 0 0 10px #00ff00; }
  to { text-shadow: 0 0 20px #00ff00, 0 0 30px #00ff00; }
}
