/* ================================
   NEET HUB - FEATURES CSS
   Cyberpunk Community Site Features
   ================================ */


/* ================================
   1. LEVEL BADGES
   ================================ */

.level-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 32px;
  height: 24px;
  padding: 0 8px;
  border-radius: 12px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: all 0.3s ease;
  background-color: rgba(119, 119, 160, 0.2);
  border: 1px solid rgba(119, 119, 160, 0.5);
  color: var(--text-muted);
}

/* Level tiers */
.level-badge.tier-gray {
  background-color: rgba(119, 119, 160, 0.2);
  border-color: rgba(119, 119, 160, 0.5);
  color: var(--text-muted);
}

.level-badge.tier-silver {
  background-color: rgba(168, 168, 204, 0.2);
  border-color: rgba(168, 168, 204, 0.5);
  color: var(--text-secondary);
}

.level-badge.tier-cyan {
  background-color: rgba(0, 245, 255, 0.15);
  border-color: var(--neon-cyan);
  color: var(--neon-cyan);
  box-shadow: 0 0 10px rgba(0, 245, 255, 0.4);
}

.level-badge.tier-green {
  background-color: rgba(57, 255, 20, 0.15);
  border-color: var(--neon-green);
  color: var(--neon-green);
  box-shadow: 0 0 10px rgba(57, 255, 20, 0.4);
}

.level-badge.tier-purple {
  background-color: rgba(184, 41, 227, 0.15);
  border-color: var(--neon-purple);
  color: var(--neon-purple);
  box-shadow: 0 0 10px rgba(184, 41, 227, 0.4);
}

.level-badge.tier-yellow {
  background-color: rgba(245, 245, 32, 0.15);
  border-color: var(--neon-yellow);
  color: var(--neon-yellow);
  box-shadow: 0 0 10px rgba(245, 245, 32, 0.4);
}

.level-badge.tier-red {
  background-color: rgba(255, 107, 107, 0.15);
  border-color: #ff6b6b;
  color: #ff6b6b;
  box-shadow: 0 0 10px rgba(255, 107, 107, 0.4);
}

.level-badge.tier-magenta {
  background-color: rgba(255, 0, 255, 0.15);
  border-color: #ff00ff;
  color: #ff00ff;
  box-shadow: 0 0 10px rgba(255, 0, 255, 0.4);
}

.level-badge.tier-rainbow {
  animation: rainbow-glow 3s ease-in-out infinite;
  background: linear-gradient(90deg,
    #ff0000,
    #ff7f00,
    #ffff00,
    #00ff00,
    #0000ff,
    #4b0082,
    #9400d3);
  background-size: 200% 100%;
  border: 2px solid transparent;
  background-clip: padding-box;
  box-shadow:
    0 0 15px rgba(255, 0, 255, 0.6),
    inset 0 0 15px rgba(0, 245, 255, 0.2);
  color: #ffffff;
  font-weight: 900;
}

@keyframes rainbow-glow {
  0%, 100% {
    box-shadow: 0 0 15px rgba(255, 0, 0, 0.6), inset 0 0 15px rgba(0, 245, 255, 0.2);
  }
  25% {
    box-shadow: 0 0 15px rgba(0, 255, 0, 0.6), inset 0 0 15px rgba(0, 245, 255, 0.2);
  }
  50% {
    box-shadow: 0 0 15px rgba(0, 0, 255, 0.6), inset 0 0 15px rgba(0, 245, 255, 0.2);
  }
  75% {
    box-shadow: 0 0 15px rgba(255, 0, 255, 0.6), inset 0 0 15px rgba(0, 245, 255, 0.2);
  }
}

.level-badge:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.xp-bar {
  height: 6px;
  background-color: var(--bg-secondary);
  border-radius: 3px;
  overflow: hidden;
  border: 1px solid var(--border-glow);
  margin: 8px 0;
}

.xp-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--neon-cyan), var(--neon-purple));
  border-radius: 3px;
  transition: width 0.4s ease;
  box-shadow: 0 0 8px rgba(0, 245, 255, 0.5);
}

.level-title {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--neon-cyan);
  margin-top: 4px;
}

/* ================================
   2. CUSTOM USER STATUS
   ================================ */

.user-status-indicator {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px 8px;
  border-radius: 8px;
  background-color: rgba(0, 245, 255, 0.08);
  border: 1px solid rgba(0, 245, 255, 0.2);
  font-size: 12px;
  color: var(--text-secondary);
  transition: all 0.3s ease;
}

.user-status-indicator:hover {
  background-color: rgba(0, 245, 255, 0.15);
  border-color: rgba(0, 245, 255, 0.4);
  transform: translateY(-1px);
}

.status-emoji {
  font-size: 16px;
  line-height: 1;
  animation: float 2s ease-in-out infinite;
}

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

.status-text {
  max-width: 150px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: var(--font-body);
}

.status-picker {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 7000;
  background-color: var(--bg-secondary);
  border: 2px solid var(--neon-cyan);
  border-radius: 12px;
  padding: 24px;
  min-width: 400px;
  max-height: 500px;
  box-shadow:
    0 0 20px rgba(0, 245, 255, 0.3),
    0 10px 40px rgba(0, 0, 0, 0.5);
  animation: slideUp 0.3s ease;
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translate(-50%, -40%);
  }
  to {
    opacity: 1;
    transform: translate(-50%, -50%);
  }
}

.status-picker h3 {
  font-family: var(--font-display);
  font-size: 16px;
  color: var(--neon-cyan);
  margin: 0 0 16px 0;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.status-picker-input {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid rgba(0, 245, 255, 0.3);
  border-radius: 8px;
  background-color: var(--bg-tertiary);
  color: var(--text-primary);
  font-family: var(--font-body);
  margin-bottom: 16px;
  transition: all 0.3s ease;
}

.status-picker-input:focus {
  outline: none;
  border-color: var(--neon-cyan);
  box-shadow: 0 0 10px rgba(0, 245, 255, 0.3), 0 0 0 2px rgba(0, 245, 255, 0.3);
}

.status-presets {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 300px;
  overflow-y: auto;
}

.status-preset {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border: 1px solid rgba(0, 245, 255, 0.2);
  border-radius: 8px;
  background-color: var(--bg-tertiary);
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 14px;
  color: var(--text-secondary);
}

.status-preset:hover {
  background-color: var(--bg-card);
  border-color: var(--neon-cyan);
  color: var(--neon-cyan);
  transform: translateX(4px);
}

.status-preset-emoji {
  font-size: 18px;
}

.status-picker-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 28px;
  height: 28px;
  border: 1px solid var(--neon-cyan);
  background-color: transparent;
  color: var(--neon-cyan);
  border-radius: 4px;
  cursor: pointer;
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}

.status-picker-close:hover {
  background-color: rgba(0, 245, 255, 0.2);
  box-shadow: 0 0 10px rgba(0, 245, 255, 0.3);
}

/* ================================
   3. LINK PREVIEW CARDS
   ================================ */

.link-preview-card {
  display: flex;
  gap: 12px;
  padding: 12px;
  background-color: var(--bg-tertiary);
  border-left: 3px solid var(--neon-cyan);
  border-radius: 8px;
  max-width: 450px;
  transition: all 0.3s ease;
  cursor: pointer;
  overflow: hidden;
}

.link-preview-card:hover {
  background-color: var(--bg-card);
  border-left-color: var(--neon-purple);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 245, 255, 0.2);
}

.link-preview-icon {
  width: 48px;
  height: 48px;
  min-width: 48px;
  border-radius: 6px;
  background-color: var(--bg-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  border: 1px solid rgba(0, 245, 255, 0.2);
}

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

.link-preview-title {
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: bold;
  color: var(--text-primary);
  margin: 0 0 4px 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.link-preview-description {
  font-family: var(--font-body);
  font-size: 12px;
  color: var(--text-secondary);
  line-height: 1.4;
  margin: 0 0 6px 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.link-preview-domain {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--neon-cyan);
  letter-spacing: 0.5px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* ================================
   4. PINNED MESSAGES
   ================================ */

.pinned-messages-bar {
  background-color: var(--bg-secondary);
  border-top: 2px solid var(--neon-cyan);
  border-bottom: 1px solid rgba(0, 245, 255, 0.2);
  box-shadow: 0 0 15px rgba(0, 245, 255, 0.15);
  padding: 0;
  margin-bottom: 0;
  overflow: hidden;
}

.pinned-bar-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  cursor: pointer;
  user-select: none;
}

.pinned-bar-toggle {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-body);
  color: var(--neon-cyan);
  font-size: 13px;
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: all 0.3s ease;
}

.pinned-bar-toggle:hover {
  color: var(--neon-purple);
}

.pinned-icon {
  font-size: 16px;
}

.pinned-count {
  background-color: rgba(0, 245, 255, 0.2);
  padding: 2px 8px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: bold;
}

.pinned-bar-toggle-arrow {
  font-size: 12px;
  transition: transform 0.3s ease;
}

.pinned-bar-toggle-arrow.expanded {
  transform: rotate(180deg);
}

.pinned-messages-list {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease;
}

.pinned-messages-list.expanded {
  max-height: 400px;
}

.pinned-message-item {
  padding: 10px 16px;
  border-bottom: 1px solid rgba(0, 245, 255, 0.1);
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  background-color: rgba(0, 245, 255, 0.05);
  cursor: pointer;
  transition: all 0.3s ease;
}

.pinned-message-item:hover {
  background-color: rgba(0, 245, 255, 0.1);
  padding-left: 20px;
}

.pinned-message-content {
  flex: 1;
}

.pinned-message-author {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--neon-cyan);
  font-weight: bold;
  margin-bottom: 2px;
}

.pinned-message-text {
  font-family: var(--font-body);
  font-size: 12px;
  color: var(--text-secondary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pinned-message-time {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-muted);
}

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

.unpin-btn {
  background-color: transparent;
  border: 1px solid rgba(255, 107, 107, 0.5);
  color: #ff6b6b;
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 11px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-weight: bold;
}

.unpin-btn:hover {
  background-color: rgba(255, 107, 107, 0.2);
  border-color: #ff6b6b;
  box-shadow: 0 0 8px rgba(255, 107, 107, 0.3);
}

.pinned-indicator {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 10px;
  color: var(--neon-cyan);
  background-color: rgba(0, 245, 255, 0.1);
  padding: 2px 6px;
  border-radius: 4px;
  font-weight: bold;
}

.pin-btn {
  background-color: transparent;
  border: 1px solid rgba(0, 245, 255, 0.3);
  color: var(--neon-cyan);
  padding: 6px 10px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 12px;
  transition: all 0.3s ease;
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.pin-btn:hover {
  background-color: rgba(0, 245, 255, 0.2);
  border-color: var(--neon-cyan);
  box-shadow: 0 0 8px rgba(0, 245, 255, 0.3);
}

.pin-btn.pinned {
  background-color: rgba(0, 245, 255, 0.3);
  border-color: var(--neon-cyan);
}

/* ================================
   5. MESSAGE REPLIES
   ================================ */

.reply-preview {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 8px 12px;
  background-color: rgba(0, 245, 255, 0.08);
  border-left: 3px solid var(--neon-cyan);
  border-radius: 6px;
  margin-bottom: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 12px;
}

.reply-preview:hover {
  background-color: rgba(0, 245, 255, 0.15);
  transform: translateX(2px);
}

.reply-preview-avatar {
  width: 24px;
  height: 24px;
  border-radius: 4px;
  background-color: var(--bg-secondary);
  border: 1px solid rgba(0, 245, 255, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  flex-shrink: 0;
}

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

.reply-preview-author {
  font-family: var(--font-mono);
  color: var(--neon-cyan);
  font-weight: bold;
  margin-bottom: 2px;
}

.reply-preview-text {
  color: var(--text-secondary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: var(--font-body);
}

.reply-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  background-color: rgba(0, 245, 255, 0.1);
  border-left: 3px solid var(--neon-cyan);
  border-radius: 6px;
  margin-bottom: 12px;
  animation: slideUp 0.3s ease;
}

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

.reply-bar-label {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--neon-cyan);
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 4px;
}

.reply-bar-preview {
  font-family: var(--font-body);
  font-size: 12px;
  color: var(--text-secondary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.reply-bar-close {
  background-color: transparent;
  border: 1px solid rgba(0, 245, 255, 0.3);
  color: var(--neon-cyan);
  width: 28px;
  height: 28px;
  border-radius: 4px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  transition: all 0.3s ease;
  flex-shrink: 0;
}

.reply-bar-close:hover {
  background-color: rgba(0, 245, 255, 0.2);
  box-shadow: 0 0 8px rgba(0, 245, 255, 0.3);
}

.reply-btn {
  background-color: transparent;
  border: 1px solid rgba(0, 245, 255, 0.3);
  color: var(--neon-cyan);
  padding: 6px 10px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 12px;
  transition: all 0.3s ease;
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.reply-btn:hover {
  background-color: rgba(0, 245, 255, 0.2);
  border-color: var(--neon-cyan);
  box-shadow: 0 0 8px rgba(0, 245, 255, 0.3);
}

/* ================================
   6. TYPING INDICATORS
   ================================ */

.typing-indicator {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 12px 16px;
  font-family: var(--font-body);
  font-size: 13px;
  color: var(--text-secondary);
  animation: fadeIn 0.4s ease;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.typing-usernames {
  color: var(--neon-cyan);
  font-weight: bold;
}

.typing-dots {
  display: inline-flex;
  gap: 2px;
  margin-left: 4px;
}

.typing-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: var(--neon-cyan);
  animation: typingBounce 1.4s infinite;
}

.typing-dot:nth-child(1) {
  animation-delay: 0s;
}

.typing-dot:nth-child(2) {
  animation-delay: 0.2s;
}

.typing-dot:nth-child(3) {
  animation-delay: 0.4s;
}

@keyframes typingBounce {
  0%, 60%, 100% {
    opacity: 0.3;
    transform: translateY(0);
  }
  30% {
    opacity: 1;
    transform: translateY(-8px);
  }
}

/* ================================
   7. GIF/IMAGE SHARING
   ================================ */

.gif-picker {
  position: absolute;
  bottom: 100%;
  left: 0;
  width: 350px;
  max-height: 400px;
  background-color: var(--bg-secondary);
  border: 2px solid var(--neon-cyan);
  border-radius: 8px;
  padding: 12px;
  margin-bottom: 8px;
  box-shadow:
    0 0 20px rgba(0, 245, 255, 0.3),
    0 -4px 20px rgba(0, 0, 0, 0.5);
  animation: slideUp 0.3s ease;
  z-index: 100;
}

.gif-search-input {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid rgba(0, 245, 255, 0.3);
  border-radius: 6px;
  background-color: var(--bg-tertiary);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 13px;
  margin-bottom: 12px;
  transition: all 0.3s ease;
}

.gif-search-input:focus {
  outline: none;
  border-color: var(--neon-cyan);
  box-shadow: 0 0 10px rgba(0, 245, 255, 0.3), 0 0 0 2px rgba(0, 245, 255, 0.3);
}

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

.gif-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  max-height: 300px;
  overflow-y: auto;
}

.gif-grid::-webkit-scrollbar {
  width: 6px;
}

.gif-grid::-webkit-scrollbar-track {
  background-color: rgba(0, 245, 255, 0.05);
}

.gif-grid::-webkit-scrollbar-thumb {
  background-color: rgba(0, 245, 255, 0.3);
  border-radius: 3px;
}

.gif-grid::-webkit-scrollbar-thumb:hover {
  background-color: rgba(0, 245, 255, 0.5);
}

.gif-item {
  width: 100%;
  aspect-ratio: 1;
  background-color: var(--bg-tertiary);
  border-radius: 6px;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.3s ease;
  border: 1px solid rgba(0, 245, 255, 0.2);
  background-size: cover;
  background-position: center;
}

.gif-item:hover {
  transform: scale(1.05);
  border-color: var(--neon-cyan);
  box-shadow: 0 0 10px rgba(0, 245, 255, 0.4);
}

.gif-attribution {
  font-family: var(--font-mono);
  font-size: 9px;
  color: var(--text-muted);
  text-align: center;
  padding-top: 8px;
  border-top: 1px solid rgba(0, 245, 255, 0.1);
  margin-top: 8px;
}

.gif-btn {
  background-color: transparent;
  border: 1px solid rgba(0, 245, 255, 0.3);
  color: var(--neon-cyan);
  width: 36px;
  height: 36px;
  border-radius: 6px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  transition: all 0.3s ease;
}

.gif-btn:hover {
  background-color: rgba(0, 245, 255, 0.2);
  border-color: var(--neon-cyan);
  box-shadow: 0 0 10px rgba(0, 245, 255, 0.3);
}

.gif-btn.active {
  background-color: rgba(0, 245, 255, 0.3);
  border-color: var(--neon-cyan);
}

.msg-gif {
  max-width: 300px;
  border-radius: 6px;
  overflow: hidden;
  border: 1px solid rgba(0, 245, 255, 0.3);
  margin: 8px 0;
  transition: all 0.3s ease;
}

.msg-gif:hover {
  border-color: var(--neon-cyan);
  box-shadow: 0 0 10px rgba(0, 245, 255, 0.3);
}

/* ================================
   8. POLLS
   ================================ */

.poll-card {
  background-color: var(--bg-tertiary);
  border: 1px solid rgba(0, 245, 255, 0.2);
  border-left: 3px solid var(--neon-cyan);
  border-radius: 8px;
  padding: 14px;
  margin: 8px 0;
  transition: all 0.3s ease;
}

.poll-card:hover {
  border-left-color: var(--neon-purple);
  box-shadow: 0 0 10px rgba(0, 245, 255, 0.15);
}

.poll-question {
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: bold;
  color: var(--text-primary);
  margin-bottom: 12px;
}

.poll-options {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 12px;
}

.poll-option {
  display: flex;
  align-items: center;
  gap: 8px;
  transition: all 0.3s ease;
}

.poll-option-bar {
  flex: 1;
  height: 32px;
  background: linear-gradient(90deg, rgba(0, 245, 255, 0.2), rgba(184, 41, 227, 0.2));
  border-radius: 6px;
  overflow: hidden;
  border: 1px solid rgba(0, 245, 255, 0.3);
  position: relative;
  cursor: pointer;
  transition: all 0.3s ease;
}

.poll-option-bar::after {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  background: linear-gradient(90deg, var(--neon-cyan), var(--neon-purple));
  width: 0%;
  transition: width 0.5s ease;
  z-index: 1;
  box-shadow: inset 0 0 8px rgba(0, 245, 255, 0.3);
}

.poll-option-text {
  position: absolute;
  left: 8px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  font-family: var(--font-body);
  font-size: 12px;
  color: var(--text-primary);
  font-weight: 500;
  max-width: calc(100% - 60px);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.poll-option-results {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-secondary);
  font-weight: bold;
}

.poll-option.voted .poll-option-bar {
  border-color: var(--neon-cyan);
  box-shadow: 0 0 10px rgba(0, 245, 255, 0.3), inset 0 0 8px rgba(0, 245, 255, 0.2);
}

.poll-option:hover .poll-option-bar {
  border-color: var(--neon-cyan);
  background: linear-gradient(90deg, rgba(0, 245, 255, 0.3), rgba(184, 41, 227, 0.3));
}

.poll-stats {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  padding-top: 8px;
  border-top: 1px solid rgba(0, 245, 255, 0.1);
}

.poll-creator {
  font-family: var(--font-body);
  font-size: 11px;
  color: var(--text-secondary);
}

.poll-votes-count {
  font-weight: bold;
  color: var(--neon-cyan);
}

.poll-create-modal {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 7000;
  background-color: var(--bg-secondary);
  border: 2px solid var(--neon-cyan);
  border-radius: 12px;
  padding: 24px;
  min-width: 450px;
  max-height: 500px;
  box-shadow:
    0 0 25px rgba(0, 245, 255, 0.4),
    0 10px 40px rgba(0, 0, 0, 0.5);
  animation: slideUp 0.3s ease;
}

.poll-create-modal h3 {
  font-family: var(--font-display);
  font-size: 16px;
  color: var(--neon-cyan);
  margin: 0 0 18px 0;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.poll-create-field {
  margin-bottom: 16px;
}

.poll-create-label {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-secondary);
  display: block;
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: bold;
}

.poll-question-input,
.poll-option-input {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid rgba(0, 245, 255, 0.3);
  border-radius: 8px;
  background-color: var(--bg-tertiary);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 13px;
  transition: all 0.3s ease;
}

.poll-question-input:focus,
.poll-option-input:focus {
  outline: none;
  border-color: var(--neon-cyan);
  box-shadow: 0 0 10px rgba(0, 245, 255, 0.3), 0 0 0 2px rgba(0, 245, 255, 0.3);
}

.poll-options-inputs {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 12px;
}

.poll-option-input-row {
  display: flex;
  gap: 8px;
}

.poll-option-input {
  flex: 1;
}

.poll-remove-option {
  background-color: transparent;
  border: 1px solid rgba(255, 107, 107, 0.5);
  color: #ff6b6b;
  width: 36px;
  height: 36px;
  border-radius: 6px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  transition: all 0.3s ease;
}

.poll-remove-option:hover {
  background-color: rgba(255, 107, 107, 0.2);
  border-color: #ff6b6b;
}

.poll-add-option {
  background-color: transparent;
  border: 1px solid rgba(57, 255, 20, 0.5);
  color: var(--neon-green);
  padding: 8px 12px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 12px;
  font-weight: bold;
  transition: all 0.3s ease;
  margin-bottom: 12px;
}

.poll-add-option:hover {
  background-color: rgba(57, 255, 20, 0.2);
  border-color: var(--neon-green);
}

.poll-create-buttons {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
}

.poll-create-btn {
  background-color: var(--neon-cyan);
  color: var(--bg-primary);
  border: none;
  padding: 10px 16px;
  border-radius: 6px;
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: all 0.3s ease;
}

.poll-create-btn:hover {
  background-color: var(--neon-purple);
  box-shadow: 0 0 15px rgba(0, 245, 255, 0.3);
  transform: translateY(-1px);
}

.poll-cancel-btn {
  background-color: transparent;
  border: 1px solid rgba(255, 107, 107, 0.5);
  color: #ff6b6b;
  padding: 10px 16px;
  border-radius: 6px;
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: all 0.3s ease;
}

.poll-cancel-btn:hover {
  background-color: rgba(255, 107, 107, 0.2);
  border-color: #ff6b6b;
}

.poll-btn {
  background-color: transparent;
  border: 1px solid rgba(0, 245, 255, 0.3);
  color: var(--neon-cyan);
  width: 36px;
  height: 36px;
  border-radius: 6px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  transition: all 0.3s ease;
}

.poll-btn:hover {
  background-color: rgba(0, 245, 255, 0.2);
  border-color: var(--neon-cyan);
  box-shadow: 0 0 10px rgba(0, 245, 255, 0.3);
}

.poll-btn.active {
  background-color: rgba(0, 245, 255, 0.3);
  border-color: var(--neon-cyan);
}

/* ================================
   9. ACHIEVEMENT BADGES
   ================================ */

.achievement-badge {
  position: relative;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  transition: all 0.3s ease;
  cursor: pointer;
  background-color: var(--bg-tertiary);
  border: 2px solid rgba(0, 245, 255, 0.3);
}

.achievement-badge.earned {
  animation: achievementUnlock 0.6s ease;
  border-color: var(--neon-cyan);
  box-shadow: 0 0 20px rgba(0, 245, 255, 0.5), inset 0 0 15px rgba(0, 245, 255, 0.2);
}

@keyframes achievementUnlock {
  0% {
    transform: scale(0.5) rotate(-180deg);
    opacity: 0;
  }
  50% {
    transform: scale(1.1);
  }
  100% {
    transform: scale(1) rotate(0deg);
    opacity: 1;
  }
}

.achievement-badge.locked {
  opacity: 0.4;
  filter: grayscale(100%);
  border-color: rgba(119, 119, 160, 0.5);
  background-color: var(--bg-secondary);
}

.achievement-badge.locked::after {
  content: '🔒';
  position: absolute;
  font-size: 16px;
  bottom: -4px;
  right: -4px;
}

.achievement-badge:hover .achievement-tooltip {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, -120%);
}

.achievements-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
}

.achievement-tooltip {
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translate(-50%, -130%);
  background-color: var(--bg-secondary);
  border: 1px solid var(--neon-cyan);
  border-radius: 6px;
  padding: 8px 12px;
  font-family: var(--font-body);
  font-size: 11px;
  color: var(--text-secondary);
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  z-index: 100;
  pointer-events: none;
  box-shadow: 0 0 15px rgba(0, 245, 255, 0.3);
}

.achievement-tooltip::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 0;
  border-left: 6px solid transparent;
  border-right: 6px solid transparent;
  border-top: 6px solid var(--neon-cyan);
}

.achievement-tooltip-title {
  font-weight: bold;
  color: var(--neon-cyan);
  margin-bottom: 2px;
}

.achievement-tooltip-desc {
  color: var(--text-muted);
}

/* ================================
   10. NOTIFICATION SOUNDS
   ================================ */

.sound-settings {
  background-color: var(--bg-tertiary);
  border: 1px solid rgba(0, 245, 255, 0.2);
  border-radius: 8px;
  padding: 16px;
}

.sound-settings-title {
  font-family: var(--font-display);
  font-size: 14px;
  color: var(--neon-cyan);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 12px;
  font-weight: bold;
}

.sound-setting-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px solid rgba(0, 245, 255, 0.1);
}

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

.sound-label {
  font-family: var(--font-body);
  font-size: 12px;
  color: var(--text-primary);
  font-weight: 500;
}

.sound-toggle {
  position: relative;
  width: 44px;
  height: 24px;
  background-color: var(--bg-secondary);
  border: 2px solid rgba(0, 245, 255, 0.3);
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  padding: 0 2px;
}

.sound-toggle.enabled {
  background-color: rgba(0, 245, 255, 0.3);
  border-color: var(--neon-cyan);
}

.sound-toggle-dot {
  width: 18px;
  height: 18px;
  background-color: var(--text-secondary);
  border-radius: 50%;
  transition: all 0.3s ease;
}

.sound-toggle.enabled .sound-toggle-dot {
  background-color: var(--neon-cyan);
  transform: translateX(20px);
  box-shadow: 0 0 10px rgba(0, 245, 255, 0.5);
}

.sound-volume-control {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid rgba(0, 245, 255, 0.1);
}

.sound-volume-label {
  font-family: var(--font-body);
  font-size: 12px;
  color: var(--text-primary);
  font-weight: 500;
  min-width: 60px;
}

.sound-volume-slider {
  flex: 1;
  height: 6px;
  border-radius: 3px;
  background: linear-gradient(90deg,
    var(--neon-cyan) 0%,
    var(--neon-purple) 100%);
  outline: none;
  -webkit-appearance: none;
  appearance: none;
}

.sound-volume-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background-color: var(--neon-cyan);
  cursor: pointer;
  transition: all 0.3s ease;
  border: 2px solid var(--bg-secondary);
  box-shadow: 0 0 8px rgba(0, 245, 255, 0.5);
}

.sound-volume-slider::-webkit-slider-thumb:hover {
  transform: scale(1.2);
  box-shadow: 0 0 12px rgba(0, 245, 255, 0.7);
}

.sound-volume-slider::-moz-range-thumb {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background-color: var(--neon-cyan);
  cursor: pointer;
  transition: all 0.3s ease;
  border: 2px solid var(--bg-secondary);
  box-shadow: 0 0 8px rgba(0, 245, 255, 0.5);
}

.sound-volume-slider::-moz-range-thumb:hover {
  transform: scale(1.2);
  box-shadow: 0 0 12px rgba(0, 245, 255, 0.7);
}

.sound-volume-value {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--neon-cyan);
  font-weight: bold;
  min-width: 25px;
}

/* ================================
   11. RESOURCE UPVOTING
   ================================ */

/* Wrapper: vote column + card side by side */
.resource-card-wrapper {
  display: flex;
  gap: 0;
  border-radius: 10px;
  overflow: hidden;
  background: var(--bg-card, #0d0d1a);
  border: 1px solid rgba(0, 245, 255, 0.1);
  transition: all 0.25s ease;
  position: relative;
}

.resource-card-wrapper:hover {
  border-color: rgba(0, 245, 255, 0.3);
  transform: translateY(-2px);
  box-shadow: 0 4px 20px rgba(0, 245, 255, 0.1);
}

.resource-card-wrapper.hidden {
  display: none !important;
}

/* Override original card styles when inside wrapper */
.resource-card-wrapper .resource-card {
  border: none !important;
  border-radius: 0 !important;
  flex: 1;
  min-width: 0;
  background: transparent !important;
  box-shadow: none !important;
}

.resource-card-wrapper .resource-card:hover {
  transform: none !important;
  box-shadow: none !important;
}

.resource-card-wrapper .resource-card::before {
  display: none;
}

/* Gradient line on wrapper instead */
.resource-card-wrapper::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--neon-cyan, #00f5ff), var(--neon-purple, #b829e3));
  opacity: 0;
  transition: opacity 0.25s;
}

.resource-card-wrapper:hover::before {
  opacity: 1;
}

/* Vote column on the left */
.resource-vote-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 12px 10px;
  background: rgba(0, 245, 255, 0.04);
  border-right: 1px solid rgba(0, 245, 255, 0.1);
  min-width: 56px;
  flex-shrink: 0;
}

/* Vote buttons */
.rv-btn {
  background: none;
  border: 1px solid transparent;
  color: var(--text-muted, #666);
  font-size: 18px;
  cursor: pointer;
  padding: 8px 12px;
  border-radius: 6px;
  transition: all 0.2s ease;
  line-height: 1;
  user-select: none;
  min-width: 40px;
  min-height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.rv-btn:hover {
  background: rgba(0, 245, 255, 0.12);
  border-color: rgba(0, 245, 255, 0.2);
}

.rv-up:hover,
.rv-up.active {
  color: var(--neon-cyan, #00f5ff);
  text-shadow: 0 0 10px rgba(0, 245, 255, 0.6);
  background: rgba(0, 245, 255, 0.1);
}

.rv-down:hover,
.rv-down.active {
  color: var(--neon-pink, #ff2d75);
  text-shadow: 0 0 10px rgba(255, 45, 117, 0.6);
  background: rgba(255, 45, 117, 0.1);
}

.rv-btn.active {
  transform: scale(1.15);
  border-color: currentColor;
}

/* Vote count */
.rv-count {
  font-family: var(--font-mono, monospace);
  font-size: 15px;
  font-weight: 700;
  color: var(--text-secondary, #999);
  text-align: center;
  min-width: 24px;
  transition: all 0.2s ease;
  padding: 2px 0;
}

.rv-count.positive {
  color: var(--neon-cyan, #00f5ff);
}

.rv-count.negative {
  color: var(--neon-pink, #ff2d75);
}

/* Mobile: still usable */
@media (max-width: 480px) {
  .resource-vote-col {
    padding: 8px 6px;
    min-width: 46px;
  }
  .rv-btn {
    font-size: 16px;
    padding: 6px 10px;
    min-width: 36px;
    min-height: 28px;
  }
  .rv-count {
    font-size: 13px;
  }
}

/* ================================
   GLOBAL STYLES & RESPONSIVE
   ================================ */

/* Smooth transitions for interactive elements */
button,
input,
textarea,
select {
  transition: all 0.3s ease;
}


/* Modal overlay */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.6);
  z-index: 6000;
  backdrop-filter: blur(2px);
  animation: fadeIn 0.3s ease;
}

/* Utility classes */
.glow-cyan {
  box-shadow: 0 0 15px rgba(0, 245, 255, 0.5);
}

.glow-purple {
  box-shadow: 0 0 15px rgba(184, 41, 227, 0.5);
}

.glow-green {
  box-shadow: 0 0 15px rgba(57, 255, 20, 0.5);
}

/* Responsive design */
@media (max-width: 768px) {
  .link-preview-card {
    max-width: 100%;
  }

  .gif-picker {
    width: 100%;
    max-width: calc(100vw - 16px);
  }

  .status-picker,
  .poll-create-modal {
    min-width: calc(100vw - 32px);
  }

  .pinned-messages-list {
    max-height: 250px;
  }

  .achievements-grid {
    gap: 12px;
  }

  .gif-grid {
    grid-template-columns: 1fr;
    max-height: 200px;
  }

  .poll-option-text {
    max-width: calc(100% - 50px);
  }

  .typing-indicator {
    font-size: 12px;
  }

  .level-badge {
    min-width: 28px;
    height: 22px;
    padding: 0 6px;
    font-size: 10px;
  }

  .user-status-indicator {
    padding: 3px 6px;
    font-size: 11px;
  }

  .status-text {
    max-width: 120px;
  }
}

@media (max-width: 480px) {
  .link-preview-card {
    flex-direction: column;
    max-width: 100%;
  }

  .link-preview-icon {
    width: 40px;
    height: 40px;
    font-size: 20px;
  }

  .pinned-messages-list {
    max-height: 200px;
  }

  .poll-card {
    padding: 10px;
  }

  .poll-question {
    font-size: 13px;
  }

  .achievement-badge {
    width: 40px;
    height: 40px;
    font-size: 20px;
  }

  .gif-picker {
    width: 100%;
    max-height: 350px;
  }

  .status-picker,
  .poll-create-modal {
    min-width: calc(100vw - 20px);
    padding: 16px;
  }

  .achievements-grid {
    gap: 8px;
  }

  .reply-bar {
    flex-direction: column;
    align-items: flex-start;
  }

  .reply-bar-close {
    align-self: flex-end;
  }
}

/* Message integration styles */
.msg .msg-body {
  transition: all 0.3s ease;
}

.msg:hover .msg-body {
  background-color: rgba(0, 245, 255, 0.05);
}

.msg-actions {
  display: flex;
  gap: 4px;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.msg:hover .msg-actions {
  opacity: 1;
}

/* Status indicator in message meta */
.msg-meta .user-status-indicator {
  margin-left: 8px;
}

/* Level badge in message meta */
.msg-meta .level-badge {
  margin-left: 6px;
}
