/* =====================================================================
   Vybe Space — Cozy Home Redesign  (Sprint 12 Phase 4B)
   my_space_themes.css  —  replaces previous dashboard-heavy styles
   Mobile-first, dark neon, emotionally alive
   ===================================================================== */

/* ── Page shell ──────────────────────────────────────────────────── */
.cozy-home-page body,
.cozy-home-page { background: radial-gradient(ellipse at 20% 0%, #130827 0%, #06090f 60%, #020304 100%); }

.vs-home {
  max-width: 680px;
  margin: 0 auto;
  padding: 0 0.75rem 5rem;
  position: relative;
}

/* ── Ambient blobs ─────────────────────────────────────────────── */
.vs-home__blobs { pointer-events: none; position: fixed; inset: 0; z-index: 0; overflow: hidden; }

.vs-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.12;
  animation: blobDrift 18s ease-in-out infinite;
}
.vs-blob--1 { width: 380px; height: 380px; background: #8b5cf6; top: -120px; left: -80px; animation-delay: 0s; }
.vs-blob--2 { width: 280px; height: 280px; background: #22d3ee; top: 30%; right: -100px; animation-delay: -6s; }
.vs-blob--3 { width: 220px; height: 220px; background: #f472b6; bottom: 20%; left: 5%; animation-delay: -12s; }

@keyframes blobDrift {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(20px, -30px) scale(1.05); }
  66% { transform: translate(-15px, 20px) scale(0.97); }
}

@media (prefers-reduced-motion: reduce) {
  .vs-blob { animation: none; }
}

/* Wrap content above blobs */
.vs-home > section,
.vs-home > div:not(.vs-home__blobs) { position: relative; z-index: 1; }

/* ── Glass card ────────────────────────────────────────────────── */
.glass-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 1rem;
  backdrop-filter: blur(12px);
}

/* ── Section spacing ───────────────────────────────────────────── */
.vs-home > section { margin-bottom: 1.25rem; }

/* ══════════════════════════════════════════════════════════════
   SECTION 1 — WELCOME + MOOD
══════════════════════════════════════════════════════════════ */
.vs-welcome-section { padding-top: 0.75rem; }

/* Greeting row */
.vs-welcome__greeting {
  display: flex;
  align-items: flex-start;
  gap: 0.9rem;
  padding: 1.1rem 0.75rem 0.9rem;
}

.vs-welcome__avatar-wrap { position: relative; flex-shrink: 0; }

.vs-welcome__avatar {
  width: 52px; height: 52px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.6rem;
  box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.4);
}

.vs-welcome__text { flex: 1; min-width: 0; }

/* Tactile Memory Wall Styles */
.ms-memory-wall-stage {
  display: flex;
  flex-wrap: wrap;
  gap: 1.1rem 1.3rem;
  min-height: 120px;
  padding: 1rem 0 .5rem 0;
  align-items: flex-start;
}
.ms-memory-card {
  background: var(--theme-surface);
  border-radius: .7rem .7rem 1.1rem .7rem;
  box-shadow: 0 2px 12px 0 rgba(0,0,0,0.10), 0 1.5px 0 0 var(--theme-border);
  padding: .85rem .95rem .7rem .95rem;
  min-width: 120px;
  max-width: 180px;
  min-height: 70px;
  font-size: .98rem;
  color: var(--theme-text);
  position: relative;
  cursor: grab;
  user-select: none;
  transition: box-shadow .18s, transform .18s;
  outline: none;
}
.ms-memory-card:focus, .ms-memory-card:active {
  box-shadow: 0 4px 18px 0 rgba(139,92,246,0.18), 0 2px 0 0 var(--theme-accent);
  z-index: 2;
  transform: scale(1.04) rotate(-1deg);
}
.ms-memory-card--pinned {
  background: linear-gradient(135deg, #fef9c3 80%, #fef3c7 100%);
  border: 1.5px solid #fde68a;
}
.ms-memory-card--board {
  background: linear-gradient(135deg, #e0e7ff 80%, #f3f4f6 100%);
  border: 1.5px solid #a5b4fc;
}
.ms-memory-card--emotion {
  background: linear-gradient(135deg, #fbcfe8 80%, #fdf2f8 100%);
  border: 1.5px solid #f472b6;
}
.ms-memory-card--collectible {
  background: linear-gradient(135deg, #d1fae5 80%, #f0fdf4 100%);
  border: 1.5px solid #34d399;
}
.ms-memory-card__icon {
  font-size: 1.3rem;
  margin-right: .5rem;
  vertical-align: middle;
}
.ms-memory-card__text {
  display: inline-block;
  vertical-align: middle;
  word-break: break-word;
}
.ms-memory-card__delete {
  position: absolute;
  top: .45rem;
  right: .45rem;
  background: none;
  border: none;
  color: #f87171;
  font-size: 1.1rem;
  opacity: .7;
  cursor: pointer;
  border-radius: .3rem;
  padding: .1rem .3rem;
  transition: background .15s;
}
.ms-memory-card__delete:hover {
  background: #fee2e2;
  opacity: 1;
}
.ms-memory-wall-actions {
  display: flex;
  align-items: center;
  gap: .7rem;
}
.ms-memory-wall-status {
  font-size: .85rem;
  color: var(--theme-text);
  opacity: .7;
}

.vs-welcome__name {
  font-size: 1.35rem;
  font-weight: 700;
  margin: 0 0 0.2rem;
  color: #f0e8ff;
}

.vs-welcome__sub {
  font-size: 0.875rem;
  color: #a78bfa;
  margin: 0 0 0.4rem;
}

.vs-mood-display-chip {
  display: inline-block;
  background: rgba(139, 92, 246, 0.2);
  border: 1px solid rgba(139, 92, 246, 0.35);
  border-radius: 2rem;
  padding: 0.2rem 0.65rem;
  font-size: 0.8rem;
  color: #c4b5fd;
}

/* Streak badge */
.vs-streak-badge {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.1rem;
  font-size: 1.3rem;
}
.vs-streak-badge__num {
  font-size: 0.7rem;
  color: #fbbf24;
  font-weight: 700;
}

/* Mood chips */
.vs-mood-chips {
  padding: 0.5rem 0.75rem 0.75rem;
}
.vs-mood-chips__label {
  font-size: 0.78rem;
  color: #94a3b8;
  margin: 0 0 0.5rem;
  text-transform: lowercase;
  letter-spacing: 0.02em;
}
.vs-mood-chips__row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}
.vs-mood-chip-btn {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 2rem;
  padding: 0.4rem 0.85rem;
  font-size: 0.875rem;
  color: #d8d3e8;
  cursor: pointer;
  transition: background 0.18s ease, border-color 0.18s ease, transform 0.12s ease;
  min-height: 44px;
  display: flex; align-items: center;
}
.vs-mood-chip-btn:hover {
  background: rgba(139, 92, 246, 0.2);
  border-color: rgba(139, 92, 246, 0.5);
  transform: translateY(-1px);
}
.vs-mood-chip-btn--active {
  background: rgba(139, 92, 246, 0.3);
  border-color: #8b5cf6;
  color: #f0e8ff;
  box-shadow: 0 0 8px rgba(139, 92, 246, 0.3);
}
.vs-mood-chip-btn--active:hover { transform: none; }

/* Stories bar */
.vs-stories-bar {
  display: flex;
  gap: 0.6rem;
  overflow-x: auto;
  padding: 0.5rem 0.75rem 0.75rem;
  scrollbar-width: none;
}
.vs-stories-bar::-webkit-scrollbar { display: none; }

.vs-story-bubble {
  display: flex; flex-direction: column; align-items: center;
  gap: 0.25rem;
  text-decoration: none; flex-shrink: 0;
  transition: transform 0.15s ease;
}

/* =====================================================================
   Customize Studio Refresh (Kids + Teens)
   Scoped to /my-space/customize layout classes.
   ===================================================================== */

.myspace-page--layered {
  max-width: 1180px;
  margin: 0 auto;
  padding: 1rem 0.9rem 6rem;
  color: #f8f7ff;
  font-family: "Baloo 2", "Nunito", "Trebuchet MS", sans-serif;
}

.myspace-page--layered::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(55% 45% at 8% 8%, rgba(255, 181, 120, 0.22), transparent 70%),
    radial-gradient(45% 35% at 86% 18%, rgba(130, 207, 255, 0.2), transparent 70%),
    radial-gradient(40% 42% at 78% 82%, rgba(214, 162, 255, 0.2), transparent 72%);
  z-index: -1;
}

.cozy-page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.9rem;
  margin: 0 0 1rem;
  padding: 1.1rem 1rem;
  border-radius: 1rem;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: linear-gradient(135deg, rgba(255, 156, 72, 0.2), rgba(123, 101, 255, 0.14));
  box-shadow: 0 14px 38px rgba(34, 10, 50, 0.35);
}

.cozy-page-header__title {
  margin: 0;
  font-size: clamp(1.25rem, 2vw, 1.75rem);
  line-height: 1.15;
}

.cozy-page-header__sub {
  margin: 0.32rem 0 0;
  color: rgba(246, 243, 255, 0.92);
  font-size: 0.95rem;
}

.cozy-page-header__actions {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  flex-wrap: wrap;
}

.room-fullscreen-btn,
.ms-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  min-height: 42px;
  border-radius: 0.8rem;
  border: 1px solid rgba(255, 255, 255, 0.22);
  padding: 0.58rem 0.85rem;
  font-weight: 700;
  font-size: 0.9rem;
  text-decoration: none;
  cursor: pointer;
  color: #fff;
  background: rgba(255, 255, 255, 0.06);
}

.ms-btn--primary,
.room-fullscreen-btn {
  border-color: rgba(255, 198, 127, 0.65);
  background: linear-gradient(135deg, #f59f39, #f06e53 52%, #c552d2 100%);
  box-shadow: 0 9px 22px rgba(241, 124, 73, 0.38);
}

.ms-btn--ghost {
  background: rgba(255, 255, 255, 0.08);
}

.ms-btn:hover,
.room-fullscreen-btn:hover {
  transform: translateY(-1px);
}

.room-creator-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(320px, 0.9fr);
  gap: 0.95rem;
  align-items: start;
}

.room-canvas-container,
.room-creator__controls,
.cozy-section,
.ms-card {
  border-radius: 1rem;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.085), rgba(255, 255, 255, 0.02));
  box-shadow: 0 15px 36px rgba(25, 5, 38, 0.35);
}

.room-canvas-container {
  padding: 0.85rem;
}

.room-canvas-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.6rem;
  margin-bottom: 0.6rem;
}

.room-canvas-title {
  margin: 0;
  font-size: 1.02rem;
}

.room-canvas-subtitle {
  font-size: 0.8rem;
  color: rgba(245, 240, 255, 0.78);
}

.room-canvas {
  border-radius: 0.9rem;
  border: 1px solid rgba(255, 255, 255, 0.16);
  min-height: 280px;
  background: linear-gradient(180deg, rgba(42, 31, 98, 0.55), rgba(15, 26, 66, 0.5));
  overflow: hidden;
  position: relative;
}

.studio-depth-glow {
  position: absolute;
  inset: -8% -5% 35% -5%;
  pointer-events: none;
  background: radial-gradient(circle at 35% 45%, rgba(255, 188, 131, 0.2), transparent 60%),
              radial-gradient(circle at 70% 25%, rgba(130, 214, 255, 0.16), transparent 62%);
  z-index: 0;
}

.studio-drift-particles {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 1;
}

.studio-drift-particles span {
  position: absolute;
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: rgba(255, 241, 228, 0.58);
  filter: blur(0.4px);
  animation: studioFloat 12s ease-in-out infinite;
}

.studio-drift-particles span:nth-child(1) { left: 12%; top: 20%; animation-delay: -1s; }
.studio-drift-particles span:nth-child(2) { left: 24%; top: 64%; animation-delay: -3s; }
.studio-drift-particles span:nth-child(3) { left: 38%; top: 32%; animation-delay: -2s; }
.studio-drift-particles span:nth-child(4) { left: 61%; top: 70%; animation-delay: -5s; }
.studio-drift-particles span:nth-child(5) { left: 76%; top: 30%; animation-delay: -4s; }
.studio-drift-particles span:nth-child(6) { left: 89%; top: 58%; animation-delay: -6s; }

@keyframes studioFloat {
  0%, 100% { transform: translateY(0) scale(1); opacity: 0.18; }
  35% { transform: translateY(-10px) scale(1.2); opacity: 0.56; }
  65% { transform: translateY(8px) scale(0.9); opacity: 0.3; }
}

.room-canvas-controls {
  margin-top: 0.65rem;
  display: flex;
  gap: 0.45rem;
  justify-content: center;
}

.room-canvas-btn {
  min-height: 38px;
  border-radius: 0.7rem;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  padding: 0.45rem 0.7rem;
}

.room-canvas-btn--primary {
  background: linear-gradient(135deg, #5e8dff, #5dd6f3);
  border-color: rgba(170, 219, 255, 0.6);
}

.room-creator__controls {
  position: sticky;
  top: 74px;
  padding: 0.72rem;
}

.studio-drawer-tabs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.42rem;
  margin-bottom: 0.62rem;
}

.studio-drawer-tab {
  min-height: 40px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.06);
  color: #fff;
  font-size: 0.78rem;
  font-weight: 800;
  padding: 0.35rem 0.4rem;
}

.studio-drawer-tab.is-active {
  border-color: rgba(255, 215, 174, 0.85);
  background: linear-gradient(135deg, rgba(252, 167, 101, 0.3), rgba(146, 109, 251, 0.32));
}

.room-creator__tabs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.38rem;
  margin-bottom: 0.7rem;
}

.room-creator__tab {
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 0.72rem;
  background: rgba(255, 255, 255, 0.05);
  color: #f6f2ff;
  min-height: 54px;
  padding: 0.4rem 0.3rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.1rem;
}

.room-creator__tab-emoji {
  font-size: 1rem;
  line-height: 1;
}

.room-creator__tab-label {
  font-size: 0.72rem;
  font-weight: 700;
}

.room-creator__tab.is-active {
  background: linear-gradient(135deg, rgba(255, 176, 96, 0.38), rgba(145, 96, 255, 0.34));
  border-color: rgba(255, 209, 151, 0.75);
  box-shadow: 0 10px 18px rgba(77, 34, 120, 0.28);
}

.room-creator__panel {
  max-height: calc(100vh - 180px);
  overflow: auto;
  padding-right: 0.2rem;
}

.room-creator__section {
  display: none;
}

.room-creator__section.is-active {
  display: block;
}

.ms-card {
  padding: 0.75rem;
  margin-bottom: 0.75rem;
}

.myspace-page--layered .ms-card h3 {
  font-size: 1rem !important;
  margin-bottom: 0.6rem !important;
  color: #fff8ef !important;
}

.ms-field {
  margin-bottom: 0.7rem;
}

.ms-label {
  display: block;
  margin-bottom: 0.3rem;
  font-size: 0.83rem;
  font-weight: 700;
  color: rgba(255, 249, 241, 0.9);
}

.ms-input,
.ms-select,
textarea.ms-input,
input.ms-input {
  width: 100%;
  border-radius: 0.72rem;
  border: 1px solid rgba(255, 255, 255, 0.25);
  background: rgba(22, 18, 42, 0.56);
  color: #f8f7ff;
  padding: 0.58rem 0.66rem;
  min-height: 40px;
  font-size: 0.92rem;
}

textarea.ms-input {
  min-height: 88px;
  resize: vertical;
}

.ms-input::placeholder {
  color: rgba(244, 239, 255, 0.56);
}

.cozy-customize-sidebar .visual-picker {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.45rem;
}

.cozy-customize-sidebar .picker-card,
.cozy-customize-sidebar .preset-card {
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 0.75rem;
  background: rgba(255, 255, 255, 0.06);
  padding: 0.55rem;
  color: #fff;
}

.cozy-customize-sidebar .picker-card.is-selected,
.cozy-customize-sidebar .preset-card:hover {
  border-color: rgba(255, 210, 161, 0.74);
  background: linear-gradient(130deg, rgba(253, 161, 97, 0.22), rgba(165, 117, 255, 0.2));
}

.cozy-customize-sidebar .cozy-section {
  margin-top: 0.82rem;
  overflow: hidden;
}

.cozy-customize-sidebar .cozy-section {
  display: none;
}

.cozy-customize-sidebar .cozy-section__toggle {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 0.7rem;
  text-align: left;
  border: 0;
  padding: 0.78rem 0.9rem;
  color: #fff;
  background: linear-gradient(95deg, rgba(255, 165, 109, 0.2), rgba(110, 93, 255, 0.19));
}

.cozy-customize-sidebar .cozy-section__icon {
  font-size: 1.2rem;
}

.cozy-customize-sidebar .cozy-section__title {
  display: flex;
  flex-direction: column;
  font-size: 0.98rem;
  font-weight: 800;
}

.cozy-customize-sidebar .cozy-section__subtitle {
  font-size: 0.74rem;
  opacity: 0.82;
  font-weight: 600;
}

.cozy-customize-sidebar .cozy-section__chevron {
  margin-left: auto;
  transition: transform 0.2s ease;
}

.cozy-customize-sidebar .cozy-section__body {
  display: none;
  padding: 0.8rem;
}

.cozy-customize-sidebar .cozy-section.cozy-section--expanded .cozy-section__body {
  display: block;
}

.cozy-section.cozy-section--expanded .cozy-section__chevron {
  transform: rotate(180deg);
}

.ms-collectible-grid,
.ms-unlock-grid,
.ms-room-spotlight-grid {
  display: grid;
  gap: 0.55rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.ms-collectible-item,
.ms-unlock-item,
.ms-room-spotlight-card {
  border-radius: 0.72rem;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.06);
  padding: 0.55rem;
}

.ms-collectible-item p,
.ms-room-spotlight-card p {
  margin: 0.2rem 0 0;
  font-size: 0.8rem;
  color: rgba(244, 241, 255, 0.8);
}

.ms-memory-card {
  color: #261725;
  font-weight: 700;
}

.studio-live-drop-toolbar {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.45rem;
  margin-bottom: 0.6rem;
}

.studio-preview-object {
  position: absolute;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.38);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  cursor: grab;
  user-select: none;
  touch-action: none;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.22), rgba(255, 255, 255, 0.08));
  backdrop-filter: blur(3px);
  box-shadow: 0 10px 20px rgba(18, 8, 36, 0.25);
  z-index: 8;
  animation: objectIdleFloat 5.8s ease-in-out infinite;
}

.studio-preview-object.is-dragging {
  cursor: grabbing;
  transform: scale(1.08);
  box-shadow: 0 16px 30px rgba(13, 5, 31, 0.36);
}

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

.studio-canvas-hint {
  margin-top: 0.55rem;
  text-align: center;
  font-size: 0.78rem;
  color: rgba(245, 239, 255, 0.85);
}

@media (max-width: 980px) {
  .room-creator-layout {
    grid-template-columns: 1fr;
  }

  .room-creator__controls {
    position: static;
  }

  .room-creator__panel {
    max-height: none;
  }

  .cozy-page-header {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 680px) {
  .myspace-page--layered {
    padding: 0.8rem 0.55rem 5rem;
  }

  .room-canvas {
    min-height: 236px;
  }

  .room-creator__tabs {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .studio-drawer-tabs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .ms-collectible-grid,
  .ms-unlock-grid,
  .ms-room-spotlight-grid,
  .visual-picker {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  .ms-btn:hover,
  .room-fullscreen-btn:hover {
    transform: none;
  }

  .cozy-section__chevron {
    transition: none;
  }

  .studio-drift-particles span,
  .studio-preview-object {
    animation: none;
  }
}
.vs-story-bubble:hover { transform: scale(1.06); }

.vs-story-bubble__inner {
  width: 52px; height: 52px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.4rem;
  border: 2px solid rgba(139, 92, 246, 0.3);
}
.vs-story-bubble__inner--add {
  background: rgba(139, 92, 246, 0.1);
  border: 2px dashed rgba(139, 92, 246, 0.5);
  color: #c4b5fd;
  font-size: 1.5rem;
}
.vs-story-bubble--unseen .vs-story-bubble__inner {
  border-color: #8b5cf6;
  box-shadow: 0 0 8px rgba(139, 92, 246, 0.4);
}
.vs-story-bubble__name {
  font-size: 0.65rem;
  color: #94a3b8;
  max-width: 52px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-align: center;
}

/* ══════════════════════════════════════════════════════════════
   SECTION 2 — COMPOSE
══════════════════════════════════════════════════════════════ */
.vs-compose-card {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.9rem 1rem;
}
.vs-compose-card__avatar {
  width: 38px; height: 38px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.2rem;
  flex-shrink: 0;
  margin-top: 0.25rem;
}
.vs-compose-form { flex: 1; min-width: 0; }
.vs-compose-input {
  width: 100%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 0.75rem;
  padding: 0.65rem 0.85rem;
  font-size: 0.9rem;
  color: #f0e8ff;
  resize: none;
  font-family: inherit;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.vs-compose-input:focus {
  outline: none;
  border-color: rgba(139, 92, 246, 0.6);
  box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.12);
}
.vs-compose-input::placeholder { color: #6b7280; }
.vs-compose-footer {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.5rem;
}
.vs-compose-privacy {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 0.5rem;
  padding: 0.35rem 0.6rem;
  font-size: 0.78rem;
  color: #94a3b8;
  cursor: pointer;
  min-height: 36px;
}
.vs-char-counter {
  font-size: 0.72rem;
  color: #6b7280;
  margin-left: auto;
}
.vs-compose-btn {
  background: linear-gradient(135deg, #8b5cf6, #6d28d9);
  border: none;
  border-radius: 2rem;
  padding: 0.45rem 1.1rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: white;
  cursor: pointer;
  min-height: 36px;
  transition: opacity 0.15s ease, transform 0.12s ease;
}
.vs-compose-btn:hover { opacity: 0.88; transform: translateY(-1px); }

/* ══════════════════════════════════════════════════════════════
   SECTION 3 — TINY QUESTS
══════════════════════════════════════════════════════════════ */
.vs-quests-card {
  overflow: hidden;
}
.vs-quests-card__header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.9rem 1rem;
  cursor: pointer;
  list-style: none;
  user-select: none;
}
.vs-quests-card__header::-webkit-details-marker { display: none; }
.vs-quests-card__title {
  font-size: 0.95rem;
  font-weight: 700;
  color: #c4b5fd;
}
.vs-quests-card__sub {
  font-size: 0.78rem;
  color: #6b7280;
  flex: 1;
}
.vs-quests-card__chevron {
  font-size: 1.2rem;
  color: #6b7280;
  transition: transform 0.2s ease;
  line-height: 1;
}
details[open] .vs-quests-card__chevron { transform: rotate(90deg); }

.vs-quests-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.5rem;
  padding: 0 0.85rem 0.9rem;
}
@media (max-width: 420px) {
  .vs-quests-grid { grid-template-columns: repeat(2, 1fr); }
}

/* Sprint 15 — Atmosphere Engine + Shared Space Identity */
.ms-theme-swatch__meta {
  margin-top: 0.35rem;
  font-size: 0.72rem;
  opacity: 0.82;
}

.ms-live-preview,
.ms-bedroom-showcase,
.ms-room-spotlight-card,
.ms-room-card--immersive {
  position: relative;
  overflow: hidden;
}

.ms-live-preview__header,
.ms-bedroom-showcase__header,
.ms-room-spotlight-card__top,
.ms-room-atmosphere-head,
.ms-atmosphere-strip,
.ms-widget-chip-row {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
}

.ms-preview-stage {
  margin-top: 0.85rem;
  position: relative;
  min-height: 210px;
  border-radius: 1rem;
  background:
    radial-gradient(circle at top right, rgba(255,255,255,0.18), transparent 30%),
    linear-gradient(180deg, rgba(255,255,255,0.08), rgba(255,255,255,0.02));
  border: 1px solid rgba(255,255,255,0.1);
  padding: 1rem;
}

.ms-preview-stage__glow {
  position: absolute;
  inset: auto 10% 12% 10%;
  height: 72px;
  border-radius: 999px;
  background: rgba(139, 92, 246, 0.22);
  filter: blur(28px);
  pointer-events: none;
}

.ms-preview-stage__card {
  position: relative;
  z-index: 1;
  min-height: 178px;
  padding: 1rem;
  border-radius: 1rem;
  background: rgba(12, 18, 32, 0.58);
  border: 1px solid rgba(255,255,255,0.12);
  backdrop-filter: blur(12px);
}

.ms-preview-stage__identity {
  display: flex;
  flex-direction: column;
  gap: 0.12rem;
  color: var(--theme-text);
}

.ms-preview-stage__identity strong {
  font-size: 1rem;
}

.ms-preview-stage__identity span,
.ms-preview-stage__memory,
.ms-room-note,
.ms-collectible-item p,
.ms-room-spotlight-card p,
.ms-room-spotlight-card small {
  color: var(--theme-text);
  opacity: 0.72;
}

.ms-preview-stage__vibe {
  margin: 0.8rem 0 0.65rem;
  font-size: 1rem;
  line-height: 1.5;
  color: var(--theme-text);
}

.ms-preview-stage__memory,
.ms-room-note,
.ms-bedroom-panel p {
  font-size: 0.82rem;
  line-height: 1.5;
}

.ms-atmosphere-pill,
.ms-atmosphere-chip,
.ms-room-mood-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.32rem;
  min-height: 34px;
  padding: 0.32rem 0.72rem;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.12);
  background: rgba(255,255,255,0.06);
  color: var(--theme-text);
  font-size: 0.76rem;
}

.ms-room-mood-pill {
  background: rgba(139, 92, 246, 0.16);
  border-color: rgba(139, 92, 246, 0.3);
}

.ms-bedroom-grid,
.ms-room-spotlight-grid,
.ms-collectible-grid {
  display: grid;
  gap: 0.75rem;
}

.ms-bedroom-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 0.85rem;
}

.ms-room-spotlight-grid,
.ms-collectible-grid {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.ms-bedroom-panel,
.ms-room-spotlight-card,
.ms-collectible-item {
  border-radius: 0.9rem;
  padding: 0.9rem;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.09);
}

.ms-room-spotlight-card--link {
  text-decoration: none;
}

.ms-bedroom-panel h3,
.ms-collectible-item strong,
.ms-room-spotlight-card strong {
  color: var(--theme-text);
  margin: 0;
}

.ms-shelf-list,
.ms-widget-list {
  margin: 0.5rem 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.38rem;
}

.ms-shelf-list li,
.ms-widget-list li {
  padding: 0.45rem 0.55rem;
  border-radius: 0.7rem;
  background: rgba(255,255,255,0.04);
  color: var(--theme-text);
  font-size: 0.8rem;
}

.ms-collectible-item {
  display: flex;
  align-items: center;
  gap: 0.7rem;
}

.ms-collectible-item.is-unlocked {
  background: rgba(139,92,246,0.12);
  border-color: rgba(139,92,246,0.24);
}

.ms-collectible-item__emoji {
  font-size: 1.45rem;
}

.ms-room-card--immersive .ms-room-card__left {
  align-items: flex-start;
}

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

@media (max-width: 430px) {
  .ms-preview-stage,
  .ms-preview-stage__card,
  .ms-bedroom-panel,
  .ms-room-spotlight-card,
  .ms-collectible-item {
    backdrop-filter: none;
  }
}

.decor-bookshelf,
.decor-fairy-lights,
.decor-rain-window,
.decor-plush-pile {
  background: linear-gradient(180deg, rgba(255,255,255,0.08), rgba(255,255,255,0.03));
  border-radius: 0.8rem;
  border: 1px solid rgba(255,255,255,0.08);
}

.vs-quest-chip {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.3rem;
  padding: 0.75rem 0.5rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 0.85rem;
  text-decoration: none;
  color: #c4b5fd;
  font-size: 0.78rem;
  text-align: center;
  transition: background 0.15s ease, border-color 0.15s ease, transform 0.12s ease;
  min-height: 80px;
  justify-content: center;
}
.vs-quest-chip:hover {
  background: rgba(139, 92, 246, 0.15);
  border-color: rgba(139, 92, 246, 0.35);
  transform: translateY(-2px);
}
.vs-quest-chip__icon { font-size: 1.4rem; }
.vs-quest-chip__label { font-size: 0.72rem; color: #94a3b8; line-height: 1.3; }
.vs-quest-chip--done {
  background: rgba(34, 197, 94, 0.08);
  border-color: rgba(34, 197, 94, 0.3);
  opacity: 0.75;
}
.vs-quest-chip--done .vs-quest-chip__label { text-decoration: line-through; color: #6b7280; }
.vs-quest-chip__check {
  font-size: 0.7rem;
  color: #4ade80;
  font-weight: 700;
}

/* ══════════════════════════════════════════════════════════════
   SECTION 4 — QUICK ACTIONS
══════════════════════════════════════════════════════════════ */
.vs-quick-actions {
  display: flex;
  gap: 0.6rem;
  overflow-x: auto;
  padding: 0.25rem 0.1rem 0.1rem;
  scrollbar-width: none;
}
.vs-quick-actions::-webkit-scrollbar { display: none; }

.vs-quick-action {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  padding: 0.9rem 0.85rem;
  border-radius: 1rem;
  text-decoration: none;
  flex-shrink: 0;
  min-width: 80px;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.vs-quick-action:hover { transform: translateY(-3px); }
.vs-quick-action__icon { font-size: 1.6rem; }
.vs-quick-action__label { font-size: 0.7rem; font-weight: 600; text-align: center; white-space: nowrap; }

.vs-quick-action--purple { background: rgba(139, 92, 246, 0.2); border: 1px solid rgba(139, 92, 246, 0.35); color: #c4b5fd; }
.vs-quick-action--purple:hover { box-shadow: 0 6px 20px rgba(139, 92, 246, 0.3); color: #c4b5fd; }
.vs-quick-action--cyan { background: rgba(34, 211, 238, 0.12); border: 1px solid rgba(34, 211, 238, 0.3); color: #67e8f9; }
.vs-quick-action--cyan:hover { box-shadow: 0 6px 20px rgba(34, 211, 238, 0.2); color: #67e8f9; }
.vs-quick-action--pink { background: rgba(244, 114, 182, 0.12); border: 1px solid rgba(244, 114, 182, 0.3); color: #f9a8d4; }
.vs-quick-action--pink:hover { box-shadow: 0 6px 20px rgba(244, 114, 182, 0.2); color: #f9a8d4; }
.vs-quick-action--green { background: rgba(52, 211, 153, 0.12); border: 1px solid rgba(52, 211, 153, 0.3); color: #6ee7b7; }
.vs-quick-action--green:hover { box-shadow: 0 6px 20px rgba(52, 211, 153, 0.15); color: #6ee7b7; }
.vs-quick-action--amber { background: rgba(251, 191, 36, 0.12); border: 1px solid rgba(251, 191, 36, 0.3); color: #fde68a; }
.vs-quick-action--amber:hover { box-shadow: 0 6px 20px rgba(251, 191, 36, 0.15); color: #fde68a; }

/* ══════════════════════════════════════════════════════════════
   SECTION 5 — FRIENDS ONLINE
══════════════════════════════════════════════════════════════ */
.vs-friends-card { padding: 0.9rem 1rem; }
.vs-friends-card__header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 0.8rem;
}
.vs-friends-card__title { font-size: 0.9rem; font-weight: 700; color: #c4b5fd; }
.vs-friends-card__seeall { font-size: 0.78rem; color: #7c3aed; text-decoration: none; }
.vs-friends-card__seeall:hover { color: #a78bfa; }

.vs-friends-strip {
  display: flex;
  gap: 0.9rem;
  overflow-x: auto;
  padding-bottom: 0.25rem;
  scrollbar-width: none;
}
.vs-friends-strip::-webkit-scrollbar { display: none; }

.vs-friend-bubble { flex-shrink: 0; }
.vs-friend-bubble__link {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.3rem;
  text-decoration: none;
  cursor: pointer;
}
.vs-friend-avatar {
  width: 50px; height: 50px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem;
  position: relative;
  border: 2px solid rgba(255, 255, 255, 0.08);
  transition: transform 0.15s ease;
}
.vs-friend-bubble__link:hover .vs-friend-avatar { transform: scale(1.08); }
.vs-friend-bubble__name {
  font-size: 0.65rem;
  color: #94a3b8;
  max-width: 52px;
  text-overflow: ellipsis;
  overflow: hidden;
  white-space: nowrap;
}

/* Online dots */
.vs-online-dot {
  width: 10px; height: 10px;
  border-radius: 50%;
  border: 2px solid #020304;
  position: absolute;
  bottom: 2px; right: 2px;
}
.vs-online-dot--on { background: #4ade80; }
.vs-online-dot--off { background: #4b5563; }
.vs-online-dot--pulse {
  background: #4ade80;
  position: absolute;
  bottom: 2px; right: 2px;
  border: 2px solid #020304;
  animation: pulseDot 2.5s ease-in-out infinite;
}
@keyframes pulseDot {
  0%, 100% { box-shadow: 0 0 0 0 rgba(74, 222, 128, 0.5); }
  50% { box-shadow: 0 0 0 4px rgba(74, 222, 128, 0); }
}

.vs-friends-empty { font-size: 0.82rem; color: #6b7280; padding: 0.5rem 0; }

/* Waiting on move */
.vs-waiting-moves { margin-top: 0.75rem; display: flex; flex-direction: column; gap: 0.4rem; }
.vs-waiting-move-chip {
  display: flex; align-items: center; gap: 0.6rem;
  padding: 0.55rem 0.75rem;
  background: rgba(139, 92, 246, 0.12);
  border: 1px solid rgba(139, 92, 246, 0.25);
  border-radius: 0.65rem;
  font-size: 0.82rem;
  color: #c4b5fd;
  text-decoration: none;
  transition: background 0.15s ease;
}
.vs-waiting-move-chip:hover { background: rgba(139, 92, 246, 0.22); color: #c4b5fd; }
.vs-waiting-move-chip__cta { margin-left: auto; font-size: 0.75rem; color: #8b5cf6; }

/* ══════════════════════════════════════════════════════════════
   SECTION 6 — FEED (emotional center)
══════════════════════════════════════════════════════════════ */
.vs-feed-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0.2rem 0.1rem 0.75rem;
}
.vs-feed-header__title {
  font-size: 1.05rem;
  font-weight: 700;
  color: #e9d5ff;
  margin: 0;
}
.vs-feed-header__link { font-size: 0.8rem; color: #7c3aed; text-decoration: none; }
.vs-feed-header__link:hover { color: #a78bfa; }

.vs-feed-list { display: flex; flex-direction: column; gap: 0.9rem; }

.vs-post-card {
  padding: 1rem;
  transition: border-color 0.15s ease;
}
.vs-post-card:hover { border-color: rgba(139, 92, 246, 0.25); }

.vs-post-card__header { display: flex; align-items: center; margin-bottom: 0.65rem; }
.vs-post-card__author-link {
  display: flex; align-items: center; gap: 0.65rem;
  text-decoration: none; color: inherit;
}
.vs-post-card__avatar {
  width: 36px; height: 36px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.15rem;
  flex-shrink: 0;
}
.vs-post-card__author-name {
  display: block;
  font-size: 0.88rem;
  font-weight: 600;
  color: #e9d5ff;
}
.vs-post-card__author-name:hover { color: #a78bfa; }
.vs-post-card__time {
  display: block;
  font-size: 0.72rem;
  color: #6b7280;
}

.vs-post-card__body {
  font-size: 0.92rem;
  line-height: 1.6;
  color: #d4c4f0;
  margin: 0 0 0.75rem;
  word-break: break-word;
}

.vs-post-card__actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding-top: 0.6rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.vs-react-btn {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 2rem;
  padding: 0.3rem 0.7rem;
  font-size: 0.82rem;
  color: #94a3b8;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, transform 0.1s ease;
  min-height: 32px;
}
.vs-react-btn:hover { background: rgba(244, 63, 94, 0.15); border-color: rgba(244, 63, 94, 0.3); transform: scale(1.05); }
.vs-react-btn--active {
  background: rgba(244, 63, 94, 0.2);
  border-color: rgba(244, 63, 94, 0.5);
  color: #fda4af;
}

.vs-post-card__comment-link {
  font-size: 0.82rem;
  color: #6b7280;
  text-decoration: none;
  transition: color 0.15s ease;
}
.vs-post-card__comment-link:hover { color: #a78bfa; }

.vs-post-card__detail-link {
  margin-left: auto;
  font-size: 0.75rem;
  color: #4b5563;
  text-decoration: none;
}
.vs-post-card__detail-link:hover { color: #7c3aed; }

.vs-feed-more-btn {
  display: block;
  text-align: center;
  padding: 0.85rem;
  background: rgba(139, 92, 246, 0.08);
  border: 1px solid rgba(139, 92, 246, 0.2);
  border-radius: 0.85rem;
  font-size: 0.85rem;
  color: #a78bfa;
  text-decoration: none;
  transition: background 0.15s ease;
}
.vs-feed-more-btn:hover { background: rgba(139, 92, 246, 0.16); color: #a78bfa; }

/* Feed empty state */
.vs-feed-empty {
  padding: 2.5rem 1.5rem;
  text-align: center;
}
.vs-feed-empty__icon { font-size: 2.5rem; margin: 0 0 0.75rem; }
.vs-feed-empty__title {
  font-size: 1.05rem;
  font-weight: 700;
  color: #e9d5ff;
  margin: 0 0 0.5rem;
}
.vs-feed-empty__sub {
  font-size: 0.875rem;
  color: #6b7280;
  margin: 0 0 1.25rem;
  line-height: 1.5;
}
.vs-feed-empty__actions { display: flex; gap: 0.75rem; justify-content: center; flex-wrap: wrap; }

/* Generic buttons */
.vs-btn {
  padding: 0.55rem 1.2rem;
  border-radius: 2rem;
  font-size: 0.875rem;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex; align-items: center;
  min-height: 44px;
  cursor: pointer;
  border: none;
  transition: opacity 0.15s ease, transform 0.12s ease;
}
.vs-btn:hover { opacity: 0.88; transform: translateY(-1px); }
.vs-btn--primary { background: linear-gradient(135deg, #8b5cf6, #6d28d9); color: white; }
.vs-btn--ghost {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #c4b5fd;
}

/* ══════════════════════════════════════════════════════════════
   SECTION 7 — INBOX CHIPS
══════════════════════════════════════════════════════════════ */
.vs-inbox-row { display: flex; gap: 0.75rem; flex-wrap: wrap; }
.vs-inbox-chip {
  flex: 1; min-width: 140px;
  display: flex; align-items: center; gap: 0.6rem;
  padding: 0.85rem 1rem;
  text-decoration: none;
  border-radius: 0.85rem;
  transition: border-color 0.15s ease, transform 0.12s ease;
}
.vs-inbox-chip:hover { transform: translateY(-2px); }
.vs-inbox-chip__icon { font-size: 1.25rem; }
.vs-inbox-chip__count { font-size: 1.2rem; font-weight: 700; color: #f0e8ff; }
.vs-inbox-chip__label { font-size: 0.78rem; color: #94a3b8; flex: 1; }
.vs-inbox-chip__arrow { color: #6b7280; font-size: 0.875rem; margin-left: auto; }
.vs-inbox-chip--notif { border-color: rgba(251, 191, 36, 0.3); }
.vs-inbox-chip--notif:hover { border-color: rgba(251, 191, 36, 0.5); color: inherit; }
.vs-inbox-chip--dm { border-color: rgba(139, 92, 246, 0.3); }
.vs-inbox-chip--dm:hover { border-color: rgba(139, 92, 246, 0.5); color: inherit; }

/* ══════════════════════════════════════════════════════════════
   SECTION 8 — GAMES
══════════════════════════════════════════════════════════════ */
.vs-games-card { padding: 0.9rem 1rem; }
.vs-games-card__header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 0.8rem;
}
.vs-games-card__title { font-size: 0.9rem; font-weight: 700; color: #c4b5fd; }
.vs-games-card__seeall { font-size: 0.78rem; color: #7c3aed; text-decoration: none; }

.vs-games-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}
.vs-game-tile {
  display: flex; flex-direction: column; align-items: center; gap: 0.3rem;
  padding: 0.75rem 0.5rem;
  border-radius: 0.85rem;
  text-decoration: none; text-align: center;
  transition: transform 0.15s ease;
}
.vs-game-tile__icon { font-size: 1.5rem; }
.vs-game-tile__name { font-size: 0.7rem; color: #94a3b8; }
.vs-game-tile__badge {
  font-size: 0.62rem;
  font-weight: 700;
  padding: 0.1rem 0.4rem;
  border-radius: 0.3rem;
  background: rgba(139, 92, 246, 0.3);
  color: #c4b5fd;
}
.vs-game-tile__badge--soon { background: rgba(255,255,255,0.06); color: #4b5563; }

.vs-game-tile--live {
  background: rgba(139, 92, 246, 0.12);
  border: 1px solid rgba(139, 92, 246, 0.3);
  color: #c4b5fd;
}
.vs-game-tile--live:hover { transform: scale(1.04); }
.vs-game-tile--soon {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
  opacity: 0.6;
}

.vs-games-friends-activity { display: flex; flex-direction: column; gap: 0.4rem; }
.vs-games-friends-activity__label {
  font-size: 0.72rem; color: #6b7280; text-transform: lowercase;
  margin: 0 0 0.2rem;
}
.vs-game-activity-row {
  display: flex; align-items: center; gap: 0.6rem;
  font-size: 0.82rem; color: #94a3b8; text-decoration: none;
  padding: 0.35rem 0;
  transition: color 0.15s ease;
}
.vs-game-activity-row:hover { color: #c4b5fd; }
.vs-game-activity-row__avatar {
  width: 26px; height: 26px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.9rem; flex-shrink: 0;
}

/* ══════════════════════════════════════════════════════════════
   SECTION 9 — PROFILE CARD
══════════════════════════════════════════════════════════════ */
.vs-profile-card { padding: 1rem; }
.vs-profile-card__top { display: flex; align-items: flex-start; gap: 0.9rem; margin-bottom: 0.85rem; }
.vs-profile-card__avatar {
  width: 54px; height: 54px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.7rem; flex-shrink: 0;
}
.vs-profile-card__info { flex: 1; min-width: 0; }
.vs-profile-card__name { font-size: 1rem; font-weight: 700; margin: 0 0 0.3rem; color: #f0e8ff; }
.vs-profile-card__bio { font-size: 0.82rem; color: #94a3b8; margin: 0 0 0.4rem; line-height: 1.45; }
.vs-profile-card__vibes { display: flex; flex-wrap: wrap; gap: 0.35rem; }
.vs-vibe-tag {
  font-size: 0.72rem;
  background: rgba(139, 92, 246, 0.15);
  border: 1px solid rgba(139, 92, 246, 0.25);
  border-radius: 1rem;
  padding: 0.15rem 0.55rem;
  color: #c4b5fd;
}
.vs-profile-card__edit-btn {
  font-size: 1rem; color: #6b7280; text-decoration: none;
  padding: 0.25rem; flex-shrink: 0;
  transition: color 0.15s ease;
}
.vs-profile-card__edit-btn:hover { color: #c4b5fd; }

.vs-profile-card__stats {
  display: flex; gap: 1.25rem;
  padding: 0.6rem 0;
  border-top: 1px solid rgba(255,255,255,0.06);
  border-bottom: 1px solid rgba(255,255,255,0.06);
  margin-bottom: 0.75rem;
}
.vs-profile-stat { display: flex; flex-direction: column; align-items: center; gap: 0.15rem; }
.vs-profile-stat__num { font-size: 1rem; font-weight: 700; color: #e9d5ff; }
.vs-profile-stat__label { font-size: 0.65rem; color: #6b7280; text-transform: lowercase; }

/* XP row — de-emphasized */
.vs-xp-row { display: flex; align-items: center; gap: 0.6rem; margin-bottom: 0.65rem; }
.vs-level-pill {
  font-size: 0.7rem; font-weight: 700;
  background: rgba(139, 92, 246, 0.2);
  border: 1px solid rgba(139, 92, 246, 0.3);
  border-radius: 1rem;
  padding: 0.15rem 0.5rem;
  color: #a78bfa;
  white-space: nowrap;
}
.vs-xp-track {
  flex: 1; height: 5px;
  background: rgba(255,255,255,0.08);
  border-radius: 3px;
  overflow: hidden;
}
.vs-xp-track__fill {
  height: 100%;
  background: linear-gradient(90deg, #6d28d9, #8b5cf6);
  border-radius: 3px;
  transition: width 0.5s ease;
}
.vs-xp-label { font-size: 0.65rem; color: #4b5563; white-space: nowrap; }

.vs-achievements-row {
  display: flex; gap: 0.4rem; flex-wrap: wrap;
  margin-bottom: 0.75rem;
}
.vs-achievement-badge { font-size: 1.3rem; cursor: default; }

.vs-profile-card__links {
  display: flex; gap: 0.5rem; flex-wrap: wrap;
}
.vs-profile-card__link {
  font-size: 0.78rem; color: #6b7280;
  text-decoration: none;
  padding: 0.3rem 0.65rem;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 0.5rem;
  transition: color 0.15s ease, border-color 0.15s ease;
}
.vs-profile-card__link:hover { color: #a78bfa; border-color: rgba(139, 92, 246, 0.3); }
.vs-profile-card__link--accent {
  background: rgba(139, 92, 246, 0.12);
  border-color: rgba(139, 92, 246, 0.3);
  color: #a78bfa;
}

/* ══════════════════════════════════════════════════════════════
   SECTION 10 — DISCOVER
══════════════════════════════════════════════════════════════ */
.vs-discover-card { padding: 0.9rem 1rem; }
.vs-discover-card__header { margin-bottom: 0.75rem; }
.vs-discover-card__title { font-size: 0.9rem; font-weight: 700; color: #c4b5fd; }
.vs-discover-list { display: flex; flex-direction: column; gap: 0.5rem; }
.vs-discover-row { display: flex; align-items: center; gap: 0.65rem; padding: 0.35rem 0; }
.vs-discover-avatar {
  width: 34px; height: 34px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem; flex-shrink: 0;
}
.vs-discover-name {
  flex: 1; font-size: 0.875rem; color: #d4c4f0;
  text-decoration: none;
}
.vs-discover-name:hover { color: #a78bfa; }
.vs-discover-follow-form { margin-left: auto; }
.vs-follow-btn {
  background: rgba(139, 92, 246, 0.15);
  border: 1px solid rgba(139, 92, 246, 0.35);
  border-radius: 2rem;
  padding: 0.3rem 0.85rem;
  font-size: 0.78rem;
  color: #c4b5fd;
  cursor: pointer;
  min-height: 36px;
  transition: background 0.15s ease;
}
.vs-follow-btn:hover { background: rgba(139, 92, 246, 0.3); }

/* ══════════════════════════════════════════════════════════════
   SECTION 11 — SAFETY
══════════════════════════════════════════════════════════════ */
.vs-safety-card { padding: 0.75rem 1rem; }
.vs-safety-card__text {
  font-size: 0.78rem;
  color: #6b7280;
  margin: 0;
  line-height: 1.55;
}
.vs-safety-card__text a { color: #7c3aed; text-decoration: none; }
.vs-safety-card__text a:hover { color: #a78bfa; }
.vs-safety-report-link {
  background: none; border: none; cursor: pointer;
  color: #7c3aed; font-size: 0.78rem; padding: 0; font-family: inherit;
  text-decoration: underline;
}
.vs-safety-report-link:hover { color: #a78bfa; }

/* ══════════════════════════════════════════════════════════════
   FOOTER
══════════════════════════════════════════════════════════════ */
.vs-home-footer {
  text-align: center;
  padding: 1.5rem 1rem 0.5rem;
}
.vs-home-footer p {
  font-size: 0.78rem;
  color: #2d1f42;
}

/* ══════════════════════════════════════════════════════════════
   SHARED / UTILITY
══════════════════════════════════════════════════════════════ */
.vs-muted { color: #6b7280; }
.vs-muted a { color: #7c3aed; text-decoration: none; }

/* ══════════════════════════════════════════════════════════════
   MODAL (unchanged)
══════════════════════════════════════════════════════════════ */
.my-space-modal {
  position: fixed; inset: 0; z-index: 500;
  display: flex; align-items: center; justify-content: center;
}
.my-space-modal[hidden] { display: none; }
.my-space-modal__backdrop {
  position: absolute; inset: 0;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(4px);
}
.my-space-modal__panel {
  position: relative; z-index: 1;
  width: min(480px, calc(100vw - 2rem));
  padding: 1.5rem;
  max-height: calc(100dvh - 3rem);
  overflow-y: auto;
}
.my-space-modal__header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 1rem;
}
.my-space-modal__close {
  background: none; border: none; font-size: 1.5rem; cursor: pointer;
  color: #94a3b8; line-height: 1; padding: 0.25rem;
}
.my-space-form { display: flex; flex-direction: column; gap: 0.85rem; }
.my-space-form label { display: flex; flex-direction: column; gap: 0.3rem; font-size: 0.875rem; color: #94a3b8; }
.my-space-form input,
.my-space-form select,
.my-space-form textarea {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 0.6rem;
  padding: 0.55rem 0.75rem;
  font-size: 0.875rem; color: #f0e8ff; font-family: inherit;
}

/* ══════════════════════════════════════════════════════════════
   NOTICE BANNER
══════════════════════════════════════════════════════════════ */
.vs-notice {
  position: fixed; bottom: 5rem; left: 50%;
  transform: translateX(-50%);
  background: rgba(30,30,50,0.95);
  border: 1px solid rgba(139,92,246,0.4);
  border-radius: 0.75rem;
  padding: 0.75rem 1.25rem;
  font-size: 0.875rem; color: #e9d5ff;
  z-index: 400;
  backdrop-filter: blur(8px);
  animation: noticeIn 0.3s ease;
}
.vs-notice--success { border-color: rgba(74, 222, 128, 0.4); }
@keyframes noticeIn {
  from { opacity: 0; transform: translateX(-50%) translateY(8px); }
  to { opacity: 1; transform: translateX(-50%) translateY(0); }
}

/* ══════════════════════════════════════════════════════════════
   MOBILE OPTIMIZATIONS
══════════════════════════════════════════════════════════════ */
@media (max-width: 430px) {
  .vs-home { padding: 0 0.5rem 5rem; }
  .vs-welcome__name { font-size: 1.2rem; }
  .vs-quick-action { min-width: 70px; padding: 0.75rem 0.6rem; }
  .vs-quick-action__icon { font-size: 1.4rem; }
  .vs-quick-action__label { font-size: 0.65rem; }
  .vs-feed-header__title { font-size: 0.95rem; }
  .vs-post-card { padding: 0.85rem; }
  .vs-post-card__body { font-size: 0.875rem; }
}

@media (max-width: 380px) {
  .vs-mood-chip-btn { font-size: 0.82rem; padding: 0.35rem 0.7rem; }
  .vs-quests-grid { grid-template-columns: repeat(2, 1fr); }
  .vs-games-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ══════════════════════════════════════════════════════════════
   PERFORMANCE: reduce blur on less capable devices
══════════════════════════════════════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
  .vs-blob, .vs-online-dot--pulse { animation: none; }
  .vs-mood-chip-btn,
  .vs-quick-action,
  .vs-quest-chip,
  .vs-post-card { transition: none; }
}

/* Low-end: disable backdrop-filter on glass-card if needed  */
@media (max-width: 430px) {
  .glass-card { backdrop-filter: none; }
}

/* Sprint 17 — Freeform Decoration + Memory World */
.ms-room-note {
  margin: 0.35rem 0 0;
  color: var(--theme-text);
  opacity: 0.8;
  font-size: 0.78rem;
}

.ms-freeform-toolbar,
.ms-freeform-actions,
.ms-freeform-zones {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.ms-freeform-toolbar .ms-btn,
.ms-freeform-actions .ms-btn {
  min-height: 40px;
}

.ms-freeform-zones {
  margin-top: 0.75rem;
}

.ms-freeform-zone {
  border: 1px dashed var(--theme-border);
  border-radius: 999px;
  padding: 0.22rem 0.72rem;
  font-size: 0.72rem;
  color: var(--theme-text);
  opacity: 0.72;
}

.ms-profile-decor-stage {
  position: relative;
  margin-top: 0.75rem;
  min-height: 360px;
  border-radius: 0.9rem;
  border: 1px solid var(--theme-border);
  background:
    linear-gradient(180deg, rgba(255,255,255,0.08), rgba(255,255,255,0.02)),
    repeating-linear-gradient(
      90deg,
      rgba(255,255,255,0.03) 0,
      rgba(255,255,255,0.03) calc(100% / 12),
      transparent calc(100% / 12),
      transparent calc(100% / 6)
    );
  overflow: hidden;
  touch-action: none;
}

.ms-profile-decor-stage--readonly {
  min-height: 280px;
  touch-action: auto;
}

.ms-decor-node {
  position: absolute;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.75rem;
  border: 1px solid rgba(255,255,255,0.24);
  background: rgba(0,0,0,0.28);
  color: #fff;
  cursor: grab;
  user-select: none;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.ms-decor-node.is-selected {
  box-shadow: 0 0 0 2px var(--theme-accent), 0 10px 24px rgba(0,0,0,0.32);
}

.ms-decor-node:active {
  cursor: grabbing;
}

.ms-decor-node__visual {
  font-size: 1.35rem;
  pointer-events: none;
}

.ms-decor-node__delete {
  position: absolute;
  top: 0.18rem;
  right: 0.18rem;
  border: none;
  border-radius: 999px;
  width: 1.2rem;
  height: 1.2rem;
  background: rgba(0,0,0,0.5);
  color: #fff;
  cursor: pointer;
  line-height: 1;
  font-size: 0.7rem;
}

.ms-freeform-actions {
  margin-top: 0.72rem;
}

.ms-freeform-status {
  min-height: 1rem;
  font-size: 0.76rem;
  opacity: 0.85;
}

.ms-profile-decor-stage.is-reduced-motion .ms-decor-node {
  transition: none;
}

@media (max-width: 430px) {
  .ms-profile-decor-stage {
    min-height: 300px;
  }

  .ms-decor-node__visual {
    font-size: 1.15rem;
  }
}

/* Sprint 18 — Emotional interaction polish + room warmth */

/* Decoration animations and easing */
.ms-decor-node {
  will-change: transform, left, top;
}

.ms-decor-node--fresh {
  animation: decorSpawn 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes decorSpawn {
  from {
    opacity: 0;
    transform: scale(0.7) rotate(-8deg);
  }
  to {
    opacity: 1;
    transform: scale(1) rotate(0deg);
  }
}

.ms-decor-node.is-selected {
  animation: decorGlow 0.5s ease-in-out;
}

@keyframes decorGlow {
  0%, 100% {
    box-shadow: 0 0 0 2px var(--theme-accent), 0 10px 24px rgba(0,0,0,0.32);
  }
  50% {
    box-shadow: 0 0 12px 4px rgba(139, 92, 246, 0.4), 0 10px 24px rgba(0,0,0,0.32);
  }
}

/* Room warmth system — ambient animations */
.ms-room-builder,
.ms-public-room-canvas {
  position: relative;
}

.ms-room-builder::before,
.ms-public-room-canvas::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 0.9rem;
  background: 
    radial-gradient(ellipse at 20% 50%, rgba(255, 183, 77, 0.03), transparent 60%),
    radial-gradient(ellipse at 80% 50%, rgba(139, 92, 246, 0.02), transparent 60%);
  pointer-events: none;
  animation: roomAmbience 12s ease-in-out infinite;
  z-index: 0;
}

@keyframes roomAmbience {
  0%, 100% {
    opacity: 0.5;
  }
  50% {
    opacity: 0.8;
  }
}

@media (prefers-reduced-motion: reduce) {
  .ms-decor-node--fresh {
    animation: none;
  }
  .ms-decor-node.is-selected {
    animation: none;
  }
  .ms-room-builder::before,
  .ms-public-room-canvas::before {
    animation: none;
  }
}

/* Micro-animations for decoration state changes */
.ms-decor-node__delete {
  opacity: 0;
  transform: scale(0.8);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.ms-decor-node:hover .ms-decor-node__delete,
.ms-decor-node.is-selected .ms-decor-node__delete {
  opacity: 1;
  transform: scale(1);
}

/* Placement preview effect */
.ms-decor-node[data-dragging="true"] {
  opacity: 0.85;
  filter: drop-shadow(0 8px 16px rgba(139, 92, 246, 0.25));
}

/* Profile decor stage breathing */
.ms-profile-decor-stage {
  animation: stageBreathing 8s ease-in-out infinite;
}

@keyframes stageBreathing {
  0%, 100% {
    background-color: rgba(0, 0, 0, 0.28);
  }
  50% {
    background-color: rgba(0, 0, 0, 0.32);
  }
}

@media (prefers-reduced-motion: reduce) {
  .ms-profile-decor-stage {
    animation: none;
  }
}

/* Room ambient effects — warmth system */
.ms-room-spotlight-card {
  position: relative;
  transition: all 0.3s ease;
}

.ms-room-spotlight-card:hover {
  transform: translateY(-2px);
  border-color: rgba(139, 92, 246, 0.4);
}

.ms-room-spotlight-card::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 0.9rem;
  background: radial-gradient(ellipse at 30% 50%, rgba(255, 193, 7, 0.05), transparent 70%);
  pointer-events: none;
  animation: roomWarmthPulse 8s ease-in-out infinite;
}

@keyframes roomWarmthPulse {
  0%, 100% {
    opacity: 0.3;
  }
  50% {
    opacity: 0.6;
  }
}

/* Rainy room effect */
.ms-room-spotlight-card[data-mood*="rainy"]::before,
.ms-room-spotlight-card[data-atmosphere*="rain"]::before {
  content: '';
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    90deg,
    transparent,
    transparent 2px,
    rgba(100, 150, 200, 0.02) 2px,
    rgba(100, 150, 200, 0.02) 4px
  );
  animation: rainFlicker 3s ease-in-out infinite;
  pointer-events: none;
  border-radius: 0.9rem;
}

@keyframes rainFlicker {
  0%, 100% {
    opacity: 0.1;
  }
  50% {
    opacity: 0.2;
  }
}

/* Fireplace glow */
.ms-room-spotlight-card[data-lighting*="fireplace"]::after,
.ms-room-spotlight-card[data-lighting*="fire"]::after {
  animation: fireplaceGlow 4s ease-in-out infinite !important;
}

@keyframes fireplaceGlow {
  0%, 100% {
    opacity: 0.4;
    transform: scale(1);
  }
  50% {
    opacity: 0.7;
    transform: scale(1.05);
  }
}

/* Room entry transitions */
.ms-rooms-nav {
  margin: 1rem 0;
}

.ms-room-tab {
  position: relative;
  transition: all 0.2s ease;
}

.ms-room-tab:hover {
  color: var(--theme-accent);
}

.ms-room-tab--active {
  animation: activeRoomTab 0.3s ease-out;
}

@keyframes activeRoomTab {
  from {
    opacity: 0.7;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* Room atmosphere intro card */
.ms-room-atmosphere-head {
  animation: atmosphereReveal 0.5s ease-out;
}

@keyframes atmosphereReveal {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Room memory wall breathing */
.ms-room-note {
  animation: memoryNotePulse 6s ease-in-out infinite;
}

@keyframes memoryNotePulse {
  0%, 100% {
    opacity: 0.8;
  }
  50% {
    opacity: 1;
  }
}

/* Gentle profile transition */
.ms-profile-header {
  animation: profileFadeIn 0.4s ease-out;
}

@keyframes profileFadeIn {
  from {
    opacity: 0;
    transform: translateY(-4px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Scrapbook panel transitions */
.ms-bedroom-panel {
  animation: panelSlideIn 0.5s ease-out backwards;
}

.ms-bedroom-panel:nth-child(1) { animation-delay: 0.1s; }
.ms-bedroom-panel:nth-child(2) { animation-delay: 0.15s; }
.ms-bedroom-panel:nth-child(3) { animation-delay: 0.2s; }
.ms-bedroom-panel:nth-child(4) { animation-delay: 0.25s; }

@keyframes panelSlideIn {
  from {
    opacity: 0;
    transform: translateX(-8px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .ms-room-spotlight-card,
  .ms-room-spotlight-card::after,
  .ms-room-spotlight-card::before,
  .ms-room-tab,
  .ms-room-tab--active,
  .ms-room-atmosphere-head,
  .ms-room-note,
  .ms-profile-header,
  .ms-bedroom-panel {
    animation: none;
    transition: none;
  }
}

/* Sprint 19 — Room Appreciation System */

.ms-room-spotlight-card-wrapper {
  position: relative;
  display: flex;
  flex-direction: column;
}

.ms-room-appreciate-actions {
  display: flex;
  gap: 0.35rem;
  justify-content: center;
  padding: 0.5rem 0;
  opacity: 0;
  transition: opacity 0.3s ease;
  margin-top: 0.35rem;
}

.ms-room-spotlight-card-wrapper:hover .ms-room-appreciate-actions {
  opacity: 1;
}

.ms-room-appreciate-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.2s ease;
  opacity: 0.7;
  touch-action: manipulation;
}

.ms-room-appreciate-btn:hover {
  background: rgba(139, 92, 246, 0.15);
  border-color: rgba(139, 92, 246, 0.3);
  opacity: 1;
  transform: scale(1.15);
}

.ms-room-appreciate-btn:active {
  transform: scale(0.95);
}

.ms-room-appreciate-btn.room-appreciated {
  background: rgba(139, 92, 246, 0.25);
  border-color: rgba(139, 92, 246, 0.5);
  opacity: 1;
}

@keyframes roomAppreciationPulse {
  0% {
    transform: scale(0.6) rotate(-180deg);
    opacity: 0;
  }
  50% {
    transform: scale(1.2);
  }
  100% {
    transform: scale(1) rotate(0deg);
    opacity: 1;
  }
}

@media (prefers-reduced-motion: reduce) {
  .ms-room-appreciate-actions,
  .ms-room-appreciate-btn {
    animation: none;
    transition: none;
  }
}

/* ═══════════════════════════════════════════════════════════════════════════
   Sprint 20 — Cozy Layering + Fullscreen Room Experience
   Phase 7B: Reduce cognitive load, increase emotional immersion
   ═══════════════════════════════════════════════════════════════════════════ */

/* ── Cozy Accordion Sections ──────────────────────────────────────────────── */

.cozy-section {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 1rem;
  margin-bottom: 0.75rem;
  overflow: hidden;
  transition: box-shadow 0.25s ease, background 0.25s ease;
}

.cozy-section:hover {
  background: rgba(255, 255, 255, 0.04);
}

.cozy-section:focus-within {
  box-shadow: 0 0 0 2px rgba(139, 92, 246, 0.25);
}

.cozy-section--expanded {
  background: rgba(139, 92, 246, 0.04);
  border-color: rgba(139, 92, 246, 0.15);
}

.cozy-section__toggle {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 1rem 1.15rem;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--theme-text, #e2d9f3);
  text-align: left;
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.4;
  transition: background 0.2s ease;
  -webkit-tap-highlight-color: transparent;
}

.cozy-section__toggle:hover {
  background: rgba(255, 255, 255, 0.04);
}

.cozy-section__toggle:focus-visible {
  outline: 2px solid rgba(139, 92, 246, 0.6);
  outline-offset: -2px;
}

.cozy-section__icon {
  font-size: 1.1rem;
  flex-shrink: 0;
  line-height: 1;
}

.cozy-section__title {
  flex: 1;
  min-width: 0;
}

.cozy-section__subtitle {
  display: block;
  font-size: 0.72rem;
  font-weight: 400;
  opacity: 0.55;
  margin-top: 0.1rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cozy-section__chevron {
  font-size: 0.7rem;
  opacity: 0.5;
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  flex-shrink: 0;
  margin-left: 0.25rem;
}

.cozy-section--expanded .cozy-section__chevron {
  transform: rotate(180deg);
  opacity: 0.8;
}

.cozy-section__body {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.45s cubic-bezier(0, 0, 0.2, 1);
}

.cozy-section--expanded .cozy-section__body {
  max-height: 9999px;
}

.cozy-section__inner {
  padding: 0 1.15rem 1.15rem;
}

/* ── Fullscreen Room Mode ─────────────────────────────────────────────────── */

.room-fullscreen-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.65rem 1.1rem;
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.25), rgba(236, 72, 153, 0.15));
  border: 1px solid rgba(139, 92, 246, 0.35);
  border-radius: 0.75rem;
  color: var(--theme-text, #e2d9f3);
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.25s ease;
  white-space: nowrap;
  -webkit-tap-highlight-color: transparent;
}

.room-fullscreen-btn:hover {
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.4), rgba(236, 72, 153, 0.25));
  border-color: rgba(139, 92, 246, 0.55);
  transform: translateY(-1px);
  box-shadow: 0 4px 20px rgba(139, 92, 246, 0.2);
}

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

/* Fullscreen Overlay */
.room-fullscreen-overlay {
  position: fixed;
  inset: 0;
  z-index: 9990;
  background: var(--theme-bg, #0d0d1a);
  display: flex;
  flex-direction: column;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.45s ease;
  overflow: hidden;
}

.room-fullscreen-overlay.is-active {
  opacity: 1;
  pointer-events: all;
}

/* Room atmosphere layer inside fullscreen */
.room-fullscreen-atmosphere {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
}

/* Ambient particles */
.room-ambient-particles {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 1;
}

.room-particle {
  position: absolute;
  border-radius: 50%;
  animation: roomParticleDrift var(--p-dur, 14s) ease-in-out infinite;
  animation-delay: var(--p-delay, 0s);
  opacity: var(--p-opacity, 0.35);
  background: var(--p-color, rgba(139, 92, 246, 0.4));
  width: var(--p-size, 6px);
  height: var(--p-size, 6px);
  left: var(--p-x, 50%);
  top: var(--p-y, 50%);
  will-change: transform, opacity;
}

@keyframes roomParticleDrift {
  0%, 100% {
    transform: translate(0, 0) scale(1);
    opacity: var(--p-opacity, 0.35);
  }
  33% {
    transform: translate(var(--p-dx1, 25px), var(--p-dy1, -18px)) scale(1.15);
    opacity: calc(var(--p-opacity, 0.35) * 1.4);
  }
  66% {
    transform: translate(var(--p-dx2, -18px), var(--p-dy2, 12px)) scale(0.85);
    opacity: calc(var(--p-opacity, 0.35) * 0.7);
  }
}

/* Glow zones inside fullscreen */
.room-glow-zone {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  animation: roomGlowPulse var(--glow-dur, 6s) ease-in-out infinite alternate;
  z-index: 0;
}

@keyframes roomGlowPulse {
  from { opacity: var(--glow-opacity-from, 0.12); transform: scale(1); }
  to { opacity: var(--glow-opacity-to, 0.22); transform: scale(1.08); }
}

/* Room fullscreen content area */
.room-fullscreen-content {
  position: relative;
  z-index: 2;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  overflow-y: auto;
}

/* Room fullscreen header bar */
.room-fullscreen-header {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.25rem;
  background: linear-gradient(to bottom, rgba(0, 0, 0, 0.6), transparent);
}

.room-fullscreen-title {
  color: rgba(255, 255, 255, 0.9);
  font-size: 1.1rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.room-fullscreen-exit {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.5rem 0.9rem;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 2rem;
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.82rem;
  cursor: pointer;
  transition: all 0.2s ease;
  -webkit-tap-highlight-color: transparent;
}

.room-fullscreen-exit:hover {
  background: rgba(0, 0, 0, 0.6);
  color: white;
}

/* Immersive decor stage inside fullscreen */
.room-fullscreen-stage {
  position: relative;
  z-index: 3;
  width: 100%;
  max-width: 900px;
  min-height: 400px;
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 1.5rem;
  backdrop-filter: blur(4px);
  padding: 1.5rem;
  margin-top: 4rem;
  overflow: hidden;
}

/* Draggable decor nodes in fullscreen */
.room-fullscreen-decor-node {
  position: absolute;
  cursor: grab;
  user-select: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  touch-action: none;
}

.room-fullscreen-decor-node:hover {
  transform: scale(1.08);
  filter: drop-shadow(0 0 12px rgba(139, 92, 246, 0.5));
}

.room-fullscreen-decor-node:active,
.room-fullscreen-decor-node.is-dragging {
  cursor: grabbing;
  transform: scale(1.12);
  filter: drop-shadow(0 0 16px rgba(139, 92, 246, 0.65));
  z-index: 100;
}

/* Drag ghost preview */
.room-drag-ghost {
  position: fixed;
  pointer-events: none;
  z-index: 9999;
  opacity: 0.55;
  transform: scale(1.15);
  filter: drop-shadow(0 4px 16px rgba(139, 92, 246, 0.6));
  transition: none;
}

/* Magnetic snap indicator */
.room-snap-indicator {
  position: absolute;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: rgba(139, 92, 246, 0.8);
  box-shadow: 0 0 12px rgba(139, 92, 246, 0.6);
  pointer-events: none;
  z-index: 50;
  transform: translate(-50%, -50%);
  animation: snapPop 0.25s ease-out;
}

@keyframes snapPop {
  from { transform: translate(-50%, -50%) scale(2); opacity: 0; }
  to { transform: translate(-50%, -50%) scale(1); opacity: 1; }
}

/* Memory wall inside fullscreen */
.room-fullscreen-memory-wall {
  position: absolute;
  bottom: 1rem;
  left: 1.5rem;
  right: 1.5rem;
  z-index: 4;
  display: flex;
  gap: 0.75rem;
  overflow-x: auto;
  padding-bottom: 0.5rem;
  scrollbar-width: thin;
}

.room-fullscreen-memory-note {
  flex-shrink: 0;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 0.75rem;
  padding: 0.65rem 1rem;
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.8);
  max-width: 200px;
  animation: memoryNoteReveal 0.5s ease-out;
  animation-fill-mode: both;
}

@keyframes memoryNoteReveal {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Presence markers inside fullscreen room */
.room-presence-pulse {
  position: absolute;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(139, 92, 246, 0.7);
  box-shadow: 0 0 8px rgba(139, 92, 246, 0.5);
  animation: presencePulse 3s ease-in-out infinite;
  z-index: 5;
}

@keyframes presencePulse {
  0%, 100% { transform: scale(1); opacity: 0.7; }
  50% { transform: scale(1.4); opacity: 1; }
}

/* Room entry animation */
@keyframes roomEntryFade {
  from { opacity: 0; transform: scale(0.97); }
  to { opacity: 1; transform: scale(1); }
}

.room-fullscreen-overlay.is-active .room-fullscreen-stage {
  animation: roomEntryFade 0.5s ease-out 0.1s both;
}

/* ── Tactile Decoration UX ────────────────────────────────────────────────── */

.ms-decor-node:hover .ms-decor-node__visual {
  box-shadow: 0 0 14px rgba(139, 92, 246, 0.4);
  transition: box-shadow 0.2s ease;
}

.ms-decor-node.is-placing {
  animation: decorPlaceAnim 0.3s ease-out;
}

@keyframes decorPlaceAnim {
  0% { transform: scale(0.8) rotate(-5deg); opacity: 0.6; }
  60% { transform: scale(1.05) rotate(1deg); opacity: 1; }
  100% { transform: scale(1) rotate(0deg); opacity: 1; }
}

/* Shelf attachment point */
.ms-freeform-zone[data-zone="shelf"] {
  background: linear-gradient(to bottom, rgba(139, 92, 246, 0.06), rgba(139, 92, 246, 0.02));
  border: 1px dashed rgba(139, 92, 246, 0.25);
  border-bottom: 3px solid rgba(139, 92, 246, 0.3);
  position: relative;
}

.ms-freeform-zone[data-zone="shelf"]::after {
  content: "shelf";
  position: absolute;
  bottom: -1.4rem;
  left: 50%;
  transform: translateX(-50%);
  font-size: 0.65rem;
  opacity: 0.4;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--theme-text);
}

/* Poster wall placement */
.ms-freeform-zone[data-zone="wall"] {
  background: linear-gradient(145deg, rgba(236, 72, 153, 0.04), rgba(139, 92, 246, 0.04));
  border: 1px dashed rgba(236, 72, 153, 0.2);
}

/* ── Visual Hierarchy Refactor ────────────────────────────────────────────── */

/* Page breathing room */
.myspace-page--layered {
  max-width: 1100px;
  margin: 0 auto;
  padding: 1rem 1.25rem 3rem;
}

/* Layered page header */
.cozy-page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.cozy-page-header__title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--theme-text, #e2d9f3);
  font-size: 1.45rem;
  font-weight: 700;
  margin: 0;
}

.cozy-page-header__sub {
  color: var(--theme-text, #e2d9f3);
  opacity: 0.6;
  font-size: 0.84rem;
  margin: 0.2rem 0 0;
}

.cozy-page-header__actions {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  align-items: center;
}

/* Layered 2-column layout */
.cozy-customize-grid {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 1.5rem;
  align-items: start;
}

/* Right sidebar sticky */
.cozy-customize-sidebar {
  position: sticky;
  top: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

/* ── Room Immersion Depth ─────────────────────────────────────────────────── */

/* Animated ambient decor loops */
.room-fullscreen-ambient-loop {
  position: absolute;
  pointer-events: none;
  will-change: transform;
}

.room-ambient-float {
  animation: ambientFloat var(--float-dur, 8s) ease-in-out infinite;
  animation-delay: var(--float-delay, 0s);
}

@keyframes ambientFloat {
  0%, 100% { transform: translateY(0px) rotate(0deg); }
  50% { transform: translateY(var(--float-y, -8px)) rotate(var(--float-rot, 2deg)); }
}

/* Nighttime mode overlay */
.room-nighttime-overlay {
  position: absolute;
  inset: 0;
  background: rgba(5, 2, 18, 0.35);
  pointer-events: none;
  z-index: 1;
  opacity: 0;
  transition: opacity 1s ease;
}

.room-fullscreen-overlay[data-room-time="night"] .room-nighttime-overlay {
  opacity: 1;
}

/* Scrapbook wall in fullscreen */
.room-scrapbook-wall {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 0.75rem;
  padding: 1rem 0;
}

.room-scrapbook-card {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 0.65rem;
  padding: 0.7rem;
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.75);
  cursor: pointer;
  transition: all 0.2s ease;
  animation: scrapbookCardReveal 0.4s ease-out both;
}

.room-scrapbook-card:nth-child(even) {
  transform: rotate(0.8deg);
}

.room-scrapbook-card:nth-child(3n) {
  transform: rotate(-0.6deg);
}

.room-scrapbook-card:hover {
  background: rgba(139, 92, 246, 0.12);
  transform: rotate(0deg) scale(1.04);
  border-color: rgba(139, 92, 246, 0.35);
}

@keyframes scrapbookCardReveal {
  from { opacity: 0; transform: rotate(2deg) translateY(10px); }
  to { opacity: 1; }
}

/* ── Social Room Feel ─────────────────────────────────────────────────────── */

/* Friends hanging out indicator */
.room-social-traces {
  position: absolute;
  bottom: 1.25rem;
  right: 1.25rem;
  z-index: 6;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  align-items: flex-end;
}

.room-vibe-pulse {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.35rem 0.75rem;
  background: rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 2rem;
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.75);
  animation: vibePulseIn 0.4s ease-out both;
}

.room-vibe-pulse__dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #a78bfa;
  animation: presencePulse 2.5s ease-in-out infinite;
}

/* Sprint 25 — emotional pacing polish */
:root {
  --vybe-calm-transition: 0.32s;
  --vybe-calm-transition-slow: 0.55s;
  --vybe-room-glow-from: 0.09;
  --vybe-room-glow-to: 0.16;
}

.vs-post-card,
.vs-quick-action,
.ms-btn,
.ms-room-node {
  transition-duration: var(--vybe-calm-transition) !important;
}

.vs-home__blobs .vs-blob,
.ms-preview-stage__glow,
.room-vibe-pulse,
.room-presence-pulse {
  animation-duration: 12s !important;
}

.room-glow-zone {
  --glow-opacity-from: var(--vybe-room-glow-from);
  --glow-opacity-to: var(--vybe-room-glow-to);
}

.vs-online-dot--pulse,
.room-vibe-pulse__dot {
  animation-duration: 4.6s !important;
}

.vs-inbox-chip,
.vs-story-bubble__inner,
.ms-room-memory-note {
  transition-duration: var(--vybe-calm-transition-slow) !important;
}

@keyframes vibePulseIn {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ── Reduced Motion Compliance ────────────────────────────────────────────── */

@media (prefers-reduced-motion: reduce) {
  .cozy-section__body,
  .cozy-section__chevron,
  .room-fullscreen-overlay,
  .room-particle,
  .room-glow-zone,
  .room-fullscreen-decor-node,
  .room-ambient-float,
  .room-scrapbook-card,
  .room-vibe-pulse {
    animation: none !important;
    transition: none !important;
  }

  .cozy-section__body {
    max-height: none;
    overflow: visible;
  }
}

/* Sprint 26 — My Space three-rail home conversion */
.vs-home {
  max-width: 1280px;
  padding: 0 1rem 5rem;
}

.vs-home-shell {
  position: relative;
  z-index: 1;
}

.vs-home-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.1rem;
  margin-bottom: 1rem;
}

.vs-home-hero__identity {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.vs-home-hero__avatar {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
}

.vs-home-hero__eyebrow {
  margin: 0;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #94a3b8;
}

.vs-home-hero__title {
  margin: 0.1rem 0;
  color: #f0e8ff;
  font-size: 1.35rem;
}

.vs-home-hero__sub,
.vs-home-hero__warmth {
  margin: 0;
  color: #c4b5fd;
  font-size: 0.84rem;
}

.vs-home-hero__signals {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.35rem;
}

.vs-home-hero__counts {
  display: flex;
  gap: 0.45rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.vs-home-hero__counts a {
  text-decoration: none;
  font-size: 0.75rem;
  color: #c4b5fd;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 999px;
  padding: 0.2rem 0.55rem;
}

.vs-home-grid {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr) 300px;
  gap: 1rem;
  align-items: start;
}

.vs-left-rail,
.vs-center-rail,
.vs-right-rail {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
}

.vs-room-card {
  padding: 1rem;
}

.vs-room-card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.7rem;
}

.vs-room-card__head h2 {
  margin: 0;
  font-size: 0.95rem;
  color: #e9d5ff;
}

.vs-room-card__head a {
  font-size: 0.8rem;
  color: #8b5cf6;
  text-decoration: none;
}

.vs-room-card__line {
  margin: 0.45rem 0 0.75rem;
  font-size: 0.82rem;
  color: #94a3b8;
}

.vs-room-card__scene {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.45rem;
  margin-bottom: 0.8rem;
}

.vs-room-card__item {
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 0.6rem;
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.03);
}

.vs-stories-wrap {
  padding: 0.4rem 0.25rem;
}

.vs-attention-strip {
  padding: 0.9rem 1rem;
}

.vs-attention-strip h3 {
  margin: 0 0 0.55rem;
  font-size: 0.9rem;
  color: #e9d5ff;
}

.vs-late-night {
  padding: 0.85rem 1rem;
}

.vs-late-night__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.7rem;
}

.vs-late-night__head h3 {
  margin: 0;
  color: #e9d5ff;
  font-size: 0.95rem;
}

.vs-late-night__head a {
  color: #8b5cf6;
  text-decoration: none;
  font-size: 0.8rem;
}

.vs-late-night p {
  margin: 0.45rem 0 0;
  color: #94a3b8;
  font-size: 0.82rem;
  line-height: 1.55;
}

.vs-inbox-stack,
.vs-presence-card,
.vs-right-rail .vs-games-card,
.vs-right-rail .vs-discover-card {
  padding: 0.9rem 1rem;
}

.vs-inbox-stack h3 {
  margin: 0 0 0.6rem;
  font-size: 0.9rem;
  color: #e9d5ff;
}

@media (max-width: 1080px) {
  .vs-home-grid {
    grid-template-columns: 240px minmax(0, 1fr);
  }

  .vs-right-rail {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.9rem;
  }
}

@media (max-width: 760px) {
  .vs-home {
    padding: 0 0.65rem 5rem;
  }

  .vs-home-hero {
    flex-direction: column;
    align-items: stretch;
  }

  .vs-home-hero__signals {
    align-items: flex-start;
  }

  .vs-home-grid {
    grid-template-columns: 1fr;
  }

  .vs-right-rail {
    grid-template-columns: 1fr;
  }

  .vs-room-card__scene {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Sprint 26.5 — Immersion layer: feels alive */
body[data-time-of-day='morning'] .vs-home {
  background: radial-gradient(ellipse at 20% 0%, #2a1f46 0%, #111325 56%, #080911 100%);
}

body[data-time-of-day='afternoon'] .vs-home {
  background: radial-gradient(ellipse at 20% 0%, #2c2b4e 0%, #111828 56%, #070a13 100%);
}

body[data-time-of-day='evening'] .vs-home {
  background: radial-gradient(ellipse at 20% 0%, #251438 0%, #0d1020 56%, #06070d 100%);
}

body[data-time-of-day='late-night'] .vs-home {
  background: radial-gradient(ellipse at 20% 0%, #160c2b 0%, #070a14 60%, #03050a 100%);
}

.vs-home,
.vs-home .glass-card,
.vs-home .vs-blob {
  transition: background 0.8s ease, border-color 0.45s ease, box-shadow 0.45s ease, opacity 0.45s ease;
}

.vs-home-memory-chip {
  border: 1px dashed rgba(196, 181, 253, 0.45);
  border-radius: 999px;
  padding: 0.22rem 0.65rem;
  color: #ddd6fe;
  font-size: 0.72rem;
}

.vs-ambient-layer {
  pointer-events: none;
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
}

.vs-ambient-dot {
  position: absolute;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: rgba(196, 181, 253, 0.38);
  animation: ambientDotFloat linear infinite;
}

@keyframes ambientDotFloat {
  0% { transform: translate3d(0, 0, 0) scale(0.9); opacity: 0.2; }
  40% { opacity: 0.45; }
  100% { transform: translate3d(18px, -24px, 0) scale(1.15); opacity: 0.1; }
}

.vs-shooting-star {
  position: absolute;
  width: 120px;
  height: 1.5px;
  background: linear-gradient(90deg, rgba(255,255,255,0), rgba(253, 230, 138, 0.8), rgba(255,255,255,0));
  animation: shootingStar 1.3s ease forwards;
}

@keyframes shootingStar {
  from { transform: translate3d(-20px, -10px, 0) rotate(-12deg); opacity: 0; }
  20% { opacity: 0.85; }
  to { transform: translate3d(140px, 55px, 0) rotate(-12deg); opacity: 0; }
}

.vs-room-card__status-bubble {
  display: inline-flex;
  align-items: center;
  gap: 0.38rem;
  padding: 0.25rem 0.6rem;
  border-radius: 0.75rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.04);
  margin-bottom: 0.65rem;
  font-size: 0.75rem;
  color: #d8d3e8;
}

.vs-mini-space-meta {
  display: grid;
  gap: 0.38rem;
  margin-bottom: 0.6rem;
}

.vs-mini-space-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.1);
  padding: 0.18rem 0.55rem;
  font-size: 0.72rem;
  color: #c4b5fd;
}

.vs-mini-shelf {
  display: flex;
  gap: 0.45rem;
  margin-bottom: 0.65rem;
}

.vs-mini-shelf span {
  min-width: 30px;
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.5rem;
  border: 1px solid rgba(255,255,255,0.1);
  background: rgba(255,255,255,0.04);
}

.vs-mini-customize summary {
  cursor: pointer;
  color: #a78bfa;
  font-size: 0.76rem;
  text-transform: lowercase;
  margin-bottom: 0.45rem;
}

.vs-mini-customize__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.45rem;
}

.vs-mini-customize label {
  font-size: 0.66rem;
  color: #94a3b8;
  text-transform: lowercase;
  display: grid;
  gap: 0.22rem;
}

.vs-mini-customize select {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 0.45rem;
  color: #f0e8ff;
  padding: 0.3rem 0.45rem;
  font-size: 0.72rem;
}

#miniMySpaceCard[data-accent='cyan'] {
  border-color: rgba(34, 211, 238, 0.42);
}

#miniMySpaceCard[data-accent='sunset'] {
  border-color: rgba(251, 146, 60, 0.42);
}

#miniMySpaceCard[data-accent='mint'] {
  border-color: rgba(52, 211, 153, 0.42);
}

#miniMySpaceCard[data-wallpaper='mesh'] .vs-room-card__scene {
  background-image: linear-gradient(45deg, rgba(255,255,255,0.04) 25%, transparent 25%), linear-gradient(-45deg, rgba(255,255,255,0.04) 25%, transparent 25%);
  background-size: 12px 12px;
  border-radius: 0.7rem;
  padding: 0.3rem;
}

#miniMySpaceCard[data-wallpaper='stars'] .vs-room-card__scene {
  background: radial-gradient(circle at 20% 20%, rgba(255,255,255,0.25) 1px, transparent 1px) 0 0 / 20px 20px, rgba(255,255,255,0.02);
  border-radius: 0.7rem;
  padding: 0.3rem;
}

#miniMySpaceCard[data-wallpaper='rain'] .vs-room-card__scene {
  background: repeating-linear-gradient(105deg, rgba(191, 219, 254, 0.12), rgba(191, 219, 254, 0.12) 2px, transparent 2px, transparent 8px);
  border-radius: 0.7rem;
  padding: 0.3rem;
}

.vs-post-card__type-chip {
  display: inline-flex;
  margin-bottom: 0.5rem;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.12);
  padding: 0.14rem 0.55rem;
  font-size: 0.66rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: #a78bfa;
}

.vs-post-card--music {
  background: linear-gradient(135deg, rgba(34,211,238,0.12), rgba(255,255,255,0.03));
}

.vs-post-card--mood {
  background: linear-gradient(135deg, rgba(244,114,182,0.14), rgba(255,255,255,0.03));
}

.vs-post-card--game {
  background: linear-gradient(135deg, rgba(251,191,36,0.12), rgba(255,255,255,0.03));
}

.vs-mixed-card {
  padding: 0.95rem 1rem;
  border-style: dashed;
}

.vs-mixed-card__eyebrow {
  margin: 0;
  font-size: 0.66rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #94a3b8;
}

.vs-mixed-card h3 {
  margin: 0.35rem 0 0.25rem;
  color: #f5f3ff;
  font-size: 0.94rem;
}

.vs-mixed-card p {
  margin: 0;
  font-size: 0.82rem;
  color: #c4b5fd;
  line-height: 1.5;
}

.vs-mixed-card a {
  display: inline-flex;
  margin-top: 0.45rem;
  color: #a78bfa;
  text-decoration: none;
  font-size: 0.76rem;
}

.vs-late-night {
  position: relative;
  overflow: hidden;
}

.vs-late-night::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(140deg, rgba(139, 92, 246, 0.08), rgba(34, 211, 238, 0.04));
  pointer-events: none;
}

.vs-late-night__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0.55rem;
}

.vs-late-night__chips span {
  font-size: 0.72rem;
  color: #c4b5fd;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  padding: 0.16rem 0.52rem;
}

.vs-live-activity,
.vs-sound-card {
  position: relative;
  overflow: hidden;
}

.vs-live-activity__head,
.vs-sound-card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  margin-bottom: 0.5rem;
}

.vs-live-activity h3,
.vs-sound-card h3 {
  margin: 0;
  font-size: 0.9rem;
  color: #e9d5ff;
}

.vs-live-activity__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #4ade80;
  animation: liveDotPulse 2.1s ease-in-out infinite;
}

@keyframes liveDotPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(74, 222, 128, 0.4); }
  50% { box-shadow: 0 0 0 7px rgba(74, 222, 128, 0); }
}

.vs-live-activity__line {
  margin: 0;
  color: #d8d3e8;
  font-size: 0.83rem;
  line-height: 1.45;
}

.vs-live-activity__sub {
  margin-top: 0.22rem;
  color: #94a3b8;
  font-size: 0.72rem;
}

.vs-sound-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  color: #c4b5fd;
  font-size: 0.74rem;
}

.vs-sound-card p {
  margin: 0;
  color: #94a3b8;
  font-size: 0.75rem;
  line-height: 1.4;
}

.vs-post-card,
.vs-room-card,
.vs-live-activity,
.vs-games-card {
  transform-style: preserve-3d;
}

.vs-home-grid .glass-card:hover {
  box-shadow: 0 12px 32px rgba(3, 4, 16, 0.45);
}

@media (max-width: 760px) {
  .vs-mini-customize__grid {
    grid-template-columns: 1fr;
  }

  .vs-live-activity,
  .vs-sound-card {
    padding: 0.82rem 0.9rem;
  }

  .vs-post-card__type-chip {
    font-size: 0.62rem;
  }
}

@media (max-width: 760px) {
  .vs-mini-customize__grid {
    grid-template-columns: 1fr;
  }

  .vs-live-activity,
  .vs-sound-card {
    padding: 0.82rem 0.9rem;
  }

  .vs-post-card__type-chip {
    font-size: 0.62rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .vs-ambient-dot,
  .vs-shooting-star,
  .vs-live-activity__dot {
    animation: none !important;
  }

  .vs-home,
  .vs-home .glass-card,
  .vs-home .vs-blob,
  .vs-post-card,
  .vs-room-card,
  .vs-live-activity,
  .vs-games-card {
    transition: none !important;
    transform: none !important;
  }
}

/* ══════════════════════════════════════════════════════════════
   PHASE P — Persistent Identity + Shared Presence
══════════════════════════════════════════════════════════════ */

/* ── Room card wallpaper + lighting system ──────────────── */
.vs-room-card {
  position: relative;
  overflow: hidden;
}

.vs-room-card__wallpaper {
  position: absolute;
  inset: 0;
  z-index: 0;
  border-radius: 1rem;
  pointer-events: none;
  opacity: 0.18;
  transition: opacity 0.5s ease, background 0.6s ease;
}

.vs-room-card > * {
  position: relative;
  z-index: 1;
}

/* Wallpaper variants */
.vs-wp--aurora .vs-room-card__wallpaper {
  background: linear-gradient(135deg, #6d28d9 0%, #0ea5e9 50%, #10b981 100%);
  opacity: 0.22;
}
.vs-wp--mesh .vs-room-card__wallpaper {
  background: radial-gradient(circle at 20% 50%, #7c3aed 0%, transparent 50%),
              radial-gradient(circle at 80% 20%, #0891b2 0%, transparent 45%),
              radial-gradient(circle at 60% 80%, #9d174d 0%, transparent 40%);
  opacity: 0.2;
}
.vs-wp--stars .vs-room-card__wallpaper {
  background: radial-gradient(ellipse at center, #1e1b4b 0%, #0f172a 100%);
  opacity: 0.6;
}
.vs-wp--rain .vs-room-card__wallpaper {
  background: linear-gradient(180deg, #1e3a5f 0%, #0c1a2e 100%);
  opacity: 0.4;
}
.vs-wp--vapor .vs-room-card__wallpaper {
  background: linear-gradient(135deg, #ff6eb4 0%, #8040ff 40%, #00d4ff 100%);
  opacity: 0.22;
}
.vs-wp--forest .vs-room-card__wallpaper {
  background: linear-gradient(180deg, #052e16 0%, #14532d 60%, #1a2e05 100%);
  opacity: 0.35;
}
.vs-wp--city .vs-room-card__wallpaper {
  background: linear-gradient(180deg, #0f0f23 0%, #1e0533 50%, #0a0a1a 100%);
  opacity: 0.5;
}
.vs-wp--space .vs-room-card__wallpaper {
  background: radial-gradient(ellipse at 60% 40%, #1e1b4b 0%, #0f0f1f 70%),
              radial-gradient(circle at 20% 80%, #312e81 0%, transparent 40%);
  opacity: 0.45;
}

/* Lighting glow overlay */
.vs-room-lighting-glow {
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 80px;
  pointer-events: none;
  z-index: 0;
  border-radius: 1rem 1rem 0 0;
  transition: background 0.6s ease;
}

/* Lighting accent on card border */
.vs-light--warm  { border-color: rgba(251, 146,  60, 0.3); box-shadow: 0 0 20px -6px #ff9a3c22 inset; }
.vs-light--cool  { border-color: rgba( 56, 189, 248, 0.3); box-shadow: 0 0 20px -6px #38bdf822 inset; }
.vs-light--neon  { border-color: rgba(244, 114, 182, 0.4); box-shadow: 0 0 20px -6px #f472b633 inset; }
.vs-light--sunset{ border-color: rgba(251, 146,  60, 0.4); box-shadow: 0 0 20px -6px #fb923c33 inset; }
.vs-light--midnight { border-color: rgba(129, 140, 248, 0.4); box-shadow: 0 0 20px -6px #818cf833 inset; }

/* Accent color overrides */
.vs-accent--violet { --room-accent: #8b5cf6; }
.vs-accent--cyan   { --room-accent: #22d3ee; }
.vs-accent--sunset { --room-accent: #fb923c; }
.vs-accent--mint   { --room-accent: #34d399; }
.vs-accent--rose   { --room-accent: #fb7185; }
.vs-accent--gold   { --room-accent: #fbbf24; }

/* Room identity flair row */
.vs-room-card__identity-flair {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.55rem 1rem 0.25rem;
  position: relative;
}

.vs-room-flair-avatar {
  width: 34px; height: 34px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.2rem;
  box-shadow: 0 0 0 2px rgba(255,255,255,0.15);
  flex-shrink: 0;
}

.vs-room-flair-labels {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
}

.vs-room-flair-name {
  font-size: 0.82rem;
  font-weight: 600;
  color: rgba(255,255,255,0.9);
  line-height: 1.2;
}

.vs-room-flair-level {
  font-size: 0.67rem;
  color: rgba(255,255,255,0.45);
  font-variant-numeric: tabular-nums;
}

/* Room scene items */
.vs-room-card__item {
  font-size: 1.4rem;
  cursor: default;
  display: inline-block;
  transition: transform 0.2s ease;
}

.vs-room-card__item:hover { transform: scale(1.2) rotate(-4deg); }

.vs-room-card__item--unlockable {
  opacity: 0.35;
  filter: grayscale(60%);
}

/* Collectible shelf badges */
.vs-collectible-badge {
  font-size: 1.25rem;
  display: inline-block;
  transition: transform 0.18s ease;
  cursor: default;
  filter: drop-shadow(0 1px 3px rgba(0,0,0,0.35));
}

.vs-collectible-badge:hover { transform: scale(1.25) translateY(-2px); }

.vs-collectible-badge--locked {
  opacity: 0.3;
  filter: grayscale(1);
}

/* Sticker wall */
.vs-sticker-wall {
  position: relative;
  height: 56px;
  margin: 0.4rem 0;
  pointer-events: none;
}

[data-editable="1"].vs-sticker-wall {
  pointer-events: all;
}

.vs-sticker {
  position: absolute;
  font-size: 1.3rem;
  user-select: none;
  line-height: 1;
  transition: transform 0.15s ease;
  cursor: default;
  filter: drop-shadow(0 1px 4px rgba(0,0,0,0.4));
}

[data-editable="1"] .vs-sticker:hover {
  transform: scale(1.2) rotate(5deg);
}

/* ── Since-you-were-away banner ─────────────────────────── */
.vs-since-away {
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
  background: rgba(139, 92, 246, 0.09);
  border: 1px solid rgba(139, 92, 246, 0.22);
  border-radius: 0.7rem;
  padding: 0.55rem 0.75rem;
  margin-top: 0.5rem;
  font-size: 0.78rem;
  line-height: 1.5;
}

.vs-since-away__icon {
  font-size: 1rem;
  flex-shrink: 0;
  margin-top: 0.05rem;
}

.vs-since-away__lines {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  color: rgba(255,255,255,0.75);
}

/* ── Weather/atmosphere chip ───────────────────────────── */
.vs-weather-chip {
  font-size: 0.72rem;
  padding: 0.2rem 0.6rem;
  border-radius: 99px;
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.12);
  color: rgba(255,255,255,0.65);
}

/* Seasonal atmosphere transitions */
.vs-home-shell.weather-winter .vs-home-hero { border-color: rgba(147, 197, 253, 0.25); }
.vs-home-shell.weather-spring .vs-home-hero { border-color: rgba(244, 114, 182, 0.2); }
.vs-home-shell.weather-summer .vs-home-hero { border-color: rgba(251, 191, 36, 0.2); }
.vs-home-shell.weather-autumn .vs-home-hero { border-color: rgba(251, 146, 60, 0.25); }
.vs-home-shell.weather-night  { background: rgba(5, 5, 20, 0.4); }

/* Seasonal particles */
.vs-season-particle {
  position: absolute;
  pointer-events: none;
  animation: seasonFall 10s linear forwards;
  top: -5%;
}

@keyframes seasonFall {
  0%   { transform: translateY(-20px) rotate(0deg); opacity: 0; }
  10%  { opacity: 1; }
  90%  { opacity: 0.8; }
  100% { transform: translateY(110vh) rotate(360deg); opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .vs-season-particle { display: none; }
}

/* ── Presence clusters ──────────────────────────────────── */
.vs-presence-clusters {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  padding: 0.5rem 0;
}

.vs-presence-cluster {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.35rem 0.5rem;
  border-radius: 0.6rem;
  transition: background 0.2s ease;
}

.vs-presence-cluster:hover {
  background: rgba(255,255,255,0.05);
}

.vs-presence-cluster__avatar-link {
  position: relative;
  flex-shrink: 0;
  text-decoration: none;
}

.vs-presence-avatar {
  width: 30px; height: 30px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem;
}

.vs-online-pulse {
  position: absolute;
  bottom: -1px; right: -1px;
  width: 9px; height: 9px;
  border-radius: 50%;
  background: #4ade80;
  border: 2px solid #06090f;
  box-shadow: 0 0 6px #4ade80;
  animation: onlinePulse 2s ease-in-out infinite;
}

@keyframes onlinePulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%       { opacity: 0.7; transform: scale(1.2); }
}

.vs-presence-cluster__info {
  flex: 1;
  min-width: 0;
}

.vs-presence-cluster__name {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: rgba(255,255,255,0.88);
  text-decoration: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.vs-presence-cluster__activity {
  display: block;
  font-size: 0.68rem;
  color: rgba(255,255,255,0.42);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.vs-presence-cluster--online .vs-presence-cluster__activity {
  color: rgba(74, 222, 128, 0.7);
}

.vs-presence-empty {
  font-size: 0.75rem;
  color: rgba(255,255,255,0.38);
  line-height: 1.5;
  padding: 0.25rem 0.5rem;
}

/* Floating presence layer */
.vs-floating-presence {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.75rem;
  padding-top: 0.6rem;
  border-top: 1px solid rgba(255,255,255,0.06);
  min-height: 28px;
}

.vs-fp-bubble {
  width: 28px; height: 28px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.95rem;
  box-shadow: 0 0 8px -2px currentColor;
  opacity: 0.7;
  cursor: default;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.vs-fp-bubble:hover {
  opacity: 1;
  transform: scale(1.15);
}

/* ── World presence bubbles (fixed overlay) ─────────────── */
.vs-world-presence {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 2;
  display: none; /* JS shows on desktop */
}

@media (min-width: 900px) {
  .vs-world-presence { display: block; }
}

.vs-world-bubble {
  position: absolute;
  width: 36px; height: 36px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem;
  box-shadow: 0 0 14px -3px rgba(0,0,0,0.5);
  opacity: 0.55;
  animation: worldFloat 6s ease-in-out infinite;
  pointer-events: all;
  cursor: default;
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.vs-world-bubble:hover {
  opacity: 0.9;
  transform: scale(1.18) !important;
}

.vs-world-bubble--expanded {
  opacity: 0.9;
  z-index: 10;
}

.vs-world-bubble__label {
  display: none;
  position: absolute;
  bottom: -1.5rem;
  left: 50%;
  transform: translateX(-50%);
  font-size: 0.6rem;
  color: rgba(255,255,255,0.7);
  white-space: nowrap;
  background: rgba(0,0,0,0.6);
  padding: 0.1rem 0.3rem;
  border-radius: 4px;
}

.vs-world-bubble--expanded .vs-world-bubble__label {
  display: block;
}

.vs-world-bubble--flash {
  animation: worldFlash 0.4s ease-out forwards, worldFloat 6s ease-in-out infinite 0.4s;
}

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

@keyframes worldFlash {
  0%   { opacity: 0.55; transform: scale(1); }
  50%  { opacity: 1;    transform: scale(1.3); box-shadow: 0 0 24px 4px rgba(255,255,255,0.35); }
  100% { opacity: 0.55; transform: scale(1); }
}

@media (prefers-reduced-motion: reduce) {
  .vs-world-bubble { animation: none; }
}

/* ── Live Spaces card ───────────────────────────────────── */
.vs-live-spaces {
  padding: 0.9rem 1rem;
}

.vs-live-spaces__head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.65rem;
}

.vs-live-spaces__title {
  font-size: 0.8rem;
  font-weight: 600;
  color: rgba(255,255,255,0.7);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.vs-live-spaces__seeall {
  font-size: 0.72rem;
  color: rgba(255,255,255,0.4);
  text-decoration: none;
}

.vs-live-spaces__list {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.vs-live-space-row {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.4rem 0.5rem;
  border-radius: 0.6rem;
  text-decoration: none;
  border: 1px solid transparent;
  transition: background 0.18s ease, border-color 0.18s ease;
}

.vs-live-space-row:hover {
  background: rgba(255,255,255,0.06);
  border-color: rgba(255,255,255,0.1);
}

.vs-live-space-row--active {
  border-color: rgba(74, 222, 128, 0.18);
  background: rgba(74, 222, 128, 0.04);
}

.vs-live-space-icon {
  font-size: 1.1rem;
  flex-shrink: 0;
}

.vs-live-space-info {
  flex: 1;
  min-width: 0;
}

.vs-live-space-name {
  display: block;
  font-size: 0.8rem;
  font-weight: 500;
  color: rgba(255,255,255,0.82);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.vs-live-space-meta {
  display: block;
  font-size: 0.67rem;
  color: rgba(255,255,255,0.38);
}

.vs-live-space-row--active .vs-live-space-meta {
  color: rgba(74, 222, 128, 0.75);
}

.vs-live-space-pulse {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: #4ade80;
  box-shadow: 0 0 6px #4ade80;
  flex-shrink: 0;
  animation: onlinePulse 2s ease-in-out infinite;
}

/* Preset grid (empty state) */
.vs-live-spaces__presets {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
}

.vs-live-space-preset {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.45rem 0.65rem;
  border-radius: 0.6rem;
  border: 1px solid rgba(255,255,255,0.09);
  text-decoration: none;
  font-size: 0.75rem;
  color: rgba(255,255,255,0.6);
  background: rgba(255,255,255,0.03);
  transition: background 0.18s ease, border-color 0.18s ease;
}

.vs-live-space-preset:hover {
  background: rgba(255,255,255,0.07);
  border-color: rgba(255,255,255,0.18);
  color: rgba(255,255,255,0.85);
}

/* Late night room chips */
.vs-late-night__rooms {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.7rem;
}

.vs-late-night__room-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.28rem 0.65rem;
  border-radius: 99px;
  font-size: 0.75rem;
  color: rgba(255,255,255,0.75);
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  text-decoration: none;
  transition: background 0.18s ease;
}

.vs-late-night__room-chip:hover {
  background: rgba(255,255,255,0.12);
}

.vs-chip-live {
  font-size: 0.62rem;
  color: #4ade80;
  background: rgba(74, 222, 128, 0.12);
  border-radius: 4px;
  padding: 0.05rem 0.3rem;
  margin-left: 0.2rem;
}

/* ── Social moment cards ───────────────────────────────── */
.vs-moment-card {
  padding: 0.9rem 1rem;
  border-left: 3px solid #8b5cf6;
}

.vs-moment-card--prompt { border-left-color: #f472b6; }
.vs-moment-card--game   { border-left-color: #22d3ee; }

.vs-moment-card__eyebrow {
  font-size: 0.67rem;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: rgba(255,255,255,0.45);
  margin: 0 0 0.35rem;
}

.vs-moment-card h3 {
  font-size: 0.88rem;
  font-weight: 600;
  color: rgba(255,255,255,0.88);
  margin: 0 0 0.25rem;
  line-height: 1.3;
}

.vs-moment-card p {
  font-size: 0.78rem;
  color: rgba(255,255,255,0.5);
  margin: 0 0 0.5rem;
  line-height: 1.45;
}

.vs-moment-card a {
  font-size: 0.75rem;
  color: #8b5cf6;
  text-decoration: none;
}

.vs-moment-card a:hover { text-decoration: underline; }

/* ── Atmospheric chip ──────────────────────────────────── */
.vs-atmosphere-chip {
  transition: background 0.5s ease;
}

@media (max-width: 760px) {
  .vs-world-presence { display: none !important; }
  .vs-live-spaces__presets { grid-template-columns: 1fr; }
  .vs-presence-clusters { gap: 0.4rem; }
}

/* ══════════════════════════════════════════════════════════════
   PHASE Q — LIVE ROOM CANVAS PREVIEW SYSTEM
   Layered room rendering for real-time customization visualization
══════════════════════════════════════════════════════════════ */

/* ── Room canvas container ──────────────────────────────────── */
.room-canvas-container {
  position: relative;
  margin: 1.5rem 0;
  padding: 1rem;
  background: rgba(10, 10, 20, 0.4);
  border: 1px solid rgba(139, 92, 246, 0.2);
  border-radius: 1.2rem;
  overflow: hidden;
}

.room-canvas-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
  padding: 0 0.5rem;
}

.room-canvas-title {
  font-size: 1.1rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.88);
  margin: 0;
}

.room-canvas-subtitle {
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.45);
}

/* ── Main room canvas ──────────────────────────────────────── */
.room-canvas {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: linear-gradient(180deg, #0a0a14 0%, #1a1a2e 50%, #0f0f1a 100%);
  border-radius: 1rem;
  border: 1px solid rgba(139, 92, 246, 0.15);
  overflow: hidden;
  box-shadow: 0 8px 32px -8px rgba(139, 92, 246, 0.2) inset;
  transition: all 0.6s ease;
}

/* ── Layered rendering system ──────────────────────────────– */
.room-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 1;
}

.room-layer--environment {
  z-index: 0;
  background: radial-gradient(ellipse at bottom right, rgba(139, 92, 246, 0.08) 0%, transparent 70%);
}

.room-layer--wallpaper {
  z-index: 2;
  background: linear-gradient(135deg, rgba(80, 30, 140, 0.3) 0%, rgba(139, 92, 246, 0.2) 50%, rgba(80, 30, 140, 0.3) 100%);
  transition: background 0.6s ease;
}

.room-layer--floor {
  z-index: 3;
  bottom: 0;
  height: 35%;
  background: linear-gradient(180deg, rgba(30, 10, 50, 0.1) 0%, rgba(10, 5, 20, 0.3) 100%);
  box-shadow: 0 -20px 40px -10px rgba(0, 0, 0, 0.4) inset;
}

.room-layer--lighting {
  z-index: 4;
  opacity: 0.2;
  background: radial-gradient(ellipse 60% 40% at center 30%, rgba(139, 92, 246, 0.4) 0%, transparent 70%);
  mix-blend-mode: screen;
  transition: background 0.6s ease, opacity 0.6s ease;
}

.room-layer--wall-decor {
  z-index: 5;
  pointer-events: all;
}

.room-layer--furniture {
  z-index: 6;
}

.room-layer--stickers {
  z-index: 7;
  pointer-events: all;
}

.room-layer--companion {
  z-index: 8;
  pointer-events: all;
}

.room-layer--ambient {
  z-index: 9;
  animation: ambientFlow 8s ease-in-out infinite;
}

/* ── Room shelf (upper wall decor) ──────────────────────────– */
.room-shelf {
  position: absolute;
  display: flex;
  align-items: flex-end;
  gap: 1rem;
  padding: 0 2rem;
}

.room-shelf--upper {
  top: 12%;
  left: 0;
  right: 0;
  height: 15%;
  background: linear-gradient(90deg, rgba(60, 20, 100, 0.2) 0%, rgba(100, 50, 150, 0.15) 50%, rgba(60, 20, 100, 0.2) 100%);
  border-bottom: 2px solid rgba(139, 92, 246, 0.2);
  font-size: 2.5rem;
  line-height: 1;
  overflow: hidden;
}

.room-shelf-item {
  display: inline-block;
  transition: transform 0.3s ease;
  filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.5));
}

.room-shelf-item:hover {
  transform: scale(1.15) translateY(-4px) rotate(5deg);
}

/* ── Memory wall ───────────────────────────────────────────── */
.room-memory-wall {
  position: absolute;
  bottom: 20%;
  left: 8%;
  width: 25%;
  height: 40%;
  border: 2px dashed rgba(139, 92, 246, 0.3);
  border-radius: 0.6rem;
  padding: 0.8rem;
  background: rgba(80, 30, 140, 0.05);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  font-size: 1.8rem;
  line-height: 1.2;
  overflow: hidden;
}

.memory-wall-item {
  display: inline-block;
  filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.6));
  transition: transform 0.2s ease;
}

/* ── Companion spot ────────────────────────────────────────– */
.room-companion {
  position: absolute;
  bottom: 10%;
  right: 12%;
  width: 80px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.6));
  animation: companionIdle 4s ease-in-out infinite;
}

@keyframes companionIdle {
  0%, 100% { transform: translateY(0px) rotate(-2deg); }
  50% { transform: translateY(-8px) rotate(2deg); }
}

/* ── Stickers on canvas ────────────────────────────────────── */
.room-sticker {
  position: absolute;
  font-size: 2rem;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.5));
  transform-origin: center;
  transition: transform 0.2s ease;
  cursor: grab;
  animation: stickerFloat 6s ease-in-out infinite;
}

.room-sticker:active { cursor: grabbing; }

@keyframes stickerFloat {
  0%, 100% { transform: translateY(0px) rotate(-3deg); }
  50% { transform: translateY(-6px) rotate(2deg); }
}

/* ── Furniture objects ─────────────────────────────────────── */
.room-furniture-item {
  position: absolute;
  font-size: 3rem;
  filter: drop-shadow(0 3px 10px rgba(0, 0, 0, 0.6));
  transition: transform 0.2s ease;
}

.room-furniture-item:hover {
  transform: scale(1.1);
}

/* ── Identity card (displayed in room) ───────────────────── */
.room-identity-card {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 20;
  padding: 1rem 1.2rem;
  background: rgba(10, 10, 20, 0.85);
  border: 1px solid rgba(139, 92, 246, 0.3);
  border-radius: 0.8rem;
  backdrop-filter: blur(10px);
  min-width: 300px;
  max-width: 420px;
  box-shadow: 0 8px 24px -6px rgba(0, 0, 0, 0.6);
  animation: cardFloat 0.8s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes cardFloat {
  from { opacity: 0; transform: translateX(-50%) translateY(20px); }
  to { opacity: 1; transform: translateX(-50%) translateY(0); }
}

.room-identity-card__content {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.room-identity-card__header {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.room-identity-card__avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  background: rgba(139, 92, 246, 0.15);
  border: 1px solid rgba(139, 92, 246, 0.3);
  flex-shrink: 0;
}

.room-identity-card__names {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
}

.room-identity-card__name {
  font-size: 1rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.92);
  line-height: 1.2;
}

.room-identity-card__handle {
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.5);
}

.room-identity-card__vibe {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.75);
  margin: 0;
  line-height: 1.4;
  font-style: italic;
}

.room-identity-card__status {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.room-status-pill {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.6rem;
  border-radius: 99px;
  font-size: 0.75rem;
  background: rgba(139, 92, 246, 0.15);
  border: 1px solid rgba(139, 92, 246, 0.25);
  color: rgba(255, 255, 255, 0.7);
  white-space: nowrap;
}

.room-status-pill--lighting {
  border-color: rgba(251, 191, 36, 0.3);
  background: rgba(251, 191, 36, 0.1);
}

.room-status-pill--music {
  border-color: rgba(74, 222, 128, 0.3);
  background: rgba(74, 222, 128, 0.1);
}

/* ── Canvas controls ───────────────────────────────────────– */
.room-canvas-controls {
  display: flex;
  gap: 0.6rem;
  justify-content: center;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(139, 92, 246, 0.1);
}

.room-canvas-btn {
  padding: 0.5rem 1rem;
  border-radius: 0.6rem;
  border: 1px solid rgba(139, 92, 246, 0.2);
  background: rgba(139, 92, 246, 0.08);
  color: rgba(255, 255, 255, 0.75);
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
}

.room-canvas-btn:hover {
  background: rgba(139, 92, 246, 0.15);
  border-color: rgba(139, 92, 246, 0.4);
  color: rgba(255, 255, 255, 0.92);
}

.room-canvas-btn--primary {
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.3) 0%, rgba(139, 92, 246, 0.15) 100%);
  border-color: rgba(139, 92, 246, 0.5);
  color: rgba(255, 255, 255, 0.92);
}

.room-canvas-btn--primary:hover {
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.45) 0%, rgba(139, 92, 246, 0.25) 100%);
  border-color: rgba(139, 92, 246, 0.7);
}

/* ── Theme-specific room variations ────────────────────────– */
[data-theme="cozy_cabin"] .room-canvas {
  background: linear-gradient(180deg, #2a1a1a 0%, #3a2a2a 50%, #1a0a0a 100%);
}

[data-theme="arcade_room"] .room-canvas {
  background: linear-gradient(180deg, #1a1a3a 0%, #2a2a4a 50%, #0a0a1a 100%);
}

[data-theme="cyber_pop"] .room-canvas {
  background: linear-gradient(180deg, #0a1a2a 0%, #1a3a4a 50%, #0a1a2a 100%);
}

[data-theme="soft_pastel"] .room-canvas {
  background: linear-gradient(180deg, #2a1a3a 0%, #3a2a4a 50%, #1a0a2a 100%);
}

/* ── Responsive layout ─────────────────────────────────────── */
@media (max-width: 1200px) {
  .room-canvas-container {
    order: -1; /* Move above form on narrow screens */
    margin-bottom: 2rem;
  }
  
  .room-canvas {
    aspect-ratio: 4 / 3;
  }
}

@media (max-width: 760px) {
  .room-canvas-container {
    padding: 0.75rem;
  }
  
  .room-canvas {
    aspect-ratio: 1 / 1;
    border-radius: 0.8rem;
  }
  
  .room-identity-card {
    min-width: 260px;
    max-width: 90%;
    padding: 0.8rem 1rem;
    bottom: 1rem;
  }
  
  .room-companion {
    width: 60px;
    height: 60px;
    font-size: 2.5rem;
  }
  
  .room-shelf--upper {
    font-size: 1.8rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .room-layer--ambient,
  .room-companion,
  .room-sticker,
  .room-identity-card,
  .room-furniture-item {
    animation: none !important;
  }
  
  .room-canvas,
  .room-layer {
    transition: none !important;
  }
}

/* ═══════════════════════════════════════════════════════════════
   PHASE 2: ROOM CREATOR UX TRANSFORMATION
   === Room-First Design + Category Navigation + Visual Pickers ===
   ═══════════════════════════════════════════════════════════════ */

/* ── Room Creator Layout (Desktop: 60/40 split) ─────────────── */
.room-creator-layout {
  display: grid;
  grid-template-columns: 1fr 0.8fr;
  gap: 1.5rem;
  padding: 1.5rem;
  min-height: 80vh;
}

.room-creator__canvas {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  position: relative;
}

.room-creator__controls {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  position: relative;
}

/* ── Category Tab Navigation ─────────────────────────────────── */
.room-creator__tabs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.5rem;
  padding: 0.5rem;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 1rem;
  backdrop-filter: blur(12px);
}

.room-creator__tab {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.3rem;
  padding: 0.7rem;
  background: transparent;
  border: 2px solid rgba(255, 255, 255, 0.1);
  border-radius: 0.8rem;
  color: var(--theme-text);
  cursor: pointer;
  font-size: 0.75rem;
  transition: all 0.2s ease;
  position: relative;
  overflow: hidden;
}

.room-creator__tab:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

.room-creator__tab.is-active {
  background: var(--theme-accent);
  border-color: var(--theme-accent);
  color: #fff;
  box-shadow: 0 0 20px rgba(139, 92, 246, 0.5);
}

.room-creator__tab-emoji {
  font-size: 1.4rem;
  line-height: 1;
}

.room-creator__tab-label {
  font-weight: 600;
  font-size: 0.7rem;
}

/* ── Creator Control Panel ───────────────────────────────────– */
.room-creator__panel {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  overflow-y: auto;
  max-height: 70vh;
  padding-right: 0.5rem;
}

.room-creator__panel::-webkit-scrollbar {
  width: 6px;
}

.room-creator__panel::-webkit-scrollbar-track {
  background: transparent;
}

.room-creator__panel::-webkit-scrollbar-thumb {
  background: rgba(139, 92, 246, 0.3);
  border-radius: 3px;
}

.room-creator__panel::-webkit-scrollbar-thumb:hover {
  background: rgba(139, 92, 246, 0.5);
}

/* ── Category Section (only one active) ──────────────────────– */
.room-creator__section {
  display: none;
  animation: fadeIn 0.25s ease;
}

.room-creator__section.is-active {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ── Visual Picker Cards ─────────────────────────────────────– */
.room-creator-layout .visual-picker {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
  gap: 0.7rem;
}

.room-creator-layout .picker-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  padding: 0.8rem;
  background: rgba(255, 255, 255, 0.04);
  border: 2px solid rgba(255, 255, 255, 0.1);
  border-radius: 0.8rem;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
  overflow: hidden;
}

.room-creator-layout .picker-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at var(--x, 50%) var(--y, 50%), rgba(139, 92, 246, 0.3), transparent);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.room-creator-layout .picker-card:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(139, 92, 246, 0.5);
  transform: translateY(-4px);
  box-shadow: 0 0 15px rgba(139, 92, 246, 0.2);
}

.room-creator-layout .picker-card:hover::before {
  opacity: 1;
}

.room-creator-layout .picker-card.is-selected {
  background: var(--theme-accent);
  border-color: var(--theme-accent);
  color: #fff;
  box-shadow: 0 0 20px rgba(139, 92, 246, 0.6), inset 0 0 10px rgba(255, 255, 255, 0.1);
  animation: pickerPulse 0.4s ease;
}

.room-creator-layout .picker-card.is-selected::before {
  content: '✨';
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  animation: twinkle 0.6s ease;
}

@keyframes pickerPulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.08); }
  100% { transform: scale(1); }
}

@keyframes twinkle {
  0% { opacity: 0; transform: scale(0); }
  50% { opacity: 1; transform: scale(1); }
  100% { opacity: 0; transform: scale(1.2); }
}

.picker-emoji {
  font-size: 1.8rem;
  line-height: 1;
}

.picker-label {
  font-size: 0.7rem;
  font-weight: 600;
  text-align: center;
  max-width: 100%;
  word-break: break-word;
  opacity: 0.8;
}

/* ── Room Theme Preset Cards ─────────────────────────────────– */
.room-creator-layout .preset-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.9rem;
  background: rgba(255, 255, 255, 0.04);
  border: 2px solid rgba(255, 255, 255, 0.1);
  border-radius: 0.8rem;
  cursor: pointer;
  transition: all 0.25s ease;
}

.room-creator-layout .preset-card:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(139, 92, 246, 0.4);
  transform: translateX(4px);
}

.room-creator-layout .preset-card.is-selected {
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.3), rgba(236, 72, 153, 0.2));
  border-color: var(--theme-accent);
  box-shadow: 0 0 20px rgba(139, 92, 246, 0.4);
}

.preset-emoji {
  font-size: 1.5rem;
  flex-shrink: 0;
}

.preset-info {
  flex: 1;
}

.preset-name {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--theme-text);
}

.preset-desc {
  font-size: 0.75rem;
  opacity: 0.6;
  margin-top: 0.2rem;
}

/* ── Collectible Cards (Treasure Style) ──────────────────────– */
.room-creator-layout .collectible-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  padding: 1rem;
  background: rgba(255, 255, 255, 0.04);
  border: 2px solid rgba(255, 255, 255, 0.1);
  border-radius: 0.8rem;
  text-align: center;
  transition: all 0.3s ease;
  position: relative;
  min-width: 100px;
}

.room-creator-layout .collectible-card:hover {
  transform: translateY(-6px);
  border-color: rgba(139, 92, 246, 0.5);
  box-shadow: 0 8px 25px rgba(139, 92, 246, 0.2);
}

.room-creator-layout .collectible-card.is-unlocked {
  background: rgba(139, 92, 246, 0.1);
  border-color: rgba(139, 92, 246, 0.4);
}

.room-creator-layout .collectible-card.is-locked {
  opacity: 0.4;
}

.collectible-emoji {
  font-size: 2rem;
  line-height: 1;
}

.collectible-rarity {
  position: absolute;
  top: 0.3rem;
  right: 0.3rem;
  font-size: 0.8rem;
}

.collectible-name {
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--theme-text);
}

.collectible-category {
  font-size: 0.7rem;
  opacity: 0.6;
}

/* ── Draggable Item States ──────────────────────────────────– */
.room-creator-layout .draggable-item {
  cursor: grab;
  transition: all 0.15s ease;
  position: relative;
}

.room-creator-layout .draggable-item:hover {
  transform: scale(1.05);
}

.room-creator-layout .draggable-item:active {
  cursor: grabbing;
}

.room-creator-layout .draggable-item.is-dragging {
  opacity: 0.7;
  z-index: 1000;
  box-shadow: 0 10px 30px rgba(139, 92, 246, 0.4);
}

.room-creator-layout .drop-zone {
  border: 2px dashed rgba(139, 92, 246, 0.3);
  border-radius: 0.8rem;
  padding: 1rem;
  transition: all 0.2s ease;
  min-height: 60px;
}

.room-creator-layout .drop-zone.is-active {
  background: rgba(139, 92, 246, 0.1);
  border-color: rgba(139, 92, 246, 0.6);
  box-shadow: inset 0 0 15px rgba(139, 92, 246, 0.15);
}

/* ── Save Success Celebration ───────────────────────────────– */
.save-celebration {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9999;
}

.celebration-sparkle {
  position: absolute;
  font-size: 1.5rem;
  animation: celebrateFloat 1.2s ease-out forwards;
}

@keyframes celebrateFloat {
  0% {
    opacity: 1;
    transform: translate(0, 0) scale(1);
  }
  100% {
    opacity: 0;
    transform: translate(var(--tx, 30px), var(--ty, -100px)) scale(0.3);
  }
}

/* ── Mobile Responsive Layout ───────────────────────────────– */
@media (max-width: 1200px) {
  .room-creator-layout {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  
  .room-creator__tabs {
    position: sticky;
    bottom: 0;
    z-index: 100;
    grid-template-columns: repeat(4, 1fr);
  }
  
  .room-creator__panel {
    max-height: 50vh;
    order: 2;
  }
}

@media (max-width: 760px) {
  .room-creator-layout {
    padding: 0.75rem;
    gap: 0;
    min-height: auto;
  }
  
  .room-creator__canvas {
    order: 1;
    gap: 0.5rem;
  }
  
  .room-creator__controls {
    order: 3;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(10, 10, 20, 0.95);
    backdrop-filter: blur(12px);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding: 0.75rem;
    border-radius: 1.5rem 1.5rem 0 0;
    z-index: 100;
    max-height: 45vh;
    overflow-y: auto;
  }
  
  .room-creator__tabs {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.4rem;
    padding: 0.4rem;
  }
  
  .room-creator__tab {
    padding: 0.6rem;
    font-size: 0.65rem;
  }
  
  .room-creator__tab-emoji {
    font-size: 1.2rem;
  }
  
  .room-creator__panel {
    margin-top: 0.75rem;
    max-height: calc(45vh - 3rem);
  }
  
  .room-canvas-container {
    margin-bottom: 50vh;
  }
  
  .visual-picker {
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
  }
  
  .picker-card {
    padding: 0.6rem;
    font-size: 0.7rem;
  }
  
  .picker-emoji {
    font-size: 1.4rem;
  }
  
  .preset-card {
    padding: 0.7rem;
    gap: 0.7rem;
  }
  
  .preset-emoji {
    font-size: 1.3rem;
  }
  
  .preset-name {
    font-size: 0.8rem;
  }
}

@media (max-width: 480px) {
  .room-creator__tabs {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .visual-picker {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ═════════════════════════════════════════════════════════════════
   PHASE 3B: AMBIENT LIFE SYSTEM
   Subtle environmental animations for "alive while idle" feeling
   ═════════════════════════════════════════════════════════════════ */

/* Lava Lamp Float — slow undulating movement */
@keyframes lavaLampFloat {
  0%   { transform: translateY(0px) translateX(-1px); }
  25%  { transform: translateY(-8px) translateX(1px); }
  50%  { transform: translateY(-4px) translateX(-2px); }
  75%  { transform: translateY(-6px) translateX(2px); }
  100% { transform: translateY(0px) translateX(-1px); }
}

/* Neon Flicker — subtle glow pulse */
@keyframes neonFlicker {
  0%   { opacity: 1; text-shadow: 0 0 5px currentColor, 0 0 15px rgba(255, 0, 150, 0.5); }
  20%  { opacity: 0.98; }
  40%  { opacity: 1; }
  60%  { opacity: 0.99; }
  80%  { opacity: 1; }
  100% { opacity: 1; text-shadow: 0 0 5px currentColor, 0 0 15px rgba(255, 0, 150, 0.5); }
}

/* Cassette Tape Spin — gentle rotation for music indicator */
@keyframes cassetteSpin {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

/* Pet Breath — companion glow pulse */
@keyframes petBreath {
  0%   { filter: drop-shadow(0 0 5px rgba(255, 255, 255, 0)); }
  50%  { filter: drop-shadow(0 0 12px rgba(139, 92, 246, 0.4)); }
  100% { filter: drop-shadow(0 0 5px rgba(255, 255, 255, 0)); }
}

/* Room Glow Drift — ambient light movement */
@keyframes roomGlowDrift {
  0%   { background-position: 0% 50%; }
  50%  { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* Light Pulse — screen glow breathing */
@keyframes lightPulse {
  0%   { opacity: 0.85; }
  50%  { opacity: 1; }
  100% { opacity: 0.85; }
}

/* Sparkle Float — drifting particles upward */
@keyframes sparkleFloat {
  0%   { 
    transform: translateY(0) translateX(0) scale(1);
    opacity: 1;
  }
  100% { 
    transform: translateY(-100px) translateX(var(--drift-x, 0px)) scale(0.3);
    opacity: 0;
  }
}

/* Ambient Float — subtle gentle motion */
@keyframes ambientFloat {
  0%, 100% { transform: translateY(0px); }
  50%      { transform: translateY(-3px); }
}

/* Star Twinkle — distant stars twinkling */
@keyframes starTwinkle {
  0%, 100% { opacity: 0.3; }
  50%      { opacity: 0.8; }
}

/* Fog Drift — layered atmospheric movement */
@keyframes fogDrift {
  0%   { transform: translateX(-100px); opacity: 0; }
  10%  { opacity: 0.15; }
  50%  { opacity: 0.08; }
  90%  { opacity: 0.15; }
  100% { transform: translateX(100px); opacity: 0; }
}

/* Companion Blink — subtle eye closure */
@keyframes companionBlink {
  0%, 85%, 100% { opacity: 1; }
  90%, 95%      { opacity: 0.4; }
}

/* Dragon ember pulse */
@keyframes dragonEmber {
  0%, 100% { filter: drop-shadow(0 0 4px rgba(251, 146, 60, 0.5)); transform: translateY(0) scale(1); }
  50%      { filter: drop-shadow(0 0 12px rgba(251, 146, 60, 0.95)); transform: translateY(-1px) scale(1.05); }
}

/* Cat purr sway */
@keyframes catPurr {
  0%, 100% { transform: translateX(0) rotate(0deg); }
  25%      { transform: translateX(-1px) rotate(-2deg); }
  75%      { transform: translateX(1px) rotate(2deg); }
}

/* Robot eye scan */
@keyframes robotScan {
  0%, 100% { filter: drop-shadow(0 0 4px rgba(56, 189, 248, 0.5)); }
  50%      { filter: drop-shadow(0 0 10px rgba(56, 189, 248, 0.95)); }
}

/* Fox twitch */
@keyframes foxTwitch {
  0%, 80%, 100% { transform: rotate(0deg); }
  84%           { transform: rotate(-5deg); }
  88%           { transform: rotate(4deg); }
  92%           { transform: rotate(-2deg); }
}

/* Ghost drift */
@keyframes ghostDrift {
  0%, 100% { opacity: 0.85; transform: translateY(0); }
  50%      { opacity: 1; transform: translateY(-3px); }
}

/* Owl blink */
@keyframes owlBlink {
  0%, 86%, 100% { opacity: 1; }
  90%, 94%      { opacity: 0.45; }
}

/* Alien wobble */
@keyframes alienBlobPulse {
  0%, 100% { transform: scale(1); filter: hue-rotate(0deg); }
  50%      { transform: scale(1.07); filter: hue-rotate(22deg); }
}

/* Slime squish */
@keyframes slimeSquish {
  0%, 100% { transform: scale(1, 1); }
  45%      { transform: scale(1.08, 0.92); }
  70%      { transform: scale(0.96, 1.05); }
}

/* ─ Ambient Life Classes ─ */

.ambient-lava-lamp {
  animation: lavaLampFloat 6s ease-in-out infinite;
}

.ambient-neon-flicker {
  animation: neonFlicker 4s ease-in-out infinite;
}

.ambient-cassette {
  animation: cassetteSpin 8s linear infinite;
  transform-origin: center;
}

.ambient-pet-breath {
  animation: petBreath var(--pet-breath-duration, 4s) ease-in-out infinite;
  will-change: transform, filter, opacity;
}

.ambient-room-glow {
  animation: roomGlowDrift 12s ease-in-out infinite;
}

.ambient-light-pulse {
  animation: lightPulse 5s ease-in-out infinite;
}

.ambient-sparkle {
  animation: sparkleFloat 3s ease-out forwards;
}

.ambient-float {
  animation: ambientFloat 4s ease-in-out infinite;
}

.ambient-star {
  animation: starTwinkle 3s ease-in-out infinite;
}

.ambient-fog {
  animation: fogDrift 8s ease-in-out infinite;
}

.ambient-blink {
  animation: companionBlink 5s ease-in-out infinite;
}

.ambient-pet-dragon {
  animation: petBreath var(--pet-breath-duration, 4s) ease-in-out infinite,
             dragonEmber 3.4s ease-in-out infinite;
}

.ambient-pet-cat {
  animation: petBreath var(--pet-breath-duration, 4s) ease-in-out infinite,
             catPurr 2.8s ease-in-out infinite,
             companionBlink 5.2s ease-in-out infinite;
}

.ambient-pet-robot {
  animation: petBreath var(--pet-breath-duration, 4s) ease-in-out infinite,
             robotScan 2.5s ease-in-out infinite;
}

.ambient-pet-fox {
  animation: petBreath var(--pet-breath-duration, 4s) ease-in-out infinite,
             foxTwitch 4.8s ease-in-out infinite;
}

.ambient-pet-ghost {
  animation: petBreath var(--pet-breath-duration, 4s) ease-in-out infinite,
             ghostDrift 3.2s ease-in-out infinite;
}

.ambient-pet-owl {
  animation: petBreath var(--pet-breath-duration, 4s) ease-in-out infinite,
             owlBlink 4.6s ease-in-out infinite;
}

.ambient-pet-alien {
  animation: petBreath var(--pet-breath-duration, 4s) ease-in-out infinite,
             alienBlobPulse 2.9s ease-in-out infinite;
}

.ambient-pet-slime {
  animation: petBreath var(--pet-breath-duration, 4s) ease-in-out infinite,
             slimeSquish 2.4s ease-in-out infinite;
}

/* Reduce motion support */
@media (prefers-reduced-motion: reduce) {
  .ambient-lava-lamp,
  .ambient-neon-flicker,
  .ambient-cassette,
  .ambient-pet-breath,
  .ambient-room-glow,
  .ambient-light-pulse,
  .ambient-sparkle,
  .ambient-float,
  .ambient-star,
  .ambient-fog,
  .ambient-blink,
  .ambient-pet-dragon,
  .ambient-pet-cat,
  .ambient-pet-robot,
  .ambient-pet-fox,
  .ambient-pet-ghost,
  .ambient-pet-owl,
  .ambient-pet-alien,
  .ambient-pet-slime {
    animation: none !important;
  }
}
