:root {
  --bg-deep: #09080d;
  --bg-card: rgba(24, 21, 35, 0.72);
  --bg-glass: rgba(18, 16, 28, 0.82);
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-glow: rgba(255, 42, 133, 0.35);

  --accent-pink: #ff2a85;
  --accent-purple: #9333ea;
  --accent-gold: #fbbf24;
  --gradient-main: linear-gradient(135deg, #ff2a85 0%, #a855f7 100%);
  --gradient-soft: linear-gradient(135deg, rgba(255, 42, 133, 0.18), rgba(168, 85, 247, 0.18));

  --text-primary: #f8fafc;
  --text-secondary: #9ca3af;
  --text-muted: #6b7280;

  --radius-sm: 12px;
  --radius-md: 18px;
  --radius-lg: 24px;
  --safe-bottom: env(safe-area-inset-bottom, 0px);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background-color: #040307;
  color: var(--text-primary);
  min-height: 100dvh;
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
}

/* Ambient glowing orbs behind mobile shell */
.bg-orb {
  position: fixed;
  border-radius: 50%;
  filter: blur(110px);
  opacity: 0.35;
  pointer-events: none;
  z-index: 0;
}
.orb-1 {
  width: 340px;
  height: 340px;
  background: var(--accent-pink);
  top: -80px;
  left: 15%;
}
.orb-2 {
  width: 360px;
  height: 360px;
  background: var(--accent-purple);
  bottom: -100px;
  right: 15%;
}

/* Mobile App Shell (Telegram Mini App viewport) */
.app-shell {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 430px;
  height: 100dvh;
  max-height: 900px;
  background: var(--bg-deep);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 25px 80px rgba(0, 0, 0, 0.85), 0 0 0 1px rgba(255, 255, 255, 0.08);
}

@media (min-width: 480px) {
  .app-shell {
    height: 92dvh;
    border-radius: 32px;
  }
}

.glass {
  background: var(--bg-glass);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

/* Views */
.view {
  display: none;
  flex-direction: column;
  height: 100%;
  width: 100%;
  animation: fadeIn 0.22s ease;
}
.view.active {
  display: flex;
}

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

/* Top Bar */
.top-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border-subtle);
  z-index: 10;
}

.brand {
  display: flex;
  align-items: center;
  gap: 8px;
}

.brand-logo {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.5px;
  display: flex;
  align-items: center;
  gap: 7px;
}

.brand-logo span {
  background: var(--gradient-main);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.pulse-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--accent-pink);
  box-shadow: 0 0 12px var(--accent-pink);
  display: inline-block;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.25); opacity: 0.65; }
}

.badge-18 {
  font-size: 10px;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: 6px;
  background: rgba(255, 42, 133, 0.16);
  border: 1px solid rgba(255, 42, 133, 0.4);
  color: #ff6aa8;
}

.top-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.balance-pill {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(251, 191, 36, 0.12);
  border: 1px solid rgba(251, 191, 36, 0.35);
  color: #fde68a;
  font-weight: 700;
  font-size: 13px;
  cursor: pointer;
  transition: transform 0.15s ease, background 0.15s ease;
}
.balance-pill:active {
  transform: scale(0.95);
}
.balance-pill .plus-badge {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--accent-gold);
  color: #000;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 800;
}
.balance-pill.mini {
  padding: 5px 10px;
  font-size: 12px;
}

.icon-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--border-subtle);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s;
}
.icon-btn:hover {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.2);
}

.page-title {
  font-size: 18px;
  font-weight: 700;
}

/* Scrollable body */
.scroll-content {
  flex: 1;
  overflow-y: auto;
  padding: 14px 16px 96px;
  scrollbar-width: none;
}
.scroll-content::-webkit-scrollbar {
  display: none;
}

/* Promo Banner */
.promo-banner {
  position: relative;
  border-radius: var(--radius-md);
  padding: 16px;
  background: linear-gradient(135deg, rgba(255, 42, 133, 0.28) 0%, rgba(147, 51, 234, 0.28) 100%);
  border: 1px solid rgba(255, 42, 133, 0.4);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
  cursor: pointer;
  overflow: hidden;
}
.promo-banner::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 35%, rgba(255, 255, 255, 0.12) 50%, transparent 65%);
  animation: sheen 4.5s infinite;
}
@keyframes sheen {
  0% { transform: translateX(-100%); }
  45%, 100% { transform: translateX(100%); }
}

.promo-tag {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.4px;
  color: #ffb3d4;
  display: block;
  margin-bottom: 4px;
}
.promo-content h2 {
  font-size: 15px;
  font-weight: 800;
  margin-bottom: 2px;
}
.promo-content p {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.78);
}
.promo-cta {
  flex-shrink: 0;
  padding: 9px 14px;
  border-radius: 12px;
  border: none;
  background: var(--gradient-main);
  color: #fff;
  font-weight: 800;
  font-size: 12px;
  box-shadow: 0 6px 20px rgba(255, 42, 133, 0.45);
  cursor: pointer;
}

/* Filters */
.filter-row {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 6px;
  margin-bottom: 14px;
  scrollbar-width: none;
}
.filter-row::-webkit-scrollbar {
  display: none;
}

.filter-chip {
  flex-shrink: 0;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid var(--border-subtle);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}
.filter-chip.active {
  background: var(--gradient-main);
  color: #fff;
  border-color: transparent;
  box-shadow: 0 4px 16px rgba(255, 42, 133, 0.35);
}

/* Section Header */
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}
.section-header h3 {
  font-size: 15px;
  font-weight: 700;
}
.online-count {
  font-size: 12px;
  color: #4ade80;
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
}
.dot-green {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #4ade80;
  box-shadow: 0 0 8px #4ade80;
  display: inline-block;
}

/* Character Grid */
.character-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.char-card {
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  aspect-ratio: 3 / 4.2;
  background: #161322;
  border: 1px solid var(--border-subtle);
  cursor: pointer;
  transition: transform 0.2s ease, border-color 0.2s ease;
}
.char-card:hover {
  border-color: var(--border-glow);
}
.char-card:active {
  transform: scale(0.97);
}

.char-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}
.char-card:hover img {
  transform: scale(1.04);
}

.char-card-top {
  position: absolute;
  top: 10px;
  left: 10px;
  right: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 2;
}

.char-tag {
  font-size: 10px;
  font-weight: 700;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(9, 8, 13, 0.65);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: #fff;
}

.char-hot {
  font-size: 10px;
  font-weight: 800;
  padding: 4px 7px;
  border-radius: 999px;
  background: var(--gradient-main);
  color: #fff;
}

.char-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(9, 8, 13, 0.96) 5%, rgba(9, 8, 13, 0.35) 48%, transparent 75%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 12px;
}

.char-name {
  font-size: 16px;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 3px;
}
.char-age {
  font-weight: 500;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.7);
}
.char-desc {
  font-size: 11.5px;
  line-height: 1.35;
  color: rgba(255, 255, 255, 0.75);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 8px;
}

.char-stats {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11px;
  color: #d8b4fe;
  font-weight: 600;
}

/* Chats List View */
.chat-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.chat-list-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border-radius: var(--radius-md);
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  cursor: pointer;
  transition: border-color 0.2s;
}
.chat-list-item:hover {
  border-color: var(--border-glow);
}
.chat-list-item img {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--accent-pink);
}
.chat-item-info {
  flex: 1;
  min-width: 0;
}
.chat-item-top {
  display: flex;
  justify-content: space-between;
  margin-bottom: 4px;
}
.chat-item-top h4 {
  font-size: 15px;
  font-weight: 700;
}
.chat-item-time {
  font-size: 11px;
  color: var(--text-muted);
}
.chat-item-preview {
  font-size: 13px;
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Gallery View */
.gallery-counter {
  font-size: 12px;
  color: var(--text-secondary);
  font-weight: 600;
}

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

.gallery-card {
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  aspect-ratio: 3 / 4;
  border: 1px solid var(--border-subtle);
  background: #14111e;
  cursor: pointer;
}
.gallery-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: filter 0.4s ease, transform 0.4s ease;
}
.gallery-card.locked img {
  filter: blur(18px) brightness(0.6);
  transform: scale(1.12);
}
.gallery-lock-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-align: center;
  padding: 12px;
  background: rgba(9, 8, 13, 0.35);
}
.lock-circle {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255, 42, 133, 0.25);
  border: 1px solid rgba(255, 42, 133, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
}
.unlock-btn {
  padding: 7px 12px;
  border-radius: 999px;
  border: none;
  background: var(--gradient-main);
  color: #fff;
  font-size: 11.5px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 4px 16px rgba(255, 42, 133, 0.45);
}

/* ==================== CHAT ROOM VIEW ==================== */
.chat-room-view {
  position: relative;
  height: 100%;
}

.chat-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--border-subtle);
}

.back-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.06);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.chat-peer {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
  min-width: 0;
}

.avatar-wrap {
  position: relative;
  width: 42px;
  height: 42px;
  flex-shrink: 0;
}
.avatar-wrap img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--accent-pink);
}
.status-dot {
  position: absolute;
  bottom: 0;
  right: 0;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: #4ade80;
  border: 2px solid var(--bg-deep);
}

.peer-name-row {
  display: flex;
  align-items: center;
  gap: 6px;
}
.peer-name-row h3 {
  font-size: 15px;
  font-weight: 700;
}
.peer-badge {
  font-size: 10px;
  padding: 2px 6px;
  border-radius: 6px;
  background: rgba(168, 85, 247, 0.22);
  color: #d8b4fe;
  font-weight: 600;
}
.peer-status {
  font-size: 12px;
  color: #4ade80;
}
.peer-status.typing {
  color: #ff6aa8;
}

/* Messages Container */
.messages-container {
  flex: 1;
  overflow-y: auto;
  padding: 16px 14px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  scrollbar-width: none;
}
.messages-container::-webkit-scrollbar {
  display: none;
}

.msg-row {
  display: flex;
  flex-direction: column;
  max-width: 84%;
  animation: msgPop 0.25s cubic-bezier(0.2, 0.8, 0.2, 1);
}
@keyframes msgPop {
  from { opacity: 0; transform: translateY(8px) scale(0.97); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.msg-row.bot {
  align-self: flex-start;
}
.msg-row.user {
  align-self: flex-end;
}

.msg-bubble {
  padding: 11px 14px;
  border-radius: 18px;
  font-size: 14px;
  line-height: 1.45;
  word-wrap: break-word;
}
.msg-row.bot .msg-bubble {
  background: rgba(32, 28, 48, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-bottom-left-radius: 5px;
  color: var(--text-primary);
}
.msg-row.user .msg-bubble {
  background: var(--gradient-main);
  border-bottom-right-radius: 5px;
  color: #fff;
  box-shadow: 0 6px 20px rgba(255, 42, 133, 0.28);
}

.msg-time {
  font-size: 10px;
  color: var(--text-muted);
  margin-top: 4px;
  padding: 0 4px;
}
.msg-row.user .msg-time {
  text-align: right;
}

/* Photo Message Card (Blurred / Unlockable) */
.photo-msg-card {
  position: relative;
  width: 230px;
  aspect-ratio: 3 / 4;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid rgba(255, 42, 133, 0.35);
  background: #14111f;
  margin-top: 6px;
}
.photo-msg-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: filter 0.55s ease, transform 0.55s ease;
}
.photo-msg-card.blurred img {
  filter: blur(22px) brightness(0.55);
  transform: scale(1.12);
}
.photo-unlock-layer {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 16px;
  text-align: center;
  background: rgba(9, 8, 13, 0.3);
  transition: opacity 0.3s ease;
}
.photo-msg-card:not(.blurred) .photo-unlock-layer {
  opacity: 0;
  pointer-events: none;
}
.photo-unlock-label {
  font-size: 12px;
  font-weight: 700;
  color: #fff;
  text-shadow: 0 2px 8px rgba(0,0,0,0.7);
}
.photo-prompt-tag {
  position: absolute;
  bottom: 8px;
  left: 8px;
  right: 8px;
  font-size: 10px;
  padding: 4px 8px;
  border-radius: 8px;
  background: rgba(9, 8, 13, 0.72);
  backdrop-filter: blur(8px);
  color: #e9d5ff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Shimmer Generating Skeleton */
.generating-card {
  width: 230px;
  aspect-ratio: 3 / 4;
  border-radius: 16px;
  border: 1px solid rgba(255, 42, 133, 0.4);
  background: linear-gradient(135deg, #1a1329, #25142d);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 18px;
  position: relative;
  overflow: hidden;
}
.generating-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 25%, rgba(255, 42, 133, 0.16) 50%, transparent 75%);
  animation: sheen 1.6s infinite;
}
.spinner-ring {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 3px solid rgba(255, 42, 133, 0.25);
  border-top-color: var(--accent-pink);
  animation: spin 0.9s linear infinite;
}
@keyframes spin {
  to { transform: rotate(360deg); }
}
.gen-text {
  font-size: 12.5px;
  font-weight: 700;
  color: #fbcfe8;
  text-align: center;
}
.gen-sub {
  font-size: 10.5px;
  color: var(--text-secondary);
}

/* Quick Prompts */
.quick-prompts {
  display: flex;
  gap: 8px;
  padding: 8px 14px;
  overflow-x: auto;
  scrollbar-width: none;
}
.quick-prompts::-webkit-scrollbar {
  display: none;
}

.quick-chip {
  flex-shrink: 0;
  padding: 7px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-primary);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.18s;
}
.quick-chip:active {
  transform: scale(0.95);
}
.quick-chip.photo-chip {
  background: rgba(255, 42, 133, 0.18);
  border-color: rgba(255, 42, 133, 0.45);
  color: #ffb3d4;
}
.quick-chip .cost {
  color: var(--accent-gold);
  margin-left: 3px;
}

/* Chat Input Bar */
.chat-input-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px calc(10px + var(--safe-bottom));
  border-top: 1px solid var(--border-subtle);
}

.input-icon-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid rgba(255, 42, 133, 0.35);
  background: rgba(255, 42, 133, 0.14);
  color: #ff6aa8;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
}

#chat-input {
  flex: 1;
  height: 42px;
  border-radius: 999px;
  border: 1px solid var(--border-subtle);
  background: rgba(255, 255, 255, 0.06);
  padding: 0 16px;
  color: #fff;
  font-size: 14px;
  outline: none;
  transition: border-color 0.2s;
}
#chat-input:focus {
  border-color: var(--accent-pink);
}

.send-btn {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: none;
  background: var(--gradient-main);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  box-shadow: 0 4px 16px rgba(255, 42, 133, 0.45);
}
.send-btn:active {
  transform: scale(0.93);
}

/* Bottom Navigation */
.bottom-nav {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  display: flex;
  justify-content: space-around;
  padding: 10px 8px calc(10px + var(--safe-bottom));
  border-top: 1px solid var(--border-subtle);
  z-index: 20;
}
.bottom-nav.hidden {
  display: none;
}

.nav-item {
  position: relative;
  background: none;
  border: none;
  color: var(--text-muted);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  padding: 2px 12px;
  transition: color 0.2s;
}
.nav-item.active {
  color: var(--accent-pink);
}
.nav-item.vip-nav {
  color: var(--accent-gold);
}
.nav-badge {
  position: absolute;
  top: -2px;
  right: 6px;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  border-radius: 999px;
  background: var(--accent-pink);
  color: #fff;
  font-size: 10px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ==================== MODALS & BOTTOM SHEETS ==================== */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(6px);
  display: none;
  align-items: flex-end;
  justify-content: center;
  z-index: 100;
}
.modal-backdrop.open {
  display: flex;
  animation: fadeIn 0.2s ease;
}

.modal-sheet {
  width: 100%;
  max-width: 430px;
  border-radius: 26px 26px 0 0;
  border-top: 1px solid rgba(255, 255, 255, 0.14);
  padding: 12px 18px calc(22px + var(--safe-bottom));
  animation: slideUp 0.26s cubic-bezier(0.2, 0.8, 0.2, 1);
}
@keyframes slideUp {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

.sheet-handle {
  width: 40px;
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.2);
  margin: 0 auto 14px;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}
.modal-header h3 {
  font-size: 17px;
  font-weight: 800;
}
.close-modal {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  cursor: pointer;
}

.vip-card {
  border-radius: var(--radius-md);
  padding: 16px;
  background: linear-gradient(145deg, rgba(255, 42, 133, 0.2), rgba(147, 51, 234, 0.25));
  border: 1px solid rgba(255, 42, 133, 0.5);
  margin-bottom: 16px;
}
.vip-card-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}
.vip-pill {
  font-size: 11px;
  font-weight: 800;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--accent-gold);
  color: #000;
}
.vip-price {
  font-size: 15px;
  font-weight: 800;
  color: #fde68a;
}
.vip-card ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 12.5px;
  color: rgba(255, 255, 255, 0.88);
  margin-bottom: 14px;
}

.btn-primary {
  padding: 13px 16px;
  border-radius: 14px;
  border: none;
  background: var(--gradient-main);
  color: #fff;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  box-shadow: 0 8px 24px rgba(255, 42, 133, 0.4);
}
.full-width {
  width: 100%;
}

.sheet-subtitle, .sheet-desc {
  font-size: 12.5px;
  color: var(--text-secondary);
  margin-bottom: 12px;
  line-height: 1.45;
}

.packs-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
.pack-card {
  position: relative;
  padding: 14px 8px;
  border-radius: 14px;
  border: 1px solid var(--border-subtle);
  background: rgba(255, 255, 255, 0.04);
  color: #fff;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  cursor: pointer;
}
.pack-card.popular {
  border-color: var(--accent-pink);
  background: rgba(255, 42, 133, 0.14);
}
.pack-tag {
  position: absolute;
  top: -8px;
  font-size: 9px;
  font-weight: 800;
  padding: 2px 7px;
  border-radius: 999px;
  background: var(--accent-pink);
}
.pack-amount {
  font-size: 15px;
  font-weight: 800;
  color: #fde68a;
}
.pack-price {
  font-size: 11px;
  color: var(--text-secondary);
}

/* Dev API Form */
.form-group {
  margin-bottom: 14px;
}
.form-group label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 6px;
}
.form-group input[type="text"] {
  width: 100%;
  padding: 11px 13px;
  border-radius: 12px;
  border: 1px solid var(--border-subtle);
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
  font-size: 13px;
  outline: none;
}
.form-group input[type="text"]:focus {
  border-color: var(--accent-pink);
}

.toggle-row {
  display: flex !important;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
  cursor: pointer;
  color: #fff !important;
}
.toggle-row input {
  display: none;
}
.toggle-slider {
  width: 44px;
  height: 24px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  position: relative;
  transition: background 0.2s;
}
.toggle-slider::after {
  content: '';
  position: absolute;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #fff;
  top: 3px;
  left: 3px;
  transition: transform 0.2s;
}
.toggle-row input:checked + .toggle-slider {
  background: var(--accent-pink);
}
.toggle-row input:checked + .toggle-slider::after {
  transform: translateX(20px);
}

/* Lightbox */
.lightbox {
  align-items: center;
  flex-direction: column;
  padding: 20px;
}
.lightbox img {
  max-width: 100%;
  max-height: 75dvh;
  border-radius: 18px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.85);
}
.lightbox-close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
  font-size: 18px;
  cursor: pointer;
}
.lightbox-caption {
  margin-top: 12px;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.8);
  text-align: center;
}

/* Toast */
.toast {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%) translateY(-80px);
  padding: 10px 18px;
  border-radius: 999px;
  background: rgba(24, 21, 35, 0.95);
  border: 1px solid var(--accent-pink);
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  z-index: 200;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
  transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
  white-space: nowrap;
}
.toast.show {
  transform: translateX(-50%) translateY(0);
}


/* ==================== ONBOARDING OVERLAY (18+ & ПРЕДПОЧТЕНИЯ) ==================== */
.onboarding-overlay {
  position: absolute;
  inset: 0;
  z-index: 90;
  background: radial-gradient(circle at top right, rgba(255, 42, 133, 0.22), transparent 50%),
              radial-gradient(circle at bottom left, rgba(147, 51, 234, 0.24), transparent 55%),
              #09080d;
  display: flex;
  flex-direction: column;
  padding: 18px 20px calc(22px + var(--safe-bottom));
  transition: opacity 0.35s ease, transform 0.35s ease;
}
.onboarding-overlay.hidden {
  opacity: 0;
  pointer-events: none;
  transform: scale(1.03);
}

.ob-progress-wrap {
  width: 100%;
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  overflow: hidden;
  margin-bottom: 24px;
}
.ob-progress-bar {
  height: 100%;
  border-radius: 999px;
  background: var(--gradient-main);
  transition: width 0.35s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.ob-step {
  display: none;
  flex-direction: column;
  flex: 1;
  justify-content: space-between;
  animation: fadeIn 0.28s ease;
}
.ob-step.active {
  display: flex;
}

.ob-hero {
  text-align: center;
  margin-top: 12px;
}

.age-crest {
  width: 82px;
  height: 82px;
  margin: 0 auto 18px;
  border-radius: 26px;
  background: linear-gradient(145deg, rgba(255, 42, 133, 0.25), rgba(147, 51, 234, 0.3));
  border: 1.5px solid rgba(255, 42, 133, 0.65);
  box-shadow: 0 0 40px rgba(255, 42, 133, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 30px;
  font-weight: 800;
  color: #fff;
}

.ob-brand {
  justify-content: center;
  margin-bottom: 10px;
}

.ob-step h1 {
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -0.5px;
  margin-bottom: 10px;
}

.ob-subtitle {
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--text-secondary);
}

.ob-kicker {
  display: inline-block;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.8px;
  color: #ff6aa8;
  margin-bottom: 8px;
}

.ob-rules-card {
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 20px 0;
}
.ob-rule {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.88);
}
.ob-rule span {
  font-size: 16px;
}

.pref-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin: 18px 0;
}
.pref-card {
  position: relative;
  padding: 20px 14px;
  border-radius: var(--radius-md);
  border: 1.5px solid var(--border-subtle);
  background: rgba(255, 255, 255, 0.04);
  color: #fff;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
}
.pref-card:active {
  transform: scale(0.97);
}
.pref-card.selected {
  border-color: var(--accent-pink);
  background: linear-gradient(145deg, rgba(255, 42, 133, 0.2), rgba(147, 51, 234, 0.16));
  box-shadow: 0 8px 26px rgba(255, 42, 133, 0.22);
}
.pref-emoji {
  font-size: 32px;
  margin-bottom: 2px;
}
.pref-card strong {
  font-size: 15px;
  font-weight: 700;
}
.pref-card small {
  font-size: 11.5px;
  color: var(--text-secondary);
}
.pref-check {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--gradient-main);
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transform: scale(0.7);
  transition: all 0.2s ease;
}
.pref-card.selected .pref-check {
  opacity: 1;
  transform: scale(1);
}

.ob-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.btn-lg {
  padding: 15px 18px;
  font-size: 15px;
}
.btn-ghost {
  padding: 12px 16px;
  border-radius: 14px;
  border: 1px solid var(--border-subtle);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 13.5px;
  cursor: pointer;
}
.btn-outline {
  padding: 13px 16px;
  border-radius: 14px;
  border: 1px solid rgba(255, 42, 133, 0.45);
  background: rgba(255, 42, 133, 0.1);
  color: #ffb3d4;
  font-weight: 700;
  font-size: 13.5px;
  cursor: pointer;
}
.dev-btn-stack {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* ==================== CENTER CREATE FAB IN BOTTOM NAV ==================== */
.nav-create-btn {
  color: #fff !important;
  margin-top: -14px;
}
.create-fab {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--gradient-main);
  color: #fff;
  font-size: 26px;
  font-weight: 600;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 22px rgba(255, 42, 133, 0.55), 0 0 0 4px var(--bg-deep);
  transition: transform 0.18s ease;
}
.nav-create-btn:active .create-fab {
  transform: scale(0.92);
}

/* ==================== CHARACTER CREATOR VIEW ==================== */
.creator-view {
  position: relative;
}

.creator-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--border-subtle);
}
.creator-title-wrap {
  flex: 1;
}
.creator-title-wrap h2 {
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 6px;
}
.creator-steps-bar {
  display: flex;
  gap: 6px;
}
.step-seg {
  flex: 1;
  height: 3.5px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  transition: background 0.25s;
}
.step-seg.active {
  background: var(--gradient-main);
}

/* Live Preview Card */
.creator-preview-card {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 12px 16px 4px;
  padding: 10px 12px;
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 42, 133, 0.32);
  background: linear-gradient(135deg, rgba(255, 42, 133, 0.12), rgba(24, 21, 35, 0.85));
}
.creator-preview-card img {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  object-fit: cover;
  border: 1.5px solid var(--accent-pink);
  flex-shrink: 0;
}
.preview-meta {
  flex: 1;
  min-width: 0;
}
.preview-name-row {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 6px;
}
.preview-name-row strong {
  font-size: 15px;
}
.preview-age {
  font-size: 12.5px;
  color: var(--text-secondary);
}
.preview-style-pill {
  font-size: 10px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 999px;
  background: rgba(168, 85, 247, 0.25);
  color: #e9d5ff;
}
.preview-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}
.preview-tag {
  font-size: 10.5px;
  padding: 2px 7px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.85);
}

.creator-body {
  padding-bottom: 24px !important;
}

.creator-step {
  display: none;
  flex-direction: column;
  gap: 18px;
  animation: fadeIn 0.22s ease;
}
.creator-step.active {
  display: flex;
}

.creator-section {
  display: flex;
  flex-direction: column;
  gap: 9px;
}
.creator-label {
  font-size: 12.5px;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.85);
}
.creator-label small {
  font-weight: 500;
  color: var(--text-muted);
}

.segmented-row {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.seg-group {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  padding: 4px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
}
.seg-btn {
  padding: 10px;
  border-radius: 10px;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
}
.seg-btn.active {
  background: var(--gradient-main);
  color: #fff;
  box-shadow: 0 4px 14px rgba(255, 42, 133, 0.35);
}

/* Archetype Grid */
.archetype-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}
.arch-card {
  padding: 13px 12px;
  border-radius: 15px;
  border: 1.5px solid var(--border-subtle);
  background: rgba(255, 255, 255, 0.035);
  color: #fff;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 4px;
  cursor: pointer;
  transition: all 0.2s;
}
.arch-card.active {
  border-color: var(--accent-pink);
  background: linear-gradient(145deg, rgba(255, 42, 133, 0.2), rgba(147, 51, 234, 0.16));
  box-shadow: 0 6px 20px rgba(255, 42, 133, 0.2);
}
.arch-emoji {
  font-size: 22px;
  margin-bottom: 2px;
}
.arch-card strong {
  font-size: 13.5px;
  font-weight: 700;
}
.arch-card small {
  font-size: 11px;
  color: var(--text-secondary);
  line-height: 1.3;
}

/* Chips & Swatches */
.chips-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.choice-chip {
  padding: 9px 13px;
  border-radius: 12px;
  border: 1px solid var(--border-subtle);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-secondary);
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.18s;
}
.choice-chip.active {
  background: rgba(255, 42, 133, 0.2);
  border-color: var(--accent-pink);
  color: #fff;
}

.swatch-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}
.swatch-btn {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 9px 11px;
  border-radius: 12px;
  border: 1px solid var(--border-subtle);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-secondary);
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
}
.swatch-btn.active {
  border-color: var(--accent-pink);
  background: rgba(255, 42, 133, 0.18);
  color: #fff;
}
.swatch-dot {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 255, 255, 0.35);
  flex-shrink: 0;
}

/* Age Slider */
.label-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.range-val {
  font-size: 13px;
  font-weight: 700;
  color: #ff6aa8;
}
.neon-slider {
  -webkit-appearance: none;
  width: 100%;
  height: 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  outline: none;
}
.neon-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--gradient-main);
  box-shadow: 0 0 14px rgba(255, 42, 133, 0.7);
  cursor: pointer;
}

/* Name input */
.name-input-row {
  display: flex;
  gap: 8px;
}
.name-input-row input {
  flex: 1;
  padding: 12px 14px;
  border-radius: 13px;
  border: 1px solid var(--border-subtle);
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  outline: none;
}
.name-input-row input:focus {
  border-color: var(--accent-pink);
}
.random-name-btn {
  width: 46px;
  border-radius: 13px;
  border: 1px solid var(--border-subtle);
  background: rgba(255, 255, 255, 0.06);
  font-size: 18px;
  cursor: pointer;
}

/* Prompt Preview Box */
.prompt-preview-box {
  border-radius: 13px;
  border: 1px dashed rgba(168, 85, 247, 0.45);
  background: rgba(168, 85, 247, 0.08);
  padding: 10px 12px;
  font-size: 12px;
}
.prompt-preview-box summary {
  cursor: pointer;
  font-weight: 700;
  color: #d8b4fe;
}
.prompt-code {
  margin-top: 8px;
  font-family: ui-monospace, SFMono-Regular, monospace;
  font-size: 11px;
  line-height: 1.45;
  color: rgba(255, 255, 255, 0.8);
  word-break: break-word;
}

/* Creator Footer */
.creator-footer {
  display: flex;
  gap: 10px;
  padding: 12px 16px calc(14px + var(--safe-bottom));
  border-top: 1px solid var(--border-subtle);
}
.flex-1 {
  flex: 1;
}

/* Creating Overlay */
.creating-overlay {
  position: absolute;
  inset: 0;
  z-index: 50;
  background: rgba(9, 8, 13, 0.92);
  backdrop-filter: blur(12px);
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 24px;
  text-align: center;
}
.creating-overlay.open {
  display: flex;
  animation: fadeIn 0.2s ease;
}
.spinner-ring.large {
  width: 52px;
  height: 52px;
  border-width: 4px;
}
.creating-overlay h3 {
  font-size: 18px;
  font-weight: 800;
}
.creating-overlay p {
  font-size: 13px;
  color: var(--text-secondary);
}

.char-custom-badge {
  font-size: 10px;
  font-weight: 800;
  padding: 4px 7px;
  border-radius: 999px;
  background: linear-gradient(135deg, #fbbf24, #f59e0b);
  color: #000;
}


/* ==================== SIMS-STYLE LIVE CHARACTER EDITOR ==================== */
.sims-stage {
  position: relative;
  height: 44%;
  min-height: 270px;
  max-height: 360px;
  width: 100%;
  background: #0d0a16;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.stage-top-bar {
  position: absolute;
  top: 12px;
  left: 12px;
  right: 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 5;
}

.stage-right-tools {
  display: flex;
  gap: 8px;
}

.stage-pill-btn {
  padding: 7px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(9, 8, 13, 0.65);
  backdrop-filter: blur(10px);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.18s;
}
.stage-pill-btn:active {
  transform: scale(0.94);
}
.stage-pill-btn.active {
  border-color: var(--accent-pink);
  background: rgba(255, 42, 133, 0.35);
}

.stage-avatar-wrap {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.38s cubic-bezier(0.2, 0.8, 0.2, 1);
  transform-origin: center 42%;
}
.stage-avatar-wrap.zoomed {
  transform: scale(1.58) translateY(8%);
}
.stage-avatar-wrap svg {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.stage-identity {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 24px 14px 10px;
  background: linear-gradient(to top, rgba(9, 8, 13, 0.92) 15%, transparent 100%);
  z-index: 4;
  pointer-events: none;
}
.stage-name-row {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 5px;
}
.stage-name-row strong {
  font-size: 17px;
  font-weight: 800;
}
.stage-age {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.72);
}

/* Sims Category Tabs */
.sims-tabs {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  border-bottom: 1px solid var(--border-subtle);
  padding: 4px 6px;
  gap: 4px;
}
.sims-tab {
  padding: 8px 4px;
  border-radius: 11px;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  font-size: 10.5px;
  font-weight: 700;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  cursor: pointer;
  transition: all 0.18s;
}
.sims-tab span {
  font-size: 16px;
}
.sims-tab.active {
  background: rgba(255, 42, 133, 0.18);
  color: #fff;
  box-shadow: inset 0 0 0 1px rgba(255, 42, 133, 0.45);
}

/* Drawer Panels */
.sims-drawer {
  flex: 1;
  padding: 14px 14px 18px !important;
}
.sims-panel {
  display: none;
  flex-direction: column;
  gap: 16px;
  animation: fadeIn 0.2s ease;
}
.sims-panel.active {
  display: flex;
}

.seg-pair {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* Hairstyle Visual Thumbnail Grid */
.hair-thumb-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 9px;
}
.hair-thumb-card {
  padding: 8px 6px;
  border-radius: 14px;
  border: 1.5px solid var(--border-subtle);
  background: rgba(255, 255, 255, 0.035);
  color: var(--text-secondary);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  cursor: pointer;
  transition: all 0.18s;
}
.hair-thumb-card span {
  font-size: 11px;
  font-weight: 600;
  text-align: center;
}
.hair-thumb-card.active {
  border-color: var(--accent-pink);
  background: rgba(255, 42, 133, 0.18);
  color: #fff;
  box-shadow: 0 4px 16px rgba(255, 42, 133, 0.25);
}

/* Circle Swatches (Skin & Eyes) */
.circle-swatch-row {
  display: flex;
  gap: 12px;
  align-items: center;
}
.circle-swatch {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 2.5px solid rgba(255, 255, 255, 0.22);
  cursor: pointer;
  transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease;
}
.circle-swatch:active {
  transform: scale(0.92);
}
.circle-swatch.active {
  border-color: #fff;
  transform: scale(1.1);
  box-shadow: 0 0 0 3px var(--accent-pink), 0 0 18px rgba(255, 42, 133, 0.6);
}


/* ==================== FULLSCREEN RPG / GACHA CHARACTER CUSTOMIZER ==================== */
.fullscreen-creator {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #08070d;
}

.hero-stage {
  position: absolute;
  inset: 0;
  z-index: 1;
  overflow: hidden;
}

.hero-stage img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 18%;
  transition: transform 0.42s cubic-bezier(0.2, 0.8, 0.2, 1), filter 0.35s ease, opacity 0.22s ease;
}

.hero-stage.zoomed img {
  transform: scale(1.42) translateY(8%);
}

.hero-vignette {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(8, 7, 13, 0.62) 0%,
    rgba(8, 7, 13, 0.05) 26%,
    rgba(8, 7, 13, 0.12) 52%,
    rgba(8, 7, 13, 0.92) 86%,
    rgba(8, 7, 13, 0.98) 100%
  );
  pointer-events: none;
}

.hero-color-tint {
  position: absolute;
  inset: 0;
  mix-blend-mode: soft-light;
  opacity: 0.35;
  pointer-events: none;
  transition: background 0.35s ease;
}

/* Floating Top-Left Header */
.hud-top-left {
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: 6;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.hud-kicker {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 16px;
  font-weight: 800;
  letter-spacing: 0.6px;
  color: #fff;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.8);
  padding-left: 8px;
  border-left: 3px solid var(--accent-pink);
  margin-bottom: 6px;
}

.hud-cat-banner {
  display: inline-block;
  padding: 5px 14px;
  border-radius: 6px;
  background: linear-gradient(90deg, rgba(255, 42, 133, 0.42), rgba(147, 51, 234, 0.15));
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.18);
  font-size: 12.5px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 6px;
}

.hud-char-pill {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.85);
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.9);
}

/* Floating Right Vertical Tools Rail */
.hud-right-rail {
  position: absolute;
  right: 12px;
  top: 30%;
  z-index: 8;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.rail-btn {
  width: 54px;
  padding: 8px 4px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(12, 10, 20, 0.56);
  backdrop-filter: blur(10px);
  color: #fff;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  cursor: pointer;
  transition: all 0.18s;
}
.rail-btn span {
  font-size: 16px;
}
.rail-btn small {
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.2px;
}
.rail-btn.active {
  border-color: var(--accent-pink);
  background: rgba(255, 42, 133, 0.35);
}
.rail-btn:active {
  transform: scale(0.93);
}

/* Fullscreen Preview Mode (Hides HUD except right rail) */
.fullscreen-creator.hud-hidden .hud-top-left,
.fullscreen-creator.hud-hidden .hud-bottom {
  opacity: 0;
  pointer-events: none;
  transform: translateY(16px);
}

/* Floating Bottom HUD */
.hud-bottom {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 7;
  padding: 0 12px calc(14px + var(--safe-bottom));
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

/* Submode diamond/pill switches above carousel */
.hud-submodes {
  display: flex;
  gap: 8px;
  align-items: center;
  padding: 0 2px;
}
.submode-btn {
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(15, 12, 24, 0.68);
  backdrop-filter: blur(10px);
  color: rgba(255, 255, 255, 0.8);
  font-size: 11.5px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.18s;
}
.submode-btn.active {
  background: var(--gradient-main);
  border-color: rgba(255, 255, 255, 0.5);
  color: #fff;
  box-shadow: 0 4px 16px rgba(255, 42, 133, 0.45);
}

/* Horizontal Portrait Thumbnail Carousel (Matches Screenshot!) */
.hud-carousel-wrap {
  width: 100%;
  overflow: hidden;
}
.hud-carousel {
  display: flex;
  gap: 9px;
  overflow-x: auto;
  padding: 4px 2px 6px;
  scrollbar-width: none;
}
.hud-carousel::-webkit-scrollbar {
  display: none;
}

.carousel-card {
  position: relative;
  flex-shrink: 0;
  width: 82px;
  height: 112px;
  border-radius: 12px;
  overflow: hidden;
  border: 2px solid rgba(255, 255, 255, 0.18);
  background: rgba(18, 15, 28, 0.85);
  cursor: pointer;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
  padding: 0;
}
.carousel-card:active {
  transform: scale(0.95);
}
.carousel-card.active {
  border-color: #fbbf24;
  box-shadow: 0 0 0 2px rgba(251, 191, 36, 0.35), 0 8px 20px rgba(0, 0, 0, 0.65);
  transform: translateY(-3px);
}

.carousel-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 20%;
  display: block;
}

.carousel-card-label {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 14px 4px 5px;
  background: linear-gradient(to top, rgba(8, 7, 13, 0.94) 20%, transparent 100%);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.carousel-swatch-fill {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
}

/* Persona compact glass panel */
.hud-persona-panel {
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  padding: 11px;
  display: flex;
  flex-direction: column;
  gap: 9px;
}
.persona-top-row {
  display: flex;
  gap: 8px;
  align-items: center;
}
.age-mini-box {
  width: 105px;
  font-size: 11px;
  font-weight: 700;
  color: #ffb3d4;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.chips-wrap.compact {
  gap: 6px;
}
.chips-wrap.compact .choice-chip {
  padding: 6px 10px;
  font-size: 11.5px;
}
.prompt-preview-box.compact {
  padding: 7px 10px;
  font-size: 11px;
}

/* 4 Main RPG Category Tabs */
.rpg-cat-tabs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
}
.rpg-tab {
  padding: 10px 6px;
  border-radius: 9px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(10px);
  color: rgba(255, 255, 255, 0.88);
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.18s;
}
.rpg-tab.active {
  background: var(--gradient-main);
  border-color: rgba(255, 255, 255, 0.5);
  color: #fff;
  box-shadow: 0 4px 16px rgba(255, 42, 133, 0.45);
}

/* Bottom Action Bar (<< | Home | Apply | Randomize) */
.rpg-action-bar {
  display: flex;
  align-items: center;
  gap: 8px;
}
.rpg-icon-btn {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(15, 12, 24, 0.78);
  color: #fff;
  font-size: 18px;
  font-weight: 700;
  cursor: pointer;
  flex-shrink: 0;
}
.rpg-apply-btn {
  flex: 1;
  height: 44px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  background: var(--gradient-main);
  color: #fff;
  font-size: 15px;
  font-weight: 800;
  letter-spacing: 0.3px;
  cursor: pointer;
  box-shadow: 0 6px 24px rgba(255, 42, 133, 0.5);
}
.rpg-rand-btn {
  height: 44px;
  padding: 0 13px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  background: rgba(15, 12, 24, 0.78);
  color: #fff;
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
  flex-shrink: 0;
}
.rpg-apply-btn:active,
.rpg-rand-btn:active,
.rpg-icon-btn:active {
  transform: scale(0.95);
}


/* ==================== VOICE (ELEVENLABS) & VIDEO (WAN 2.2) IN CHAT ==================== */
.msg-actions-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 5px;
}

.voice-btn, .animate-video-btn {
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid rgba(168, 85, 247, 0.45);
  background: rgba(168, 85, 247, 0.16);
  color: #e9d5ff;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.18s;
}
.voice-btn:hover, .animate-video-btn:hover {
  background: rgba(168, 85, 247, 0.3);
}
.voice-btn:disabled, .animate-video-btn:disabled {
  opacity: 0.5;
  cursor: wait;
}

.msg-audio {
  width: 220px;
  height: 32px;
  margin-top: 6px;
  border-radius: 999px;
}

.video-msg-card {
  width: 230px;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid rgba(56, 189, 248, 0.5);
  background: #0b0d14;
  margin-top: 6px;
}
.video-msg-card video {
  width: 100%;
  display: block;
}


/* ==================== PUSH NOTIFICATION BANNER ==================== */
.push-banner {
  position: absolute;
  top: 10px;
  left: 12px;
  right: 12px;
  z-index: 150;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 16px;
  border: 1px solid rgba(255, 42, 133, 0.55);
  box-shadow: 0 12px 34px rgba(0, 0, 0, 0.72);
  cursor: pointer;
  transform: translateY(-130%);
  opacity: 0;
  transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 0.25s ease;
}
.push-banner.show {
  transform: translateY(0);
  opacity: 1;
}
.push-banner img {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  border: 1.5px solid var(--accent-pink);
  flex-shrink: 0;
}
.push-body {
  flex: 1;
  min-width: 0;
}
.push-top {
  display: flex;
  justify-content: space-between;
  font-size: 12.5px;
  margin-bottom: 2px;
}
.push-top span {
  font-size: 10.5px;
  color: var(--text-muted);
}
.push-body p {
  font-size: 12px;
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ==================== ONBOARDING 2-CARD STYLE PICKER ==================== */
.style-pick-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin: 18px 0;
}
.style-pick-card {
  position: relative;
  aspect-ratio: 3 / 4.2;
  border-radius: 18px;
  overflow: hidden;
  border: 2px solid var(--border-subtle);
  background: #14111f;
  padding: 0;
  cursor: pointer;
  transition: transform 0.18s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}
.style-pick-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.style-pick-card.selected {
  border-color: var(--accent-pink);
  box-shadow: 0 10px 28px rgba(255, 42, 133, 0.32);
}
.style-pick-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(9, 8, 13, 0.94) 10%, transparent 62%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 14px 12px;
  text-align: left;
  color: #fff;
}
.style-pick-overlay strong {
  font-size: 16px;
  font-weight: 800;
}
.style-pick-overlay small {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.72);
  margin-top: 2px;
}
.style-pick-card.selected .pref-check {
  opacity: 1;
  transform: scale(1);
}

/* ==================== PART-BY-PART CREATOR & 3D SCAN EFFECT ==================== */
.creator-sub-hint {
  font-size: 11px;
  color: var(--text-muted);
}
.creator-builder {
  flex: 1;
  padding: 14px 16px 24px !important;
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.role-textarea {
  width: 100%;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--border-subtle);
  background: rgba(255, 255, 255, 0.045);
  color: #fff;
  font-family: inherit;
  font-size: 12.5px;
  line-height: 1.4;
  resize: none;
  outline: none;
}
.role-textarea:focus {
  border-color: var(--accent-pink);
}

/* Result Review Screen */
.creator-result-screen {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 14px 16px 20px;
  gap: 14px;
  justify-content: space-between;
}
.result-portrait-frame {
  position: relative;
  flex: 1;
  border-radius: 22px;
  overflow: hidden;
  border: 1.5px solid rgba(255, 42, 133, 0.45);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.65);
  background: #120f1c;
}
.result-portrait-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.result-badge {
  position: absolute;
  bottom: 14px;
  left: 14px;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(9, 8, 13, 0.78);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.16);
  font-size: 14px;
  font-weight: 800;
}
.result-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.result-secondary-row {
  display: flex;
  gap: 8px;
}

/* 3D Holographic Scan Overlay */
.scan-overlay {
  position: absolute;
  inset: 0;
  z-index: 60;
  background: radial-gradient(circle at center, #181028 0%, #07060c 100%);
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 24px;
  text-align: center;
}
.scan-overlay.open {
  display: flex;
  animation: fadeIn 0.22s ease;
}
.scan-stage {
  position: relative;
  width: 220px;
  height: 270px;
  border-radius: 20px;
  border: 1.5px solid rgba(56, 189, 248, 0.45);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(15, 18, 34, 0.75);
  box-shadow: 0 0 40px rgba(168, 85, 247, 0.25), inset 0 0 30px rgba(56, 189, 248, 0.12);
}
.scan-grid-bg {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(56, 189, 248, 0.12) 1px, transparent 1px),
    linear-gradient(90deg, rgba(56, 189, 248, 0.12) 1px, transparent 1px);
  background-size: 20px 20px;
  animation: gridScroll 3s linear infinite;
}
@keyframes gridScroll {
  from { background-position: 0 0; }
  to { background-position: 0 40px; }
}
.scan-silhouette {
  position: relative;
  z-index: 2;
  animation: pulse 2s ease-in-out infinite;
}
.scan-beam {
  position: absolute;
  left: 0;
  right: 0;
  height: 4px;
  z-index: 3;
  background: linear-gradient(90deg, transparent, #38bdf8, #ff2a85, #38bdf8, transparent);
  box-shadow: 0 0 18px #38bdf8, 0 0 28px #ff2a85;
  animation: scanSweep 2.1s ease-in-out infinite;
}
@keyframes scanSweep {
  0% { top: 4%; }
  50% { top: 94%; }
  100% { top: 4%; }
}
.scan-percent {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 26px;
  font-weight: 800;
  background: linear-gradient(90deg, #38bdf8, #ff2a85);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
.scan-overlay h3 {
  font-size: 17px;
  font-weight: 800;
}
.scan-overlay p {
  font-size: 12.5px;
  color: var(--text-secondary);
}

/* ==================== TELEGRAM VOICE SPECTROGRAM PLAYER ==================== */
.tg-voice-player {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 6px;
  padding: 8px 11px;
  border-radius: 16px;
  background: rgba(25, 22, 38, 0.92);
  border: 1px solid rgba(255, 42, 133, 0.28);
  width: 245px;
}
.tg-play-btn {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: none;
  background: var(--gradient-main);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(255, 42, 133, 0.4);
}
.tg-waveform-wrap {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}
.tg-waveform {
  display: flex;
  align-items: center;
  gap: 2.5px;
  height: 24px;
  cursor: pointer;
}
.wf-bar {
  flex: 1;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.24);
  transition: background 0.12s ease;
}
.wf-bar.played {
  background: var(--accent-pink);
}
.tg-voice-dur {
  font-size: 10px;
  color: var(--text-muted);
  font-family: ui-monospace, Consolas, monospace;
}

/* ==================== TELEGRAM VIDEO CIRCLES (КРУЖОЧКИ) ==================== */
.tg-video-circle-wrap {
  position: relative;
  width: 210px;
  height: 210px;
  margin-top: 6px;
  border-radius: 50%;
  padding: 3px;
  background: linear-gradient(135deg, #ff2a85, #a855f7, #38bdf8);
  box-shadow: 0 12px 32px rgba(255, 42, 133, 0.32);
  cursor: pointer;
}
.tg-video-circle {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  overflow: hidden;
  background: #09080d;
  position: relative;
}
.tg-video-circle video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.circle-badge {
  position: absolute;
  bottom: 10px;
  left: 50%;
  transform: translateX(-50%);
  padding: 3px 9px;
  border-radius: 999px;
  background: rgba(9, 8, 13, 0.72);
  backdrop-filter: blur(6px);
  font-size: 10px;
  font-weight: 700;
  color: #fff;
  white-space: nowrap;
}

/* ==================== CHAT UNREAD BADGE & SHARED MEDIA SHEET ==================== */
.chat-peer {
  cursor: pointer;
}
.chat-unread-pill {
  min-width: 22px;
  height: 22px;
  padding: 0 6px;
  border-radius: 999px;
  background: var(--accent-pink);
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.media-sheet {
  max-height: 75dvh;
  display: flex;
  flex-direction: column;
}
.media-tabs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  margin-bottom: 12px;
  padding: 4px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.04);
}
.media-tab {
  padding: 8px;
  border-radius: 9px;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
}
.media-tab.active {
  background: var(--gradient-main);
  color: #fff;
}
.media-sheet-body {
  overflow-y: auto;
  min-height: 160px;
  max-height: 52dvh;
}
.media-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}
.media-thumb {
  aspect-ratio: 1;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--border-subtle);
  cursor: pointer;
  background: #14111f;
}
.media-thumb img, .media-thumb video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.media-thumb.circle-thumb {
  border-radius: 50%;
  border: 2px solid var(--accent-pink);
}
.media-audio-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.media-empty {
  text-align: center;
  padding: 36px 16px;
  color: var(--text-muted);
  font-size: 13px;
}


/* ==================== POLISHED CHAT HEADER PILLS & AFFECTION BAR ==================== */
.chat-header-actions {
  display: flex;
  align-items: center;
  gap: 7px;
}

.header-pill-btn {
  width: 34px;
  height: 34px;
  border-radius: 11px;
  border: 1px solid rgba(255, 255, 255, 0.11);
  background: rgba(255, 255, 255, 0.05);
  color: rgba(255, 255, 255, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.18s ease;
}
.header-pill-btn:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 42, 133, 0.45);
  color: #fff;
}
.header-pill-btn:active {
  transform: scale(0.93);
}

.star-pill-pro {
  height: 34px;
  padding: 0 11px;
  border-radius: 11px;
  border: 1px solid rgba(251, 191, 36, 0.32);
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.14), rgba(245, 158, 11, 0.06));
  color: #fde68a;
  font-size: 12.5px;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 5px;
  cursor: pointer;
  transition: all 0.18s ease;
}
.star-pill-pro:hover {
  border-color: rgba(251, 191, 36, 0.65);
  background: rgba(251, 191, 36, 0.2);
}
.star-pill-pro:active {
  transform: scale(0.94);
}
.tg-star-svg {
  filter: drop-shadow(0 0 6px rgba(251, 191, 36, 0.55));
}

.affection-strip {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 14px;
  background: rgba(14, 12, 22, 0.86);
  border-bottom: 1px solid var(--border-subtle);
}
.affection-label {
  font-size: 10.5px;
  font-weight: 700;
  color: #f9a8d4;
  white-space: nowrap;
}
.affection-track {
  flex: 1;
  height: 5px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}
.affection-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #ff2a85, #fbbf24);
  transition: width 0.55s cubic-bezier(0.2, 0.8, 0.2, 1);
  box-shadow: 0 0 10px rgba(255, 42, 133, 0.6);
}

/* ==================== LUXURY ANIMATED GIFTS ==================== */
.gift-trigger-btn {
  border-color: rgba(251, 191, 36, 0.45) !important;
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.18), rgba(255, 42, 133, 0.16)) !important;
  color: #fde68a !important;
}

.sheet-mini-sub {
  font-size: 11.5px;
  color: var(--text-muted);
  margin-top: 2px;
}

.gifts-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  max-height: 58dvh;
  overflow-y: auto;
  padding-bottom: 4px;
}

.gift-card {
  position: relative;
  padding: 14px 10px 12px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: linear-gradient(155deg, rgba(28, 22, 44, 0.9), rgba(14, 12, 22, 0.95));
  color: #fff;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  cursor: pointer;
  overflow: hidden;
  transition: transform 0.18s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}
.gift-card.legendary {
  border-color: rgba(251, 191, 36, 0.48);
  background: linear-gradient(155deg, rgba(64, 34, 24, 0.55), rgba(28, 16, 40, 0.95));
}
.gift-card:hover {
  border-color: var(--accent-pink);
  box-shadow: 0 8px 24px rgba(255, 42, 133, 0.22);
}
.gift-card:active {
  transform: scale(0.95);
}

.gift-anim-icon {
  font-size: 40px;
  line-height: 1.1;
  filter: drop-shadow(0 6px 14px rgba(255, 42, 133, 0.45));
  animation: giftFloat 2.8s ease-in-out infinite;
}
@keyframes giftFloat {
  0%, 100% { transform: translateY(0) scale(1) rotate(-2deg); }
  50% { transform: translateY(-6px) scale(1.08) rotate(3deg); }
}

.gift-name {
  font-size: 13px;
  font-weight: 700;
  text-align: center;
}
.gift-boost {
  font-size: 10.5px;
  font-weight: 700;
  color: #f9a8d4;
}
.gift-price-pill {
  margin-top: 3px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(251, 191, 36, 0.16);
  border: 1px solid rgba(251, 191, 36, 0.4);
  color: #fde68a;
  font-size: 12px;
  font-weight: 800;
}

/* Animated Gift Sticker Bubble inside Chat */
.gift-sticker-msg {
  width: 215px;
  padding: 16px 14px 12px;
  border-radius: 20px;
  background: linear-gradient(145deg, rgba(255, 42, 133, 0.24), rgba(147, 51, 234, 0.28), rgba(251, 191, 36, 0.16));
  border: 1.5px solid rgba(251, 191, 36, 0.55);
  box-shadow: 0 12px 32px rgba(255, 42, 133, 0.28);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  text-align: center;
  position: relative;
  overflow: hidden;
  animation: giftPop 0.45s cubic-bezier(0.18, 0.9, 0.3, 1.2);
}
@keyframes giftPop {
  0% { transform: scale(0.6); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}
.gift-sticker-msg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, transparent 30%, rgba(255, 255, 255, 0.18) 50%, transparent 70%);
  animation: sheen 3.2s infinite;
  pointer-events: none;
}
.gift-sticker-emoji {
  font-size: 62px;
  line-height: 1;
  filter: drop-shadow(0 8px 20px rgba(251, 191, 36, 0.5));
  animation: giftFloat 2.4s ease-in-out infinite;
}
.gift-sticker-title {
  font-size: 13.5px;
  font-weight: 800;
  color: #fff;
}
.gift-sticker-meta {
  font-size: 11px;
  font-weight: 700;
  color: #fde68a;
}

/* ==================== VIP BADGE ==================== */
.vip-top-badge {
  font-size: 10px;
  font-weight: 800;
  color: #1c1304;
  background: linear-gradient(135deg, #fde047, #f59e0b);
  padding: 2px 8px;
  border-radius: 999px;
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.45);
  letter-spacing: 0.3px;
}
