/* Butanero Tycoon Game Styles */
#butanero-game {
  font-family: "Arial", sans-serif;
  user-select: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
}

#game-canvas {
  cursor: crosshair;
}

/* Joystick Styles */
#joystick-base {
  border: 2px solid rgba(255, 255, 255, 0.3);
}

#joystick-knob {
  transition: all 0.1s ease;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

/* Upgrade Panel Animation */
#upgrades-panel {
  transform: translateX(100%);
  transition: transform 0.3s ease;
}

#upgrades-panel.show {
  transform: translateX(0);
}

/* Notification Styles */
.notification {
  background: rgba(0, 0, 0, 0.8);
  color: white;
  padding: 12px 24px;
  border-radius: 8px;
  margin-bottom: 8px;
  animation: slideInDown 0.3s ease, fadeOut 0.3s ease 2.7s forwards;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.notification.success {
  background: rgba(34, 197, 94, 0.9);
}

.notification.error {
  background: rgba(239, 68, 68, 0.9);
}

.notification.info {
  background: rgba(59, 130, 246, 0.9);
}

@keyframes slideInDown {
  from {
    transform: translateY(-100%);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

@keyframes fadeOut {
  to {
    opacity: 0;
    transform: translateY(-20px);
  }
}

/* Loading Animation */
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* Responsive Design */
@media (max-width: 768px) {
  #upgrades-panel {
    right: 2px;
    left: 2px;
    width: auto;
  }

  .notification {
    font-size: 14px;
    padding: 8px 16px;
  }
}

/* Button Hover Effects */
.upgrade-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.upgrade-btn:active {
  transform: translateY(0);
}

/* Fuel Bar Animation */
#fuel-bar {
  transition: width 0.3s ease;
}

/* Modal Animations */
.modal-enter {
  animation: modalEnter 0.3s ease;
}

.modal-exit {
  animation: modalExit 0.3s ease;
}

@keyframes modalEnter {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes modalExit {
  from {
    opacity: 1;
    transform: scale(1);
  }
  to {
    opacity: 0;
    transform: scale(0.9);
  }
}

/* 3D Effect for Buildings */
.building-3d {
  filter: drop-shadow(2px 2px 4px rgba(0, 0, 0, 0.3));
}

/* Truck Trail Effect */
.truck-trail {
  opacity: 0.6;
  animation: trailFade 1s ease-out forwards;
}

@keyframes trailFade {
  to {
    opacity: 0;
    transform: scale(0.8);
  }
}
