@import url('https://fonts.googleapis.com/css2?family=VT323&display=swap');

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

html, body {
  width: 100%;
  height: 100%;
  overflow: hidden;
}

body {
  background: #1a0a2e;
  font-family: 'VT323', monospace;
}

#room {
  width: 100vw;
  height: 100vh;
  position: relative;
  overflow: hidden;
  user-select: none;
  cursor: default;
}

/* NALO — swap background/border for your gif */
#nalo {
  position: fixed;
  width: 200px;
  height: 200px;
  cursor: pointer;
  image-rendering: pixelated;
  z-index: 10;
}

/* NALO WALKING LEFT — add: #nalo.facing-left { content: url('nalo-left.gif'); } */
#nalo.facing-left {
  transform: scaleX(-1);
}

/* NALO STATES — swap each src for your own art */
/* idle:       Nalo.gif          */
/* walking:    nalo-walk.gif     */
/* sitting:    nalo-sit.gif      */
/* happy:      nalo-happy.gif    */
/* eating:     nalo-eat.gif      */
/* playing:    nalo-play.gif     */

.bubble {
  position: fixed;
  background: rgba(255,255,255,0.92);
  color: #333;
  border-radius: 8px;
  padding: 4px 10px;
  font-size: 16px;
  pointer-events: none;
  white-space: nowrap;
  z-index: 50;
  animation: bubble-pop 0.2s ease;
}

.bubble::after {
  content: '';
  position: absolute;
  bottom: -6px;
  left: 50%;
  transform: translateX(-50%);
  border: 6px solid transparent;
  border-top-color: rgba(255,255,255,0.92);
  border-bottom: none;
}

@keyframes bubble-pop {
  from { transform: scale(0.7); opacity: 0; }
  to   { transform: scale(1); opacity: 1; }
}

.particle {
  position: fixed;
  pointer-events: none;
  font-size: 16px;
  animation: particle-fly 0.9s ease forwards;
  z-index: 60;
}

@keyframes particle-fly {
  0%   { transform: translate(0,0) scale(1); opacity: 1; }
  100% { transform: translate(var(--px), var(--py)) scale(0); opacity: 0; }
}

@keyframes nalo-bounce {
  0%,100% { transform: translateY(0) scaleY(1); }
  30%      { transform: translateY(-18px) scaleY(1.1); }
  60%      { transform: translateY(4px) scaleY(0.9); }
}

@keyframes nalo-spin {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

@keyframes nalo-sit {
  0%,100% { transform: scaleY(1) translateY(0); }
  50%      { transform: scaleY(0.75) translateY(12px); }
}

.dropped-item {
  position: fixed;
  width: 200px;
  height: 200px;
  cursor: grab;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  z-index: 10;
  image-rendering: pixelated;
}

/* FOOD IMAGE — swap font-size/content for: .dropped-item.food img { width: 50px; } */
/* TOY IMAGE  — swap font-size/content for: .dropped-item.toy  img { width: 50px; } */

.toolbar {
  position: fixed;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 10px;
  z-index: 20;
}

.tool-btn {
  width: 56px;
  height: 56px;
  background: rgba(255,255,255,0.07);
  border: 1px dashed rgba(255,255,255,0.2);
  border-radius: 10px;
  cursor: grab;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  color: rgba(255,255,255,0.4);
  text-align: center;
  line-height: 1.3;
  transition: background 0.15s ease;
}

.tool-btn:hover {
  background: rgba(255,255,255,0.12);
}

.tool-btn img {
  width: 30px;
  image-rendering: pixelated;
  pointer-events: none;
}

.planet {
  position: fixed;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-decoration: none;
  z-index: 10;
  animation: float 5s ease-in-out infinite;
  transition: transform 0.2s ease;
}

.zoomable:hover { transform: scale(1.15) !important; }

.zoomable {
  z-index: 20;
}

.planet img { display: block; }

.planet-label {
  color: rgba(180,220,120,0.8);
  font-size: 0.55rem;
  letter-spacing: 0.15em;
  margin-top: 8px;
  opacity: 0.7;
  text-align: center;
  font-family: 'Cinzel', serif;
}

.planet:hover .planet-label {
  opacity: 1;
  color: #aaddaa;
}

@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50%       { transform: translateY(-15px); }
}

.mirrored img { transform: scaleX(-1); }

.page-transition {
  position: fixed;
  inset: 0;
  background: #0a1a0a;
  z-index: 999;
  animation: fadein 0.6s ease 0.1s forwards;
  pointer-events: none;
  opacity: 1;
}

@keyframes fadein {
  from { opacity: 1; }
  to   { opacity: 0; }
}

@keyframes fadeout {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.centered {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  animation: float-center 5s ease-in-out infinite;
}

@keyframes float-center {
  0%, 100% { transform: translate(-50%, -50%) translateY(0px); }
  50%       { transform: translate(-50%, -50%) translateY(-15px); }
}