* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  user-select: none;
  -webkit-user-select: none;
}

body, html {
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #0a0f1d;
  font-family: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
  color: #f1f5f9;
}

#builder-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: block;
  cursor: crosshair;
  z-index: 1;
}

/* Minimal Top HUD - Borderless Frosted Glass */
.top-bar {
  position: absolute;
  top: 16px;
  left: 20px;
  right: 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 10;
  pointer-events: none;
}

.brand-pill {
  display: flex;
  align-items: center;
  gap: 10px;
  pointer-events: auto;
  background: rgba(20, 32, 35, 0.65);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: none !important;
  padding: 4px 6px 4px 18px;
  border-radius: 999px;
  box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.25);
}

/* Customize button: tiny 3D dino next to the logo */
.brand-dino-btn {
  position: relative;
  width: 46px;
  height: 46px;
  padding: 0;
  border: none !important;
  border-radius: 50%;
  cursor: pointer;
  background: radial-gradient(circle at 50% 65%, rgba(56, 189, 248, 0.35), rgba(15, 23, 42, 0.6));
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.2s;
}

.brand-dino-btn:hover {
  transform: scale(1.12);
  box-shadow: 0 0 16px rgba(56, 189, 248, 0.5);
}

.brand-dino-btn canvas {
  width: 46px;
  height: 46px;
  display: block;
}

.brand-dino-btn .key-badge {
  position: absolute;
  right: -4px;
  bottom: -2px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.55rem;
  color: #fff;
  background: rgba(0, 0, 0, 0.6);
  padding: 1px 5px;
  border-radius: 6px;
}

/* Build Kit button, bottom right */
.kit-btn {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 25;
  min-width: 72px;
  font-size: 0.75rem;
}

.kit-btn .kit-icon {
  font-size: 1.4rem;
}

.brand-title {
  font-weight: 800;
  font-size: 0.95rem;
  letter-spacing: -0.01em;
  background: linear-gradient(135deg, #38bdf8, #818cf8, #c084fc);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.status-cluster {
  display: flex;
  align-items: center;
  gap: 12px;
  pointer-events: auto;
  background: rgba(20, 32, 35, 0.65);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: none !important;
  padding: 8px 18px;
  border-radius: 999px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.8rem;
  color: #cbd5e1;
  box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.25);
}

.status-badge b {
  color: #38bdf8;
}

/* LEFT VERTICAL DOCK - BORDERLESS FROSTED GLASS */
.left-dock-container {
  position: fixed;
  left: 18px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 6px;
  z-index: 20;
}

.left-dock {
  display: flex;
  flex-direction: column;
  gap: 8px;
  /* No shared panel: each button floats on its own glass */
  background: none;
  border: none !important;
  padding: 0;
  transition: all 0.28s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Collapsed: only the toggle and the active tool. display:none (not max-height: 0)
   so hidden buttons don't leave their flex gaps behind as empty space. */
.left-dock.collapsed .dock-btn:not(.active):not(#dock-toggle),
.left-dock.collapsed .dock-divider {
  display: none;
}

.dock-btn {
  position: relative;
  width: 48px;
  height: 48px;
  max-height: 48px;
  background: rgba(20, 32, 35, 0.68);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
  border: none !important;
  color: #cbd5e1;
  border-radius: 12px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  transform: scale(1) translateY(0);
  opacity: 1;
}

.dock-btn:hover {
  background: rgba(255, 255, 255, 0.14);
  color: #ffffff;
  transform: scale(1.06);
}

.dock-btn.active {
  background: linear-gradient(135deg, rgba(2, 132, 199, 0.85), rgba(37, 99, 235, 0.85));
  box-shadow: 0 0 12px rgba(66, 211, 252, 0.4);
  outline: 2px solid #38bdf8;
  color: #ffffff;
}

.dock-btn.destroy-btn.active {
  background: linear-gradient(135deg, rgba(220, 38, 38, 0.85), rgba(185, 28, 28, 0.85));
  box-shadow: 0 0 12px rgba(248, 113, 113, 0.4);
  outline: 2px solid #f87171;
}

.dock-btn.select-btn.active {
  background: linear-gradient(135deg, rgba(13, 148, 136, 0.85), rgba(5, 150, 105, 0.85));
  box-shadow: 0 0 12px rgba(52, 211, 153, 0.4);
  outline: 2px solid #34d399;
}

.dock-icon {
  font-size: 1.2rem;
  line-height: 1;
}

.dock-shortcut {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.6rem;
  background: rgba(0, 0, 0, 0.35);
  padding: 1px 4px;
  border-radius: 4px;
  color: #94a3b8;
  line-height: 1;
}

.dock-btn.active .dock-shortcut {
  background: rgba(255, 255, 255, 0.25);
  color: #ffffff;
}

.dock-tooltip {
  position: absolute;
  left: calc(100% + 10px);
  top: 50%;
  transform: translateY(-50%) translateX(-4px);
  background: rgba(20, 32, 35, 0.95);
  backdrop-filter: blur(16px);
  border: none !important;
  border-radius: 10px;
  padding: 6px 10px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transition: all 0.18s cubic-bezier(0.16, 1, 0.3, 1);
  white-space: nowrap;
  z-index: 50;
  text-align: left;
}

.dock-btn:hover .dock-tooltip {
  opacity: 1;
  visibility: visible;
  transform: translateY(-50%) translateX(0);
}

.tooltip-title {
  font-weight: 700;
  font-size: 0.78rem;
  color: #f8fafc;
}

.tooltip-desc {
  font-size: 0.68rem;
  color: #94a3b8;
  margin-top: 1px;
}

.dock-divider {
  height: 1px;
  background: rgba(255, 255, 255, 0.08);
  margin: 2px 4px;
}

/* RIGHT BUTTON CLUSTER (BORDERLESS FROSTED GLASS) */
.right-cluster {
  position: fixed;
  right: 18px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 25;
}

.action-badge-btn {
  background: rgba(20, 32, 35, 0.65);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: none !important;
  border-radius: 14px;
  box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.25);
  color: #ffffff;
  font-weight: 700;
  font-size: 0.68rem;
  padding: 8px 10px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  min-width: 54px;
}

.action-badge-btn:hover {
  background: rgba(255, 255, 255, 0.14);
  transform: scale(1.06);
  box-shadow: 0 0 16px rgba(56, 189, 248, 0.35);
}

.action-badge-btn .key-badge {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.55rem;
  background: rgba(0, 0, 0, 0.35);
  padding: 1px 5px;
  border-radius: 4px;
  color: #cbd5e1;
}

/* BOTTOM PALETTE ROW - BORDERLESS FROSTED GLASS */
.bottom-deck {
  position: absolute;
  bottom: 18px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(20, 32, 35, 0.65);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: none !important;
  padding: 8px 14px;
  border-radius: 999px;
  box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.25);
  z-index: 20;
}

.palette-item {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.06);
  border: none !important;
  cursor: pointer;
  font-size: 1.25rem;
  transition: all 0.18s ease;
}

.palette-item:hover {
  background: rgba(255, 255, 255, 0.14);
  transform: translateY(-2px) scale(1.04);
}

.palette-item.active {
  background: rgba(56, 189, 248, 0.25);
  box-shadow: 0 0 12px rgba(66, 211, 252, 0.4);
  outline: 2px solid #38bdf8;
}

.palette-num {
  position: absolute;
  bottom: 2px;
  right: 3px;
  font-size: 0.58rem;
  font-family: 'JetBrains Mono', monospace;
  font-weight: 700;
  color: #94a3b8;
}

/* RIGHT SLIDE-OUT DRAWER - BORDERLESS MODERN FROSTED GLASS */
.drawer-overlay {
  position: fixed;
  top: 0;
  right: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(10, 15, 29, 0.35);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  z-index: 90;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.drawer-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.right-drawer {
  position: fixed;
  top: 18px;
  right: 18px;
  bottom: 18px;
  width: 330px;
  max-width: calc(100vw - 36px);
  background: rgba(20, 32, 35, 0.75);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: none !important;
  border-radius: 20px;
  box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.35);
  z-index: 100;
  transform: translateX(calc(100% + 40px));
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.right-drawer.open {
  transform: translateX(0);
}

.drawer-header {
  padding: 16px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.drawer-header-left {
  display: flex;
  align-items: center;
  gap: 8px;
}

.drawer-title {
  font-size: 1.05rem;
  font-weight: 800;
  color: #f8fafc;
}

.drawer-key-badge {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.62rem;
  background: rgba(255, 255, 255, 0.08);
  padding: 2px 6px;
  border-radius: 6px;
  color: #38bdf8;
  font-weight: 700;
}

.drawer-tools-row {
  display: flex;
  align-items: center;
  gap: 6px;
}

.drawer-btn-tool {
  background: rgba(255, 255, 255, 0.08);
  border: none !important;
  color: #cbd5e1;
  font-size: 0.78rem;
  font-weight: 700;
  padding: 6px 9px;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 3px;
  transition: all 0.15s ease;
}

.drawer-btn-tool:hover {
  background: rgba(255, 255, 255, 0.16);
  color: #ffffff;
}

.drawer-close-btn {
  background: rgba(255, 255, 255, 0.08);
  border: none !important;
  color: #94a3b8;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  transition: all 0.15s ease;
}

.drawer-close-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  color: #ffffff;
}

.drawer-body {
  padding: 14px 16px;
  overflow-y: auto;
  flex: 1;
}

.selected-showcase {
  background: rgba(255, 255, 255, 0.06);
  border: none !important;
  border-radius: 14px;
  padding: 10px 14px;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.showcase-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.showcase-icon {
  font-size: 1.6rem;
}

.showcase-title {
  font-weight: 800;
  font-size: 0.85rem;
  color: #ffffff;
}

.showcase-badge {
  font-size: 0.65rem;
  font-family: 'JetBrains Mono', monospace;
  color: #38bdf8;
  margin-top: 1px;
}

.showcase-rotate-btn {
  background: rgba(255, 255, 255, 0.08);
  border: none !important;
  color: #ffffff;
  font-size: 0.82rem;
  font-weight: 700;
  padding: 6px 9px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.showcase-rotate-btn:hover {
  background: rgba(56, 189, 248, 0.25);
  color: #38bdf8;
}

.category-tabs {
  display: flex;
  gap: 5px;
  margin-bottom: 14px;
  overflow-x: auto;
  padding-bottom: 2px;
}

.cat-filter-btn {
  background: rgba(255, 255, 255, 0.06);
  border: none !important;
  color: #94a3b8;
  font-weight: 600;
  font-size: 0.72rem;
  padding: 5px 10px;
  border-radius: 999px;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.15s ease;
}

.cat-filter-btn.active, .cat-filter-btn:hover {
  background: rgba(56, 189, 248, 0.25);
  color: #38bdf8;
}

/* 3-ITEMS CIRCULAR PEDESTAL GRID (NO OUTLINES, NO SELECT BUTTONS) */
.library-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px 8px;
  padding: 6px 0;
}

.blueprint-disc-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  background: transparent;
  border: none !important;
  position: relative;
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.blueprint-disc-card:hover {
  transform: scale(1.08);
}

.bp-pedestal {
  width: 74px;
  height: 74px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  border: none !important;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  transition: all 0.2s ease;
  overflow: hidden;
}

.blueprint-disc-card:hover .bp-pedestal {
  background: rgba(255, 255, 255, 0.12);
  box-shadow: 0 0 16px rgba(56, 189, 248, 0.3);
}

.blueprint-disc-card.selected .bp-pedestal {
  background: rgba(56, 189, 248, 0.2);
  box-shadow: 0 0 14px rgba(66, 211, 252, 0.4);
  outline: 2px solid #38bdf8;
  outline-offset: 1px;
}

.bp-3d-canvas {
  width: 68px;
  height: 68px;
  display: block;
}

.bp-disc-name {
  font-size: 0.68rem;
  font-weight: 700;
  color: #cbd5e1;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 82px;
}

.btn-delete-sq {
  position: absolute;
  top: -2px;
  right: 4px;
  background: rgba(239, 68, 68, 0.7);
  border: none !important;
  color: #ffffff;
  font-size: 0.58rem;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 5;
}

/* MODAL OVERLAY - CLEAN FROSTED BACKDROP WITH SMOOTH ANIMATION */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(10, 15, 29, 0.45);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  z-index: 120;
  display: none;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-overlay.open {
  display: flex;
  opacity: 1;
}

.modal-overlay .customizer-card,
.modal-overlay .animals-showcase-card,
.modal-overlay .modal-card {
  transform: scale(0.92) translateY(12px);
  opacity: 0;
  transition: transform 0.32s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.28s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-overlay.open .customizer-card,
.modal-overlay.open .animals-showcase-card,
.modal-overlay.open .modal-card {
  transform: scale(1) translateY(0);
  opacity: 1;
}

/* ==========================================================================
   2. PLAYER CUSTOMIZER MODAL (C KEY) – 2-COLUMN SPLIT LAYOUT
   ========================================================================== */
.customizer-card {
  background: rgba(20, 32, 35, 0.75);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: none !important;
  border-radius: 24px;
  box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.35);
  width: 580px;
  max-width: 94vw;
  display: flex;
  flex-direction: row;
  align-items: stretch;
  overflow: hidden;
}

/* Left Column: 3D Stage & Sizing (~50%) */
.customizer-stage-col {
  width: 50%;
  padding: 22px 18px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  position: relative;
  background: rgba(0, 0, 0, 0.12);
}

.stage-back-btn {
  position: absolute;
  top: 16px;
  left: 16px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  border: none !important;
  color: #f1f5f9;
  font-size: 1.15rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
  z-index: 10;
}

.stage-back-btn:hover {
  background: rgba(255, 255, 255, 0.18);
  transform: scale(1.08);
}

.stage-canvas-wrap {
  position: relative;
  width: 100%;
  height: 210px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 12px;
}

#dino-preview-canvas {
  width: 100%;
  height: 100%;
  display: block;
  position: relative;
  z-index: 2;
}

.stage-spotlight-floor {
  position: absolute;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  width: 140px;
  height: 34px;
  background: radial-gradient(ellipse at center, rgba(56, 189, 248, 0.22) 0%, rgba(56, 189, 248, 0) 72%);
  border-radius: 50%;
  pointer-events: none;
  z-index: 1;
}

.stage-indicator {
  font-size: 0.72rem;
  font-family: 'JetBrains Mono', monospace;
  color: #94a3b8;
  letter-spacing: 0.08em;
  margin: 4px 0 10px 0;
}

.stage-sizing-row {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 90%;
  margin-bottom: 12px;
}

.stage-sizing-label {
  font-size: 0.76rem;
  font-weight: 700;
  color: #cbd5e1;
}

.minimal-slider {
  flex: 1;
  -webkit-appearance: none;
  appearance: none;
  height: 4px;
  background: rgba(255, 255, 255, 0.15);
  border-radius: 999px;
  outline: none;
  cursor: pointer;
}

.minimal-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #38bdf8;
  box-shadow: 0 0 10px rgba(56, 189, 248, 0.6);
  cursor: pointer;
  border: none;
}

.stage-scale-val {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.76rem;
  font-weight: 800;
  color: #38bdf8;
  min-width: 32px;
  text-align: right;
}

.stage-builder-pill {
  background: rgba(255, 255, 255, 0.08);
  border: none !important;
  border-radius: 999px;
  padding: 5px 16px;
  font-size: 0.72rem;
  font-weight: 800;
  color: #e2e8f0;
  letter-spacing: 0.04em;
}

/* Right Column: Options & Equipment (~50%) */
.customizer-options-col {
  width: 50%;
  padding: 24px 22px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.opt-section {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.opt-section-title {
  font-size: 0.84rem;
  font-weight: 800;
  color: #f1f5f9;
  letter-spacing: 0.02em;
}

.skin-swatches-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.skin-swatch-circle {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--swatch-hex);
  border: none !important;
  cursor: pointer;
  transition: all 0.2s ease;
  margin: 0 auto;
}

.skin-swatch-circle:hover {
  transform: scale(1.12);
}

.skin-swatch-circle.active {
  box-shadow: 0 0 12px rgba(66, 211, 252, 0.6);
  outline: 2px solid #38bdf8;
  outline-offset: 2px;
}

.equipment-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.equipment-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.06);
  border: none !important;
  border-radius: 12px;
  padding: 7px 10px;
  cursor: pointer;
  color: #94a3b8;
  font-weight: 700;
  font-size: 0.76rem;
  transition: all 0.18s ease;
}

.equipment-pill:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
}

.equipment-pill.active {
  background: rgba(255, 255, 255, 0.14);
  color: #ffffff;
  box-shadow: 0 0 12px rgba(66, 211, 252, 0.3);
}

.eq-icon {
  font-size: 1.1rem;
}

.eq-text {
  flex: 1;
  text-align: left;
}

/* ==========================================================================
   3. ANIMAL EXPLORER MODAL (U KEY) – DUAL-ROW SHOWCASE
   ========================================================================== */
.animals-showcase-card {
  background: rgba(20, 32, 35, 0.75);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: none !important;
  border-radius: 24px;
  box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.35);
  width: 520px;
  max-width: 94vw;
  padding: 22px 20px 20px 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
}

.stage-close-btn {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  border: none !important;
  color: #94a3b8;
  font-size: 1.15rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
  z-index: 10;
}

.stage-close-btn:hover {
  background: rgba(255, 255, 255, 0.18);
  color: #ffffff;
}

.animal-showcase-upper {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 16px;
  width: 100%;
}

.animal-showcase-canvas-wrap {
  position: relative;
  width: 260px;
  height: 160px;
  display: flex;
  align-items: center;
  justify-content: center;
}

#animal-showcase-canvas {
  width: 260px;
  height: 160px;
  display: block;
  position: relative;
  z-index: 2;
}

.animal-showcase-info {
  font-size: 0.95rem;
  font-weight: 800;
  color: #f1f5f9;
  letter-spacing: 0.02em;
  margin-top: 4px;
  text-align: center;
}

.animal-dock-lower {
  display: flex;
  align-items: center;
  gap: 8px;
  overflow-x: auto;
  max-width: 100%;
  padding: 6px 4px;
  scrollbar-width: none;
}

.animal-dock-lower::-webkit-scrollbar {
  display: none;
}

.animal-dock-item {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.06);
  border: none !important;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  flex-shrink: 0;
}

.animal-dock-item:hover {
  background: rgba(255, 255, 255, 0.14);
  transform: scale(1.1);
}

.animal-dock-item.active {
  background: rgba(56, 189, 248, 0.22);
  box-shadow: 0 0 12px rgba(66, 211, 252, 0.5);
  outline: 2px solid #38bdf8;
  outline-offset: 1px;
}

/* ==========================================================================
   4. ANIMAL WORLD HOVER SHEET (ON-HOVER 3D ENTITY TAG)
   ========================================================================== */
.animal-hoversheet {
  position: fixed;
  top: 80px;
  left: 20px;
  transform: translateY(-12px);
  pointer-events: none;
  z-index: 95;
  background: rgba(20, 32, 35, 0.75);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: none !important;
  border-radius: 20px;
  box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.25);
  padding: 6px 18px 6px 6px;
  display: flex;
  align-items: center;
  gap: 10px;
  opacity: 0;
  transition: opacity 0.25s ease, transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  font-weight: 700;
  font-size: 0.95rem;
  color: #f1f5f9;
}

.animal-hoversheet.visible {
  opacity: 1;
  transform: translateY(0);
}

/* BOX CAPTURE MODAL - CLEAN FROSTED GLASS */
.modal-card {
  background: rgba(20, 32, 35, 0.75);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: none !important;
  border-radius: 24px;
  box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.35);
  width: 90%;
  max-width: 480px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  padding: 22px 24px;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.modal-header h3 {
  font-size: 1.15rem;
  font-weight: 800;
  color: #f8fafc;
}

.form-group {
  margin-bottom: 14px;
}

.form-label {
  display: block;
  font-size: 0.78rem;
  font-weight: 700;
  color: #cbd5e1;
  margin-bottom: 6px;
}

.form-input, .form-select {
  width: 100%;
  background: rgba(255, 255, 255, 0.08);
  border: none !important;
  border-radius: 12px;
  padding: 10px 14px;
  color: #f8fafc;
  font-family: inherit;
  font-size: 0.88rem;
  outline: none;
}

.form-select option {
  background: #0f172a;
  color: #ffffff;
}

.icon-picker-row {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.icon-choice-btn {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.08);
  border: none !important;
  font-size: 1.2rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
}

.icon-choice-btn:hover {
  background: rgba(255, 255, 255, 0.18);
}

.icon-choice-btn.active {
  background: rgba(56, 189, 248, 0.3);
  outline: 2px solid #38bdf8;
}

.btn-action {
  background: linear-gradient(135deg, #0284c7, #2563eb);
  border: none !important;
  color: #ffffff;
  font-weight: 800;
  font-size: 0.92rem;
  padding: 12px 18px;
  border-radius: 14px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  margin-top: 10px;
  box-shadow: 0 4px 16px rgba(37, 99, 235, 0.35);
  transition: all 0.18s ease;
}

.btn-action:hover {
  box-shadow: 0 0 20px rgba(56, 189, 248, 0.5);
  transform: translateY(-1px);
}

/* TOAST NOTIFICATION - POSITIONED DIRECTLY BELOW TOP-RIGHT STATUS BAR */
.toast-msg {
  position: fixed;
  top: 64px;
  right: 20px;
  background: rgba(20, 32, 35, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: none !important;
  color: #f8fafc;
  font-weight: 700;
  font-size: 0.82rem;
  padding: 9px 18px;
  border-radius: 999px;
  box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.25);
  z-index: 150;
  display: none;
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

/* BOTTOM-LEFT FLOATING ZOOM CLUSTER */
.bottom-left-cluster {
  position: fixed;
  left: 18px;
  bottom: 18px;
  display: flex;
  align-items: center;
  gap: 6px;
  z-index: 20;
  background: rgba(20, 32, 35, 0.65);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: none !important;
  padding: 6px 10px;
  border-radius: 999px;
  box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.25);
}

.zoom-btn {
  background: rgba(255, 255, 255, 0.06);
  border: none !important;
  color: #cbd5e1;
  border-radius: 8px;
  padding: 5px 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 0.78rem;
  font-weight: 700;
  transition: all 0.18s ease;
}

.zoom-btn:hover {
  background: rgba(255, 255, 255, 0.16);
  color: #ffffff;
  transform: scale(1.06);
}

.zoom-key {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.6rem;
  background: rgba(0, 0, 0, 0.35);
  padding: 1px 4px;
  border-radius: 4px;
  color: #94a3b8;
}
