/* ============================================================
   TealRiot — MVP Frontend Styles
   Dark theme, violet accent, matching logo palette
   ============================================================ */

:root {
  --bg-darkest: #020204;
  --bg-dark: #060610;
  --bg-card: #050509;
  --bg-input: #050509;
  --bg: #020204;
  --nav-bg: #040408;
  --bg-darker: #010102;
  --teal: #c48de8;
  --teal-dim: #a06bc8;
  --teal-dark: #7c3aed;
  --teal-soft: #c48de8;
  --teal-glow: 0 0 14px rgba(196,141,232,0.3);
  --purple: #c48de8;
  --purple-dim: #a06bc8;
  --purple-soft: #d4a8f0;
  --purple-glow: 0 0 14px rgba(196,141,232,0.3);
  --blue: #c48de8;
  --blue-dim: #00a8cc;
  --blue-soft: #33e0ff;
  --text: #ffffff;
  --text-dim: #b8b8c8;
  --text-muted: #7878a0;
  --text-very-muted: #484868;
  --border: #0e0e20;
  --border-hover: #141430;
  --danger: #ff4757;
  --radius: 16px;
  --radius-sm: 12px;
  --max-width: 100%;
  --header-h: 53px;
  --left-nav-w: 260px;
  --right-sidebar-w: 350px;
}

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

body {
  background: var(--bg-darkest);
  color: var(--text);
  font-family: 'Space Grotesk', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}

a {
  color: var(--text);
  text-decoration: none;
}

a:hover { text-decoration: underline; }

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  outline: none;
}

input, textarea {
  font-family: inherit;
  outline: none;
}

/* ============================================================
   Auth Screen
   ============================================================ */

.auth-screen {
  display: none;
}

.auth-screen.active {
  display: block;
  padding: 60px 20px 0;
}

.auth-screen.active .auth-card {
  margin: 0 auto;
}

/* Anti-flash: if token detected, hide auth screen before JS loads */
html.tr-authed .auth-screen { display: none !important; }

/* NOTE: showAuth() handles adding .active class when user is NOT authenticated.
   The old override `html.tr-authed .auth-screen.active { display: block !important }`
   was causing the auth screen to flash visible on every refresh for logged-in users. */

.auth-card {
  background: rgba(6, 6, 12, 0.9);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 44px 40px;
  max-width: 400px;
  width: 100%;
  text-align: center;
}

.auth-card .logo {
  width: 80px;
  height: 80px;
  border-radius: 20px;
  margin: 0 auto 20px;
  display: block;
}

.auth-card h1 {
  font-size: 1.8rem;
  font-weight: 800;
  background: linear-gradient(135deg, var(--blue), var(--blue-dim));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 6px;
}

.auth-card .tagline {
  color: var(--teal-soft);
  font-size: 0.9rem;
  margin-bottom: 32px;
}

.auth-tabs {
  display: flex;
  gap: 4px;
  background: var(--bg-input);
  border-radius: var(--radius-sm);
  padding: 4px;
  margin-bottom: 24px;
}

.auth-tabs button {
  flex: 1;
  padding: 10px;
  background: transparent;
  color: var(--text-dim);
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.9rem;
  transition: all 0.2s;
}

.auth-tabs button.active {
  background: var(--bg-darkest);
  color: var(--teal);
  border: 1.5px solid var(--teal);
}

.auth-field {
  margin-bottom: 16px;
  text-align: left;
}

.auth-field label {
  display: block;
  font-size: 0.8rem;
  color: var(--text-dim);
  margin-bottom: 6px;
  font-weight: 600;
}

.auth-field input {
  width: 100%;
  padding: 12px 14px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 0.95rem;
  transition: border-color 0.2s;
}

.auth-field input:focus {
  border-color: var(--text);
}

.auth-field input::placeholder {
  color: var(--text-muted);
}

.btn-primary {
  width: 100%;
  padding: 13px;
  background: var(--bg-darkest);
  color: var(--purple);
  border: 1.5px solid var(--purple);
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: 0.95rem;
  margin-top: 8px;
  transition: all 0.2s;
}

.btn-primary:hover { box-shadow: 0 0 14px rgba(196,141,232,0.25); }
.btn-primary:active { transform: scale(0.98); }
.btn-primary:disabled { opacity: 0.5; cursor: not-allowed; }

.auth-error {
  color: var(--danger);
  font-size: 0.85rem;
  margin-top: 12px;
  min-height: 20px;
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 24px 0 16px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  text-transform: uppercase;
}
.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}

.btn-nucleus {
  width: 100%;
  padding: 13px;
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.2s;
}
.btn-nucleus:hover {
  border-color: var(--teal-dim);
  background: rgba(196, 141, 232, 0.06);
}

.nav-ecosystem {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-dim);
  text-decoration: none;
  transition: all 0.15s;
}

.nav-ecosystem:hover {
  background: rgba(196, 141, 232, 0.1);
  color: var(--text);
}

/* Topbar search bar */
.search-bar {
  flex: 1;
  max-width: 420px;
  margin: 0 16px;
  position: relative;
}

.search-bar input {
  width: 100%;
  height: 44px;
  padding: 0 16px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 22px;
  color: var(--text);
  font-size: 0.92rem;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.search-bar input:focus {
  border-color: var(--text);
  box-shadow: 0 0 0 2px rgba(196, 141, 232, 0.08);
}

.search-bar input::placeholder {
  color: var(--text-muted);
}

.search-dropdown {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  background: var(--bg-card);
  border: 1px solid var(--teal-dim);
  border-radius: var(--radius-sm);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
  z-index: 500;
  max-height: 400px;
  overflow-y: auto;
}

.search-group {
  padding: 8px 14px 4px;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-muted);
}

.search-result {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 14px;
  cursor: pointer;
  transition: background 0.1s;
}

.search-result:hover {
  background: rgba(196, 141, 232, 0.06);
}

.search-empty {
  padding: 20px;
  text-align: center;
  color: var(--text-dim);
  font-size: 0.85rem;
}

@media (max-width: 600px) {
  .search-bar { max-width: none; margin: 0 8px; }
  .search-bar input { height: 38px; font-size: 0.85rem; }
}

/* ============================================================
   App Shell
   ============================================================ */

.app-shell {
  display: none;
}

.app-shell.active {
  display: grid;
  grid-template-rows: 1fr;
  min-height: 100vh;
}

.topbar {
  display: none;
}

.main-content {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  min-height: 100vh;
  padding-top: 0;
  margin-left: var(--left-nav-w);
  margin-right: var(--right-sidebar-w);
  gap: 0;
  border-top: 1px solid var(--border);
}

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

.topbar .brand img {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  object-fit: cover;
}

.topbar .brand span {
  font-weight: 800;
  font-size: 1.1rem;
  color: var(--text);
}

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

.topbar .nav button {
  background: transparent;
  color: var(--text-dim);
  padding: 8px 14px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.85rem;
  transition: all 0.15s;
}

.topbar .nav button:hover,
.topbar .nav button.active {
  background: rgba(196, 141, 232, 0.1);
  color: var(--text);
}

.topbar .nav .logout-btn {
  color: var(--text-muted);
}

/* ============================================================
   Left Navigation (persistent sidebar)
   ============================================================ */

.left-nav {
  background: var(--bg-darkest);
  border-right: 1px solid var(--border);
  padding: 8px 16px 16px;
  position: fixed;
  top: 0;
  width: var(--left-nav-w);
  min-width: var(--left-nav-w);
  height: 100vh;
  display: flex;
  flex-direction: column;
  z-index: 90;
  overflow-y: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.left-nav::-webkit-scrollbar {
  display: none;
}

.left-nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  border-radius: 8px;
  color: rgba(255, 255, 255, 0.88);
  font-family: 'Space Grotesk', -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 13.5px;
  font-weight: 500;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.15s;
  margin-bottom: 2px;
  text-decoration: none;
  background: rgba(6, 6, 12, 0.5);
  border: 1px solid transparent;
}

.left-nav-item:hover {
  background: rgba(255, 255, 255, 0.06);
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.08);
  text-shadow: 0 0 8px rgba(196, 141, 232, 0.4);
}

.left-nav-item.active {
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
  border-color: rgba(196, 141, 232, 0.3);
  text-shadow: 0 0 10px rgba(196, 141, 232, 0.5);
  box-shadow: inset 0 0 12px rgba(196, 141, 232, 0.06);
}

.left-nav-item svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  color: #ffffff;
}

.left-nav-item img {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  filter: brightness(0) invert(1);
}

.left-nav-divider {
  border: none;
  border-top: 1px solid var(--border);
  margin: 14px 0;
}

.left-nav-label {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.5);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 0 12px;
  margin-bottom: 8px;
  margin-top: 4px;
  font-weight: 700;
  font-family: 'Space Grotesk', -apple-system, sans-serif;
}

.left-nav .genre-filter {
  font-size: 12px;
  padding: 6px 10px;
  color: #ffffff;
}

.left-nav .genre-filter:hover {
  color: #ffffff;
  text-shadow: 0 0 8px rgba(196, 141, 232, 0.4);
}

/* ============================================================
   Right Sidebar (persistent)
   ============================================================ */

.right-sidebar {
  background: var(--bg-darkest);
  border-left: 1px solid var(--border);
  border-top: 1px solid var(--border);
  padding: 56px 16px 16px;
  position: fixed;
  top: 0;
  width: var(--right-sidebar-w);
  min-width: var(--right-sidebar-w);
  height: 100vh;
  display: flex;
  flex-direction: column;
  gap: 16px;
  z-index: 90;
  overflow-y: auto;
}

/* ============================================================
   Composer
   ============================================================ */

.composer {
  background: rgba(4, 4, 8, 0.8);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin-bottom: 20px;
}

.composer textarea {
  width: 100%;
  background: transparent;
  border: none;
  color: var(--text);
  font-size: 0.95rem;
  resize: none;
  min-height: 80px;
  line-height: 1.6;
}

.composer textarea::placeholder {
  color: var(--text-muted);
}

.composer-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
  flex-wrap: wrap;
}

.char-counter {
  font-size: 0.8rem;
  color: var(--text-very-muted);
}

.char-counter.warn { color: #ffa502; }
.char-counter.danger { color: var(--danger); }

.composer .btn-post {
  padding: 8px 24px;
  background: var(--bg-darkest);
  color: var(--purple);
  border: 1.5px solid var(--purple);
  border-radius: 8px;
  font-weight: 700;
  font-size: 0.85rem;
  transition: all 0.15s;
  flex-shrink: 0;
}

.composer .btn-post:hover {
  box-shadow: 0 0 14px rgba(196,141,232,0.25);
}

.composer .btn-post:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* ============================================================
   Composer Tools — Image Upload + GIF Search
   ============================================================ */

.composer-tools {
  display: flex;
  gap: 4px;
}

.tool-btn {
  background: transparent;
  color: var(--purple-dim);
  padding: 6px 8px;
  border-radius: 8px;
  font-size: 1.1rem;
  cursor: pointer;
  border: none;
  outline: none;
  transition: all 0.15s;
  opacity: 0.75;
}

.tool-btn:hover {
  opacity: 1;
  color: var(--purple);
}

.tool-btn img,
.tool-btn svg {
  width: 18px;
  height: 18px;
  filter: brightness(0) invert(1);
  opacity: 0.8;
}

.tool-btn:hover img,
.tool-btn:hover svg {
  opacity: 1;
  filter: brightness(0) invert(1) drop-shadow(0 0 6px rgba(196, 141, 232, 0.4));
}

/* Image preview in composer */
.composer-preview {
  margin: 12px 0 0;
}

.preview-wrap {
  position: relative;
  display: inline-block;
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.preview-wrap img {
  max-width: 100%;
  max-height: 280px;
  border-radius: var(--radius-sm);
  display: block;
}

.preview-remove {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.6);
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
}

.preview-remove:hover {
  background: rgba(255, 71, 87, 0.8);
  color: #fff;
}

/* ============================================================
   Video Upload — 27s max duration
   ============================================================ */

.video-upload-btn {
  position: relative;
}

.video-duration-badge {
  position: absolute;
  bottom: -2px;
  right: -2px;
  background: var(--purple);
  color: var(--bg-darkest);
  font-size: 0.55rem;
  padding: 1px 3px;
  border-radius: 3px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0.02em;
}

.video-preview {
  margin-top: 8px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid var(--border);
  position: relative;
}

.video-preview video {
  width: 100%;
  max-height: 200px;
  object-fit: cover;
  display: block;
  background: #000;
}

.video-duration-indicator {
  position: absolute;
  bottom: 8px;
  left: 8px;
  background: rgba(0,0,0,0.75);
  color: #fff;
  font-size: 0.7rem;
  padding: 2px 6px;
  border-radius: 4px;
  font-family: 'Share Tech Mono', monospace;
  font-weight: 600;
  letter-spacing: 0.05em;
}

.post-video {
  margin-top: 10px;
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.post-video video {
  width: 100%;
  max-height: 500px;
  object-fit: cover;
  display: block;
  background: #000;
  border-radius: var(--radius-sm);
  cursor: pointer;
}

/* ============================================================
   Voice Note Recording
   ============================================================ */

.voice-note-btn {
  position: relative;
  cursor: pointer;
}

.voice-note-btn.recording {
  color: var(--danger) !important;
}

.voice-note-btn.recording svg {
  stroke: var(--danger) !important;
  animation: mic-pulse 1s ease-in-out infinite;
}

@keyframes mic-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

.recording-indicator {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  margin-top: 8px;
  background: rgba(255, 71, 87, 0.08);
  border: 1px solid rgba(255, 71, 87, 0.25);
  border-radius: var(--radius-sm);
}

.recording-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--danger);
  animation: rec-blink 1s ease-in-out infinite;
  flex-shrink: 0;
}

@keyframes rec-blink {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.85); }
}

.recording-timer {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.8rem;
  color: var(--danger);
  font-weight: 600;
  letter-spacing: 0.05em;
}

.audio-preview {
  margin-top: 8px;
  border-radius: 12px;
  overflow: visible;
  border: 1px solid var(--border);
  background: var(--bg-darkest);
  position: relative;
}

.audio-preview-inner {
  display: flex;
  align-items: center;
  gap: 0;
  padding: 0;
}

.audio-preview-inner .voice-player {
  margin-top: 0;
}

.audio-preview-inner .preview-remove {
  position: absolute;
  top: 6px;
  right: 6px;
  background: rgba(255, 71, 87, 0.15);
  border: none;
  cursor: pointer;
  padding: 4px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
  z-index: 2;
}

.audio-preview-inner .preview-remove:hover {
  background: rgba(255, 71, 87, 0.4);
}

/* Styled audio player in feed posts */
.post-audio .voice-player {
  margin-top: 0;
}

/* ============================================================
   LinkedIn-style Compose Box
   ============================================================ */

.linkedin-compose-box {
  background: rgba(4, 4, 8, 0.8);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px 16px;
  margin-bottom: 20px;
}

.linkedin-compose-row {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
}

.linkedin-compose-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(196, 141, 232, 0.15);
  border: 2px solid rgba(196, 141, 232, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  overflow: hidden;
}

.linkedin-compose-avatar img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
}

.linkedin-compose-avatar span {
  font-size: 16px;
  font-weight: 700;
  color: var(--purple);
  letter-spacing: 0.03em;
}

.linkedin-compose-input {
  flex: 1;
  padding: 12px 16px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 24px;
  color: var(--text-muted);
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.15s;
}

.linkedin-compose-input:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.12);
}

.linkedin-compose-actions {
  display: flex;
  justify-content: space-around;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--border);
}

.linkedin-compose-action {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  background: transparent;
  border: none;
  color: var(--text-dim);
  font-size: 0.85rem;
  font-weight: 600;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.15s;
}

.linkedin-compose-action:hover {
  background: rgba(196, 141, 232, 0.06);
  color: var(--text);
}

.linkedin-compose-action img,
.linkedin-compose-action svg {
  width: 20px;
  height: 20px;
  filter: brightness(0.8) saturate(0.6);
  transition: filter 0.15s;
}

.linkedin-compose-action:hover img,
.linkedin-compose-action:hover svg {
  filter: brightness(1) saturate(1);
}

/* Post images */
.post-image {
  margin-top: 10px;
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.post-image img {
  width: 100%;
  max-height: 500px;
  object-fit: cover;
  cursor: pointer;
  border-radius: var(--radius-sm);
  display: block;
}

/* ============================================================
   Notifications + Mention Dropdown
   ============================================================ */

.nav-notif {
  position: relative;
}

.notif-badge {
  position: absolute;
  top: 2px;
  right: 0;
  min-width: 16px;
  height: 16px;
  background: var(--danger);
  color: #fff;
  border-radius: 10px;
  font-size: 0.6rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
}

#dm-badge {
  background: var(--teal);
}

.notif-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
  transition: background 0.15s;
  border-left: 3px solid transparent;
}

.notif-item:hover {
  background: rgba(196, 141, 232, 0.04);
}

.notif-item.notif-unread {
  background: rgba(196, 141, 232, 0.06);
  border-left-color: var(--text);
}

.notif-item.notif-unread .notif-text strong {
  color: var(--purple);
}

.notif-content {
  flex: 1;
  min-width: 0;
}

.notif-text {
  font-size: 0.9rem;
  line-height: 1.4;
}

.notif-text strong {
  color: var(--text);
}

.notif-time {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 3px;
}

.notif-icon {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  flex-shrink: 0;
  border-radius: 50%;
  background: rgba(196, 141, 232, 0.08);
  border: 1px solid rgba(196, 141, 232, 0.12);
  backdrop-filter: blur(4px);
}

.notif-icon svg {
  filter: drop-shadow(0 0 3px currentColor);
}

.notif-section-header {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  padding: 12px 16px 6px;
  font-weight: 600;
  border-bottom: 1px solid var(--border);
  background: var(--bg);
}

/* Mention dropdown */
.mention-dropdown {
  display: none;
  background: var(--bg-card);
  border: 1px solid var(--teal-dim);
  border-radius: var(--radius-sm);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
  z-index: 1000;
  max-height: 240px;
  overflow-y: auto;
}

.mention-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  cursor: pointer;
  transition: background 0.1s;
}

.mention-item:hover {
  background: rgba(196, 141, 232, 0.1);
}

/* ============================================================
   GIF Picker
   ============================================================ */

.gif-picker {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 16px;
  overflow: hidden;
}

.gif-picker-header {
  display: flex;
  gap: 8px;
  padding: 12px;
  border-bottom: 1px solid var(--border);
}

.gif-picker-header input {
  flex: 1;
  padding: 8px 14px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 20px;
  color: var(--text);
  font-size: 0.9rem;
}

.gif-picker-header input:focus {
  border-color: var(--text);
}

.gif-close {
  background: transparent;
  color: var(--text-dim);
  border: none;
  cursor: pointer;
  font-size: 1.1rem;
  padding: 4px 8px;
}

.gif-results {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  padding: 10px;
  max-height: 360px;
  overflow-y: auto;
}

.gif-item {
  cursor: pointer;
  border-radius: 8px;
  overflow: hidden;
  aspect-ratio: 1;
  background: var(--bg-input);
  transition: transform 0.1s;
}

.gif-item:hover {
  transform: scale(0.96);
}

.gif-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

@media (max-width: 600px) {
  .gif-results { grid-template-columns: repeat(2, 1fr); }
}

.feed-search-bar {
  position: relative;
  margin-bottom: 16px;
}

.feed-search-bar input {
  width: 100%;
  height: 44px;
  padding: 0 16px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 22px;
  color: var(--text);
  font-size: 0.92rem;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.feed-search-bar input:focus {
  border-color: var(--teal);
  box-shadow: 0 0 0 2px rgba(196, 141, 232, 0.08);
}

.feed-search-bar input::placeholder {
  color: var(--text-muted);
}

.feed-tabs {
  display: flex;
  gap: 0;
  margin-bottom: 0;
  border-bottom: 1px solid var(--border);
}

.feed-tabs button {
  background: transparent;
  color: var(--text-dim);
  padding: 14px 20px;
  font-weight: 700;
  font-size: 14px;
  position: relative;
  transition: color 0.15s;
}

.feed-tabs button.active {
  color: var(--text);
}

.feed-tabs button.active::after {
  content: '';
  position: absolute;
  bottom: -1px;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--purple);
  border-radius: 3px;
}

/* ============================================================
   Post Card
   ============================================================ */

.post-card {
  background: transparent;
  border: 1px solid var(--border);
  border-bottom-color: var(--border);
  border-radius: 0;
  border-left: none;
  border-right: none;
  border-top: none;
  padding: 16px 20px;
  margin-bottom: 0;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.post-card:hover {
  border-color: var(--border-hover);
  box-shadow: 0 0 8px rgba(0,229,208,0.06);
}

.post-pinned-indicator {
  font-size: 0.72rem;
  color: var(--purple);
  margin-bottom: 8px;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 5px;
}

.post-pinned-indicator svg {
  filter: none;
}

.btn-pin {
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px 8px;
  font-size: 1rem;
  opacity: 0.6;
  transition: opacity 0.15s;
}

.btn-pin:hover {
  opacity: 1;
}

.post-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 6px;
}

.post-header .avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(196, 141, 232, 0.2), rgba(196, 141, 232, 0.15));
  border: 1.5px solid rgba(196, 141, 232, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text);
  font-weight: 700;
  font-size: 1rem;
  flex-shrink: 0;
  overflow: hidden;
  transition: box-shadow 0.2s;
}

.post-header .avatar:hover {
  box-shadow: 0 0 10px rgba(196, 141, 232, 0.3);
}

.post-header .avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Universal avatar image sizing — applies everywhere a .avatar appears
   (notifications, DM conversations, search, mentions), not just .post-header.
   Without this, images render at native size outside the post feed. */
.avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Same fix for .avatar-lg — the edit-profile upload preview lives OUTSIDE
   .profile-header, so the scoped rule above doesn't catch it and the preview
   image rendered at native size. */
.avatar-lg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.post-header .meta {
  flex: 1;
  min-width: 0;
}

.post-header .meta .name {
  font-weight: 700;
  color: var(--text);
  font-size: 0.95rem;
}

.post-header .meta .handle {
  color: var(--text-dim);
  font-size: 0.85rem;
}

.clickable {
  cursor: pointer;
  transition: color 0.15s;
}

.clickable:hover {
  color: var(--text);
}

.post-header .time {
  color: var(--text-muted);
  font-size: 0.8rem;
  white-space: nowrap;
}

.post-body {
  font-size: 0.98rem;
  line-height: 1.55;
  color: var(--text);
  word-wrap: break-word;
  white-space: pre-wrap;
}

.post-body .hashtag {
  color: #b0a8c0;
  cursor: pointer;
}
.post-body .hashtag:hover {
  color: var(--text);
}

.post-body .mention {
  color: var(--blue);
  cursor: pointer;
}

/* Mention links also appear in profile bios — same accent as posts */
.profile-header .bio .mention,
.bio .mention {
  color: var(--blue);
  cursor: pointer;
}

.link-preview-card {
  transition: border-color 0.2s;
}
.link-preview-card:hover {
  border-color: var(--teal) !important;
}
.link-preview-card img {
  background: var(--bg);
}
.post-link:hover {
  color: #1ae0ff !important;
}

.post-actions {
  display: flex;
  gap: 24px;
  margin-top: 12px;
  padding-top: 10px;
}

.post-actions button {
  background: transparent;
  color: var(--purple-dim);
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 4px 8px;
  border-radius: 8px;
  transition: all 0.15s;
}

.post-actions button svg {
  transition: color 0.15s, filter 0.15s;
}

.post-actions button:hover {
  background: rgba(196, 141, 232, 0.08);
  color: var(--purple);
}

.post-actions button:hover svg {
  filter: drop-shadow(0 0 4px rgba(196, 141, 232, 0.3));
}

.post-actions button.liked {
  color: var(--purple);
}

.post-actions button.liked svg {
  filter: drop-shadow(0 0 6px rgba(196, 141, 232, 0.5));
}

.post-actions button.btn-repost.reposted {
  color: var(--purple);
}

.post-actions button.btn-repost.reposted svg {
  filter: drop-shadow(0 0 6px rgba(196, 141, 232, 0.5));
}

.post-actions button.btn-delete {
  margin-left: auto;
  opacity: 0.5;
}

.post-actions button.btn-delete:hover {
  background: rgba(255, 71, 87, 0.1);
  color: var(--danger);
  opacity: 1;
}

/* Report buttons — subtle by default, red on hover (mirrors btn-delete). */
.post-actions button.btn-report,
.post-actions button.btn-report-reply {
  opacity: 0.5;
}

.post-actions button.btn-report:hover,
.post-actions button.btn-report-reply:hover {
  background: rgba(255, 71, 87, 0.1);
  color: var(--danger);
  opacity: 1;
}

.post-actions .icon {
  font-size: 1.1rem;
}

/* ============================================================
   Inline Thread Preview (inside feed cards)
   ============================================================ */

.thread-preview {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}

.thread-preview-reply {
  display: flex;
  gap: 8px;
  padding: 4px 0;
}

.thread-preview-reply:not(:last-child) {
  margin-bottom: 4px;
}

.thread-preview-body {
  flex: 1;
  min-width: 0;
  font-size: 0.85rem;
  line-height: 1.4;
  color: var(--text);
  word-wrap: break-word;
}

.thread-preview-name {
  font-weight: 700;
  margin-right: 4px;
  color: var(--purple);
}

.thread-preview-text {
  white-space: pre-wrap;
}

.thread-preview-time {
  color: var(--text-muted);
  font-size: 0.75rem;
  white-space: nowrap;
}

.btn-view-thread {
  display: block;
  width: 100%;
  margin-top: 8px;
  padding: 8px;
  background: transparent;
  border: none;
  border-top: 1px solid var(--border);
  color: var(--text);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s;
}

.btn-view-thread:hover {
  background: rgba(196, 141, 232, 0.06);
}

/* ============================================================
   Profile View
   ============================================================ */

.profile-header {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 28px;
  margin-bottom: 20px;
  text-align: center;
  position: relative;
}

.profile-header .avatar-lg {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  margin: 0 auto 16px;
  background: var(--purple-dim);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  font-weight: 800;
  color: var(--text);
  overflow: hidden;
}

.profile-header .avatar-lg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.profile-header .display-name {
  font-size: 1.4rem;
  font-weight: 800;
  margin-bottom: 4px;
  color: var(--text);
}

.profile-header .handle {
  color: var(--teal);
  font-size: 0.95rem;
  margin-bottom: 12px;
}

.profile-header .bio {
  color: var(--text);
  font-size: 0.95rem;
  margin-bottom: 16px;
  line-height: 1.5;
}

.profile-header .stats {
  display: flex;
  justify-content: center;
  gap: 36px;
  margin-top: 16px;
}

.profile-header .stats .stat {
  text-align: center;
}

.profile-header .stats .stat .num {
  font-weight: 800;
  font-size: 1.2rem;
  color: var(--text);
}

.profile-header .stats .stat .label {
  font-size: 0.8rem;
  color: var(--text-dim);
}

.profile-header .btn-follow {
  padding: 7px 20px;
  background: linear-gradient(135deg, #8b5cf6, #a78bfa);
  color: #ffffff;
  border: none;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.82rem;
  transition: all 0.2s;
}

.profile-header .btn-follow:hover {
  background: linear-gradient(135deg, #7c3aed, #8b5cf6);
  box-shadow: 0 4px 16px rgba(139, 92, 246, 0.4);
  transform: translateY(-1px);
}

.profile-header .btn-follow.following {
  background: rgba(139, 92, 246, 0.12);
  border: 1px solid rgba(139, 92, 246, 0.4);
  color: #a78bfa;
}

/* Profile corner actions — top-right of profile card */
.profile-corner-actions {
  position: absolute;
  top: 12px;
  right: 12px;
  display: flex;
  gap: 6px;
  z-index: 2;
}

.corner-action-btn {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid rgba(196, 141, 232, 0.3);
  background: transparent;
  color: var(--purple);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
}

.corner-action-btn:hover {
  background: rgba(196, 141, 232, 0.08);
  color: var(--text);
  border-color: var(--purple-dim);
}

.corner-action-btn.corner-action-nuke {
  color: var(--danger);
  border-color: rgba(255, 71, 87, 0.3);
  font-size: 16px;
  font-weight: 700;
}

.corner-action-btn.corner-action-nuke:hover {
  background: rgba(255, 71, 87, 0.15);
  border-color: var(--danger);
  color: var(--danger);
}

.corner-action-btn.corner-action-report {
  color: var(--purple);
  border-color: rgba(196, 141, 232, 0.3);
}

.corner-action-btn.corner-action-report:hover {
  background: rgba(196, 141, 232, 0.1);
  border-color: var(--purple);
  color: var(--purple);
}

.profile-actions {
  display: flex;
  gap: 10px;
  justify-content: center;
  align-items: center;
  margin-top: 16px;
}

/* Artist badge — shown next to display name for account_type='artist' */
.artist-badge {
  display: inline-block;
  background: rgba(180, 122, 204, 0.12);
  color: var(--purple);
  border: 1px solid var(--purple-dim);
  border-radius: 10px;
  padding: 1px 8px;
  font-size: 0.7rem;
  font-weight: 700;
  vertical-align: middle;
  margin-left: 4px;
}

/* Profile links — chips under the bio */
.profile-links {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: center;
  margin: 4px 0 12px;
}

.profile-link-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-darkest);
  color: var(--purple);
  border: 1px solid rgba(196, 141, 232, 0.3);
  border-radius: 12px;
  padding: 4px 12px;
  font-size: 0.75rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.15s;
  letter-spacing: 0.5px;
}

.profile-link-chip::before {
  content: '≡';
  font-size: 1rem;
  margin-right: 4px;
  line-height: 1;
}

.profile-link-chip:hover {
  color: var(--purple);
  background: rgba(196, 141, 232, 0.08);
  border-color: var(--purple);
}

/* ============================================================
   Artist Stats Block (metadata only — no content surveillance)
   ============================================================ */

.artist-stats-block {
  margin-top: 16px;
}

.chart-peak-badge {
  background: linear-gradient(135deg, rgba(255, 215, 0, 0.12), rgba(255, 165, 0, 0.08));
  border: 1px solid rgba(255, 215, 0, 0.3);
  color: #ffdf6b;
  border-radius: 12px;
  padding: 8px 14px;
  font-size: 0.82rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 12px;
}

.artist-stats-row {
  display: flex;
  justify-content: space-around;
  gap: 8px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 8px;
  margin-bottom: 12px;
}

.artist-stat {
  text-align: center;
  flex: 1;
}

.artist-stat .num {
  font-weight: 800;
  font-size: 1.05rem;
  color: var(--text);
}

.artist-stat .label {
  font-size: 0.72rem;
  color: var(--text-dim);
  margin-top: 2px;
}

/* Releases list */
.artist-releases {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.release-card {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 10px 12px;
  transition: border-color 0.15s;
}

.release-card:hover {
  border-color: var(--border-hover);
}

.release-cover {
  width: 44px;
  height: 44px;
  border-radius: 8px;
  background: var(--purple-dim);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  flex-shrink: 0;
  overflow: hidden;
}

.release-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.release-info {
  flex: 1;
  min-width: 0;
}

.release-title {
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.release-genre {
  font-size: 0.75rem;
  color: var(--purple-soft);
}

.release-stats {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 2px;
}

.track-play-btn {
  background: var(--teal);
  color: var(--purple);
  border: 1px solid var(--teal);
  border-radius: 50%;
  width: 34px;
  height: 34px;
  font-size: 0.9rem;
  cursor: pointer;
  flex-shrink: 0;
  transition: all 0.15s;
}

.track-play-btn:hover {
  background: var(--teal);
  color: var(--bg-darkest);
}

/* Verified badge */
.verified-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  background: #ffffff;
  color: #000000;
  border-radius: 50%;
  font-size: 0.65rem;
  font-weight: 900;
  margin-left: 6px;
  vertical-align: middle;
  flex-shrink: 0;
}

.verified-badge.admin-badge {
  background: var(--purple);
  color: var(--bg-darkest);
}

/* Super admin badge — stryfe gets special violet glow treatment */
.verified-badge.super-admin-badge {
  background: linear-gradient(135deg, #8b5cf6, #a78bfa);
  color: #ffffff;
  width: 20px;
  height: 20px;
  font-size: 0.7rem;
  box-shadow: 0 0 8px rgba(139, 92, 246, 0.5), 0 0 16px rgba(139, 92, 246, 0.3);
  animation: super-admin-glow 2s ease-in-out infinite;
}

@keyframes super-admin-glow {
  0%, 100% { box-shadow: 0 0 8px rgba(139, 92, 246, 0.5), 0 0 16px rgba(139, 92, 246, 0.3); }
  50% { box-shadow: 0 0 12px rgba(139, 92, 246, 0.7), 0 0 24px rgba(139, 92, 246, 0.4); }
}

/* Super admin username styling */
.super-admin-name {
  background: linear-gradient(135deg, #c084fc, #a78bfa, #8b5cf6);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Compact verified badge for inline contexts (DM conv names, etc.) */
.verified-badge.badge-sm {
  width: 14px;
  height: 14px;
  font-size: 0.5rem;
  margin-left: 4px;
}

/* Ensure profile display-name is always white */
.profile-header .display-name,
.post-header .meta .name,
.explore-name {
  color: #ffffff;
}

/* ============================================================
   Utility
   ============================================================ */

.loading {
  text-align: center;
  padding: 40px;
  color: var(--text-dim);
}

/* Skeleton loaders — animated placeholders */
.skeleton-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin-bottom: 4px;
  border-bottom: 1px solid var(--border);
}

.skeleton-line {
  height: 12px;
  border-radius: 6px;
  background: linear-gradient(90deg, var(--bg-input) 0%, rgba(196,141,232,0.08) 50%, var(--bg-input) 100%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  margin-bottom: 8px;
}

.skeleton-line.short { width: 40%; }
.skeleton-line.medium { width: 70%; }
.skeleton-line.long { width: 100%; }

.skeleton-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.skeleton-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: linear-gradient(90deg, var(--bg-input) 0%, rgba(196,141,232,0.08) 50%, var(--bg-input) 100%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  flex-shrink: 0;
}

@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

/* Fade-in animations */
.fade-in { animation: fadeInUp 0.3s ease-out; }

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

.slide-in-top { animation: slideInTop 0.4s ease-out; }

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

.slide-in-bottom { animation: slideInBottom 0.3s ease-out; }

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

/* ============================================================
   Profile Editing / Settings
   ============================================================ */

.edit-profile-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
  max-width: 600px;
  margin: 0 auto;
}

/* Settings Tabs */
.settings-tabs {
  display: flex;
  gap: 0;
  border-bottom: 1px solid var(--border);
  margin-bottom: 20px;
  overflow-x: auto;
}

.settings-tab {
  padding: 10px 16px;
  background: transparent;
  border: none;
  border-bottom: 2px solid transparent;
  color: var(--text-dim);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
  white-space: nowrap;
}

.settings-tab:hover {
  color: var(--text);
}

.settings-tab.active {
  color: var(--text);
  border-bottom-color: var(--text);
}

.settings-panel {
  display: none;
}

.settings-panel.active {
  display: block;
}

.edit-profile-card select,
.edit-profile-card textarea {
  width: 100%;
  padding: 12px 14px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 0.95rem;
  font-family: inherit;
  resize: vertical;
}

/* CSS Sandbox presets */
.preset-btn {
  padding: 6px 12px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 16px;
  color: var(--text-dim);
  font-size: 0.8rem;
  cursor: pointer;
  transition: all 0.15s;
}

.preset-btn:hover {
  border-color: var(--teal-dim);
  color: var(--text);
  background: rgba(196, 141, 232, 0.05);
}

/* ============================================================
   Links Editor + Block List (Edit Profile)
   ============================================================ */

.edit-link-row {
  display: flex;
  gap: 6px;
  margin-bottom: 6px;
  align-items: center;
}

.edit-link-row .link-platform {
  flex: 0 0 38%;
  padding: 8px 10px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 0.85rem;
  font-family: inherit;
}

.edit-link-row .link-url {
  flex: 1;
  min-width: 0;
  padding: 8px 10px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 0.85rem;
  font-family: inherit;
}

.edit-link-row .link-platform:focus,
.edit-link-row .link-url:focus {
  outline: none;
  border-color: var(--teal-dim);
}

.link-remove-btn {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 50%;
  color: var(--text-dim);
  cursor: pointer;
  font-size: 0.75rem;
  transition: all 0.15s;
}

.link-remove-btn:hover {
  border-color: var(--danger);
  color: var(--danger);
  background: rgba(255, 71, 87, 0.1);
}

.edit-block-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
}

.edit-block-row:last-child {
  border-bottom: none;
}

.unblock-btn {
  font-size: 0.75rem;
}

/* ============================================================
   Thread View
   ============================================================ */

.back-btn {
  background: transparent;
  color: var(--text);
  padding: 8px 16px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.9rem;
  transition: all 0.15s;
}

.back-btn:hover {
  background: rgba(196, 141, 232, 0.1);
}

.thread-toggle {
  margin-top: 12px;
  margin-bottom: 4px;
}

.thread-toggle-btn {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-dim);
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
  font-family: inherit;
}

.thread-toggle-btn:hover {
  border-color: var(--purple-dim);
  color: var(--purple);
}

.thread-replies {
  margin-top: 8px;
}

.reply-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  margin-bottom: 8px;
  margin-top: 8px;
  border-left: 2px solid var(--purple-dim);
}

.reply-card .post-actions button {
  padding: 2px 6px;
  font-size: 0.8rem;
}

/* ============================================================
   DMs (Direct Messages)
   ============================================================ */

.dm-layout {
  display: flex;
  gap: 0;
  width: 100%;
  height: calc(100vh - 24px);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.dm-sidebar {
  width: 240px;
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  background: var(--bg-dark);
}

.dm-new {
  padding: 12px;
  border-bottom: 1px solid var(--border);
}

.dm-conversations {
  flex: 1;
  overflow-y: auto;
}

.dm-conv-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  cursor: pointer;
  transition: background 0.15s;
  border-bottom: 1px solid rgba(196, 141, 232, 0.05);
}

.dm-conv-item:hover {
  background: rgba(196, 141, 232, 0.05);
}

.dm-conv-item.active {
  background: rgba(196, 141, 232, 0.1);
  border-left: 3px solid var(--purple);
}

.dm-conv-info {
  flex: 1;
  min-width: 0;
}

.dm-conv-name {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--purple);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dm-conv-time {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.dm-chat {
  flex: 1;
  display: flex;
  flex-direction: column;
  background: var(--bg-darkest);
}

.dm-empty {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--text-dim);
}

.dm-empty .icon {
  font-size: 2.5rem;
  margin-bottom: 12px;
  opacity: 0.5;
}

.dm-chat-header {
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
  background: var(--bg-dark);
}

.dm-chat-name {
  font-weight: 700;
  color: var(--purple);
}

.dm-messages {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.dm-msg {
  display: flex;
  flex-direction: column;
  max-width: 70%;
}

.dm-msg-me {
  align-self: flex-end;
  align-items: flex-end;
}

.dm-msg-them {
  align-self: flex-start;
}

.dm-msg-bubble {
  padding: 10px 14px;
  border-radius: 16px;
  font-size: 0.92rem;
  line-height: 1.4;
  word-wrap: break-word;
}

.dm-msg-me .dm-msg-bubble {
  background: var(--teal-dark);
  color: var(--text);
  border-bottom-right-radius: 4px;
}

.dm-msg-them .dm-msg-bubble {
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text);
  border-bottom-left-radius: 4px;
}

.dm-msg-time {
  font-size: 0.7rem;
  color: var(--text-muted);
  margin-top: 3px;
  padding: 0 4px;
}

.dm-input-bar {
  display: flex;
  gap: 8px;
  padding: 12px;
  border-top: 1px solid var(--border);
  background: var(--bg-dark);
}

.dm-input-bar input {
  flex: 1;
  padding: 10px 14px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 20px;
  color: var(--text);
  font-size: 0.9rem;
}

.dm-input-bar input:focus {
  border-color: var(--text);
}

.dm-input-bar .btn-post {
  padding: 8px 20px;
  border-radius: 20px;
  background: var(--bg-darkest);
  color: var(--purple);
  border: 1.5px solid var(--purple);
  transition: all 0.2s;
}

.dm-input-bar .btn-post:hover {
  box-shadow: 0 0 14px rgba(196,141,232,0.25);
}

.dm-new-form {
  padding: 24px;
  max-width: 360px;
  margin: 0 auto;
  align-self: center;
  width: 100%;
}

/* Mobile DM layout */
@media (max-width: 600px) {
  .dm-layout { flex-direction: column; height: calc(100vh - var(--header-h) - 32px); }
  .dm-sidebar { width: 100%; height: 45%; }
  .dm-chat { height: 55%; }
  .dm-chat-header .back-btn { display: inline-block !important; }
}

.reply-flattened {
  color: var(--text-dim);
  font-size: 0.8rem;
  padding: 6px 12px;
  font-style: italic;
}

.inline-reply-composer {
  border: 1px solid rgba(139, 92, 246, 0.15) !important;
  background: rgba(6, 6, 12, 0.5) !important;
  border-radius: 12px !important;
}

.inline-reply-box {
  padding: 8px 16px 12px;
  border-top: 1px solid var(--border);
}

.inline-reply-preview {
  padding: 8px 0;
}

.inline-reply-preview .preview-wrap {
  position: relative;
  display: inline-block;
  max-width: 200px;
}

.inline-reply-preview .preview-wrap img {
  max-width: 100%;
  max-height: 120px;
  border-radius: 8px;
}

.reply-composer-wrap {
  margin-top: 16px;
}

.empty-state {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-dim);
}

.empty-state .icon {
  font-size: 2.5rem;
  margin-bottom: 12px;
  opacity: 0.5;
}

.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--bg-card);
  border: 1px solid var(--teal-dim);
  color: var(--text);
  padding: 12px 24px;
  border-radius: 24px;
  font-size: 0.9rem;
  font-weight: 600;
  z-index: 999;
  animation: toastIn 0.3s ease;
}

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

/* Mobile */
@media (max-width: 600px) {
  .main-content {
    margin-left: 0;
    margin-right: 0;
    padding: 0 0 80px;
  }
  .left-nav { display: none; }
  .right-sidebar { display: none; }
  .topbar .nav button { padding: 8px 10px; font-size: 0.8rem; }
  .auth-card { padding: 28px 20px; }
}

/* ============================================================
   Mobile Bottom Tab Bar
   ============================================================ */

.mobile-tabbar {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(8, 13, 11, 0.95);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-top: 1px solid var(--border);
  z-index: 200;
  padding: 6px 0 env(safe-area-inset-bottom, 6px);
  justify-content: space-around;
}

.mobile-tabbar button {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  background: transparent;
  border: none;
  color: var(--text-dim);
  padding: 6px 14px;
  border-radius: 10px;
  transition: color 0.15s;
}

.mobile-tabbar button.active {
  color: var(--text);
}

.mobile-tabbar .tab-icon {
  font-size: 1.3rem;
}

.mobile-tabbar .tab-label {
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.3px;
}

@media (max-width: 600px) {
  .mobile-tabbar { display: flex; }
  .topbar .nav { display: none; }
  .main-content { padding-bottom: 80px; }
}

/* ============================================================
   SVG Icon Styles
   ============================================================ */

.nav-icon {
  width: 22px;
  height: 22px;
  color: #ffffff;
  transition: color 0.15s;
}

.nav-notif:hover .nav-icon,
.nav-ecosystem:hover .nav-icon,
.topbar .nav button:hover .nav-icon {
  color: #ffffff;
}

.fab-icon {
  width: 28px;
  height: 28px;
  filter: brightness(0) invert(1);
}

.post-fab {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--bg-darkest);
  border: 2px solid #8b5cf6;
  position: fixed;
  bottom: 28px;
  right: 24px;
  z-index: 150;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
  cursor: pointer;
  box-shadow: 0 0 15px rgba(139, 92, 246, 0.4), 0 0 30px rgba(139, 92, 246, 0.15);
}

.fab-icon {
  font-size: 24px;
  font-weight: 300;
  color: var(--purple);
  line-height: 1;
}

.post-fab:hover {
  box-shadow: 0 0 14px rgba(196,141,232,0.25);
}

.post-fab:active {
  transform: scale(0.95);
}

.icon-btn {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  padding: 0;
  border-radius: 50%;
  transition: background 0.15s;
}

.icon-btn:hover {
  background: rgba(196, 141, 232, 0.1);
}

.icon-cover {
  width: 32px;
  height: 32px;
}


.mobile-tabbar .tab-icon {
  width: 24px;
  height: 24px;
  color: var(--text-dim);
  transition: color 0.15s;
}

.mobile-tabbar button.active .tab-icon {
  color: var(--text);
}

.mobile-tabbar button:hover .tab-icon {
  color: var(--text);
}

/* Show post-fab only when authenticated (app-shell is active) */
.app-shell.active .post-fab {
  display: flex;
}

@media (max-width: 600px) {
  .post-fab {
    bottom: 88px;
    right: 16px;
    width: 48px;
    height: 48px;
  }
  .fab-icon { width: 24px; height: 24px; }
}

/* ============================================================
   Unauthenticated Explore Page
   ============================================================ */

.unauth-explore {
  max-width: 600px;
  margin: 0 auto;
  padding: 0 20px 60px;
}

.explore-container {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.explore-section {
  background: transparent;
}

.explore-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.explore-tags {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.explore-tag {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  transition: border-color 0.15s;
}

.explore-tag:hover {
  border-color: var(--border-hover);
}

.explore-rank {
  font-weight: 800;
  color: var(--teal-dim);
  width: 20px;
}

.explore-tag-name {
  font-weight: 700;
  font-size: 0.95rem;
}

.explore-tag-stats {
  margin-left: auto;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.explore-posts {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.explore-post-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
}

.explore-post-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.explore-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--purple-dim);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--text);
  overflow: hidden;
  flex-shrink: 0;
}

.explore-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.explore-name {
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--purple);
}

.explore-handle {
  font-size: 0.75rem;
  color: var(--text-dim);
}

.explore-post-body {
  font-size: 0.9rem;
  line-height: 1.5;
  color: var(--text);
  margin-bottom: 10px;
}

.explore-post-img-tag {
  display: inline-block;
  margin-top: 6px;
  font-size: 0.78rem;
  color: var(--teal-soft);
  background: rgba(196,141,232,0.08);
  padding: 2px 8px;
  border-radius: 4px;
}

.explore-post-stats {
  display: flex;
  gap: 16px;
  font-size: 0.78rem;
  color: var(--text-dim);
  padding-top: 8px;
  border-top: 1px solid var(--border);
}

.explore-cta {
  text-align: center;
  padding: 40px 20px;
  background: var(--bg-card);
  border: 1px solid var(--teal-dim);
  border-radius: var(--radius);
}

.explore-cta-title {
  font-size: 1.6rem;
  font-weight: 800;
  background: linear-gradient(135deg, var(--blue), var(--blue-dim));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 8px;
}

.explore-cta-text {
  color: var(--text-dim);
  font-size: 0.92rem;
  margin-bottom: 20px;
}

.explore-cta-btn {
  max-width: 280px;
  margin: 0 auto;
}

/* Right sidebar search bar */
.sidebar-search {
  width: 100%;
  position: relative;
}

.sidebar-search input {
  width: 100%;
  height: 44px;
  padding: 0 16px 0 44px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 22px;
  color: var(--text);
  font-size: 0.92rem;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.sidebar-search input:focus {
  border-color: var(--text);
  box-shadow: 0 0 0 2px rgba(196, 141, 232, 0.08);
}

.sidebar-search input::placeholder {
  color: var(--text-muted);
}

.sidebar-search .search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 1rem;
  pointer-events: none;
}

/* ============================================================
   Feed Layout (center column)
   ============================================================ */

.feed-center {
  flex: 1;
  min-width: 0;
  max-width: 600px;
  padding: 56px 16px 0;
}

.feed-layout {
  display: block;
  max-width: 600px;
  margin: 0 auto;
}

.feed-main {
  min-width: 0;
}

.feed-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
  padding: 8px 0;
}

.feed-grid-item {
  transition: transform 0.15s, box-shadow 0.15s;
}

.feed-grid-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 20px rgba(139, 92, 246, 0.15);
}

.feed-sidebar {
  display: none;
}

.sidebar-card {
  background: rgba(2, 2, 4, 0.6);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.sidebar-header {
  padding: 16px 20px;
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--text);
  border-bottom: 1px solid var(--border);
  background: transparent;
}

.sidebar-body {
  padding: 8px 0;
}

.sidebar-icon {
  width: 16px;
  height: 16px;
  vertical-align: middle;
  margin-right: 6px;
  opacity: 0.85;
  filter: brightness(1.8);
}

.sidebar-empty {
  padding: 16px;
  color: var(--text-dim);
  font-size: 0.82rem;
  text-align: center;
}

/* Trending items */
.trend-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  cursor: pointer;
  transition: background 0.15s;
}

.trend-item:hover {
  background: rgba(196, 141, 232, 0.05);
}

.trend-rank {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 20px;
}

.pulse-bullet {
  width: 8px;
  height: 8px;
  background: var(--purple);
  border-radius: 50%;
  animation: bullet-pulse 2s ease-in-out infinite;
}

@keyframes bullet-pulse {
  0%, 100% { opacity: 0.3; box-shadow: 0 0 4px var(--purple); }
  50% { opacity: 1; box-shadow: 0 0 10px var(--purple), 0 0 20px rgba(196, 141, 232, 0.3); }
}

.linkedin-compose-action .compose-icon-white,
.linkedin-compose-action .compose-icon-white:hover {
  filter: brightness(0) invert(1) !important;
}

.trend-genre {
  font-size: 0.7rem;
  color: var(--text-muted);
  margin-top: 2px;
}

.trend-content {
  flex: 1;
  min-width: 0;
}

.trend-tag {
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--text);
}

.trend-item:hover .trend-tag {
  color: var(--text);
}

.trend-stats {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 2px;
}

/* Full-page trending list */
.trending-list-full .trend-item {
  border-bottom: 1px solid var(--border);
}
.trending-list-full .trend-item:last-child {
  border-bottom: none;
}

/* Responsive — hide sidebars on tablet */
@media (max-width: 1024px) {
  .left-nav { display: none; }
  .right-sidebar { display: none; }
  .main-content {
    margin-left: 0;
    margin-right: 0;
  }
}

@media (max-width: 800px) {
  .feed-sidebar { display: none; }
}

/* ============================================================
   Repost marker + embedded quote card
   ============================================================ */

.repost-marker {
  font-size: 0.78rem;
  color: var(--text-dim);
  margin-bottom: 8px;
  padding-left: 2px;
}

.quote-card {
  margin-top: 12px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-left: 3px solid var(--purple-dim);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.015);
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}

.quote-card:hover {
  background: rgba(196, 141, 232, 0.04);
  border-color: var(--teal-dim);
}

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

.quote-header .meta .name {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--purple);
}

.quote-header .meta .handle {
  font-size: 0.78rem;
}

.quote-card .post-image {
  margin-top: 8px;
}

/* ============================================================
   Compose modal — Premium cyberpunk / glassmorphism
   ============================================================ */

@keyframes composer-glow-pulse {
  0%, 100% { box-shadow: 0 0 15px rgba(196, 141, 232, 0.15), 0 0 30px rgba(196, 141, 232, 0.08), 0 16px 48px rgba(0, 0, 0, 0.5); }
  50% { box-shadow: 0 0 22px rgba(196, 141, 232, 0.28), 0 0 44px rgba(196, 141, 232, 0.14), 0 16px 48px rgba(0, 0, 0, 0.5); }
}

@keyframes composer-border-glow {
  0%, 100% { border-color: rgba(196, 141, 232, 0.25); }
  33% { border-color: rgba(196, 141, 232, 0.3); }
  66% { border-color: rgba(100, 140, 255, 0.25); }
}

@keyframes post-btn-pulse {
  0%, 100% { box-shadow: 0 0 8px rgba(196, 141, 232, 0.2), 0 0 16px rgba(196, 141, 232, 0.1); }
  50% { box-shadow: 0 0 14px rgba(196, 141, 232, 0.35), 0 0 28px rgba(196, 141, 232, 0.15); }
}

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  z-index: 200;
  padding: 5vh 16px;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.compose-modal {
  width: 100%;
  max-width: 560px;
  background: rgba(6, 6, 16, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(196, 141, 232, 0.2);
  border-radius: 16px;
  padding: 20px;
  position: relative;
  overflow: hidden;
  animation: modal-in 0.2s ease-out, composer-border-glow 4s ease-in-out infinite, composer-glow-pulse 3s ease-in-out infinite;
  box-shadow: 0 0 20px rgba(196, 141, 232, 0.15), 0 0 40px rgba(196, 141, 232, 0.08), 0 16px 48px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

.compose-modal::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(196, 141, 232, 0.5), rgba(196, 141, 232, 0.5), rgba(100, 140, 255, 0.5), transparent);
}

.compose-modal::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 80px;
  background: linear-gradient(180deg, rgba(196, 141, 232, 0.04) 0%, transparent 100%);
  pointer-events: none;
  z-index: 0;
}

@keyframes modal-in {
  from { opacity: 0; transform: translateY(-12px) scale(0.97); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

.compose-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
  font-weight: 700;
  color: #ffffff;
  font-size: 1rem;
  position: relative;
  z-index: 1;
}

.compose-modal-header span {
  background: linear-gradient(135deg, #ffffff, #c48de8);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  letter-spacing: 0.02em;
}

.compose-modal-close {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--text-dim);
  font-size: 1.1rem;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 8px;
  transition: all 0.2s;
}

.compose-modal-close:hover {
  background: rgba(255, 71, 87, 0.15);
  border-color: rgba(255, 71, 87, 0.3);
  color: #ffffff;
}

.compose-modal textarea {
  width: 100%;
  background: rgba(2, 2, 8, 0.6);
  border: 1px solid rgba(196, 141, 232, 0.12);
  border-radius: 12px;
  color: #ffffff;
  padding: 14px 16px;
  font-size: 1rem;
  font-family: inherit;
  resize: none;
  min-height: 100px;
  line-height: 1.6;
  position: relative;
  z-index: 1;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.compose-modal textarea::placeholder {
  color: rgba(255, 255, 255, 0.3);
}

.compose-modal textarea:focus {
  outline: none;
  border-color: rgba(196, 141, 232, 0.4);
  box-shadow: 0 0 0 2px rgba(196, 141, 232, 0.08), inset 0 0 20px rgba(196, 141, 232, 0.03);
}

.compose-modal .composer-footer {
  margin-top: 12px;
  position: relative;
  z-index: 1;
}

.compose-modal .composer-footer .char-counter {
  color: rgba(255, 255, 255, 0.35);
}

.compose-modal .btn-post {
  background: linear-gradient(135deg, rgba(196, 141, 232, 0.15), rgba(196, 141, 232, 0.1));
  color: var(--purple);
  border: 1.5px solid rgba(196, 141, 232, 0.5);
  border-radius: 10px;
  padding: 9px 28px;
  font-weight: 700;
  font-size: 0.88rem;
  letter-spacing: 0.02em;
  transition: all 0.25s;
}

.compose-modal .btn-post:not(:disabled) {
  animation: post-btn-pulse 2.5s ease-in-out infinite;
}

.compose-modal .btn-post:not(:disabled):hover {
  background: linear-gradient(135deg, rgba(196, 141, 232, 0.25), rgba(196, 141, 232, 0.18));
  border-color: rgba(196, 141, 232, 0.7);
  box-shadow: 0 0 18px rgba(196, 141, 232, 0.3), 0 0 36px rgba(196, 141, 232, 0.1);
  transform: translateY(-1px);
}

.compose-modal .btn-post:not(:disabled):active {
  transform: translateY(0) scale(0.98);
}

.compose-modal .btn-post:disabled {
  opacity: 0.3;
  cursor: not-allowed;
  animation: none;
}

.compose-modal .composer-tools .tool-btn {
  color: rgba(255, 255, 255, 0.6);
}

.compose-modal .composer-tools .tool-btn:hover {
  color: #ffffff;
}

/* Ensure composer icons are always white regardless of SVG fill */
.compose-modal .composer-tools .tool-btn img.icon-btn,
.compose-modal .composer-tools .tool-btn svg.icon-btn {
  filter: brightness(0) invert(1);
  opacity: 0.85;
}

.compose-modal .composer-tools .tool-btn:hover img.icon-btn,
.compose-modal .composer-tools .tool-btn:hover svg.icon-btn {
  opacity: 1;
  filter: brightness(0) invert(1) drop-shadow(0 0 4px rgba(255, 255, 255, 0.3));
}

/* Video duration badge in modal composer */
.compose-modal .video-duration-badge {
  background: rgba(196, 141, 232, 0.9);
  color: #fff;
}

/* Video preview in modal composer */
.compose-modal .video-preview {
  border-color: rgba(196, 141, 232, 0.2);
  margin-top: 10px;
}

.compose-modal .video-preview .preview-remove {
  background: rgba(0, 0, 0, 0.6);
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
}

.compose-modal .video-preview .preview-remove:hover {
  background: rgba(255, 71, 87, 0.8);
}

.compose-modal .video-duration-indicator {
  background: rgba(196, 141, 232, 0.85);
  color: #fff;
  font-family: 'Share Tech Mono', monospace;
}

.compose-modal .audio-preview {
  margin-top: 8px;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--bg-darkest);
  padding: 0;
}

.compose-modal .audio-preview .audio-preview-inner {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0;
}

.compose-modal .audio-preview .voice-player {
  margin-top: 0;
}

.compose-modal .audio-preview .preview-remove {
  position: absolute;
  top: 6px;
  right: 6px;
  background: rgba(255, 71, 87, 0.15);
  border: none;
  cursor: pointer;
  padding: 4px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
  z-index: 2;
}

.compose-modal .audio-preview .preview-remove:hover {
  background: rgba(255, 71, 87, 0.4);
}

.compose-modal .recording-indicator {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  margin-top: 8px;
  background: rgba(255, 71, 87, 0.08);
  border: 1px solid rgba(255, 71, 87, 0.25);
  border-radius: var(--radius-sm);
}

.compose-modal .recording-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--danger);
  animation: rec-blink 1s ease-in-out infinite;
  flex-shrink: 0;
}

.compose-modal .recording-timer {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.8rem;
  color: var(--danger);
  font-weight: 600;
  letter-spacing: 0.05em;
}

/* ============================================================
   Report modal (mirrors compose-modal structure)
   ============================================================ */
.report-modal {
  width: 100%;
  max-width: 480px;
  background: var(--bg-dark);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 16px;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.5);
  animation: modal-in 0.15s ease-out;
}

.report-modal-hint {
  font-size: 0.85rem;
  color: var(--text-dim);
  margin-bottom: 10px;
}

.report-modal-body select {
  width: 100%;
  background: var(--bg-darkest);
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--text);
  padding: 10px 12px;
  font-size: 0.95rem;
  font-family: inherit;
}

.report-modal-body select:focus {
  outline: none;
  border-color: var(--text);
}

.report-modal-body textarea {
  width: 100%;
  background: var(--bg-darkest);
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--text);
  padding: 10px 12px;
  font-size: 0.95rem;
  font-family: inherit;
  resize: vertical;
  min-height: 72px;
}

.report-modal-body textarea:focus {
  outline: none;
  border-color: var(--teal-dim);
}

.report-modal-body .btn-primary {
  margin-top: 14px;
  width: 100%;
}

/* ============================================================
   Submission & Cap Modals
   ============================================================ */
.submission-modal {
  width: 100%;
  max-width: 480px;
  background: var(--bg-dark);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 16px;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.5);
  animation: modal-in 0.15s ease-out;
}

.submission-modal textarea {
  width: 100%;
  background: var(--bg-darkest);
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--text);
  padding: 10px 12px;
  font-size: 0.95rem;
  font-family: inherit;
  resize: vertical;
  min-height: 72px;
}

.submission-modal textarea:focus {
  outline: none;
  border-color: var(--text);
}

.submission-modal select {
  width: 100%;
  background: var(--bg-darkest);
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--text);
  padding: 10px 12px;
  font-size: 0.95rem;
  font-family: inherit;
}

.submission-modal select:focus {
  outline: none;
  border-color: var(--text);
}

.submission-modal .btn-primary {
  margin-top: 14px;
  width: 100%;
}

.submission-modal .form-field {
  margin-bottom: 12px;
}

.submission-modal .form-field label {
  display: block;
  font-size: 0.85rem;
  color: var(--text-dim);
  margin-bottom: 4px;
  font-weight: 600;
}

.submission-modal .form-hint {
  font-size: 0.78rem;
  color: var(--text-dim);
  margin-top: 2px;
}

.submission-status-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  background: var(--bg-darkest);
  border-radius: 10px;
  margin-bottom: 8px;
  font-size: 0.9rem;
}

.submission-status-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 10px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
}

.submission-status-badge.pending {
  background: rgba(255, 193, 7, 0.15);
  color: #ffc107;
}

.submission-status-badge.approved {
  background: rgba(196, 141, 232, 0.15);
  color: #00e5cc;
}

.submission-status-badge.rejected {
  background: rgba(255, 71, 87, 0.15);
  color: #ff4757;
}

.submission-status-badge.refunded {
  background: rgba(155, 155, 155, 0.15);
  color: #999;
}

/* Cap intercept modal */
.cap-modal {
  width: 100%;
  max-width: 440px;
  background: var(--bg-dark);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 28px 24px;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.5);
  animation: modal-in 0.15s ease-out;
  text-align: center;
}

.cap-modal-icon {
  font-size: 2.5rem;
  margin-bottom: 12px;
}

.cap-modal h3 {
  font-size: 1.2rem;
  color: var(--text);
  margin-bottom: 8px;
}

.cap-modal-desc {
  font-size: 0.9rem;
  color: var(--text-dim);
  margin-bottom: 20px;
  line-height: 1.4;
}

.cap-modal-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.cap-btn-primary {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 14px 20px;
  font-size: 1rem;
  font-weight: 700;
}

.cap-btn-secondary {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 12px 20px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 12px;
  color: var(--text-dim);
  font-size: 0.9rem;
  cursor: pointer;
  transition: border-color 0.15s;
}

.cap-btn-secondary:hover {
  border-color: var(--text);
  color: var(--text);
}

.cap-btn-sub {
  font-size: 0.75rem;
  font-weight: 400;
  opacity: 0.7;
}

/* Track submission badge (in artist profile releases) */
.release-submission-badge {
  display: inline-block;
  padding: 1px 6px;
  border-radius: 6px;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  vertical-align: middle;
  margin-left: 6px;
}

.release-submission-badge.pending {
  background: rgba(255, 193, 7, 0.15);
  color: #ffc107;
}

.release-submission-badge.approved {
  background: rgba(196, 141, 232, 0.15);
  color: #00e5cc;
}

.release-submission-badge.rejected {
  background: rgba(255, 71, 87, 0.15);
  color: #ff4757;
}

/* Submission queue cards (admin) */
.submission-queue-card {
  background: var(--bg-darker);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px 16px;
  margin-bottom: 10px;
}

.submission-queue-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}

.submission-queue-actions {
  display: flex;
  gap: 8px;
  margin-top: 10px;
}

.submission-queue-actions .btn-approve {
  background: rgba(196, 141, 232, 0.15);
  color: #00e5cc;
  border: 1px solid rgba(196, 141, 232, 0.3);
  border-radius: 8px;
  padding: 6px 14px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s;
}

.submission-queue-actions .btn-approve:hover {
  background: rgba(196, 141, 232, 0.25);
}

.submission-queue-actions .btn-reject {
  background: rgba(255, 71, 87, 0.1);
  color: #ff4757;
  border: 1px solid rgba(255, 71, 87, 0.3);
  border-radius: 8px;
  padding: 6px 14px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s;
}

.submission-queue-actions .btn-reject:hover {
  background: rgba(255, 71, 87, 0.2);
}

/* ============================================================
   Admin Safety Console
   ============================================================ */
.admin-console {
  max-width: 720px;
  margin: 0 auto;
}

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

.admin-header h2 {
  color: var(--text);
  font-size: 1.3rem;
}

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

.admin-report-card {
  margin-bottom: 12px;
}

.admin-report-target {
  font-size: 0.9rem;
  color: var(--text);
  margin-bottom: 4px;
}

.admin-report-reason {
  font-size: 0.9rem;
  color: var(--text-dim);
  font-style: italic;
}

.admin-report-actions {
  flex-wrap: wrap;
  gap: 4px;
}

.admin-report-actions .btn-admin-action {
  background: transparent;
  color: var(--text-dim);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 4px 10px;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
}

.admin-report-actions .btn-admin-action:hover {
  background: rgba(196, 141, 232, 0.08);
  color: var(--text);
  border-color: var(--teal-dim);
}

.admin-report-actions .btn-admin-action[data-action="escalated"]:hover,
.admin-report-actions .btn-admin-action[data-action="suspended"]:hover {
  background: rgba(255, 71, 87, 0.1);
  color: var(--danger);
  border-color: var(--danger);
}

/* Status chips — color by severity, using existing theme vars. */
.admin-status-chip {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-dim);
}

.admin-status-chip.status-open,
.admin-status-chip.status-reviewing {
  background: rgba(196, 141, 232, 0.15);
  color: var(--text);
}

.admin-status-chip.status-suspended,
.admin-status-chip.status-escalated {
  background: rgba(255, 71, 87, 0.15);
  color: var(--danger);
}

/* Audit log panel */
#admin-audit-panel {
  margin-top: 16px;
  border-top: 1px solid var(--border);
  padding-top: 12px;
}

.audit-section {
  margin-bottom: 20px;
}

.audit-section h3 {
  color: var(--text);
  font-size: 0.95rem;
  margin-bottom: 8px;
}

.audit-row {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 8px 10px;
  background: var(--bg-darkest);
  border-radius: 8px;
  margin-bottom: 6px;
  font-size: 0.85rem;
}

.audit-type {
  font-weight: 700;
  color: var(--text);
}

.audit-type.audit-lea {
  color: var(--danger);
}

.audit-meta {
  color: var(--text-dim);
  font-size: 0.78rem;
}

/* ============================================================
   Mini-Player (luxury tech / hacker vibe, glassmorphism)
   Sits fixed at the bottom; on mobile it stacks above the tabbar.
   ============================================================ */

.mini-player {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 250;
  background: rgba(2, 2, 4, 0.88);
  backdrop-filter: blur(24px) saturate(1.4);
  -webkit-backdrop-filter: blur(24px) saturate(1.4);
  border-top: 1px solid rgba(196, 141, 232, 0.12);
  box-shadow: 0 -4px 30px rgba(0, 0, 0, 0.6), 0 -1px 0 rgba(196, 141, 232, 0.08) inset;
}

.mp-full {
  display: flex;
  align-items: center;
  gap: 0;
  padding: 10px 16px;
  width: 100%;
}

/* Track info — left */
.mp-info {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  flex-shrink: 0;
  width: 220px;
  padding-right: 16px;
  border-right: 1px solid rgba(255,255,255,0.06);
}

.mp-cover {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: #0a0a14;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  overflow: hidden;
  border: 1px solid rgba(196,141,232,0.15);
  box-shadow: 0 0 12px rgba(196,141,232,0.08);
  transition: box-shadow 0.3s;
}

.mp-cover:hover {
  box-shadow: 0 0 18px rgba(196,141,232,0.18);
}

.mp-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.mp-meta {
  min-width: 0;
}

.mp-title {
  font-weight: 700;
  font-size: 0.88rem;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  letter-spacing: 0.01em;
}

.mp-artist {
  font-size: 0.74rem;
  color: var(--text-dim);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Center controls */
.mp-controls {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
  min-width: 0;
  padding: 0 20px;
}

/* Right section */
.mp-right {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}

/* Shared button base */
.mp-btn {
  background: transparent;
  border: none;
  color: var(--text-dim);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6px;
  border-radius: 8px;
  transition: all 0.2s;
}

.mp-btn:hover {
  color: var(--text);
  background: rgba(196,141,232,0.1);
}

/* Play / Pause button — bigger, violet accent */
.mp-play {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(196,141,232,0.12);
  color: var(--purple);
  flex-shrink: 0;
  transition: all 0.2s;
}

.mp-play:hover {
  background: rgba(196,141,232,0.22);
  box-shadow: 0 0 16px rgba(196,141,232,0.25);
  transform: scale(1.06);
}

.mp-play:active {
  transform: scale(0.95);
}

/* Progress bar area */
.mp-progress-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
  min-width: 0;
}

.mp-time {
  font-family: 'Share Tech Mono', 'Courier New', monospace;
  font-size: 0.72rem;
  color: var(--text-muted);
  min-width: 36px;
  text-align: center;
  letter-spacing: 0.04em;
  user-select: none;
}

.mp-progress {
  flex: 1;
  height: 4px;
  background: rgba(255,255,255,0.08);
  border-radius: 4px;
  position: relative;
  cursor: pointer;
  transition: height 0.15s;
}

.mp-progress:hover {
  height: 6px;
}

.mp-progress-bar {
  height: 100%;
  border-radius: 4px;
  background: linear-gradient(90deg, var(--purple), var(--purple-soft));
  width: 0%;
  position: absolute;
  top: 0;
  left: 0;
  pointer-events: none;
  transition: width 0.1s linear;
}

.mp-progress-knob {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--purple);
  position: absolute;
  top: 50%;
  left: 0%;
  transform: translate(-50%, -50%);
  box-shadow: 0 0 8px rgba(196,141,232,0.4);
  opacity: 0;
  transition: opacity 0.15s, transform 0.15s;
  pointer-events: none;
  z-index: 2;
}

.mp-progress:hover .mp-progress-knob {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1.2);
}

/* Volume controls */
.mp-volume-wrap {
  display: flex;
  align-items: center;
  gap: 4px;
}

.mp-volume-btn {
  padding: 5px;
}

.mp-volume-slider {
  width: 80px;
  height: 4px;
  background: rgba(255,255,255,0.08);
  border-radius: 4px;
  position: relative;
  cursor: pointer;
}

.mp-volume-slider:hover {
  height: 5px;
}

.mp-volume-bar {
  height: 100%;
  border-radius: 4px;
  background: var(--purple);
  width: 80%;
  pointer-events: none;
}

/* Minimize / Close */
.mp-minimize, .mp-close {
  padding: 5px;
}

.mp-close:hover {
  color: var(--danger);
  background: rgba(255,71,87,0.1);
}

/* Hidden audio element */
#mp-audio {
  display: none;
}

/* ============================================================
   Minimized pill — floating bottom-right
   ============================================================ */
.mp-pill {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 260;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px 8px 10px;
  background: rgba(2, 2, 4, 0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(196,141,232,0.15);
  border-radius: 24px;
  box-shadow: 0 4px 24px rgba(0,0,0,0.5), 0 0 16px rgba(196,141,232,0.1);
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4,0,0.2,1);
}

.mp-pill:hover {
  border-color: rgba(196,141,232,0.3);
  box-shadow: 0 4px 28px rgba(0,0,0,0.6), 0 0 24px rgba(196,141,232,0.18);
  transform: translateY(-2px);
}

.mp-pill-play {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(196,141,232,0.15);
  border: none;
  color: var(--purple);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: all 0.2s;
}

.mp-pill-play:hover {
  background: rgba(196,141,232,0.28);
  box-shadow: 0 0 12px rgba(196,141,232,0.3);
}

.mp-pill-title {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-dim);
  max-width: 140px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Stack the player above the mobile tabbar on small screens */
@media (max-width: 600px) {
  .mini-player { bottom: 60px; }
  .mp-info { width: 140px; padding-right: 10px; }
  .mp-cover { width: 36px; height: 36px; border-radius: 8px; }
  .mp-controls { padding: 0 10px; gap: 8px; }
  .mp-volume-wrap { display: none; }
  .mp-pill { bottom: 70px; right: 12px; }
}

/* ============================================================
   Upload Form (artist track release)
   ============================================================ */

.upload-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-top: 16px;
  max-width: 480px;
}

.upload-form .form-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.upload-form label {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text);
}

.upload-form .opt {
  font-weight: 400;
  color: var(--text-dim);
}

.upload-form input[type="text"],
.upload-form input[type="file"] {
  padding: 10px 12px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 0.95rem;
  transition: border-color 0.15s;
}

.upload-form input[type="text"]:focus {
  border-color: var(--text);
}

.upload-form .form-hint {
  font-size: 0.76rem;
  color: var(--text-muted);
}

.coming-soon-banner {
  padding: 14px 16px;
  margin-bottom: 8px;
  background: rgba(196, 141, 232, 0.07);
  border: 1px solid var(--border-hover);
  border-radius: var(--radius-sm);
  color: var(--teal-soft);
  font-size: 0.88rem;
  line-height: 1.5;
}

/* ============================================================
   Charts Page
   ============================================================ */

.page-card {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px 80px;
}

.page-title {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 6px;
}

.charts-week {
  font-size: 0.8rem;
  color: var(--text-dim);
  margin-bottom: 12px;
}

.charts-tabs {
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.charts-tabs .tab-count {
  opacity: 0.6;
  font-size: 0.78rem;
  margin-left: 3px;
}

.chart-section-title {
  font-weight: 700;
  font-size: 1rem;
  color: var(--text);
  margin: 18px 0 8px;
  padding-left: 2px;
}

.chart-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.chart-entry {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  transition: background 0.15s;
}

.chart-entry:hover {
  background: rgba(196, 141, 232, 0.04);
}

.chart-rank {
  font-weight: 800;
  font-size: 1rem;
  color: var(--teal-dim);
  width: 26px;
  text-align: center;
  flex-shrink: 0;
}

.chart-entry .release-cover {
  width: 42px;
  height: 42px;
  flex-shrink: 0;
}

.chart-peak-note {
  color: var(--teal-soft);
  font-weight: 600;
  margin-right: 6px;
}

/* ============================================================
   Phase 4 — Discovery sidebar elements
   (scope tabs, suggested-users rail, charts rail)
   ============================================================ */

.sidebar-header-tabs {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.scope-tabs {
  display: flex;
  gap: 2px;
}

.scope-tabs button {
  background: transparent;
  color: var(--text-dim);
  padding: 3px 6px;
  border-radius: 6px;
  font-size: 0.68rem;
  font-weight: 700;
  transition: all 0.15s;
}

.scope-tabs button:hover {
  color: var(--text);
}

.scope-tabs button.active {
  background: rgba(196, 141, 232, 0.15);
  color: var(--text);
}

/* Suggested users rail */
/* Terminal-style suggested users */
#suggested-widget .sidebar-header {
  font-family: 'Share Tech Mono', 'SF Mono', 'Fira Code', 'Consolas', monospace;
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #c48de8;
  text-shadow: 0 0 8px rgba(196, 141, 232, 0.5), 0 0 16px rgba(100, 140, 255, 0.3);
  animation: signal-pulse 2s ease-in-out infinite;
}

@keyframes signal-pulse {
  0%, 100% { text-shadow: 0 0 8px rgba(196, 141, 232, 0.5), 0 0 16px rgba(100, 140, 255, 0.3); }
  50% { text-shadow: 0 0 14px rgba(196, 141, 232, 0.8), 0 0 28px rgba(100, 140, 255, 0.5); }
}

#suggested-widget .sidebar-icon {
  display: none;
}

.terminal-log {
  max-height: 220px;
  overflow-y: auto;
  padding: 8px 12px;
  scrollbar-width: none;
  background: linear-gradient(180deg, rgba(10,10,18,0.4) 0%, rgba(5,5,12,0.2) 100%);
  border-radius: 6px;
  border: 1px solid rgba(196,141,232,0.1);
}

.terminal-log::-webkit-scrollbar {
  display: none;
}

.terminal-line {
  font-family: 'Share Tech Mono', 'SF Mono', 'Fira Code', 'Consolas', monospace;
  font-size: 0.8rem;
  padding: 4px 0;
  color: #c48de8;
  opacity: 0;
  animation: terminal-appear 0.3s ease forwards;
  letter-spacing: 0.04em;
}

@keyframes terminal-appear {
  from { opacity: 0; transform: translateX(-6px); }
  to { opacity: 1; transform: translateX(0); }
}

.terminal-prompt {
  color: var(--text-muted);
  font-size: 0.72rem;
  opacity: 1;
  text-shadow: 0 0 6px rgba(196,141,232,0.3);
}

.terminal-user {
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px 4px;
  border-radius: 4px;
  transition: background 0.15s;
}

.terminal-user:hover {
  background: rgba(196, 141, 232, 0.08);
  box-shadow: inset 0 0 12px rgba(100,140,255,0.08);
}

.terminal-user:hover .terminal-name {
  color: #fff;
  text-shadow: 0 0 10px rgba(196, 141, 232, 0.7), 0 0 20px rgba(100, 140, 255, 0.4);
}

.terminal-prefix {
  color: #9a7cb8;
  font-size: 0.75rem;
  text-shadow: 0 0 4px rgba(100,140,255,0.3);
  animation: prefix-blink 1.2s step-end infinite;
}

@keyframes prefix-blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

.terminal-name {
  color: #e0d0f0;
  font-weight: 600;
  font-family: 'Share Tech Mono', 'SF Mono', 'Fira Code', monospace;
  letter-spacing: 0.06em;
  text-transform: lowercase;
  text-shadow: 0 0 6px rgba(196,141,232,0.3);
  transition: all 0.15s;
}

.terminal-status {
  color: var(--text-muted);
  font-size: 0.68rem;
  opacity: 0.7;
}

.terminal-done {
  color: var(--text-muted);
  font-size: 0.72rem;
  opacity: 1;
  animation: blink-cursor 1s step-end infinite;
}

.terminal-empty {
  font-family: 'Share Tech Mono', 'SF Mono', 'Fira Code', monospace;
  font-size: 0.75rem;
  color: var(--text-muted);
  padding: 12px;
  text-shadow: 0 0 4px rgba(196,141,232,0.15);
}

@keyframes blink-cursor {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

.btn-follow-mini {
  background: linear-gradient(135deg, #8b5cf6, #a78bfa);
  color: #ffffff;
  border: none;
  padding: 5px 12px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.74rem;
  flex-shrink: 0;
  transition: all 0.15s;
}

.btn-follow-mini:hover {
  background: linear-gradient(135deg, #7c3aed, #8b5cf6);
  box-shadow: 0 4px 12px rgba(139, 92, 246, 0.3);
}

.btn-follow-mini.following {
  background: rgba(139, 92, 246, 0.12);
  border: 1px solid rgba(139, 92, 246, 0.4);
  color: #a78bfa;
}

/* Charts rail (compact weekly top) */
.chart-rail-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 16px;
  transition: background 0.15s;
}

.chart-rail-item:hover {
  background: rgba(196, 141, 232, 0.04);
}

.chart-rail-rank {
  font-weight: 800;
  font-size: 0.85rem;
  color: var(--teal-dim);
  width: 16px;
  text-align: center;
  flex-shrink: 0;
}

.chart-rail-cover {
  width: 34px;
  height: 34px;
  border-radius: 6px;
  background: var(--bg-input);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.95rem;
  flex-shrink: 0;
  overflow: hidden;
}

.chart-rail-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.chart-rail-title {
  font-weight: 700;
  font-size: 0.82rem;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.chart-rail-genre {
  font-size: 0.72rem;
  color: var(--text-dim);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Compact play button in the rail rows */
.chart-rail-item .track-play-btn {
  width: 28px;
  height: 28px;
  font-size: 0.8rem;
  flex-shrink: 0;
}

/* ============================================================
   Admin Panel
   ============================================================ */

.admin-panel {
  padding: 20px 24px;
}

.admin-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 20px;
}

.admin-search {
  display: flex;
  gap: 8px;
  margin-bottom: 20px;
}

.admin-search input {
  flex: 1;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 8px 12px;
  color: var(--text);
  font-size: 0.9rem;
}

.admin-search input:focus {
  outline: none;
  border-color: var(--text);
}

.admin-users-list {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.admin-user-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  background: var(--nav-bg);
  border-radius: 8px;
  margin-bottom: 4px;
}

.admin-user-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

.admin-user-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.admin-user-name {
  font-weight: 600;
  color: var(--purple);
  text-decoration: none;
}

.admin-user-name:hover {
  color: var(--purple-soft);
}

.admin-user-meta {
  font-size: 0.78rem;
  color: var(--text-dim);
}

.admin-user-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.admin-user-badge {
  font-size: 0.85rem;
}

.admin-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 20px;
  color: var(--text-dim);
  font-size: 0.85rem;
}

.admin-pagination button {
  padding: 6px 12px;
}

.admin-pagination button:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* ============================================================
   Genre Filter Banner
   ============================================================ */

.genre-filter-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 16px;
  margin-bottom: 12px;
  background: rgba(196, 141, 232, 0.08);
  border: 1px solid var(--teal-dim);
  border-radius: var(--radius-sm);
  color: var(--teal-soft);
  font-size: 0.9rem;
}

.genre-filter-banner strong {
  color: var(--text);
}

.genre-filter-clear {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--teal-dim);
  border-radius: 14px;
  padding: 4px 14px;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
}

.genre-filter-clear:hover {
  background: rgba(196, 141, 232, 0.12);
}

/* ============================================================
   Save / Bookmark Button
   ============================================================ */

.post-actions button.btn-save {
  margin-left: auto;
  opacity: 0.6;
}

.post-actions button.btn-save:hover {
  opacity: 1;
  background: rgba(196, 141, 232, 0.06);
  color: var(--text);
}

.post-actions button.btn-save.saved {
  opacity: 1;
  color: var(--text);
}

/* ============================================================
   Hot Regions Widget (right sidebar)
   ============================================================ */

.pulse-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--teal);
  margin-right: 6px;
  position: relative;
  vertical-align: middle;
  box-shadow: 0 0 6px var(--teal), 0 0 12px var(--teal);
  animation: pulse-glow 2s ease-in-out infinite;
}

.pulse-dot::after {
  content: '';
  position: absolute;
  top: -4px;
  left: -4px;
  right: -4px;
  bottom: -4px;
  border-radius: 50%;
  border: 1px solid var(--teal);
  opacity: 0;
  animation: pulse-ring 2s ease-out infinite;
}

@keyframes pulse-glow {
  0%, 100% { opacity: 1; box-shadow: 0 0 6px var(--teal), 0 0 12px var(--teal); }
  50% { opacity: 0.6; box-shadow: 0 0 3px var(--teal), 0 0 6px var(--teal); }
}

@keyframes pulse-ring {
  0% { transform: scale(1); opacity: 0.6; }
  100% { transform: scale(2.2); opacity: 0; }
}

#hot-regions-widget .sidebar-header {
  font-family: 'Share Tech Mono', 'SF Mono', 'Fira Code', monospace;
  font-size: 0.65rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--teal);
  text-shadow: 0 0 12px rgba(0, 229, 160, 0.6), 0 0 24px rgba(0, 229, 160, 0.2);
  border-bottom: 1px solid rgba(0, 229, 160, 0.15);
  position: relative;
  overflow: hidden;
}

/* Scanline overlay */
#hot-regions-widget .sidebar-header::after {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 2px,
    rgba(0, 229, 160, 0.015) 2px,
    rgba(0, 229, 160, 0.015) 4px
  );
  pointer-events: none;
}

.hot-region-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 16px;
  cursor: pointer;
  transition: all 0.2s;
  border-bottom: 1px solid rgba(255, 255, 255, 0.02);
  font-family: 'Share Tech Mono', 'SF Mono', 'Fira Code', monospace;
  opacity: 0;
  animation: surge-row-in 0.4s ease forwards;
}

.hot-region-item:hover {
  background: rgba(0, 229, 160, 0.04);
}

.hot-region-item:hover .hot-region-name {
  text-shadow: 0 0 10px rgba(0, 229, 160, 0.5);
}

.hot-region-code {
  font-family: 'Share Tech Mono', 'SF Mono', 'Fira Code', monospace;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  min-width: 28px;
  text-align: center;
  color: var(--teal);
  text-shadow: 0 0 8px rgba(0, 229, 160, 0.4);
  animation: surge-glow 3s ease-in-out infinite;
}

.hot-region-info {
  flex: 1;
  min-width: 0;
}

.hot-region-name {
  font-weight: 500;
  font-size: 0.82rem;
  color: var(--teal);
  letter-spacing: 0.04em;
  text-shadow: 0 0 6px rgba(0, 229, 160, 0.25);
  animation: surge-city-pulse 4s ease-in-out infinite;
}

.hot-region-count {
  font-size: 0.68rem;
  color: rgba(0, 229, 160, 0.4);
  letter-spacing: 0.05em;
}

.hot-region-trend {
  font-size: 0.7rem;
  font-weight: 700;
}

.trend-up { color: #00e5a0; text-shadow: 0 0 8px rgba(0, 229, 160, 0.5); animation: surge-arrow-pulse 2s ease-in-out infinite; }
.trend-down { color: #ff4757; text-shadow: 0 0 8px rgba(255, 71, 87, 0.4); }
.trend-stable { color: rgba(0, 229, 160, 0.3); }

/* ============================================================
   Nuke Confirmation Modal
   ============================================================ */

.nuke-modal {
  background: var(--bg-card);
  border: 1px solid var(--danger);
  border-radius: var(--radius);
  padding: 36px 32px;
  max-width: 380px;
  width: 100%;
  text-align: center;
  box-shadow: 0 0 30px rgba(255, 71, 87, 0.15);
}

.nuke-modal-icon {
  font-size: 2.4rem;
  margin-bottom: 12px;
}

.nuke-modal-title {
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--danger);
  margin-bottom: 12px;
}

.nuke-modal-desc {
  font-size: 0.88rem;
  color: var(--text-dim);
  margin-bottom: 24px;
  line-height: 1.5;
}

.nuke-modal-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
}

.nuke-modal-actions .btn-secondary {
  padding: 10px 24px;
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-dim);
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 0.88rem;
  cursor: pointer;
  transition: all 0.15s;
}

.nuke-modal-actions .btn-secondary:hover {
  border-color: var(--text);
  color: var(--text);
}

.nuke-modal-actions .btn-danger {
  padding: 10px 24px;
  background: var(--danger);
  border: none;
  color: #fff;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: 0.88rem;
  cursor: pointer;
  transition: all 0.15s;
}

.nuke-modal-actions .btn-danger:hover {
  opacity: 0.85;
  box-shadow: 0 0 16px rgba(255, 71, 87, 0.3);
}

/* ============================================================
   Floating DM Panel (LinkedIn-style)
   ============================================================ */

.dm-float-panel {
  position: fixed;
  bottom: 0;
  right: 20px;
  width: 360px;
  height: 460px;
  background: var(--bg-dark);
  border: 1px solid var(--border);
  border-bottom: none;
  border-radius: 12px 12px 0 0;
  z-index: 300;
  display: flex;
  flex-direction: column;
  box-shadow: 0 -4px 24px rgba(0, 0, 0, 0.5), 0 0 1px rgba(196, 141, 232, 0.2);
  animation: dm-float-in 0.2s ease-out;
  overflow: hidden;
}

@keyframes dm-float-in {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.dm-float-panel.hidden {
  display: none !important;
}

/* Float panel header (always visible, shows "Messages" or conversation name) */
.dm-float-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: var(--bg-darkest);
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  user-select: none;
  flex-shrink: 0;
}

.dm-float-header:hover {
  background: rgba(196, 141, 232, 0.05);
}

.dm-float-title {
  flex: 1;
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--text);
}

.dm-float-close {
  background: transparent;
  border: none;
  color: var(--text-dim);
  font-size: 1.1rem;
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 6px;
  transition: all 0.15s;
  line-height: 1;
}

.dm-float-close:hover {
  background: rgba(255, 71, 87, 0.15);
  color: var(--danger);
}

/* Float body — holds conversation list OR chat thread */
.dm-float-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-height: 0;
}

/* Conversation list inside float panel */
.dm-float-conv-list {
  flex: 1;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
}

.dm-float-conv-list::-webkit-scrollbar {
  width: 4px;
}

.dm-float-conv-list::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 4px;
}

/* Search bar inside conversation list */
.dm-float-search {
  padding: 8px 12px;
  border-bottom: 1px solid var(--border);
}

.dm-float-search input {
  width: 100%;
  padding: 7px 12px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 16px;
  color: var(--text);
  font-size: 0.82rem;
  outline: none;
  transition: border-color 0.15s;
}

.dm-float-search input:focus {
  border-color: var(--text);
}

.dm-float-search input::placeholder {
  color: var(--text-muted);
}

/* Individual conversation row in float panel */
.dm-float-conv-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  cursor: pointer;
  transition: background 0.12s;
  border-bottom: 1px solid rgba(196, 141, 232, 0.04);
}

.dm-float-conv-item:hover {
  background: rgba(196, 141, 232, 0.06);
}

.dm-float-conv-item.active {
  background: rgba(196, 141, 232, 0.1);
}

.dm-float-conv-info {
  flex: 1;
  min-width: 0;
}

.dm-float-conv-name {
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dm-float-conv-preview {
  font-size: 0.76rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-top: 1px;
}

.dm-float-conv-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 4px;
  flex-shrink: 0;
}

.dm-float-conv-time {
  font-size: 0.7rem;
  color: var(--text-muted);
  white-space: nowrap;
}

.dm-float-conv-badge {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--teal);
  box-shadow: 0 0 6px var(--teal);
}

/* Chat thread inside float panel */
.dm-float-chat {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.dm-float-chat-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-bottom: 1px solid var(--border);
  background: var(--bg-darkest);
  flex-shrink: 0;
}

.dm-float-back {
  background: transparent;
  border: none;
  color: var(--text-dim);
  font-size: 1rem;
  cursor: pointer;
  padding: 4px 6px;
  border-radius: 6px;
  transition: all 0.15s;
}

.dm-float-back:hover {
  background: rgba(196, 141, 232, 0.1);
  color: var(--text);
}

.dm-float-chat-name {
  font-weight: 700;
  font-size: 0.88rem;
  color: var(--teal);
  flex: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Messages area */
.dm-float-messages {
  flex: 1;
  overflow-y: auto;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
  min-height: 0;
}

.dm-float-messages::-webkit-scrollbar {
  width: 4px;
}

.dm-float-messages::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 4px;
}

/* Chat bubbles in float panel */
.dm-float-msg {
  display: flex;
  flex-direction: column;
  max-width: 80%;
}

.dm-float-msg-me {
  align-self: flex-end;
  align-items: flex-end;
}

.dm-float-msg-them {
  align-self: flex-start;
}

.dm-float-msg-row {
  display: flex;
  align-items: flex-end;
  gap: 6px;
}

.dm-float-msg-them .dm-float-msg-row {
  flex-direction: row;
}

.dm-float-msg-me .dm-float-msg-row {
  flex-direction: row-reverse;
}

.dm-float-msg-avatar {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(196, 141, 232, 0.25), rgba(196, 141, 232, 0.2));
  border: 1px solid rgba(196, 141, 232, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text);
  font-weight: 700;
  font-size: 0.6rem;
  flex-shrink: 0;
  overflow: hidden;
}

.dm-float-msg-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.dm-float-msg-bubble {
  padding: 8px 12px;
  border-radius: 14px;
  font-size: 0.85rem;
  line-height: 1.4;
  word-wrap: break-word;
}

.dm-float-msg-me .dm-float-msg-bubble {
  background: var(--teal-dark);
  color: var(--text);
  border-bottom-right-radius: 4px;
}

.dm-float-msg-them .dm-float-msg-bubble {
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text);
  border-bottom-left-radius: 4px;
}

.dm-float-msg-time {
  font-size: 0.65rem;
  color: var(--text-muted);
  margin-top: 2px;
  padding: 0 4px;
}

/* Input bar inside float panel */
.dm-float-input-bar {
  display: flex;
  gap: 6px;
  padding: 8px 10px;
  border-top: 1px solid var(--border);
  background: var(--bg-darkest);
  flex-shrink: 0;
}

.dm-float-input-bar input {
  flex: 1;
  padding: 8px 12px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 18px;
  color: var(--text);
  font-size: 0.82rem;
  outline: none;
}

.dm-float-input-bar input:focus {
  border-color: var(--text);
}

.dm-float-input-bar input::placeholder {
  color: var(--text-muted);
}

.dm-float-send {
  padding: 6px 16px;
  background: var(--bg-darkest);
  color: var(--purple);
  border: 1.5px solid var(--purple);
  border-radius: 18px;
  font-weight: 700;
  font-size: 0.8rem;
  cursor: pointer;
  transition: all 0.15s;
  white-space: nowrap;
}

.dm-float-send:hover {
  box-shadow: 0 0 10px rgba(196, 141, 232, 0.25);
}

.dm-float-send:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* Empty state inside float */
.dm-float-empty {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--text-dim);
  font-size: 0.85rem;
  gap: 8px;
}

.dm-float-empty .icon {
  font-size: 2rem;
  opacity: 0.4;
}

/* New DM form inside float */
.dm-float-new-form {
  padding: 16px;
}

.dm-float-new-form .auth-field {
  margin-bottom: 12px;
}

.dm-float-new-form .auth-field label {
  font-size: 0.8rem;
}

.dm-float-new-form .auth-field input {
  padding: 8px 12px;
  font-size: 0.85rem;
}

/* Mobile float panel */
@media (max-width: 600px) {
  .dm-float-panel {
    width: 100%;
    right: 0;
    height: calc(100vh - 60px);
    bottom: 60px;
    border-radius: 0;
  }

  .dm-float-msg {
    max-width: 88%;
  }
}

/* ═══════════════════════════════════════════════════════════════════
   GRAND OPENING — Apple Quality × Dystopian Quantum Tech Luxury
   Premium UI overhaul: alignments, detailing, spacing, glow
   ═══════════════════════════════════════════════════════════════════ */

/* ── Left Nav Premium ───────────────────────────────────────────── */
.left-nav {
  border-right: 1px solid rgba(139, 92, 246, 0.08);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.left-nav-item {
  position: relative;
  overflow: hidden;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.left-nav-item::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 3px;
  height: 0;
  background: linear-gradient(180deg, #8b5cf6, #a78bfa);
  border-radius: 0 2px 2px 0;
  transition: height 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 0 8px rgba(139, 92, 246, 0.5);
}

.left-nav-item:hover::before,
.left-nav-item.active::before {
  height: 60%;
}

.left-nav-item.active {
  background: linear-gradient(90deg, rgba(139, 92, 246, 0.12), rgba(139, 92, 246, 0.04));
  border-color: rgba(139, 92, 246, 0.15);
  box-shadow: inset 0 0 20px rgba(139, 92, 246, 0.06);
}

.left-nav-divider {
  border-top: 1px solid rgba(139, 92, 246, 0.1);
  margin: 12px 8px;
}

/* ── FAB Premium ────────────────────────────────────────────────── */
.post-fab {
  width: 52px;
  height: 52px;
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(15, 15, 25, 0.95), rgba(10, 10, 20, 0.98));
  border: 1.5px solid rgba(139, 92, 246, 0.6);
  position: fixed;
  bottom: 28px;
  left: 24px;
  z-index: 150;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow:
    0 0 20px rgba(139, 92, 246, 0.25),
    0 0 40px rgba(139, 92, 246, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(12px);
}

.post-fab:hover {
  border-color: rgba(139, 92, 246, 0.9);
  box-shadow:
    0 0 24px rgba(139, 92, 246, 0.4),
    0 0 48px rgba(139, 92, 246, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  transform: translateY(-2px);
}

.post-fab:active {
  transform: scale(0.95) translateY(0);
}

.post-fab .fab-icon {
  font-size: 22px;
  font-weight: 300;
  color: #a78bfa;
  transition: color 0.2s;
}

.post-fab:hover .fab-icon {
  color: #c4b5fd;
}

/* ── Composer Premium ───────────────────────────────────────────── */
.composer-bar {
  background: linear-gradient(180deg, rgba(10, 10, 18, 0.98), rgba(8, 8, 14, 0.95));
  border-top: 1px solid rgba(139, 92, 246, 0.1);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 -4px 24px rgba(0, 0, 0, 0.4);
}

.composer-bar textarea,
.composer-bar input {
  background: rgba(20, 20, 35, 0.6);
  border: 1px solid rgba(139, 92, 246, 0.12);
  border-radius: 12px;
  color: var(--text);
  font-family: 'Space Grotesk', -apple-system, sans-serif;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.composer-bar textarea:focus,
.composer-bar input:focus {
  border-color: rgba(139, 92, 246, 0.4);
  box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.08), 0 0 16px rgba(139, 92, 246, 0.06);
  outline: none;
}

.compose-modal {
  background: linear-gradient(180deg, #0c0c14, #08080e);
  border: 1px solid rgba(139, 92, 246, 0.15);
  border-radius: 16px;
  box-shadow:
    0 24px 64px rgba(0, 0, 0, 0.6),
    0 0 1px rgba(139, 92, 246, 0.3);
}

.compose-modal textarea {
  background: rgba(15, 15, 28, 0.8);
  border: 1px solid rgba(139, 92, 246, 0.1);
  border-radius: 12px;
  color: var(--text);
  transition: border-color 0.2s, box-shadow 0.2s;
}

.compose-modal textarea:focus {
  border-color: rgba(139, 92, 246, 0.35);
  box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.06);
  outline: none;
}

/* ── Post Cards Premium ─────────────────────────────────────────── */
.post-card {
  background: linear-gradient(180deg, rgba(12, 12, 20, 0.8), rgba(8, 8, 16, 0.6));
  border: 1px solid rgba(139, 92, 246, 0.06);
  border-radius: 16px;
  padding: 20px;
  margin-bottom: 2px;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.post-card::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(139, 92, 246, 0.15), transparent);
  opacity: 0;
  transition: opacity 0.3s;
}

.post-card:hover {
  border-color: rgba(139, 92, 246, 0.12);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.3), 0 0 1px rgba(139, 92, 246, 0.1);
}

.post-card:hover::after {
  opacity: 1;
}

/* ── Sidebar Cards Premium ──────────────────────────────────────── */
.sidebar-card {
  background: linear-gradient(180deg, rgba(12, 12, 20, 0.7), rgba(8, 8, 16, 0.5));
  border: 1px solid rgba(139, 92, 246, 0.08);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.2);
}

.sidebar-header {
  padding: 16px 20px;
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text);
  border-bottom: 1px solid rgba(139, 92, 246, 0.06);
  background: linear-gradient(90deg, rgba(139, 92, 246, 0.04), transparent);
}

.sidebar-body {
  padding: 8px 0;
}

/* ── Trending / Sub Nets Premium ────────────────────────────────── */
.trend-item {
  padding: 12px 20px;
  border-bottom: 1px solid rgba(139, 92, 246, 0.04);
  transition: background 0.15s;
  cursor: pointer;
}

.trend-item:last-child {
  border-bottom: none;
}

.trend-item:hover {
  background: rgba(139, 92, 246, 0.04);
}

.trend-tag {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text);
}

.trend-genre {
  font-size: 0.75rem;
  color: var(--text-dim);
  margin-top: 2px;
}

/* ── Buttons Premium ────────────────────────────────────────────── */
.btn-primary {
  background: linear-gradient(135deg, #8b5cf6, #7c3aed);
  color: #ffffff;
  border: none;
  border-radius: 10px;
  padding: 10px 20px;
  font-weight: 600;
  font-size: 0.85rem;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 2px 8px rgba(139, 92, 246, 0.25);
}

.btn-primary:hover {
  background: linear-gradient(135deg, #9b6ff7, #8b5cf6);
  box-shadow: 0 4px 16px rgba(139, 92, 246, 0.35);
  transform: translateY(-1px);
}

.btn-primary:active {
  transform: translateY(0) scale(0.98);
}

.btn-follow {
  background: linear-gradient(135deg, #8b5cf6, #a78bfa);
  color: #ffffff;
  border: none;
  border-radius: 10px;
  padding: 7px 20px;
  font-weight: 600;
  font-size: 0.82rem;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-follow:hover {
  background: linear-gradient(135deg, #7c3aed, #8b5cf6);
  box-shadow: 0 4px 16px rgba(139, 92, 246, 0.4);
  transform: translateY(-1px);
}

.btn-follow.following {
  background: rgba(139, 92, 246, 0.12);
  border: 1px solid rgba(139, 92, 246, 0.4);
  color: #a78bfa;
}

.btn-message {
  background: linear-gradient(135deg, #8b5cf6, #a78bfa);
  color: #ffffff;
  border: none;
  border-radius: 10px;
  padding: 7px 20px;
  font-weight: 600;
  font-size: 0.82rem;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-message:hover {
  background: linear-gradient(135deg, #7c3aed, #8b5cf6);
  box-shadow: 0 4px 16px rgba(139, 92, 246, 0.4);
  transform: translateY(-1px);
}

/* ── DM Float Panel Premium ─────────────────────────────────────── */
.dm-float-panel {
  border: 1px solid rgba(139, 92, 246, 0.15);
  border-bottom: none;
  border-radius: 16px 16px 0 0;
  background: linear-gradient(180deg, rgba(10, 10, 18, 0.98), rgba(8, 8, 14, 0.95));
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow:
    0 -8px 40px rgba(0, 0, 0, 0.5),
    0 0 1px rgba(139, 92, 246, 0.3),
    0 0 40px rgba(139, 92, 246, 0.04);
}

.dm-float-header {
  padding: 16px 20px;
  border-bottom: 1px solid rgba(139, 92, 246, 0.1);
  background: linear-gradient(90deg, rgba(139, 92, 246, 0.06), transparent);
}

.dm-float-conv-item {
  padding: 12px 20px;
  border-bottom: 1px solid rgba(139, 92, 246, 0.04);
  transition: background 0.15s;
}

.dm-float-conv-item:hover {
  background: rgba(139, 92, 246, 0.06);
}

/* ── Topbar Premium ─────────────────────────────────────────────── */
.topbar {
  border-bottom: 1px solid rgba(139, 92, 246, 0.08);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  background: linear-gradient(180deg, rgba(8, 8, 14, 0.98), rgba(6, 6, 12, 0.95));
}

/* ── Notification Items Premium ─────────────────────────────────── */
.notif-item {
  padding: 14px 20px;
  border-bottom: 1px solid rgba(139, 92, 246, 0.04);
  transition: background 0.15s;
}

.notif-item:hover {
  background: rgba(139, 92, 246, 0.04);
}

.notif-item.notif-unread {
  background: rgba(139, 92, 246, 0.04);
  border-left: 3px solid #8b5cf6;
}

/* ── Input Fields Premium ───────────────────────────────────────── */
input[type="text"],
input[type="email"],
input[type="password"],
input[type="search"] {
  background: rgba(15, 15, 28, 0.6);
  border: 1px solid rgba(139, 92, 246, 0.1);
  border-radius: 10px;
  color: var(--text);
  font-family: 'Space Grotesk', -apple-system, sans-serif;
  transition: border-color 0.2s, box-shadow 0.2s;
}

input:focus {
  border-color: rgba(139, 92, 246, 0.35);
  box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.06);
  outline: none;
}

/* ── Scrollbar Premium ──────────────────────────────────────────── */
::-webkit-scrollbar {
  width: 6px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

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

::-webkit-scrollbar-thumb:hover {
  background: rgba(139, 92, 246, 0.35);
}

/* ── Profile Card Premium ───────────────────────────────────────── */
.profile-header {
  border-bottom: 1px solid rgba(139, 92, 246, 0.08);
}

.profile-stats {
  display: flex;
  gap: 24px;
}

.profile-stat {
  text-align: center;
  padding: 8px 12px;
  border-radius: 10px;
  transition: background 0.15s;
}

.profile-stat:hover {
  background: rgba(139, 92, 246, 0.06);
}

/* ── Verified Badges Premium ────────────────────────────────────── */
.verified-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: linear-gradient(135deg, #8b5cf6, #a78bfa);
  color: #ffffff;
  font-size: 0.65rem;
  font-weight: 700;
  margin-left: 6px;
  vertical-align: middle;
  box-shadow: 0 0 6px rgba(139, 92, 246, 0.3);
  flex-shrink: 0;
}

/* Holographic creator badge */
.verified-badge.creator-badge {
  background: linear-gradient(135deg,
    rgba(255, 107, 157, 0.6),
    rgba(196, 141, 232, 0.7),
    rgba(109, 213, 250, 0.6),
    rgba(168, 224, 99, 0.5));
  background-size: 300% 300%;
  animation: holoShift 4s ease infinite;
  box-shadow:
    0 0 8px rgba(196, 141, 232, 0.4),
    0 0 16px rgba(109, 213, 250, 0.2);
}

@keyframes holoShift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

.verified-badge.admin-badge {
  background: linear-gradient(135deg, #6366f1, #818cf8);
}

.verified-badge.nucleus-badge {
  background: radial-gradient(circle, rgba(139,92,246,0.3) 0%, transparent 70%);
  animation: nucleusPulse 2s ease-in-out infinite;
}

.verified-badge.nucleus-badge svg {
  width: 14px;
  height: 14px;
}

.verified-badge.creator-badge {
  background: conic-gradient(from 0deg, #c48de8, #818cf8, #38bdf8, #34d399, #fbbf24, #f472b6, #c48de8);
  animation: holoSpin 3s linear infinite;
  overflow: hidden;
}

.verified-badge.creator-badge svg {
  width: 14px;
  height: 14px;
  filter: drop-shadow(0 0 2px rgba(255,255,255,0.5));
}

/* ── Loading States Premium ─────────────────────────────────────── */
.loading {
  text-align: center;
  padding: 32px;
  color: var(--text-dim);
  font-size: 0.85rem;
  letter-spacing: 0.04em;
}

.loading::after {
  content: '';
  display: inline-block;
  width: 16px;
  height: 16px;
  border: 2px solid rgba(139, 92, 246, 0.2);
  border-top-color: #8b5cf6;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin-left: 8px;
  vertical-align: middle;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* ── Empty States Premium ───────────────────────────────────────── */
.empty-state {
  text-align: center;
  padding: 48px 24px;
  color: var(--text-dim);
}

.empty-state .icon {
  font-size: 2rem;
  margin-bottom: 12px;
  opacity: 0.5;
}

/* ── Toast Notifications Premium ────────────────────────────────── */
.toast {
  position: fixed;
  bottom: 88px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: rgba(15, 15, 28, 0.95);
  border: 1px solid rgba(139, 92, 246, 0.2);
  border-radius: 12px;
  padding: 12px 24px;
  color: var(--text);
  font-size: 0.85rem;
  z-index: 9999;
  opacity: 0;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  backdrop-filter: blur(12px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4), 0 0 1px rgba(139, 92, 246, 0.2);
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ── Genre Tags Premium ─────────────────────────────────────────── */
.genre-filter {
  display: inline-flex;
  align-items: center;
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: rgba(139, 92, 246, 0.08);
  border: 1px solid rgba(139, 92, 246, 0.15);
  color: #a78bfa;
  cursor: pointer;
  transition: all 0.2s;
}

.genre-filter:hover,
.genre-filter.active {
  background: rgba(139, 92, 246, 0.15);
  border-color: rgba(139, 92, 246, 0.3);
  box-shadow: 0 0 12px rgba(139, 92, 246, 0.1);
}

/* ── Modal Overlay Premium ──────────────────────────────────────── */
.modal-overlay {
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

/* ── Subtle Glow Utility ────────────────────────────────────────── */
.glow-violet {
  box-shadow: 0 0 12px rgba(139, 92, 246, 0.2), 0 0 24px rgba(139, 92, 246, 0.08);
}

.glow-violet-strong {
  box-shadow: 0 0 16px rgba(139, 92, 246, 0.35), 0 0 32px rgba(139, 92, 246, 0.15);
}

/* ── Separator Lines Premium ────────────────────────────────────── */
hr, .divider {
  border: none;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(139, 92, 246, 0.12), transparent);
  margin: 0;
}

/* ── Creator Profile ────────────────────────────────────────────── */

.creator-profile-header {
  text-align: left;
  padding: 24px;
  padding-right: 90px; /* room for profile-corner-actions (absolutely positioned top-right) */
}

.creator-header-row {
  display: flex;
  align-items: flex-start;
  gap: 20px;
}

.creator-avatar {
  background: linear-gradient(135deg, rgba(120, 50, 200, 0.3), rgba(196, 141, 232, 0.15));
  border: 1px solid var(--border);
}

.creator-avatar img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
}

.creator-header-info {
  flex: 1;
  min-width: 0;
}

.display-name-row {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.display-name-row .display-name {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

/* Creator badge */
.creator-badge {
  display: inline-block;
  background: rgba(196, 141, 232, 0.12);
  color: var(--purple);
  border: 1px solid rgba(196, 141, 232, 0.3);
  border-radius: 10px;
  padding: 1px 8px;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  vertical-align: middle;
}

/* Creator type icon (soccer ball etc.) */
.creator-type-icon {
  font-size: 1.2rem;
  vertical-align: middle;
}

/* Stats row */
.creator-stats-row {
  display: flex;
  gap: 24px;
  margin-top: 12px;
}

.creator-stat {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.85rem;
  color: var(--text-dim);
}

.creator-stat-icon {
  color: var(--purple);
  display: flex;
  align-items: center;
}

.creator-stat-icon svg {
  width: 14px;
  height: 14px;
}

.creator-stat-value {
  color: var(--text);
  font-weight: 700;
}

.creator-stat-label {
  color: var(--text-muted);
  font-size: 0.8rem;
}

/* Header actions */
.creator-header-actions {
  display: flex;
  flex-direction: row;
  gap: 8px;
  align-items: flex-start;
}

.creator-header-actions .btn-follow {
  margin-top: 0;
  padding: 7px 16px;
  border-radius: 8px;
  font-size: 0.78rem;
}

.creator-header-actions .btn-message {
  margin-top: 0;
  padding: 7px 16px;
  border-radius: 8px;
  font-size: 0.78rem;
}

/* Featured video */
.creator-featured {
  margin-bottom: 24px;
}

.creator-featured-label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-dim);
  margin-bottom: 12px;
}

.creator-video-card {
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--bg-card);
  cursor: pointer;
  transition: border-color 0.2s;
}

.creator-video-card:hover {
  border-color: var(--border-hover);
}

.creator-video-aspect {
  position: relative;
  aspect-ratio: 16 / 9;
  background: var(--bg-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

/* EYEPLVY provenance ring — violet instead of green */
.creator-video-aspect::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: var(--radius-sm);
  box-shadow: inset 0 0 0 1px rgba(196, 141, 232, 0.15);
  pointer-events: none;
}

.creator-video-placeholder {
  color: var(--text-very-muted);
}

.creator-play-btn {
  position: absolute;
  inset: 0;
  margin: auto;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: rgba(2, 2, 4, 0.6);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(196, 141, 232, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.2s, border-color 0.2s;
}

.creator-play-btn:hover {
  transform: scale(1.05);
  border-color: rgba(196, 141, 232, 0.5);
}

.creator-duration-badge {
  position: absolute;
  bottom: 10px;
  right: 10px;
  font-size: 0.75rem;
  padding: 2px 6px;
  border-radius: 4px;
  background: rgba(2, 2, 4, 0.7);
  color: var(--text-dim);
  font-family: 'Share Tech Mono', monospace;
}

.creator-eyeplvy-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  font-size: 0.6rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 2px 8px;
  border-radius: 4px;
  background: rgba(2, 2, 4, 0.7);
  color: var(--purple);
  border: 1px solid rgba(196, 141, 232, 0.25);
  font-weight: 700;
}

.creator-video-info {
  padding: 12px 14px;
  background: var(--bg-card);
}

.creator-video-title {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.creator-video-meta {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 2px;
}

/* Creator tabs */
.creator-tabs button {
  display: flex;
  align-items: center;
  gap: 6px;
}

.creator-tabs button svg {
  width: 14px;
  height: 14px;
}

/* Video grid */
.creator-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.creator-grid-loading,
.creator-grid-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 40px 20px;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.creator-grid-item {
  cursor: pointer;
}

.creator-grid-thumb {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--bg-dark);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.2s;
}

.creator-grid-item:hover .creator-grid-thumb {
  border-color: var(--border-hover);
}

.creator-grid-item-placeholder {
  color: var(--text-very-muted);
}

.creator-grid-hover {
  position: absolute;
  inset: 0;
  background: rgba(2, 2, 4, 0);
  transition: background 0.2s;
}

.creator-grid-item:hover .creator-grid-hover {
  background: rgba(2, 2, 4, 0.3);
}

.creator-grid-duration {
  position: absolute;
  bottom: 6px;
  right: 6px;
  font-size: 0.7rem;
  padding: 1px 5px;
  border-radius: 3px;
  background: rgba(2, 2, 4, 0.75);
  color: var(--text-dim);
  font-family: 'Share Tech Mono', monospace;
}

.creator-grid-title {
  font-size: 0.8rem;
  color: var(--text-dim);
  margin-top: 8px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.creator-grid-meta {
  font-size: 0.7rem;
  color: var(--text-muted);
  margin-top: 2px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.creator-grid-meta svg {
  width: 12px;
  height: 12px;
}

/* Tab content */
.creator-tab-placeholder {
  color: var(--text-muted);
  font-size: 0.9rem;
  padding: 24px 0;
}

.creator-tab-about {
  color: var(--text);
  font-size: 0.95rem;
  line-height: 1.6;
  max-width: 520px;
}

/* Responsive */
@media (max-width: 640px) {
  .creator-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .creator-header-row {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
  .creator-header-actions {
    align-items: center;
  }
  .creator-stats-row {
    justify-content: center;
  }
}

/* ── Sidebar Network Search ────────────────────────────────────── */
.sidebar-search {
  position: relative;
}

.sidebar-search-inner {
  position: relative;
  display: flex;
  align-items: center;
}

.sidebar-search-icon {
  position: absolute;
  left: 12px;
  color: var(--text-muted);
  pointer-events: none;
  z-index: 1;
}

.sidebar-search-input {
  width: 100%;
  height: 38px;
  padding: 0 12px 0 34px;
  background: rgba(2, 2, 4, 0.8);
  border: 1px solid rgba(139, 92, 246, 0.15);
  border-radius: 10px;
  color: var(--text);
  font-family: 'Share Tech Mono', 'SF Mono', 'Fira Code', monospace;
  font-size: 0.8rem;
  letter-spacing: 0.03em;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  box-sizing: border-box;
}

.sidebar-search-input::placeholder {
  color: var(--text-very-muted);
  font-style: normal;
}

.sidebar-search-input:focus {
  border-color: rgba(139, 92, 246, 0.4);
  box-shadow: 0 0 0 2px rgba(139, 92, 246, 0.06), 0 0 16px rgba(139, 92, 246, 0.08);
}

.sidebar-search .search-dropdown {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  background: rgba(5, 5, 12, 0.98);
  border: 1px solid rgba(139, 92, 246, 0.15);
  border-radius: 12px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.6), 0 0 1px rgba(139, 92, 246, 0.2);
  z-index: 500;
  max-height: 380px;
  overflow-y: auto;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.sidebar-search .search-group {
  padding: 10px 14px 4px;
  font-family: 'Share Tech Mono', 'SF Mono', 'Fira Code', monospace;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--text-very-muted);
}

.sidebar-search .search-result {
  padding: 8px 14px;
  border-radius: 0;
  transition: background 0.15s;
}

.sidebar-search .search-result:hover {
  background: rgba(139, 92, 246, 0.06);
}

/* ============================================================
   Surge Times — Spaceport Departure Board
   ============================================================ */

.surge-divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--teal), transparent);
  margin: 0;
  opacity: 0.3;
}

.surge-header {
  padding: 12px 16px 8px;
  font-family: 'Share Tech Mono', 'SF Mono', 'Fira Code', monospace;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--teal);
  text-shadow: 0 0 12px rgba(0, 229, 160, 0.6), 0 0 24px rgba(0, 229, 160, 0.2);
  display: flex;
  align-items: center;
  gap: 8px;
  border-bottom: 1px solid rgba(0, 229, 160, 0.15);
  position: relative;
  overflow: hidden;
}

/* Scanline overlay */
.surge-header::after {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 2px,
    rgba(0, 229, 160, 0.015) 2px,
    rgba(0, 229, 160, 0.015) 4px
  );
  pointer-events: none;
}

.surge-icon {
  font-size: 0.8rem;
  animation: surge-blink 2s ease-in-out infinite;
}

@keyframes surge-blink {
  0%, 100% { opacity: 1; text-shadow: 0 0 8px var(--teal); }
  50% { opacity: 0.2; text-shadow: none; }
}

.surge-body {
  padding: 2px 0 !important;
  position: relative;
  overflow: hidden;
}

/* Scanline sweep animation on the body */
.surge-body::after {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--teal), transparent);
  opacity: 0.15;
  animation: surge-sweep 4s linear infinite;
  pointer-events: none;
}

@keyframes surge-sweep {
  0% { top: 0; }
  100% { top: 100%; }
}

.surge-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 16px;
  font-family: 'Share Tech Mono', 'SF Mono', 'Fira Code', monospace;
  font-size: 0.75rem;
  transition: all 0.2s;
  cursor: pointer;
  border-bottom: 1px solid rgba(255, 255, 255, 0.02);
  position: relative;
  opacity: 0;
  animation: surge-row-in 0.4s ease forwards;
}

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

.surge-row:hover {
  background: rgba(0, 229, 160, 0.04);
  border-bottom-color: rgba(0, 229, 160, 0.1);
}

.surge-row:hover .surge-city {
  text-shadow: 0 0 10px rgba(0, 229, 160, 0.5);
}

.surge-indicator {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--teal);
  box-shadow: 0 0 6px var(--teal), 0 0 14px rgba(0, 229, 160, 0.3);
  animation: surge-dot-pulse 2.5s ease-in-out infinite;
  flex-shrink: 0;
}

.surge-row:nth-child(2n) .surge-indicator { animation-delay: 0.4s; }
.surge-row:nth-child(3n) .surge-indicator { animation-delay: 0.8s; }
.surge-row:nth-child(5n) .surge-indicator { animation-delay: 1.2s; }

@keyframes surge-dot-pulse {
  0%, 100% { opacity: 1; box-shadow: 0 0 6px var(--teal), 0 0 14px rgba(0, 229, 160, 0.4); transform: scale(1); }
  50% { opacity: 0.3; box-shadow: 0 0 2px var(--teal); transform: scale(0.7); }
}

.surge-code {
  font-weight: 700;
  font-size: 0.78rem;
  min-width: 22px;
  letter-spacing: 0.08em;
  color: var(--teal);
  text-shadow: 0 0 8px rgba(0, 229, 160, 0.4);
  animation: surge-glow 3s ease-in-out infinite;
}

@keyframes surge-glow {
  0%, 100% { text-shadow: 0 0 8px rgba(0, 229, 160, 0.4); }
  50% { text-shadow: 0 0 16px rgba(0, 229, 160, 0.7), 0 0 30px rgba(0, 229, 160, 0.2); }
}

.surge-city {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--teal);
  font-weight: 500;
  letter-spacing: 0.04em;
  text-shadow: 0 0 6px rgba(0, 229, 160, 0.25);
  animation: surge-city-pulse 4s ease-in-out infinite;
}

.surge-row:nth-child(2n) .surge-city { animation-delay: 0.6s; }
.surge-row:nth-child(3n) .surge-city { animation-delay: 1.2s; }
.surge-row:nth-child(5n) .surge-city { animation-delay: 1.8s; }

@keyframes surge-city-pulse {
  0%, 100% { opacity: 0.85; text-shadow: 0 0 6px rgba(0, 229, 160, 0.25); }
  50% { opacity: 1; text-shadow: 0 0 14px rgba(0, 229, 160, 0.5), 0 0 28px rgba(0, 229, 160, 0.15); }
}

.surge-meta {
  font-size: 0.6rem;
  color: rgba(0, 229, 160, 0.35);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  max-width: 60px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.surge-count {
  font-size: 0.68rem;
  color: var(--teal);
  min-width: 16px;
  text-align: right;
  opacity: 0.7;
  font-variant-numeric: tabular-nums;
}

.surge-arrow {
  font-size: 0.6rem;
  min-width: 12px;
  text-align: center;
}

.surge-arrow.trend-up {
  color: #00e5a0;
  text-shadow: 0 0 8px rgba(0, 229, 160, 0.5);
  animation: surge-arrow-pulse 2s ease-in-out infinite;
}

.surge-arrow.trend-down {
  color: var(--danger);
  text-shadow: 0 0 8px rgba(255, 71, 87, 0.4);
}

.surge-arrow.trend-stable {
  color: rgba(0, 229, 160, 0.3);
}

@keyframes surge-arrow-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

/* Terminal empty state */
.terminal-empty {
  padding: 16px;
  font-family: 'Share Tech Mono', 'SF Mono', monospace;
  font-size: 0.72rem;
  color: var(--teal);
  opacity: 0.5;
  text-shadow: 0 0 6px rgba(0, 229, 160, 0.3);
  animation: terminal-blink 1.5s step-end infinite;
}

@keyframes terminal-blink {
  0%, 100% { opacity: 0.5; }
  50% { opacity: 0.2; }
}

/* ============================================================
   Stories Row — Horizontal Scrollable Avatars
   ============================================================ */

#stories-row {
  margin-bottom: 16px;
  overflow: hidden;
}

.stories-track {
  display: flex;
  gap: 14px;
  padding: 8px 4px;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.stories-track::-webkit-scrollbar {
  display: none;
}

.story-bubble {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
  cursor: pointer;
  transition: transform 0.15s;
}

.story-bubble:hover {
  transform: scale(1.08);
}

.story-ring {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  padding: 3px;
  background: linear-gradient(135deg, #c48de8, #00bfff, #c48de8);
  box-shadow: 0 0 12px rgba(196, 141, 232, 0.3), 0 0 24px rgba(0, 191, 255, 0.15);
  animation: ring-rotate 4s linear infinite;
}

@keyframes ring-rotate {
  0% { background: linear-gradient(0deg, #c48de8, #00bfff, #c48de8); }
  25% { background: linear-gradient(90deg, #c48de8, #00bfff, #c48de8); }
  50% { background: linear-gradient(180deg, #c48de8, #00bfff, #c48de8); }
  75% { background: linear-gradient(270deg, #c48de8, #00bfff, #c48de8); }
  100% { background: linear-gradient(360deg, #c48de8, #00bfff, #c48de8); }
}

.story-avatar {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: var(--bg-card);
  border: 2px solid var(--bg-darkest);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--teal);
  letter-spacing: 0.04em;
  overflow: hidden;
}

.story-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}

.story-name {
  font-size: 0.68rem;
  color: var(--text-muted);
  max-width: 64px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-align: center;
}

/* --- Add Story (+) button ring --- */
.story-ring--add {
  background: var(--text-muted);
  box-shadow: none;
  animation: none;
}

.story-ring--add .story-avatar {
  background: var(--bg-card);
}

.story-add-icon {
  font-size: 1.4rem;
  font-weight: 300;
  color: var(--teal);
  line-height: 1;
}

.story-ring--demo {
  background: rgba(0, 180, 160, 0.25);
  box-shadow: none;
  animation: none;
}

/* --- Story Modal (Add Story) --- */
.story-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  padding: 16px;
}

.story-modal {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  width: 100%;
  max-width: 420px;
  overflow: hidden;
}

.story-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px 0;
}

.story-modal-header h3 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text);
  margin: 0;
}

.story-modal-close {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 1.5rem;
  cursor: pointer;
  padding: 0 4px;
  line-height: 1;
}

.story-modal-close:hover {
  color: var(--text);
}

.story-modal-body {
  padding: 16px 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.story-caption-input {
  background: var(--bg-darkest);
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--text);
  font-family: inherit;
  font-size: 0.92rem;
  padding: 12px 14px;
  resize: vertical;
  min-height: 80px;
  outline: none;
}

.story-caption-input:focus {
  border-color: var(--teal);
}

.story-caption-input::placeholder {
  color: var(--text-muted);
}

.story-upload-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.story-modal .video-preview {
  border-color: rgba(196, 141, 232, 0.2);
  margin-top: 0;
}

.story-modal .video-preview video {
  width: 100%;
  max-height: 180px;
  object-fit: cover;
  display: block;
  border-radius: var(--radius-sm);
  background: #000;
}

.story-modal .video-preview .preview-remove {
  background: rgba(0, 0, 0, 0.6);
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  position: absolute;
  top: 6px;
  right: 6px;
  border-radius: 50%;
  width: 24px;
  height: 24px;
  align-items: center;
  justify-content: center;
}

.story-modal .video-preview .preview-remove:hover {
  background: rgba(255, 71, 87, 0.8);
}

.story-modal .video-duration-indicator {
  background: rgba(196, 141, 232, 0.85);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 4px;
  position: absolute;
  bottom: 6px;
  left: 6px;
}

.story-viewer-video {
  width: 100%;
  max-height: 340px;
  object-fit: contain;
  display: block;
  border-radius: 8px;
  background: #000;
}

.story-modal-footer {
  display: flex;
  gap: 10px;
  padding: 0 20px 16px;
  justify-content: flex-end;
}

.story-cancel-btn {
  background: var(--bg-darkest);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text-muted);
  font-size: 0.85rem;
  font-weight: 600;
  padding: 8px 16px;
  cursor: pointer;
  transition: all 0.15s;
}

.story-cancel-btn:hover {
  color: var(--text);
  border-color: var(--text-muted);
}

.story-submit-btn {
  background: var(--teal);
  border: none;
  border-radius: 8px;
  color: var(--bg-darkest);
  font-size: 0.85rem;
  font-weight: 700;
  padding: 8px 20px;
  cursor: pointer;
  transition: opacity 0.15s;
}

.story-submit-btn:hover {
  opacity: 0.85;
}

/* --- Story Viewer (full-screen overlay) --- */
.story-viewer-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.92);
  backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10001;
  padding: 16px;
}

.story-viewer {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  width: 100%;
  max-width: 420px;
  max-height: 80vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.story-viewer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
}

.story-viewer-user {
  display: flex;
  align-items: center;
  gap: 10px;
}

.story-viewer-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--bg-darkest);
  border: 2px solid var(--teal);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.65rem;
  font-weight: 700;
  color: var(--teal);
  overflow: hidden;
  flex-shrink: 0;
}

.story-viewer-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}

.story-viewer-info {
  display: flex;
  flex-direction: column;
}

.story-viewer-name {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text);
}

.story-viewer-time {
  font-size: 0.72rem;
  color: var(--text-muted);
}

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

.story-viewer-close {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 1.5rem;
  cursor: pointer;
  padding: 0 4px;
  line-height: 1;
}

.story-viewer-close:hover {
  color: var(--text);
}

.story-delete-btn {
  background: rgba(220, 50, 50, 0.15);
  border: 1px solid rgba(220, 50, 50, 0.3);
  border-radius: 6px;
  color: #dc3232;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 4px 10px;
  cursor: pointer;
  transition: all 0.15s;
}

.story-delete-btn:hover {
  background: rgba(220, 50, 50, 0.25);
}

.story-viewer-body {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 20px;
  min-height: 200px;
}

.story-viewer-image {
  width: 100%;
  max-height: 50vh;
  object-fit: contain;
  border-radius: 8px;
  margin-bottom: 16px;
}

.story-viewer-caption {
  font-size: 0.95rem;
  color: var(--text);
  line-height: 1.5;
  text-align: center;
  word-break: break-word;
  max-width: 100%;
}

.story-viewer-caption--empty {
  color: var(--text-muted);
  font-style: italic;
  font-size: 0.85rem;
}

/* ============================================================
   Custom Wave Audio Player — Voice Notes
   ============================================================ */

.voice-player {
  display: flex;
  flex-direction: column;
  background: var(--bg-darkest);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px 14px;
  margin-top: 10px;
  transition: border-color 0.2s;
}

.voice-player:hover {
  border-color: var(--border-hover);
}

.voice-player-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.voice-play-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--teal);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background 0.2s, transform 0.1s, box-shadow 0.2s;
  box-shadow: 0 0 8px rgba(196, 141, 232, 0.25);
}

.voice-play-btn:hover {
  transform: scale(1.08);
  box-shadow: 0 0 14px rgba(196, 141, 232, 0.4);
}

.voice-play-btn:active {
  transform: scale(0.95);
}

.voice-play-btn svg {
  fill: var(--bg-darkest);
}

.voice-waveform {
  flex: 1;
  height: 36px;
  position: relative;
  cursor: pointer;
  overflow: hidden;
}

.voice-waveform-bars {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  gap: 1.5px;
}

.voice-waveform-bar {
  flex: 1;
  min-width: 2px;
  max-width: 4px;
  background: var(--teal-dim);
  border-radius: 1px;
  transition: background 0.15s;
  transform-origin: center;
}

.voice-player.playing .voice-waveform-bar.active {
  background: var(--teal);
}

.voice-player.playing .voice-waveform-bar.behind {
  background: rgba(196, 141, 232, 0.4);
}

.voice-player.playing .voice-waveform-bar.ahead {
  background: var(--text-very-muted);
}

.voice-time {
  font-family: 'Share Tech Mono', 'Courier New', monospace;
  font-size: 0.75rem;
  color: var(--text-muted);
  white-space: nowrap;
  min-width: 75px;
  text-align: right;
  flex-shrink: 0;
}

.voice-progress-wrap {
  width: 100%;
  height: 3px;
  background: var(--border);
  border-radius: 2px;
  margin-top: 8px;
  cursor: pointer;
  position: relative;
}

.voice-progress-fill {
  height: 100%;
  background: var(--teal);
  border-radius: 2px;
  width: 0%;
  transition: width 0.1s linear;
  position: relative;
}

.voice-progress-fill::after {
  content: '';
  position: absolute;
  right: -4px;
  top: 50%;
  transform: translateY(-50%);
  width: 8px;
  height: 8px;
  background: var(--teal);
  border-radius: 50%;
  opacity: 0;
  transition: opacity 0.15s;
  box-shadow: 0 0 6px rgba(196, 141, 232, 0.4);
}

.voice-progress-wrap:hover .voice-progress-fill::after {
  opacity: 1;
}

/* ================================================================
   Story Overlay Editor — Instagram-style text & sticker overlays
   ================================================================ */

.story-editor-overlay {
  position: fixed;
  inset: 0;
  background: #000;
  z-index: 10010;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.story-editor-canvas {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  flex: 1;
}

.story-editor-bg-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.story-editor-bg-gradient {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, #0a0a1a 0%, #1a0a2e 40%, #0d1f3c 70%, #0a0a1a 100%);
}

.story-editor-layers {
  position: absolute;
  inset: 0;
  z-index: 10;
}

/* Overlay elements on canvas */
.se-overlay-element {
  position: absolute;
  left: 0;
  top: 0;
  cursor: grab;
  user-select: none;
  -webkit-user-select: none;
  touch-action: none;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6px 10px;
  border-radius: 6px;
  border: 2px solid transparent;
  transition: border-color 0.15s, transform 0.08s;
}

.se-overlay-element:active {
  cursor: grabbing;
}

.se-overlay-element.se-overlay-selected {
  border-color: rgba(93, 202, 165, 0.8);
  box-shadow: 0 0 0 3px rgba(93, 202, 165, 0.15);
}

.se-overlay-pop {
  animation: se-pop-in 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes se-pop-in {
  0% { transform: translate(-50%, -50%) translate(var(--x, 50%), var(--y, 40%)) scale(0); opacity: 0; }
  100% { transform: translate(-50%, -50%) translate(var(--x, 50%), var(--y, 40%)) scale(1); opacity: 1; }
}

.se-overlay-text {
  white-space: nowrap;
  line-height: 1.3;
  pointer-events: none;
}

.se-overlay-sticker {
  line-height: 1;
  pointer-events: none;
}

.se-overlay-delete {
  position: absolute;
  top: -10px;
  right: -10px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: rgba(220, 50, 50, 0.9);
  border: 2px solid #000;
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.15s;
  line-height: 1;
  padding: 0;
}

.se-overlay-element:hover .se-overlay-delete,
.se-overlay-element.se-overlay-selected .se-overlay-delete {
  opacity: 1;
}

.se-overlay-grip {
  position: absolute;
  bottom: -4px;
  left: 50%;
  transform: translateX(-50%);
  width: 16px;
  height: 4px;
  background: rgba(255,255,255,0.4);
  border-radius: 2px;
  opacity: 0;
}

.se-overlay-element:hover .se-overlay-grip,
.se-overlay-element.se-overlay-selected .se-overlay-grip {
  opacity: 1;
}

/* Bottom toolbar */
.story-editor-toolbar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 12px 16px;
  padding-bottom: max(12px, env(safe-area-inset-bottom));
  background: linear-gradient(to top, rgba(0,0,0,0.95) 0%, rgba(0,0,0,0.7) 70%, transparent 100%);
  z-index: 20;
}

.se-tool-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 10px;
  color: #fff;
  font-size: 0.65rem;
  font-weight: 600;
  padding: 8px 12px;
  cursor: pointer;
  transition: all 0.15s;
  min-width: 54px;
  backdrop-filter: blur(8px);
}

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

.se-tool-btn svg {
  flex-shrink: 0;
}

.se-tool-done {
  background: var(--teal);
  border-color: var(--teal);
  color: #000;
}

.se-tool-done:hover {
  opacity: 0.85;
}

.se-font-label {
  font-size: 16px;
  font-weight: 700;
  line-height: 1;
}

.se-color-dot {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2px solid rgba(255,255,255,0.4);
}

/* Size bar */
.story-editor-size-bar {
  position: fixed;
  bottom: 80px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(0,0,0,0.85);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 20px;
  padding: 6px 16px;
  z-index: 25;
  backdrop-filter: blur(8px);
}

.se-size-btn {
  background: rgba(255,255,255,0.1);
  border: none;
  color: #fff;
  font-size: 0.8rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 12px;
  cursor: pointer;
  transition: background 0.15s;
}

.se-size-btn:hover {
  background: rgba(255,255,255,0.2);
}

.se-size-label {
  color: #fff;
  font-size: 0.8rem;
  font-weight: 600;
  min-width: 24px;
  text-align: center;
}

/* Sticker tray */
.story-editor-sticker-tray {
  position: fixed;
  bottom: 80px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  background: rgba(0,0,0,0.9);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 14px;
  padding: 12px;
  z-index: 25;
  backdrop-filter: blur(8px);
  max-width: 90vw;
}

.se-sticker-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 6px;
}

.se-sticker-item {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  background: rgba(255,255,255,0.08);
  border: none;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.15s;
  padding: 0;
}

.se-sticker-item:hover {
  background: rgba(255,255,255,0.2);
  transform: scale(1.15);
}

/* Color tray */
.story-editor-color-tray {
  position: fixed;
  bottom: 80px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  background: rgba(0,0,0,0.9);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 20px;
  padding: 10px 16px;
  z-index: 25;
  backdrop-filter: blur(8px);
}

.se-color-grid {
  display: flex;
  gap: 8px;
  align-items: center;
}

.se-color-swatch {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all 0.15s;
  padding: 0;
  box-shadow: 0 1px 4px rgba(0,0,0,0.4);
}

.se-color-swatch:hover {
  transform: scale(1.15);
}

.se-color-swatch.active {
  border-color: #fff;
  box-shadow: 0 0 0 2px rgba(255,255,255,0.3), 0 1px 4px rgba(0,0,0,0.4);
}

/* Story viewer overlay rendering */
.sv-media-wrap {
  position: relative;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.sv-media-wrap--text {
  min-height: 300px;
  background: linear-gradient(135deg, #0a0a1a 0%, #1a0a2e 40%, #0d1f3c 70%, #0a0a1a 100%);
  border-radius: 8px;
}

.sv-overlay-text,
.sv-overlay-sticker {
  text-align: center;
}

.story-viewer-body--gradient {
  background: linear-gradient(180deg, rgba(26,10,46,0.3) 0%, rgba(13,31,60,0.3) 100%);
}

/* ============================================================
   EYEPLVY — Get Quote Button & Modal
   ============================================================ */

.btn-quote {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 16px;
  border: 1px solid rgba(0, 229, 204, 0.4);
  border-radius: 8px;
  background: transparent;
  color: var(--accent, #00E5CC);
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.btn-quote:hover {
  background: rgba(0, 229, 204, 0.1);
  border-color: var(--accent, #00E5CC);
}

.creator-header-actions .btn-quote {
  margin-top: 0;
  padding: 7px 16px;
  border-radius: 8px;
  font-size: 0.78rem;
}

/* Quote Modal Overlay */
.quote-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 9000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  animation: fadeIn 0.2s ease;
}

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

/* Quote Modal Card */
.quote-modal {
  width: 100%;
  max-width: 520px;
  max-height: 90vh;
  overflow-y: auto;
  background: var(--bg-card, #1a1a2e);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.5);
  margin: 16px;
}

.quote-modal-header {
  position: relative;
  padding: 24px 24px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.quote-modal-header h3 {
  margin: 0;
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text-primary, #fff);
}

.quote-modal-subtitle {
  margin: 4px 0 0;
  font-size: 0.85rem;
  color: var(--text-muted, #8b8b9e);
}

.quote-modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-muted, #8b8b9e);
  border-radius: 8px;
  font-size: 1.2rem;
  cursor: pointer;
  transition: all 0.15s ease;
}

.quote-modal-close:hover {
  background: rgba(255, 255, 255, 0.12);
  color: var(--text-primary, #fff);
}

.quote-modal-body {
  padding: 20px 24px;
}

.quote-field {
  margin-bottom: 16px;
}

.quote-field label {
  display: block;
  margin-bottom: 6px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary, #b0b0c0);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.quote-field label .required {
  color: var(--accent, #00E5CC);
}

.quote-field textarea,
.quote-field input,
.quote-field select {
  width: 100%;
  padding: 10px 12px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  color: var(--text-primary, #fff);
  font-size: 0.9rem;
  font-family: inherit;
  transition: border-color 0.15s ease;
  box-sizing: border-box;
}

.quote-field textarea:focus,
.quote-field input:focus,
.quote-field select:focus {
  outline: none;
  border-color: var(--accent, #00E5CC);
}

.quote-field textarea {
  resize: vertical;
  min-height: 80px;
}

.quote-field select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%238b8b9e' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 36px;
}

.quote-field select option {
  background: var(--bg-card, #1a1a2e);
  color: var(--text-primary, #fff);
}

.quote-field-row {
  display: flex;
  gap: 12px;
}

.quote-field-row .quote-field {
  flex: 1;
}

.quote-modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding: 16px 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.quote-cancel-btn {
  padding: 8px 18px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  background: transparent;
  color: var(--text-muted, #8b8b9e);
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s ease;
}

.quote-cancel-btn:hover {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-primary, #fff);
}

.quote-submit-btn {
  padding: 8px 20px;
  border: none;
  border-radius: 8px;
  background: var(--accent, #00E5CC);
  color: #0a1f1c;
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
}

.quote-submit-btn:hover {
  filter: brightness(1.1);
}

.quote-submit-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.quote-success {
  text-align: center;
  padding: 32px 16px;
}

.quote-success h4 {
  margin: 16px 0 8px;
  font-size: 1.1rem;
  color: var(--text-primary, #fff);
}

.quote-success p {
  font-size: 0.9rem;
  color: var(--text-muted, #8b8b9e);
  line-height: 1.5;
}

/* Creator Dashboard */
.creator-dashboard {
  padding: 16px;
}

.creator-dashboard-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

@media (max-width: 768px) {
  .creator-dashboard-grid {
    grid-template-columns: 1fr;
  }
}

.creator-dashboard-card {
  background: var(--bg-card, rgba(20, 20, 30, 0.8));
  border: 1px solid rgba(139, 92, 246, 0.15);
  border-radius: 12px;
  padding: 16px;
}

.creator-dashboard-card h3 {
  font-size: 0.95rem;
  font-weight: 600;
  margin-bottom: 12px;
  color: var(--purple, #a78bfa);
}

.creator-dashboard-card.full-width {
  grid-column: 1 / -1;
}

.dashboard-stat {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  padding: 12px 16px;
  background: rgba(139, 92, 246, 0.08);
  border-radius: 8px;
  min-width: 80px;
}

.dashboard-stat .num {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text-primary, #fff);
}

.dashboard-stat .label {
  font-size: 0.7rem;
  color: var(--text-muted, #888);
  margin-top: 2px;
}

.dashboard-stats-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

/* Dashboard form fields */
.dash-field {
  margin-bottom: 12px;
}

.dash-field label {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted, #888);
  margin-bottom: 4px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.dash-field input,
.dash-field textarea,
.dash-field select {
  width: 100%;
  padding: 8px 12px;
  background: var(--bg-input, rgba(30, 30, 45, 0.9));
  border: 1px solid rgba(139, 92, 246, 0.2);
  border-radius: 8px;
  color: var(--text-primary, #fff);
  font-size: 0.85rem;
  font-family: inherit;
}

.dash-field input:focus,
.dash-field textarea:focus,
.dash-field select:focus {
  outline: none;
  border-color: var(--purple, #a78bfa);
}

.dash-field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.btn-dash-upload {
  width: 100%;
  padding: 10px;
  background: linear-gradient(135deg, #8b5cf6, #a78bfa);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-dash-upload:hover {
  background: linear-gradient(135deg, #7c3aed, #8b5cf6);
  transform: translateY(-1px);
}

/* Video list in dashboard */
.dash-video-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px;
  border-bottom: 1px solid rgba(139, 92, 246, 0.1);
}

.dash-video-item:last-child {
  border-bottom: none;
}

.dash-video-info {
  flex: 1;
  min-width: 0;
}

.dash-video-title {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary, #fff);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dash-video-meta {
  font-size: 0.72rem;
  color: var(--text-muted, #888);
}

.dash-status-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 10px;
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.dash-status-badge.published {
  background: rgba(34, 197, 94, 0.15);
  color: #22c55e;
}

.dash-status-badge.draft {
  background: rgba(234, 179, 8, 0.15);
  color: #eab308;
}

.dash-status-badge.scheduled {
  background: rgba(59, 130, 246, 0.15);
  color: #3b82f6;
}

.btn-dash-sm {
  padding: 4px 10px;
  border: 1px solid rgba(139, 92, 246, 0.3);
  background: transparent;
  color: var(--purple, #a78bfa);
  border-radius: 6px;
  font-size: 0.72rem;
  cursor: pointer;
  transition: all 0.15s;
}

.btn-dash-sm:hover {
  background: rgba(139, 92, 246, 0.1);
}

.btn-dash-sm.danger {
  border-color: rgba(239, 68, 68, 0.3);
  color: #ef4444;
}

.btn-dash-sm.danger:hover {
  background: rgba(239, 68, 68, 0.1);
}

/* Quote request items */
.dash-quote-item {
  padding: 12px;
  border-bottom: 1px solid rgba(139, 92, 246, 0.1);
}

.dash-quote-item:last-child {
  border-bottom: none;
}

.dash-quote-desc {
  font-size: 0.82rem;
  color: var(--text-primary, #fff);
  margin-bottom: 6px;
}

.dash-quote-meta {
  font-size: 0.72rem;
  color: var(--text-muted, #888);
  margin-bottom: 8px;
}

.dash-quote-actions {
  display: flex;
  gap: 8px;
}

.btn-dash-accept {
  padding: 4px 12px;
  background: rgba(34, 197, 94, 0.15);
  color: #22c55e;
  border: 1px solid rgba(34, 197, 94, 0.3);
  border-radius: 6px;
  font-size: 0.72rem;
  cursor: pointer;
}

.btn-dash-decline {
  padding: 4px 12px;
  background: rgba(239, 68, 68, 0.15);
  color: #ef4444;
  border: 1px solid rgba(239, 68, 68, 0.3);
  border-radius: 6px;
  font-size: 0.72rem;
  cursor: pointer;
}

.dash-empty {
  text-align: center;
  padding: 20px;
  color: var(--text-muted, #888);
  font-size: 0.82rem;
}
