:root {
  --bg-dark: #10252e;
  --mint-wall: #2bb698;
  --pink-primary: #ff4f93;
  --pink-soft: #ff85b3;
  --pink-pastel: #ffd6e7;
  --purple-magic: #8b5cf6;
  --gold-star: #fbbf24;
  --turquoise: #06b6d4;
  --green-budgie: #84cc16;
  --glass-bg: rgba(18, 33, 46, 0.78);
  --glass-light: rgba(255, 255, 255, 0.92);
  --glass-border: rgba(255, 255, 255, 0.28);
  --shadow-lg: 0 14px 35px rgba(0, 0, 0, 0.35);
  --radius-xl: 22px;
  --radius-lg: 16px;
  --radius-md: 12px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  user-select: none;
  -webkit-user-select: none;
  -webkit-touch-callout: none;
  -webkit-tap-highlight-color: transparent;
}

html, body {
  width: 100%;
  height: 100%;
  overflow: hidden;
  font-family: 'Nunito', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: radial-gradient(circle at center, #1e3c48 0%, #0f1f26 100%);
  color: #ffffff;
}

/* ==================== LOGIN & LOBBY SCREEN ==================== */
.screen-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: linear-gradient(135deg, rgba(20, 62, 70, 0.94) 0%, rgba(88, 28, 135, 0.92) 50%, rgba(219, 39, 119, 0.92) 100%);
  backdrop-filter: blur(14px);
  overflow-y: auto;
}

.screen-overlay.hidden {
  display: none !important;
}

.welcome-card {
  width: 100%;
  max-width: 880px;
  background: rgba(255, 255, 255, 0.96);
  color: #1f2937;
  border-radius: 28px;
  padding: 24px 28px;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.45), 0 0 0 4px rgba(255, 133, 179, 0.5);
  text-align: center;
  animation: popIn 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  max-height: 95vh;
  overflow-y: auto;
}

@keyframes popIn {
  from { transform: scale(0.92); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

.welcome-header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}

.welcome-app-icon {
  width: 72px;
  height: 72px;
  border-radius: 18px;
  box-shadow: 0 8px 20px rgba(255, 79, 147, 0.35);
  border: 3px solid #ff4f93;
  object-fit: cover;
}

.welcome-title h1 {
  font-size: 1.75rem;
  font-weight: 900;
  background: linear-gradient(90deg, #ec4899, #8b5cf6, #06b6d4);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  line-height: 1.2;
}

.welcome-title p {
  font-size: 0.95rem;
  color: #4b5563;
  font-weight: 600;
}

.hero-birds-strip {
  display: flex;
  justify-content: center;
  gap: 18px;
  margin: 14px 0 18px;
  flex-wrap: wrap;
}

.hero-bird-pill {
  display: flex;
  align-items: center;
  gap: 10px;
  background: linear-gradient(135deg, #fdf2f8, #f3e8ff);
  border: 2px solid #fbcfe8;
  padding: 8px 16px 8px 8px;
  border-radius: 999px;
  box-shadow: 0 4px 12px rgba(236, 72, 153, 0.12);
}

.hero-bird-pill img {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid #ff4f93;
}

.hero-bird-pill strong {
  display: block;
  font-size: 1rem;
  color: #be185d;
}

.hero-bird-pill span {
  font-size: 0.78rem;
  color: #6b7280;
}

.login-columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  margin-top: 12px;
}

@media (max-width: 680px) {
  .login-columns {
    grid-template-columns: 1fr;
  }
}

.login-box {
  border-radius: 20px;
  padding: 20px;
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 12px;
}

.login-box.admin-box {
  background: linear-gradient(145deg, #fff1f2 0%, #fce7f3 100%);
  border: 3px solid #f472b6;
  box-shadow: 0 10px 25px rgba(244, 114, 182, 0.2);
}

.login-box.guest-box {
  background: linear-gradient(145deg, #f0fdfa 0%, #e0f2fe 100%);
  border: 3px solid #38bdf8;
  box-shadow: 0 10px 25px rgba(56, 189, 248, 0.18);
}

.login-box h2 {
  font-size: 1.25rem;
  font-weight: 800;
}

.login-box p {
  font-size: 0.88rem;
  color: #4b5563;
}

.input-field {
  width: 100%;
  padding: 12px 16px;
  border-radius: 14px;
  border: 2px solid #93c5fd;
  font-size: 1rem;
  font-weight: 700;
  outline: none;
  text-align: center;
  background: #ffffff;
  color: #111827;
}

.input-field:focus {
  border-color: #ec4899;
  box-shadow: 0 0 0 3px rgba(236, 72, 153, 0.2);
}

.btn-big {
  width: 100%;
  padding: 14px 18px;
  border: none;
  border-radius: 16px;
  font-size: 1.05rem;
  font-weight: 800;
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: #fff;
}

.btn-big:active {
  transform: scale(0.96);
}

.btn-pink {
  background: linear-gradient(135deg, #ff3e88 0%, #d946ef 100%);
  box-shadow: 0 8px 20px rgba(236, 72, 153, 0.4);
}

.btn-blue {
  background: linear-gradient(135deg, #06b6d4 0%, #3b82f6 100%);
  box-shadow: 0 8px 20px rgba(6, 182, 212, 0.35);
}

.btn-green {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  box-shadow: 0 8px 20px rgba(16, 185, 129, 0.35);
}

.pwa-install-strip {
  margin-top: 16px;
  padding: 12px 16px;
  border-radius: 16px;
  background: linear-gradient(90deg, #ede9fe, #fce7f3);
  border: 2px dashed #a855f7;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.pwa-install-strip span {
  font-size: 0.88rem;
  font-weight: 700;
  color: #6b21a8;
}

.btn-pwa {
  padding: 9px 16px;
  border-radius: 12px;
  border: none;
  background: #7c3aed;
  color: #fff;
  font-weight: 800;
  font-size: 0.88rem;
  cursor: pointer;
}

/* ==================== BIRD SELECTION CARDS ==================== */
.select-birds-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin: 16px 0;
}

@media (max-width: 680px) {
  .select-birds-grid {
    grid-template-columns: 1fr;
  }
}

.bird-select-card {
  border-radius: 20px;
  padding: 16px;
  background: #fdf2f8;
  border: 3px solid #e5e7eb;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
}

.bird-select-card.selected {
  border-color: #ff3e88;
  background: linear-gradient(180deg, #fff1f2 0%, #fce7f3 100%);
  box-shadow: 0 10px 24px rgba(255, 62, 136, 0.22);
  transform: translateY(-3px);
}

.bird-select-card img {
  width: 90px;
  height: 90px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid #ff4f93;
  margin-bottom: 8px;
}

.bird-select-card h3 {
  font-size: 1.2rem;
  color: #be185d;
}

.bird-select-card .badge-sub {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 99px;
  background: #fbcfe8;
  color: #9d174d;
  font-size: 0.75rem;
  font-weight: 800;
  margin: 4px 0 6px;
}

.bird-select-card p {
  font-size: 0.8rem;
  color: #4b5563;
  line-height: 1.35;
}

.select-check-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #e5e7eb;
  color: #fff;
  font-weight: 900;
  display: flex;
  align-items: center;
  justify-content: center;
}

.bird-select-card.selected .select-check-badge {
  background: #10b981;
}

/* ==================== MAIN GAME LAYOUT ==================== */
#game-app {
  position: relative;
  width: 100vw;
  height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
}

/* SCENE STAGE */
#scene-stage {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
  transition: background-image 0.5s ease, filter 0.5s ease;
  z-index: 1;
}

#scene-stage.scene-room {
  background-image: url('/assets/scenes/ceylin_room.jpg');
}

#scene-stage.scene-bathroom {
  background-image: url('/assets/scenes/bird_bathroom.jpg');
}

#scene-stage.scene-school {
  background-image: url('/assets/scenes/bird_school.jpg');
}

#scene-stage.scene-wonderland {
  background-image: url('/assets/scenes/wonderland_park.jpg');
}

/* Night & Disco lighting overlays */
#lighting-overlay {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 2;
  transition: background 0.6s ease;
}

#lighting-overlay.mode-night {
  background: radial-gradient(circle at 82% 45%, rgba(139, 92, 246, 0.28) 0%, rgba(10, 18, 42, 0.68) 70%);
}

#lighting-overlay.mode-disco {
  animation: discoPulse 2s infinite alternate;
}

@keyframes discoPulse {
  0% { background: rgba(236, 72, 153, 0.22); }
  50% { background: rgba(6, 182, 212, 0.22); }
  100% { background: rgba(168, 85, 247, 0.25); }
}

/* Astronaut Star Projector & Fairy Lights Effect */
.star-field {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 3;
  opacity: 0;
  transition: opacity 0.6s ease;
  background-image:
    radial-gradient(2px 2px at 15% 20%, #fff, transparent),
    radial-gradient(3px 3px at 35% 12%, #fde047, transparent),
    radial-gradient(2px 2px at 55% 18%, #f472b6, transparent),
    radial-gradient(3px 3px at 75% 15%, #38bdf8, transparent),
    radial-gradient(2px 2px at 88% 25%, #fff, transparent),
    radial-gradient(3px 3px at 25% 32%, #a78bfa, transparent),
    radial-gradient(2px 2px at 65% 28%, #fde047, transparent);
}

#lighting-overlay.mode-night + .star-field,
#lighting-overlay.mode-disco + .star-field {
  opacity: 0.95;
  animation: twinkleStars 3s infinite alternate;
}

@keyframes twinkleStars {
  0% { transform: scale(1); opacity: 0.7; }
  100% { transform: scale(1.03); opacity: 1; }
}

/* ==================== TOP HUD BAR ==================== */
.top-hud {
  position: relative;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 8px 14px;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.85) 0%, rgba(15, 23, 42, 0.35) 100%);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.18);
  flex-wrap: wrap;
}

.hud-left, .hud-center, .hud-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.player-pill {
  display: flex;
  align-items: center;
  gap: 7px;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.3);
  padding: 5px 12px;
  border-radius: 999px;
  font-weight: 800;
  font-size: 0.86rem;
}

.xp-pill {
  display: flex;
  align-items: center;
  gap: 6px;
  background: linear-gradient(135deg, #f59e0b, #ec4899);
  padding: 5px 13px;
  border-radius: 999px;
  font-weight: 900;
  font-size: 0.86rem;
  box-shadow: 0 4px 12px rgba(236, 72, 153, 0.35);
}

.scene-nav-btn {
  border: 1px solid rgba(255, 255, 255, 0.28);
  background: rgba(15, 23, 42, 0.65);
  color: #fff;
  padding: 6px 12px;
  border-radius: 12px;
  font-weight: 800;
  font-size: 0.82rem;
  cursor: pointer;
  transition: all 0.15s ease;
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.scene-nav-btn.active {
  background: linear-gradient(135deg, #ff4f93, #8b5cf6);
  border-color: #fbcfe8;
  box-shadow: 0 4px 14px rgba(255, 79, 147, 0.45);
  transform: translateY(-1px);
}

.hud-btn {
  border: 1px solid rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
  padding: 6px 11px;
  border-radius: 12px;
  font-weight: 800;
  font-size: 0.8rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.hud-btn:active, .scene-nav-btn:active {
  transform: scale(0.95);
}

.hud-btn.admin-only {
  background: linear-gradient(135deg, #be185d, #7c3aed);
  border-color: #f9a8d4;
}

/* ==================== ROOM HOTSPOTS ==================== */
#room-hotspots {
  position: absolute;
  inset: 60px 0 115px 0;
  z-index: 6;
  pointer-events: none;
}

.hotspot-pin {
  position: absolute;
  transform: translate(-50%, -50%);
  pointer-events: auto;
  background: rgba(15, 23, 42, 0.72);
  border: 2px solid rgba(255, 255, 255, 0.65);
  color: #fff;
  padding: 5px 11px;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35);
  transition: transform 0.18s ease, background 0.18s ease;
  white-space: nowrap;
  backdrop-filter: blur(4px);
}

.hotspot-pin:hover, .hotspot-pin:active {
  transform: translate(-50%, -50%) scale(1.1);
  background: #ff4f93;
  border-color: #fff;
}

/* ==================== INTERACTIVE BIRDS ON STAGE ==================== */
#birds-layer {
  position: absolute;
  inset: 0;
  z-index: 10;
  pointer-events: none;
}

.bird-actor {
  position: absolute;
  transform: translate(-50%, -50%);
  pointer-events: auto;
  cursor: pointer;
  transition: left 1.1s cubic-bezier(0.22, 1, 0.36, 1), top 1.1s cubic-bezier(0.22, 1, 0.36, 1);
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 150px;
}

/* Speech bubble above bird */
.bird-speech-bubble {
  background: rgba(255, 255, 255, 0.96);
  color: #1f2937;
  border: 2px solid #ff4f93;
  border-radius: 16px;
  padding: 6px 11px;
  font-size: 0.78rem;
  font-weight: 800;
  text-align: center;
  min-width: 145px;
  max-width: 215px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.25);
  margin-bottom: 6px;
  position: relative;
  line-height: 1.28;
  animation: bubbleFloat 2.4s ease-in-out infinite alternate;
}

.bird-speech-bubble::after {
  content: '';
  position: absolute;
  bottom: -8px;
  left: 50%;
  transform: translateX(-50%);
  border-width: 8px 7px 0;
  border-style: solid;
  border-color: #ff4f93 transparent transparent;
}

@keyframes bubbleFloat {
  0% { transform: translateY(0px); }
  100% { transform: translateY(-4px); }
}

/* Bird Avatar Container */
.bird-body-wrap {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.3s ease;
}

/* Life stage sizing */
.bird-actor.stage-baby .bird-body-wrap {
  transform: scale(0.76);
}
.bird-actor.stage-child .bird-body-wrap {
  transform: scale(0.92);
}
.bird-actor.stage-student .bird-body-wrap {
  transform: scale(1.02);
}
.bird-actor.stage-adult .bird-body-wrap {
  transform: scale(1.12);
}

/* Bird Animations by Activity */
.bird-actor.act-idle .bird-svg-group {
  animation: birdBreathe 2.2s ease-in-out infinite alternate;
}
.bird-actor.act-swinging .bird-svg-group {
  animation: birdSwing 1.6s ease-in-out infinite alternate;
  transform-origin: top center;
}
.bird-actor.act-dancing .bird-svg-group,
.bird-actor.act-playing_piano .bird-svg-group {
  animation: birdDance 0.55s ease-in-out infinite alternate;
}
.bird-actor.act-eating .bird-svg-group,
.bird-actor.act-drinking .bird-svg-group {
  animation: birdPeck 0.45s ease-in-out infinite alternate;
}
.bird-actor.act-bathing .bird-svg-group {
  animation: birdShake 0.35s ease-in-out infinite alternate;
}
.bird-actor.act-sleeping .bird-svg-group {
  filter: brightness(0.88);
  transform: rotate(-6deg);
}

@keyframes birdBreathe {
  0% { transform: translateY(0px) scale(1); }
  100% { transform: translateY(-5px) scale(1.03); }
}
@keyframes birdSwing {
  0% { transform: rotate(-11deg) translateX(-6px); }
  100% { transform: rotate(11deg) translateX(6px); }
}
@keyframes birdDance {
  0% { transform: translateY(0) rotate(-8deg) scale(1.04); }
  100% { transform: translateY(-12px) rotate(8deg) scale(1.08); }
}
@keyframes birdPeck {
  0% { transform: rotate(0deg) translateY(0); }
  100% { transform: rotate(16deg) translateY(6px); }
}
@keyframes birdShake {
  0% { transform: translateX(-4px) rotate(-5deg); }
  100% { transform: translateX(4px) rotate(5deg); }
}

.bird-photo-badge {
  position: absolute;
  bottom: -4px;
  right: -8px;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid #fff;
  box-shadow: 0 3px 10px rgba(0,0,0,0.4);
  z-index: 4;
}

.bird-actor.photo-mode .bird-photo-main {
  display: block;
  width: 96px;
  height: 96px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid #fff;
  box-shadow: 0 8px 22px rgba(0,0,0,0.45);
}

.bird-actor:not(.photo-mode) .bird-photo-main {
  display: none;
}

.bird-actor.photo-mode .bird-rig-svg {
  display: none;
}

.bird-name-plate {
  margin-top: 4px;
  background: rgba(15, 23, 42, 0.84);
  border: 1px solid rgba(255, 255, 255, 0.35);
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 800;
  color: #fff;
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 5px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

.bird-mini-bars {
  display: flex;
  gap: 3px;
  margin-top: 3px;
}

.mini-stat-dot {
  width: 22px;
  height: 5px;
  border-radius: 99px;
  background: rgba(255,255,255,0.25);
  overflow: hidden;
}

.mini-stat-fill {
  height: 100%;
  border-radius: 99px;
}

/* ==================== LEFT BIRD STATUS PANEL ==================== */
.side-status-panel {
  position: absolute;
  left: 12px;
  top: 62px;
  z-index: 15;
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-width: 245px;
}

.bird-status-card {
  background: rgba(15, 23, 42, 0.78);
  backdrop-filter: blur(8px);
  border: 1.5px solid rgba(255, 255, 255, 0.24);
  border-radius: 16px;
  padding: 8px 10px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.bird-status-card.focused {
  border-color: #ff4f93;
  box-shadow: 0 0 0 2px rgba(255, 79, 147, 0.45);
  background: rgba(30, 20, 48, 0.86);
}

.bsc-top {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 5px;
}

.bsc-top img {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid #ff4f93;
}

.bsc-info h4 {
  font-size: 0.85rem;
  font-weight: 900;
  line-height: 1.1;
}

.bsc-info span {
  font-size: 0.7rem;
  color: #fbcfe8;
  font-weight: 700;
}

.bsc-bars {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px 8px;
  font-size: 0.68rem;
}

.stat-row {
  display: flex;
  align-items: center;
  gap: 4px;
}

.stat-bar-bg {
  flex: 1;
  height: 6px;
  background: rgba(255, 255, 255, 0.18);
  border-radius: 99px;
  overflow: hidden;
}

.stat-bar-val {
  height: 100%;
  border-radius: 99px;
  transition: width 0.3s ease;
}

/* ==================== BOTTOM DOCK & PUSH-TO-TALK MIC ==================== */
.bottom-dock {
  position: relative;
  z-index: 20;
  padding: 8px 14px 10px;
  background: linear-gradient(0deg, rgba(15, 23, 42, 0.92) 0%, rgba(15, 23, 42, 0.65) 85%, transparent 100%);
  backdrop-filter: blur(8px);
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.voice-quick-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  overflow-x: auto;
  padding-bottom: 2px;
  scrollbar-width: none;
}

.voice-quick-row::-webkit-scrollbar {
  display: none;
}

.quick-cmd-chip {
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: #fff;
  padding: 5px 11px;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 800;
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.15s;
}

.quick-cmd-chip:active, .quick-cmd-chip:hover {
  background: #ff4f93;
  border-color: #fff;
  transform: scale(0.96);
}

.dock-controls-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.care-buttons-group {
  display: flex;
  align-items: center;
  gap: 7px;
  flex-wrap: wrap;
}

.care-btn {
  border: 1.5px solid rgba(255, 255, 255, 0.32);
  background: rgba(30, 41, 59, 0.85);
  color: #fff;
  padding: 8px 12px;
  border-radius: 14px;
  font-size: 0.82rem;
  font-weight: 800;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.25);
  transition: transform 0.12s, background 0.15s;
}

.care-btn:active {
  transform: scale(0.93);
}

.care-btn.highlight-pink {
  background: linear-gradient(135deg, #ec4899, #8b5cf6);
  border-color: #fbcfe8;
}

/* PUSH TO TALK MIC BUTTON */
.ptt-mic-container {
  display: flex;
  align-items: center;
  gap: 8px;
}

.ptt-mic-btn {
  background: linear-gradient(135deg, #ff2e7e 0%, #9333ea 100%);
  border: 3px solid #fbcfe8;
  color: #fff;
  padding: 10px 20px;
  border-radius: 999px;
  font-size: 0.95rem;
  font-weight: 900;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 8px 24px rgba(255, 46, 126, 0.5);
  transition: all 0.2s ease;
}

.ptt-mic-btn.listening {
  background: linear-gradient(135deg, #ef4444 0%, #f59e0b 100%);
  transform: scale(1.06);
  animation: micPulse 0.9s infinite alternate;
}

@keyframes micPulse {
  from { box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.7); }
  to { box-shadow: 0 0 0 14px rgba(239, 68, 68, 0); }
}

.voice-text-input-wrap {
  display: flex;
  align-items: center;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 999px;
  padding: 3px 5px 3px 12px;
}

.voice-text-input-wrap input {
  background: transparent;
  border: none;
  color: #fff;
  font-size: 0.82rem;
  font-weight: 700;
  outline: none;
  width: 165px;
}

.voice-text-input-wrap input::placeholder {
  color: rgba(255, 255, 255, 0.68);
}

.voice-send-btn {
  background: #ff4f93;
  border: none;
  color: #fff;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  font-weight: 900;
  cursor: pointer;
}

/* ==================== MODALS & DRAWERS ==================== */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 500;
  background: rgba(10, 15, 28, 0.72);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.modal-backdrop.hidden {
  display: none !important;
}

.modal-card {
  width: 100%;
  max-width: 780px;
  max-height: 88vh;
  background: #ffffff;
  color: #1f2937;
  border-radius: 26px;
  border: 4px solid #ff85b3;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.5);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: popIn 0.25s ease;
}

.modal-header {
  padding: 14px 20px;
  background: linear-gradient(90deg, #ff4f93, #8b5cf6);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.modal-header h3 {
  font-size: 1.2rem;
  font-weight: 900;
}

.modal-close-btn {
  background: rgba(255, 255, 255, 0.25);
  border: none;
  color: #fff;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  font-size: 1.1rem;
  font-weight: 900;
  cursor: pointer;
}

.modal-body {
  padding: 18px 20px;
  overflow-y: auto;
  flex: 1;
}

/* SHOP GRID */
.shop-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(165px, 1fr));
  gap: 12px;
}

.shop-item-card {
  border: 2px solid #f3e8ff;
  background: #fdf4ff;
  border-radius: 18px;
  padding: 12px;
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 8px;
}

.shop-item-card.owned {
  border-color: #10b981;
  background: #ecfdf5;
}

.shop-item-card .shop-icon {
  font-size: 2.2rem;
}

.shop-item-card h4 {
  font-size: 0.88rem;
  color: #1f2937;
}

.shop-btn {
  padding: 8px 12px;
  border-radius: 12px;
  border: none;
  font-weight: 800;
  font-size: 0.82rem;
  cursor: pointer;
  color: #fff;
  background: linear-gradient(135deg, #ec4899, #8b5cf6);
}

.shop-btn.equipped {
  background: #059669;
}

/* PIANO KEYBOARD OVERLAY */
.piano-Popup {
  position: absolute;
  bottom: 118px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 30;
  background: linear-gradient(180deg, #ff7eb3 0%, #ff4f93 100%);
  border: 4px solid #fff;
  border-radius: 24px;
  padding: 14px 18px 18px;
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.45);
  text-align: center;
}

.piano-Popup.hidden {
  display: none !important;
}

.piano-top-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 10px;
  color: #fff;
  font-weight: 900;
}

.piano-keys-row {
  display: flex;
  gap: 6px;
}

.piano-key {
  width: 52px;
  height: 120px;
  background: linear-gradient(180deg, #ffffff 0%, #f3f4f6 100%);
  border: 2px solid #fbcfe8;
  border-bottom: 6px solid #d1d5db;
  border-radius: 0 0 12px 12px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: center;
  padding-bottom: 10px;
  font-weight: 900;
  color: #db2777;
  cursor: pointer;
  transition: transform 0.08s;
}

.piano-key:active, .piano-key.playing {
  transform: translateY(4px);
  background: #fce7f3;
  border-bottom-width: 2px;
}

/* DOORBELL JOIN APPROVAL POPUP FOR CEYLİN MİA */
#doorbell-toast {
  position: fixed;
  top: 70px;
  right: 20px;
  z-index: 900;
  background: #ffffff;
  color: #111827;
  border: 4px solid #f59e0b;
  border-radius: 22px;
  padding: 16px 20px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.45);
  max-width: 360px;
  animation: popIn 0.3s ease;
}

#doorbell-toast.hidden {
  display: none !important;
}

.doorbell-actions {
  display: flex;
  gap: 10px;
  margin-top: 12px;
}

/* FLOATING PARTICLES (HEARTS, NOTES, BUBBLES, XP) */
.floating-fx {
  position: fixed;
  pointer-events: none;
  z-index: 800;
  font-size: 1.7rem;
  font-weight: 900;
  animation: floatUpFade 1.4s ease-out forwards;
}

@keyframes floatUpFade {
  0% { transform: translateY(0) scale(0.8); opacity: 1; }
  100% { transform: translateY(-95px) scale(1.35); opacity: 0; }
}

/* ALBUM PHOTO GALLERY */
.photo-gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(175px, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}

.real-photo-card {
  border-radius: 16px;
  overflow: hidden;
  border: 3px solid #fbcfe8;
  background: #fdf2f8;
  text-align: center;
}

.real-photo-card img {
  width: 100%;
  height: 140px;
  object-fit: cover;
}

.real-photo-card span {
  display: block;
  padding: 6px;
  font-size: 0.8rem;
  font-weight: 800;
  color: #9d174d;
}
