/* chat_room_shared.css — CSS extracted from chat_room.html inline <style> block.
 * Loaded by both classic and v3 templates.
 * Do not edit manually — source of truth is chat_room.html inline styles.
 */

/* XP bar shimmer sweep */
.don-xp-bar-fill::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 50%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.35),
    transparent
  );
  animation: none;
  border-radius: 999px;
}
@keyframes xpShimmer {
  0% {
    transform: translateX(-120%);
    opacity: 0;
  }
  10% {
    opacity: 1;
  }
  80% {
    opacity: 1;
  }
  100% {
    transform: translateX(320%);
    opacity: 0;
  }
}

/* XP icon bounce */
.don-xp-icon i {
  display: inline-block;
  animation: none;
}
@keyframes trophyBounce {
  0%,
  100% {
    transform: translateY(0) rotate(0deg);
  }
  20% {
    transform: translateY(-3px) rotate(-8deg);
  }
  40% {
    transform: translateY(0) rotate(0deg);
  }
  60% {
    transform: translateY(-2px) rotate(5deg);
  }
  80% {
    transform: translateY(0) rotate(0deg);
  }
}

/* Notification bell: wiggle when unread */
.tb-btn .noti-count:not([hidden]) ~ i,
.tb-btn:has(.noti-count:not([hidden])) i {
  animation: none;
}
@keyframes bellWiggle {
  0%,
  100% {
    transform: rotate(0deg);
  }
  10% {
    transform: rotate(12deg);
  }
  20% {
    transform: rotate(-10deg);
  }
  30% {
    transform: rotate(8deg);
  }
  40% {
    transform: rotate(-6deg);
  }
  50% {
    transform: rotate(0deg);
  }
}

/* Sidebar toggle leaf: slow spin on hover */
.sidebarToggle:hover .sidebar-toggle-icon {
  animation: leafSpin 0.5s ease-in-out;
}
@keyframes leafSpin {
  0% {
    transform: rotate(0deg) scale(1);
  }
  50% {
    transform: rotate(180deg) scale(1.2);
  }
  100% {
    transform: rotate(360deg) scale(1);
  }
}

/* Activity indicator on channel pill — typing dots */
.top-channel-activity {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  padding: 0 2px;
}
.top-channel-activity span {
  display: inline-block;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: #818cf8;
  animation: none;
}
.top-channel-activity span:nth-child(2) {
  animation-delay: 0.2s;
}
.top-channel-activity span:nth-child(3) {
  animation-delay: 0.4s;
}
@keyframes activityDot {
  0%,
  80%,
  100% {
    transform: scale(0.6);
    opacity: 0.4;
  }
  40% {
    transform: scale(1.2);
    opacity: 1;
  }
}

/* XP urgency pill — enhanced pulse */
.don-xp-urgency {
  animation: none !important;
}
@keyframes urgencyFlash {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.7;
  }
}

/* tb-divider fade-in */
.tb-divider {
  opacity: 0.5;
  transition: opacity 0.2s ease;
}
.navbar.topbar:hover .tb-divider {
  opacity: 0.8;
}

/* ── Topbar Points Pill ── */
.topbar-points-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px 4px 8px;
  border-radius: 20px;
  background: linear-gradient(
    135deg,
    rgba(251, 191, 36, 0.18),
    rgba(245, 158, 11, 0.1)
  );
  border: 1.5px solid rgba(251, 191, 36, 0.4);
  cursor: pointer;
  transition:
    transform 0.2s ease,
    border-color 0.2s ease;
  white-space: nowrap;
  flex-shrink: 0;
  text-decoration: none;
}
.topbar-points-pill:hover {
  background: linear-gradient(
    135deg,
    rgba(251, 191, 36, 0.28),
    rgba(245, 158, 11, 0.18)
  );
  border-color: rgba(251, 191, 36, 0.65);
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(245, 158, 11, 0.25);
}
.topbar-points-coin {
  width: 18px;
  height: 18px;
  object-fit: contain;
  display: block;
  flex-shrink: 0;
  animation: none;
}
@keyframes coinSpin {
  0%,
  100% {
    transform: rotateY(0deg);
  }
  45% {
    transform: rotateY(0deg);
  }
  50% {
    transform: rotateY(90deg);
  }
  55% {
    transform: rotateY(0deg);
  }
}
.topbar-points-value {
  font-size: 0.78rem;
  font-weight: 800;
  color: #fbbf24;
  letter-spacing: 0.01em;
}
.topbar-points-label {
  font-size: 0.58rem;
  font-weight: 600;
  color: rgba(251, 191, 36, 0.75);
  letter-spacing: 0.02em;
  text-transform: uppercase;
}
html.theme-trueblue-light .topbar-points-value {
  color: #b45309;
}
html.theme-trueblue-light .topbar-points-label {
  color: #92400e;
}

.topbar-points-game-btn {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1.5px solid rgba(251, 191, 36, 0.45);
  background: radial-gradient(
    circle at 30% 25%,
    rgba(251, 191, 36, 0.35),
    rgba(245, 158, 11, 0.16)
  );
  color: #fbbf24;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  margin-left: 6px;
  flex-shrink: 0;
}
.topbar-points-game-btn:hover {
  transform: translateY(-1px) scale(1.03);
  border-color: rgba(251, 191, 36, 0.72);
  color: #fde68a;
}
.topbar-points-game-btn i {
  font-size: 1rem;
}

/* Pill points value — count-up animation disabled */
.points-value-pop {
  animation: none;
}

/* Pill earn glow burst disabled */
.topbar-points-pill.earning {
  animation: none;
}

/* Floating +N particle from pill */
.gc-pts-particle {
  position: fixed;
  font-size: 0.8rem;
  font-weight: 900;
  color: #fbbf24;
  pointer-events: none;
  z-index: 9999;
  white-space: nowrap;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.5);
  animation: none;
  opacity: 0;
}
@keyframes gcPtsFloat {
  0% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
  60% {
    opacity: 1;
    transform: translateY(-28px) scale(1.1);
  }
  100% {
    opacity: 0;
    transform: translateY(-50px) scale(0.8);
  }
}

/* ── Points Modal ── */
#pointsModal .modal-dialog {
  margin: 8px auto;
  max-width: min(400px, calc(100vw - 16px));
}
#pointsModal .modal-content {
  max-height: calc(100dvh - 24px);
  overflow-y: auto;
}

/* Collapsible earn section */
.points-benefits-collapsible {
  padding: 0 !important;
}
.points-benefits-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  background: none;
  border: none;
  padding: 12px 20px;
  cursor: pointer;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--bs-body-color, #e2e8f0);
  text-align: left;
  border-top: 1px solid rgba(255, 255, 255, 0.07);
  transition: background 0.15s;
  min-height: 44px;
}
.points-benefits-toggle:hover {
  background: rgba(251, 191, 36, 0.06);
}
html.theme-trueblue-light .points-benefits-toggle {
  color: #374151;
  border-top-color: rgba(0, 0, 0, 0.08);
}
.points-toggle-chevron {
  transition: transform 0.25s ease;
  font-size: 1rem;
  flex-shrink: 0;
}
.points-benefits-toggle[aria-expanded="true"] .points-toggle-chevron {
  transform: rotate(180deg);
}
.points-earn-body {
  max-height: 0;
  overflow: hidden;
  transition:
    max-height 0.3s ease,
    padding 0.2s ease;
  padding: 0 20px;
}
.points-earn-body.open {
  max-height: 600px;
  padding: 2px 20px 12px;
}
.points-benefits-divider {
  height: 1px;
  background: rgba(255, 255, 255, 0.08);
  margin: 8px 0;
}
html.theme-trueblue-light .points-benefits-divider {
  background: rgba(0, 0, 0, 0.08);
}

#pointsModal .modal-content {
  border-radius: 20px;
  border: 1.5px solid rgba(251, 191, 36, 0.3);
}
.points-modal-header {
  background: linear-gradient(135deg, #1c1a2e, #0f172a);
  padding: 24px 24px 16px;
  position: relative;
  text-align: center;
}
html.theme-trueblue-light .points-modal-header {
  background: linear-gradient(135deg, #fffbeb, #fef3c7);
}
.points-modal-coin-big {
  width: 56px;
  height: 56px;
  object-fit: contain;
  display: block;
  margin: 0 auto 8px;
  animation: none;
}
.points-modal-title {
  font-size: 1.3rem;
  font-weight: 900;
  color: #fbbf24;
  letter-spacing: 0.02em;
}
html.theme-trueblue-light .points-modal-title {
  color: #b45309;
}
.points-modal-sub {
  font-size: 0.8rem;
  color: rgba(251, 191, 36, 0.7);
  margin-top: 4px;
  font-weight: 500;
}
html.theme-trueblue-light .points-modal-sub {
  color: #78350f;
}
.points-tier-table {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 20px 20px 8px;
}
.points-tier-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-radius: 12px;
  border: 1.5px solid rgba(128, 128, 128, 0.12);
  background: rgba(128, 128, 128, 0.04);
  transition: all 0.2s ease;
  cursor: default;
}
.points-tier-row.is-current {
  border-color: rgba(251, 191, 36, 0.5);
  background: linear-gradient(
    135deg,
    rgba(251, 191, 36, 0.1),
    rgba(245, 158, 11, 0.06)
  );
  box-shadow: 0 2px 12px rgba(245, 158, 11, 0.15);
}
.points-tier-row.is-locked {
  opacity: 0.55;
}
.points-tier-emoji {
  font-size: 1.4rem;
  flex-shrink: 0;
}
.points-tier-info {
  flex: 1;
  min-width: 0;
}
.points-tier-name {
  font-size: 0.82rem;
  font-weight: 700;
  line-height: 1.2;
}
.points-tier-desc {
  font-size: 0.65rem;
  color: #64748b;
  margin-top: 2px;
  font-weight: 500;
}
.points-tier-token-img {
  width: 14px;
  height: 14px;
  object-fit: contain;
  display: inline-block;
  vertical-align: middle;
  flex-shrink: 0;
}
.points-tier-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.78rem;
  font-weight: 900;
  color: #fbbf24;
  background: rgba(251, 191, 36, 0.12);
  border: 1px solid rgba(251, 191, 36, 0.3);
  border-radius: 20px;
  padding: 3px 10px;
  white-space: nowrap;
  flex-shrink: 0;
}
.points-tier-row.is-current .points-tier-badge {
  background: rgba(251, 191, 36, 0.22);
  border-color: rgba(251, 191, 36, 0.55);
  box-shadow: 0 0 8px rgba(245, 158, 11, 0.3);
}
.points-tier-lock {
  font-size: 0.85rem;
  opacity: 0.4;
  flex-shrink: 0;
}
.points-tier-current-tag {
  display: none;
  font-size: 0.55rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #f59e0b;
  background: rgba(245, 158, 11, 0.15);
  border-radius: 4px;
  padding: 1px 5px;
  margin-left: 4px;
}
.points-tier-row.is-current .points-tier-current-tag {
  display: inline;
}

/* Earn-rate bar inside tier rows */
.points-tier-rate {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-top: 4px;
}
.points-tier-rate-bar {
  flex: 1;
  height: 3px;
  border-radius: 999px;
  background: rgba(128, 128, 128, 0.15);
  overflow: hidden;
}
.points-tier-rate-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #fbbf24, #f59e0b);
  transition: none;
}
.points-tier-rate-label {
  font-size: 0.6rem;
  font-weight: 700;
  color: #f59e0b;
  white-space: nowrap;
}
.points-tier-row.is-locked .points-tier-rate-fill {
  background: rgba(128, 128, 128, 0.3);
}
.points-tier-row.is-locked .points-tier-rate-label {
  color: #64748b;
}
.points-tier-row.is-current .points-tier-rate-fill {
  background: linear-gradient(90deg, #fbbf24, #f97316);
  box-shadow: 0 0 6px rgba(245, 158, 11, 0.5);
}

/* Modal earn rate summary */
.points-earn-summary {
  margin: 0 20px 12px;
  padding: 10px 14px;
  border-radius: 12px;
  background: linear-gradient(
    135deg,
    rgba(251, 191, 36, 0.1),
    rgba(245, 158, 11, 0.06)
  );
  border: 1px solid rgba(251, 191, 36, 0.2);
  display: flex;
  align-items: center;
  gap: 10px;
}
.points-earn-summary-icon {
  font-size: 1.3rem;
  flex-shrink: 0;
}
.points-earn-summary-text {
  flex: 1;
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1.4;
}
.points-earn-summary-rate {
  font-weight: 900;
  color: #fbbf24;
}
.points-earn-summary-next {
  font-size: 0.65rem;
  color: #64748b;
  margin-top: 2px;
}

/* Earn value / cap labels in modal */
.points-earn-val {
  margin-left: auto;
  font-size: 0.72rem;
  font-weight: 800;
  color: #fbbf24;
  background: rgba(251, 191, 36, 0.12);
  border: 1px solid rgba(251, 191, 36, 0.25);
  border-radius: 8px;
  padding: 1px 7px;
  white-space: nowrap;
  flex-shrink: 0;
}
.points-earn-cap {
  font-size: 0.6rem;
  font-weight: 500;
  color: #64748b;
  margin-left: 3px;
  flex-shrink: 0;
}
.points-benefit-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.73rem;
  font-weight: 600;
  padding: 3px 0;
}

/* Activity earned micro-toast (bottom-center) */
#gcActivityToast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2100;
  display: none;
  pointer-events: none;
  white-space: nowrap;
}
.gc-activity-toast-inner {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  border-radius: 20px;
  background: rgba(15, 23, 42, 0.95);
  border: 1px solid rgba(251, 191, 36, 0.35);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
  font-size: 0.75rem;
  font-weight: 700;
  color: #fbbf24;
  animation: none;
}
.gc-activity-toast-inner.hiding {
  animation: none;
  opacity: 0;
}
@keyframes activityToastIn {
  from {
    opacity: 0;
    transform: translateY(12px) scale(0.9);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}
@keyframes activityToastOut {
  from {
    opacity: 1;
    transform: translateY(0);
  }
  to {
    opacity: 0;
    transform: translateY(8px);
  }
}
.gc-activity-toast-img {
  width: 16px;
  height: 16px;
  object-fit: contain;
}
.points-benefits {
  margin: 0 20px 16px;
  padding: 12px 14px;
  border-radius: 12px;
  background: rgba(99, 102, 241, 0.07);
  border: 1px solid rgba(99, 102, 241, 0.15);
}
.points-benefits-title {
  font-size: 0.72rem;
  font-weight: 800;
  color: #818cf8;
  margin-bottom: 8px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.points-benefit-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.73rem;
  font-weight: 600;
  padding: 3px 0;
  color: var(--bs-body-color, #64748b);
}
.points-benefit-item i {
  color: #818cf8;
  font-size: 0.9rem;
}
.points-modal-cta {
  margin: 0 20px 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.points-cta-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 20px;
  border-radius: 12px;
  font-size: 0.85rem;
  font-weight: 800;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
}
.points-cta-btn--primary {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: #fff;
  box-shadow: 0 4px 16px rgba(245, 158, 11, 0.35);
}
.points-cta-btn--primary:hover {
  background: linear-gradient(135deg, #fbbf24, #f59e0b);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(245, 158, 11, 0.45);
  color: #fff;
}
.points-cta-btn--secondary {
  background: rgba(99, 102, 241, 0.1);
  color: #818cf8;
  border: 1.5px solid rgba(99, 102, 241, 0.25);
}
.points-cta-btn--secondary:hover {
  background: rgba(99, 102, 241, 0.18);
  border-color: rgba(99, 102, 241, 0.45);
  color: #a5b4fc;
}

#pointsTransactionsModal .modal-dialog {
  max-width: min(520px, calc(100vw - 16px));
  margin: 10px auto;
}
#pointsTransactionsModal .modal-content {
  border-radius: 18px;
  border: 1.5px solid rgba(99, 102, 241, 0.35);
  background: linear-gradient(
    180deg,
    rgba(17, 24, 39, 0.98),
    rgba(15, 23, 42, 0.98)
  );
  max-height: calc(100dvh - 24px);
  overflow: hidden;
}
html.theme-trueblue-light #pointsTransactionsModal .modal-content {
  background: linear-gradient(180deg, #ffffff, #f8fafc);
  border-color: rgba(99, 102, 241, 0.25);
}
.ptsx-header {
  padding: 16px 18px 12px;
  border-bottom: 1px solid rgba(99, 102, 241, 0.22);
  background: linear-gradient(
    135deg,
    rgba(79, 70, 229, 0.24),
    rgba(30, 64, 175, 0.18)
  );
}
.ptsx-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 900;
  color: #c7d2fe;
  letter-spacing: 0.01em;
}
.ptsx-sub {
  margin-top: 3px;
  font-size: 0.78rem;
  color: rgba(199, 210, 254, 0.85);
}
.ptsx-sub strong {
  color: #fbbf24;
}
.ptsx-body {
  padding: 8px 0 0;
  overflow-y: auto;
}
.ptsx-footer {
  padding: 10px 14px 14px;
  border-top: 1px solid rgba(99, 102, 241, 0.2);
  text-align: center;
}
.ptsx-close-btn {
  border: 1px solid rgba(99, 102, 241, 0.35);
  background: rgba(99, 102, 241, 0.12);
  color: #a5b4fc;
  border-radius: 9px;
  padding: 7px 14px;
  font-size: 0.78rem;
  font-weight: 700;
}
.ptsx-close-btn:hover {
  background: rgba(99, 102, 241, 0.2);
}

/* ── Points History ── */
.pts-hist-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  font-size: 0.8rem;
}
.pts-hist-row:last-child {
  border-bottom: none;
}
html.theme-trueblue-light .pts-hist-row {
  border-bottom-color: rgba(0, 0, 0, 0.06);
}
.pts-hist-icon {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(99, 102, 241, 0.15);
  color: #818cf8;
  flex-shrink: 0;
  font-size: 0.85rem;
}
.pts-hist-icon.pos {
  background: rgba(34, 197, 94, 0.13);
  color: #4ade80;
}
.pts-hist-icon.neg {
  background: rgba(239, 68, 68, 0.13);
  color: #f87171;
}
.pts-hist-label {
  flex: 1;
  color: var(--bs-body-color, #e2e8f0);
}
.pts-hist-label small {
  display: block;
  color: var(--color-text-muted, #94a3b8);
  font-size: 0.72rem;
  margin-top: 1px;
}
.pts-hist-pts {
  font-weight: 700;
  white-space: nowrap;
}
.pts-hist-pts.pos {
  color: #4ade80;
}
.pts-hist-pts.neg {
  color: #f87171;
}
.pts-hist-empty {
  padding: 14px;
  text-align: center;
  color: var(--color-text-muted, #94a3b8);
  font-size: 0.8rem;
}
.pts-hist-loading {
  padding: 14px;
  text-align: center;
  color: var(--color-text-muted, #94a3b8);
  font-size: 0.8rem;
}
#ptsHistoryPager {
  padding: 8px 14px;
  display: flex;
  gap: 6px;
  align-items: center;
  justify-content: center;
}
.pts-hist-pager-btn {
  background: rgba(99, 102, 241, 0.12);
  border: 1px solid rgba(99, 102, 241, 0.25);
  color: #818cf8;
  border-radius: 6px;
  padding: 4px 12px;
  font-size: 0.75rem;
  cursor: pointer;
  transition: background 0.15s;
}
.pts-hist-pager-btn:hover {
  background: rgba(99, 102, 241, 0.22);
}
.points-earn-body.open {
  max-height: 900px;
}

.topbar-forum-btn {
  font-size: 0.8rem;
  font-weight: 600;
  border-radius: 8px;
  padding: 5px 12px;
  border: 1.5px solid rgba(253, 126, 20, 0.55);
  color: #fd7e14;
  background: rgba(253, 126, 20, 0.08);
  white-space: nowrap;
  text-decoration: none;
  transition:
    background 0.15s ease,
    color 0.15s ease;
}

.topbar-forum-btn:hover {
  background: rgba(253, 126, 20, 0.18);
  color: #fd7e14;
}

.topbar-ads-btn {
  font-size: 0.8rem;
  font-weight: 600;
  border-radius: 8px;
  padding: 5px 12px;
  border: 1.5px solid rgba(253, 126, 20, 0.55);
  color: #fd7e14;
  background: rgba(253, 126, 20, 0.08);
  white-space: nowrap;
  text-decoration: none;
  transition:
    background 0.15s ease,
    color 0.15s ease;
}

.topbar-ads-btn:hover {
  background: rgba(253, 126, 20, 0.18);
  color: #fd7e14;
}

.topbar-menu-btn {
  font-weight: 600;
}

/* ── Unified topbar button system ── */
.tb-btn {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 4px 8px;
  border-radius: 8px;
  border: none;
  background: transparent;
  color: var(--bs-body-color, #64748b);
  font-size: 0.72rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition:
    background 0.15s ease,
    color 0.15s ease,
    transform 0.15s ease;
  white-space: nowrap;
  min-width: 44px;
  position: relative;
  line-height: 1;
}
.tb-btn i,
.tb-btn .tb-btn-icon {
  font-size: 1.1rem;
  line-height: 1;
  display: block;
}
.tb-btn .tb-btn-label {
  font-size: 0.6rem;
  font-weight: 600;
  opacity: 0.7;
  letter-spacing: 0.01em;
  line-height: 1;
  display: block;
}
.tb-btn:hover {
  background: rgba(99, 102, 241, 0.08);
  color: var(--bs-body-color, #334155);
  transform: translateY(-1px);
}
.tb-btn:hover .tb-btn-label {
  opacity: 1;
}
html.theme-dark .tb-btn:hover,
body.theme-dark .tb-btn:hover,
html.theme-trueblue .tb-btn:hover,
body.theme-trueblue .tb-btn:hover {
  background: rgba(255, 255, 255, 0.07);
}
.tb-btn .noti-count {
  position: absolute;
  top: 2px;
  right: 4px;
}
.tb-divider {
  width: 1px;
  height: 28px;
  background: rgba(128, 128, 128, 0.18);
  margin: 0 4px;
  flex-shrink: 0;
  align-self: center;
}
.topbar-donate-btn {
  font-weight: 700;
  font-size: 0.78rem;
  background: linear-gradient(
    135deg,
    rgba(139, 92, 246, 0.15) 0%,
    rgba(124, 58, 237, 0.1) 100%
  );
  border: 1.5px solid rgba(139, 92, 246, 0.35);
  border-radius: 8px;
  color: #a78bfa;
  transition: all 0.2s ease;
  white-space: nowrap;
  letter-spacing: 0.01em;
}
.topbar-donate-btn:hover {
  background: linear-gradient(
    135deg,
    rgba(139, 92, 246, 0.28) 0%,
    rgba(124, 58, 237, 0.2) 100%
  );
  border-color: rgba(139, 92, 246, 0.6);
  box-shadow:
    0 0 0 3px rgba(139, 92, 246, 0.15),
    0 4px 12px rgba(139, 92, 246, 0.2);
  transform: translateY(-1px);
  color: #c4b5fd;
}
.topbar-leave-btn {
  font-size: 0.78rem;
  font-weight: 600;
  border-radius: 8px;
  padding: 5px 10px;
  border: 1.5px solid rgba(239, 68, 68, 0.35);
  color: #f87171;
  background: rgba(239, 68, 68, 0.07);
  white-space: nowrap;
  transition: all 0.2s ease;
}
.topbar-leave-btn:hover {
  background: rgba(239, 68, 68, 0.15);
  border-color: rgba(239, 68, 68, 0.6);
  color: #fca5a5;
}
.don-xp-pct {
  font-size: 0.55rem;
  font-weight: 800;
  color: #10b981;
  white-space: nowrap;
  flex-shrink: 0;
  letter-spacing: 0.02em;
}
html.theme-light .don-xp-pct,
body.theme-light .don-xp-pct {
  color: #059669;
}

.chat-donation-topbar {
  flex: 1 1 auto;
  min-width: 120px;
  max-width: 280px;
  align-self: center;
  width: auto;
}
@media (min-width: 992px) {
  .chat-donation-topbar {
    flex: 0 0 auto;
    min-width: 200px;
    max-width: 400px;
    width: auto;
  }
}
.chat-don-tier-lbl {
  display: inline !important;
}
#main-room .page-content-wrapper > .navbar.topbar,
#main-private .page-content-wrapper > .navbar.topbar {
  overflow: visible !important;
}
.chat-donation-trigger {
  padding: 4px 8px !important;
}

body.v3-ui #mobile-top-donation-trigger.chat-donation-trigger {
  width: 34px;
  min-width: 34px;
  max-width: 34px;
  height: 34px;
  min-height: 34px;
  max-height: 34px;
  padding: 0 !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.chat-badge-promo {
  display: inline-flex;
  flex-direction: row;
  align-items: center;
  gap: 6px;
  padding: 4px 8px;
  border-radius: 6px;
  background: linear-gradient(
    135deg,
    rgba(253, 126, 20, 0.16),
    rgba(139, 92, 246, 0.14)
  );
  text-decoration: none;
  color: inherit;
  min-width: 0;
  max-width: 200px;
  flex-shrink: 1;
  transition:
    transform 0.18s ease,
    box-shadow 0.18s ease,
    border-color 0.18s ease;
}

.chat-badge-promo:hover {
  transform: translateY(-1px);
  border-color: rgba(253, 126, 20, 0.78);
  box-shadow: 0 6px 16px rgba(17, 24, 39, 0.18);
  color: inherit;
}

.chat-badge-promo-title {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.64rem;
  font-weight: 800;
  color: #fd7e14;
  line-height: 1.1;
  letter-spacing: 0.01em;
  white-space: nowrap;
}

.chat-badge-promo-tiers {
  display: inline-flex;
  flex-wrap: nowrap;
  gap: 4px;
  line-height: 1;
  justify-content: flex-end;
  flex-shrink: 0;
}

.chat-badge-tier-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  object-fit: contain;
  opacity: 0.5;
  transform: scale(0.95);
  transition: none;
}

.chat-badge-tier-icon.is-active {
  opacity: 1;
  transform: scale(1.15);
  filter: drop-shadow(0 0 4px rgba(16, 185, 129, 0.55));
}

.chat-badge-tier-icon.is-legend.is-active {
  filter: drop-shadow(0 0 5px rgba(139, 92, 246, 0.8));
}

.chat-badge-promo-rotator {
  min-width: 0;
  max-width: 320px;
  font-size: 0.58rem;
  font-weight: 700;
  color: #475569;
  text-align: left;
  white-space: normal;
  overflow-wrap: anywhere;
  line-height: 1.2;
  opacity: 1;
  transition: none;
}

.chat-badge-promo-rotator.is-fading {
  opacity: 0;
}

/* Theme-aware promo text colors */
html.theme-dark .chat-badge-promo-rotator,
body.theme-dark .chat-badge-promo-rotator,
.dark .chat-badge-promo-rotator,
html.theme-trueblue .chat-badge-promo-rotator,
body.theme-trueblue .chat-badge-promo-rotator,
.trueblue .chat-badge-promo-rotator {
  color: #f8fafc;
}

html.theme-light .chat-badge-promo-rotator,
body.theme-light .chat-badge-promo-rotator,
.light .chat-badge-promo-rotator {
  color: #1e293b;
}

html.theme-dark .chat-badge-promo-title,
body.theme-dark .chat-badge-promo-title,
.dark .chat-badge-promo-title,
html.theme-trueblue .chat-badge-promo-title,
body.theme-trueblue .chat-badge-promo-title,
.trueblue .chat-badge-promo-title {
  color: #fbbf24;
}

html.theme-light .chat-badge-promo-title,
body.theme-light .chat-badge-promo-title,
.light .chat-badge-promo-title {
  color: #d97706;
}

/* Multi-tier track bar */
.chat-don-track-wrap {
  position: relative;
  width: 100%;
  min-width: 0;
  padding-bottom: 2px;
}
.chat-don-track-rail {
  position: relative;
  height: 7px;
  border-radius: 999px;
  background: rgba(128, 128, 128, 0.18);
  overflow: visible;
}
@keyframes chatDonLegendePulse {
  0%,
  100% {
    opacity: 1;
    transform: translateX(-50%) scale(1.3);
  }
  50% {
    opacity: 0.7;
    transform: translateX(-50%) scale(1.5);
  }
}
@keyframes chatDonLegendeBadgePulse {
  0%,
  100% {
    opacity: 1;
    transform: scale(1.2);
  }
  50% {
    opacity: 0.7;
    transform: scale(1.35);
  }
}
.chat-don-track-fill {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  border-radius: 999px;
  width: 0;
  transition: none;
  background: linear-gradient(
    90deg,
    #f59e0b 0%,
    #22c55e 40%,
    #fbbf24 70%,
    #8b5cf6 100%
  );
}
.chat-don-track-milestones {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  pointer-events: none;
}
.chat-don-milestone {
  position: absolute;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
}
.chat-don-milestone-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(128, 128, 128, 0.3);
  border: 1.5px solid rgba(255, 255, 255, 0.5);
  transition: none;
  flex-shrink: 0;
}
.chat-don-milestone.reached .chat-don-milestone-dot {
  background: #10b981;
  border-color: rgba(255, 255, 255, 0.9);
  transform: scale(1.25);
}
.chat-don-milestone-img {
  width: 16px;
  height: 16px;
  object-fit: contain;
  margin-top: 4px;
  opacity: 0.3;
  transition: none;
  flex-shrink: 0;
}
.chat-don-milestone.reached .chat-don-milestone-img {
  opacity: 1;
  transform: scale(1.15);
}
.chat-don-milestone-label {
  font-size: 0.52rem;
  color: var(--bs-body-color, #64748b);
  opacity: 0.55;
  white-space: nowrap;
  margin-top: 1px;
  transition: none;
}
.chat-don-milestone.reached .chat-don-milestone-label {
  opacity: 1;
  font-weight: 700;
  color: #10b981;
}
.chat-don-topbar-label {
  font-size: 0.6rem;
  white-space: nowrap;
  font-weight: 600;
}
.don-cta-gradient {
  background: linear-gradient(135deg, #a78bfa 0%, #8b5cf6 50%, #7c3aed 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 700;
}
.chat-don-topbar-guest {
  display: flex;
  align-items: center;
  gap: 5px;
}

/* ── Gamified XP topbar widget ── */
.don-xp-top {
  display: flex;
  flex-direction: column;
  gap: 2px;
  width: 100%;
  min-width: 120px;
  max-width: 320px;
}
.don-xp-row1 {
  display: flex;
  align-items: center;
  gap: 5px;
  min-width: 0;
}
.don-xp-icon {
  font-size: 0.75rem;
  color: #f59e0b;
  flex-shrink: 0;
  line-height: 1;
}
.don-xp-label {
  font-size: 0.6rem;
  font-weight: 700;
  white-space: nowrap;
  flex-shrink: 0;
  letter-spacing: 0.01em;
}
.don-xp-live {
  font-size: 0.55rem;
  font-weight: 600;
  color: #10b981;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
  flex: 1 1 auto;
  transition: opacity 0.3s ease;
}
html.theme-light .don-xp-live,
body.theme-light .don-xp-live {
  color: #059669;
}
.don-xp-urgency {
  font-size: 0.52rem;
  font-weight: 800;
  color: #fff;
  background: linear-gradient(135deg, #ef4444, #dc2626);
  border-radius: 4px;
  padding: 1px 5px;
  white-space: nowrap;
  flex-shrink: 0;
  animation: none;
}
@keyframes donXpUrgencyPulse {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.6;
  }
}
.don-xp-bar-wrap {
  width: 100%;
  min-width: 80px;
  display: block;
  padding-top: 6px;
}
.don-xp-bar-rail {
  position: relative;
  height: 8px;
  min-height: 8px;
  border-radius: 999px;
  background: rgba(128, 128, 128, 0.18);
  overflow: visible;
  display: block;
  width: 100%;
}
.don-xp-bar-fill {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  border-radius: 999px;
  width: 0;
  background: linear-gradient(90deg, #f59e0b 0%, #10b981 45%, #8b5cf6 100%);
  transition: none;
}
.don-xp-bar-fill::after {
  content: "";
  position: absolute;
  right: -1px;
  top: 50%;
  transform: translateY(-50%);
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #10b981;
  animation: none;
}
@keyframes donXpHeadPulse {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.7;
  }
}
.don-xp-milestones {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.don-xp-ms {
  position: absolute;
  top: 50%;
  transform: translate(-50%, -50%);
  font-size: 0.65rem;
  opacity: 0.3;
  filter: grayscale(1);
  transition: none;
  pointer-events: none;
  line-height: 1;
}
.don-xp-ms.reached {
  opacity: 1;
  filter: none;
  transform: translate(-50%, -60%) scale(1.3);
  animation: none;
}
@keyframes donXpMsReached {
  0% {
    transform: translate(-50%, -60%) scale(1);
  }
  60% {
    transform: translate(-50%, -60%) scale(1.5);
  }
  100% {
    transform: translate(-50%, -60%) scale(1.3);
  }
}

.chat-donation-trigger {
  display: block;
  width: 100%;
  min-width: 120px;
  border: 1px solid rgba(139, 92, 246, 0.3);
  border-radius: 10px;
  padding: 6px 12px;
  background: linear-gradient(
    135deg,
    rgba(139, 92, 246, 0.15) 0%,
    rgba(124, 58, 237, 0.1) 100%
  );
  text-decoration: none;
  color: var(--bs-body-color, inherit);
  transition: all 0.2s ease;
}

.chat-donation-trigger:hover {
  background: linear-gradient(
    135deg,
    rgba(139, 92, 246, 0.25) 0%,
    rgba(124, 58, 237, 0.2) 100%
  );
  border-color: rgba(139, 92, 246, 0.5);
}

.chat-donation-head {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 2px;
  min-width: 0;
  width: 100%;
  margin-bottom: 3px;
  font-size: 0.64rem;
  line-height: 1;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.chat-donation-title {
  font-weight: 600;
  color: var(--bs-body-color, inherit);
  letter-spacing: 0.01em;
  white-space: normal;
  overflow: visible;
  line-height: 1.3;
  opacity: 0.9;
}

.chat-donation-percent {
  font-weight: 800;
  color: #10b981;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.chat-donation-progress {
  position: relative;
  height: 6px;
  width: 100%;
  border-radius: 999px;
  overflow: hidden;
  background: var(--bs-border-color, rgba(0, 0, 0, 0.12));
}

.chat-donation-progress-fill {
  height: 100%;
  width: 0;
  border-radius: inherit;
  background: linear-gradient(90deg, #22c55e 0%, #10b981 60%, #14b8a6 100%);
  transition: none;
}

.chat-donation-percent-label {
  font-size: 0.58rem;
  font-weight: 700;
  color: #10b981;
  white-space: nowrap;
  line-height: 1;
  align-self: center;
}

.chat-donation-progress-fill.chat-donation-pop {
  animation: none;
}

.animate-pulse {
  animation: none;
}

@keyframes pulse {
  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0.7;
  }
}

.hover-lift {
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

.hover-lift:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Donation badge overlay on chat message avatars */
.msg-donation-badge {
  position: absolute;
  bottom: -2px;
  right: -2px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  object-fit: contain;
  opacity: 1;
  pointer-events: none;
  z-index: 3;
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  outline: none !important;
}

.msg-donation-badge.is-legende-watermark {
  bottom: -2px;
  right: -2px;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  object-fit: contain;
  opacity: 1;
  z-index: 2;
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  outline: none !important;
}

/* Additional overrides for any potential black ring */
.msg-donation-badge img,
.msg-donation-badge.is-legende-watermark img {
  background: transparent !important;
  border: none !important;
  border-radius: 50%;
  box-shadow: none !important;
}

/* Donation badge overlay on join/part announcement avatars (smaller, 22px avatar) */
.cht-system-event-avatar-wrap {
  position: relative;
  display: inline-block;
  flex: 0 0 22px;
  width: 22px;
  height: 22px;
}

.cht-system-event-avatar-wrap .cht-system-event-avatar {
  display: block;
  position: relative;
  z-index: 1;
}

.cht-system-event-donation-badge {
  position: absolute;
  bottom: -1px;
  right: -1px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  object-fit: contain;
  pointer-events: none;
  z-index: 2;
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  outline: none !important;
}

.cht .msg-avatar-wrap {
  position: relative;
  overflow: visible;
}

.cht .msg-avatar-wrap .avatar {
  position: relative;
  z-index: 1;
  display: block;
}

/* Glow effect for Legende tier messages - talk bubble only */
.cht.legende-tier .message-data {
  position: relative;
  border-radius: 8px;
  border: 2px solid rgba(245, 158, 11, 0.15);
}

@keyframes legende-glow-disabled {
  0% {
    border-color: rgba(245, 158, 11, 0.15);
    box-shadow:
      0 0 10px 2px rgba(245, 158, 11, 0.075),
      0 0 15px 4px rgba(245, 158, 11, 0.05);
  }
  100% {
    border-color: rgba(245, 158, 11, 0.2);
    box-shadow:
      0 0 12px 3px rgba(245, 158, 11, 0.1),
      0 0 18px 5px rgba(245, 158, 11, 0.06);
  }
}

.cht.legende-tier .msg-avatar-wrap {
  border: none;
  box-shadow: none;
}

/* Donation modal above navbar, white close on dark themes */
#chatDonationModal {
  z-index: 12100 !important;
}
.modal-backdrop.donation-modal-backdrop {
  z-index: 12090 !important;
}
html.theme-trueblue #chatDonationModal .btn-close,
html.theme-dark #chatDonationModal .btn-close {
  filter: invert(1) brightness(2);
}

/* True Blue theme specific donation modal styles */
html.theme-trueblue .chat-donation-modal .modal-content,
body.theme-trueblue .chat-donation-modal .modal-content,
.trueblue .chat-donation-modal .modal-content {
  border: 1px solid rgba(102, 171, 245, 0.4);
  background: radial-gradient(circle at top, #08285c, #061224 58%);
}

html.theme-trueblue .chat-donation-modal .modal-title,
body.theme-trueblue .chat-donation-modal .modal-title,
.trueblue .chat-donation-modal .modal-title {
  color: #eef7ff;
}

html.theme-trueblue .chat-donation-qr-wrap,
body.theme-trueblue .chat-donation-qr-wrap,
.trueblue .chat-donation-qr-wrap {
  background: linear-gradient(
    135deg,
    rgba(8, 40, 92, 0.15) 0%,
    rgba(16, 52, 94, 0.08) 100%
  ) !important;
  border: 1px solid rgba(102, 171, 245, 0.25);
}

html.theme-trueblue .chat-donation-shortcode,
body.theme-trueblue .chat-donation-shortcode,
.trueblue .chat-donation-shortcode {
  color: #66b3ff !important;
}

html.theme-trueblue .chat-donation-modal .col-md-5 > div,
body.theme-trueblue .chat-donation-modal .col-md-5 > div,
.trueblue .chat-donation-modal .col-md-5 > div {
  background: linear-gradient(
    135deg,
    rgba(8, 40, 92, 0.2) 0%,
    rgba(16, 52, 94, 0.1) 100%
  ) !important;
  border: 1px solid rgba(102, 171, 245, 0.35);
}

html.theme-trueblue
  .chat-donation-modal
  .col-md-5
  > div
  > div:first-of-type
  > div,
body.theme-trueblue
  .chat-donation-modal
  .col-md-5
  > div
  > div:first-of-type
  > div,
.trueblue .chat-donation-modal .col-md-5 > div > div:first-of-type > div {
  color: #66b3ff !important;
}

html.theme-trueblue .chat-donation-modal .col-md-5 .bg-white,
body.theme-trueblue .chat-donation-modal .col-md-5 .bg-white,
.trueblue .chat-donation-modal .col-md-5 .bg-white {
  background: rgba(8, 40, 92, 0.3) !important;
  border: 1px solid rgba(102, 171, 245, 0.2);
}

html.theme-trueblue .chat-donation-modal .col-md-5 .fw-bold,
body.theme-trueblue .chat-donation-modal .col-md-5 .fw-bold,
.trueblue .chat-donation-modal .col-md-5 .fw-bold {
  color: #eef7ff !important;
}

html.theme-trueblue .chat-donation-modal .col-md-5 .small.text-muted,
body.theme-trueblue .chat-donation-modal .col-md-5 .small.text-muted,
.trueblue .chat-donation-modal .col-md-5 .small.text-muted {
  color: rgba(170, 214, 255, 0.7) !important;
}

html.theme-trueblue .chat-donation-modal .btn-light,
body.theme-trueblue .chat-donation-modal .btn-light,
.trueblue .chat-donation-modal .btn-light {
  background: rgba(8, 40, 92, 0.5) !important;
  border-color: rgba(102, 171, 245, 0.4) !important;
  color: #eef7ff !important;
}

html.theme-trueblue .chat-donation-modal .btn-light:hover,
body.theme-trueblue .chat-donation-modal .btn-light:hover,
.trueblue .chat-donation-modal .btn-light:hover {
  background: rgba(16, 52, 94, 0.6) !important;
  border-color: rgba(102, 171, 245, 0.6) !important;
}

html.theme-trueblue .chat-donation-modal .btn-success,
body.theme-trueblue .chat-donation-modal .btn-success,
.trueblue .chat-donation-modal .btn-success {
  background: linear-gradient(135deg, #1e7fcc 0%, #3a9fd9 100%) !important;
  border-color: #66b3ff !important;
  color: #ffffff !important;
}

html.theme-trueblue .chat-donation-modal .btn-success:hover,
body.theme-trueblue .chat-donation-modal .btn-success:hover,
.trueblue .chat-donation-modal .btn-success:hover {
  background: linear-gradient(135deg, #2a8fd9 0%, #4ab0e8 100%) !important;
  border-color: #7cc3ff !important;
}

html.theme-trueblue .chat-donation-modal .modal-subtitle,
body.theme-trueblue .chat-donation-modal .modal-subtitle,
.trueblue .chat-donation-modal .modal-subtitle {
  color: rgba(170, 214, 255, 0.85) !important;
}

html.theme-trueblue .chat-donation-modal .badge,
body.theme-trueblue .chat-donation-modal .badge,
.trueblue .chat-donation-modal .badge {
  background: rgba(8, 40, 92, 0.5) !important;
  color: #66b3ff !important;
  border: 1px solid rgba(102, 171, 245, 0.4);
}

.chat-donation-modal .modal-content {
  border: 1px solid rgba(16, 185, 129, 0.35);
  background: radial-gradient(
    circle at top,
    rgba(6, 95, 70, 0.25),
    rgba(15, 23, 42, 0.98) 58%
  );
}

.chat-donation-modal .modal-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
}

.chat-donation-simple-tabs {
  border: 1px solid var(--bs-border-color, rgba(148, 163, 184, 0.35));
  border-radius: 10px;
  padding: 4px;
  background: var(--bs-body-bg, #ffffff);
  gap: 4px;
}

.chat-donation-simple-tabs .nav-link {
  border-radius: 8px;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--bs-body-color, #111827);
  border: 1px solid #cbd5e1;
  background: #f8fafc;
  box-shadow: 0 1px 2px rgba(2, 6, 23, 0.08);
  transition: all 0.18s ease;
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.chat-donation-simple-tabs .nav-link.active {
  border-color: color-mix(in srgb, var(--bs-primary, #0d6efd) 75%, #000 25%);
  background: linear-gradient(135deg, #0d6efd 0%, #0a58ca 100%);
  color: #fff;
  box-shadow: 0 3px 10px rgba(13, 110, 253, 0.35);
}

html.theme-trueblue .chat-donation-simple-tabs .nav-link.active,
body.theme-trueblue .chat-donation-simple-tabs .nav-link.active,
.trueblue .chat-donation-simple-tabs .nav-link.active {
  background: linear-gradient(135deg, #2f7ed8 0%, #4aa8ff 100%);
  color: #ffffff;
  box-shadow: 0 2px 8px rgba(74, 168, 255, 0.35);
}

html.theme-dark .chat-donation-simple-tabs .nav-link.active,
body.theme-dark .chat-donation-simple-tabs .nav-link.active,
.dark .chat-donation-simple-tabs .nav-link.active {
  background: linear-gradient(135deg, #2563eb 0%, #3b82f6 100%);
  color: #ffffff;
}

.chat-donation-simple-tabs .nav-link:hover {
  background: color-mix(
    in srgb,
    var(--bs-primary, #0d6efd) 16%,
    var(--bs-body-bg, #fff)
  );
  border-color: color-mix(
    in srgb,
    var(--bs-primary, #0d6efd) 40%,
    var(--bs-border-color, #94a3b8)
  );
  color: color-mix(
    in srgb,
    var(--bs-primary, #0d6efd) 70%,
    var(--bs-body-color, #111827)
  );
  transform: translateY(-1px);
}

.chat-donation-simple-card {
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 14px;
  background: var(--bs-body-bg, #ffffff);
}

.chat-donation-step-list {
  margin: 0;
  padding-left: 1rem;
  font-size: 0.88rem;
  line-height: 1.5;
}

.chat-donation-modal .btn-primary {
  border: 0;
  background: linear-gradient(135deg, #0d6efd 0%, #0a58ca 100%);
  color: #fff;
  font-weight: 600;
}

.chat-donation-modal .btn-primary:hover,
.chat-donation-modal .btn-primary:focus {
  background: linear-gradient(135deg, #0b5ed7 0%, #084298 100%);
  color: #fff;
}

.chat-donation-modal .btn-outline-primary {
  border-color: color-mix(in srgb, var(--bs-primary, #0d6efd) 55%, #94a3b8 45%);
  color: var(--bs-primary, #0d6efd);
  font-weight: 600;
}

.chat-donation-modal .btn-outline-primary:hover,
.chat-donation-modal .btn-outline-primary:focus {
  background: color-mix(in srgb, var(--bs-primary, #0d6efd) 88%, #000 12%);
  border-color: color-mix(in srgb, var(--bs-primary, #0d6efd) 92%, #000 8%);
  color: #fff;
}

.chat-donation-kv {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px dashed var(--bs-border-color, rgba(148, 163, 184, 0.35));
}

.chat-donation-kv:last-child {
  border-bottom: 0;
}

.chat-donation-info-tile {
  border: 1px solid #e2e8f0;
  background: var(--bs-body-bg, #ffffff);
}

.chat-donation-cost-card {
  border: 1px solid #e2e8f0;
  background: #f8fafc;
}

.chat-donation-impact-card {
  border: 1px solid #86efac;
  background: #f0fdf4;
}

html.theme-trueblue .chat-donation-simple-card,
body.theme-trueblue .chat-donation-simple-card,
.trueblue .chat-donation-simple-card {
  background: #0c1830;
  border-color: #3b82f6;
}

html.theme-dark .chat-donation-simple-card,
body.theme-dark .chat-donation-simple-card,
.dark .chat-donation-simple-card,
html.dark .chat-donation-simple-card,
body.dark .chat-donation-simple-card {
  background: #0f172a !important;
  border-color: #334155 !important;
}

html.theme-trueblue .chat-donation-simple-tabs,
body.theme-trueblue .chat-donation-simple-tabs,
.trueblue .chat-donation-simple-tabs {
  background: #0c1830;
  border-color: #3b82f6;
}

html.theme-trueblue .chat-donation-simple-tabs .nav-link,
body.theme-trueblue .chat-donation-simple-tabs .nav-link,
.trueblue .chat-donation-simple-tabs .nav-link {
  background: #0f2647;
  border-color: #3b82f6;
  color: #dceeff;
  box-shadow: 0 1px 2px rgba(3, 10, 24, 0.35);
}

html.theme-trueblue .chat-donation-simple-tabs .nav-link:hover,
body.theme-trueblue .chat-donation-simple-tabs .nav-link:hover,
.trueblue .chat-donation-simple-tabs .nav-link:hover {
  background: #194c88;
  border-color: #60a5fa;
  color: #ffffff;
}

html.theme-dark .chat-donation-simple-tabs .nav-link,
body.theme-dark .chat-donation-simple-tabs .nav-link,
.dark .chat-donation-simple-tabs .nav-link,
html.theme-trueblue .chat-donation-simple-tabs .nav-link,
body.theme-trueblue .chat-donation-simple-tabs .nav-link,
.trueblue .chat-donation-simple-tabs .nav-link {
  color: #e6edf7;
}

html.theme-dark .chat-donation-simple-tabs .nav-link,
body.theme-dark .chat-donation-simple-tabs .nav-link,
.dark .chat-donation-simple-tabs .nav-link {
  background: #1e293b;
  border-color: #475569;
  color: #e5edf8;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
}

html.theme-dark .chat-donation-simple-tabs .nav-link:hover,
body.theme-dark .chat-donation-simple-tabs .nav-link:hover,
.dark .chat-donation-simple-tabs .nav-link:hover {
  color: #ffffff;
  background: #3b82f6;
}
html.theme-trueblue .chat-donation-simple-tabs .nav-link:hover,
body.theme-trueblue .chat-donation-simple-tabs .nav-link:hover,
.trueblue .chat-donation-simple-tabs .nav-link:hover {
  color: #ffffff;
  background: #194c88;
}

html.theme-light .chat-donation-simple-tabs .nav-link,
body.theme-light .chat-donation-simple-tabs .nav-link,
.light .chat-donation-simple-tabs .nav-link {
  background: #ffffff;
  border-color: rgba(148, 163, 184, 0.45);
  color: #1e293b;
}

html.theme-light .chat-donation-simple-tabs .nav-link:hover,
body.theme-light .chat-donation-simple-tabs .nav-link:hover,
.light .chat-donation-simple-tabs .nav-link:hover {
  background: #eff6ff;
  border-color: rgba(59, 130, 246, 0.45);
  color: #1d4ed8;
}

/* Light theme - ensure no pure black text */
html.theme-light .chat-donation-simple-card,
body.theme-light .chat-donation-simple-card,
.light .chat-donation-simple-card {
  color: #334155;
}

html.theme-light .chat-donation-simple-card .fw-semibold,
body.theme-light .chat-donation-simple-card .fw-semibold,
.light .chat-donation-simple-card .fw-semibold,
html.theme-light .chat-donation-simple-card strong,
body.theme-light .chat-donation-simple-card strong,
.light .chat-donation-simple-card strong {
  color: #1e293b;
}

html.theme-light .chat-donation-simple-card code,
body.theme-light .chat-donation-simple-card code,
.light .chat-donation-simple-card code {
  color: #334155;
  background: rgba(148, 163, 184, 0.15) !important;
}

html.theme-dark .chat-donation-simple-card .text-muted,
body.theme-dark .chat-donation-simple-card .text-muted,
.dark .chat-donation-simple-card .text-muted,
html.theme-trueblue .chat-donation-simple-card .text-muted,
body.theme-trueblue .chat-donation-simple-card .text-muted,
.trueblue .chat-donation-simple-card .text-muted {
  color: rgba(217, 230, 247, 0.86) !important;
}

html.theme-dark .chat-donation-info-tile,
body.theme-dark .chat-donation-info-tile,
.dark .chat-donation-info-tile,
html.theme-trueblue .chat-donation-info-tile,
body.theme-trueblue .chat-donation-info-tile,
.trueblue .chat-donation-info-tile,
html.theme-dark .chat-donation-cost-card,
body.theme-dark .chat-donation-cost-card,
.dark .chat-donation-cost-card,
html.theme-trueblue .chat-donation-cost-card,
body.theme-trueblue .chat-donation-cost-card,
.trueblue .chat-donation-cost-card {
  background: rgba(15, 23, 42, 0.72) !important;
  border-color: rgba(102, 171, 245, 0.28) !important;
}

html.theme-dark .chat-donation-impact-card,
body.theme-dark .chat-donation-impact-card,
.dark .chat-donation-impact-card,
html.theme-trueblue .chat-donation-impact-card,
body.theme-trueblue .chat-donation-impact-card,
.trueblue .chat-donation-impact-card {
  background: rgba(8, 40, 92, 0.35) !important;
  border-color: rgba(102, 171, 245, 0.4) !important;
}

html.theme-dark .chat-donation-simple-card code,
body.theme-dark .chat-donation-simple-card code,
.dark .chat-donation-simple-card code,
html.theme-trueblue .chat-donation-simple-card code,
body.theme-trueblue .chat-donation-simple-card code,
.trueblue .chat-donation-simple-card code {
  color: #eaf2ff;
  background: rgba(15, 23, 42, 0.5) !important;
}

html.theme-dark .chat-donation-modal .btn-primary,
body.theme-dark .chat-donation-modal .btn-primary,
.dark .chat-donation-modal .btn-primary,
html.theme-trueblue .chat-donation-modal .btn-primary,
body.theme-trueblue .chat-donation-modal .btn-primary,
.trueblue .chat-donation-modal .btn-primary {
  background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
  color: #fff;
}

html.theme-dark .chat-donation-modal .btn-outline-primary,
body.theme-dark .chat-donation-modal .btn-outline-primary,
.dark .chat-donation-modal .btn-outline-primary,
html.theme-trueblue .chat-donation-modal .btn-outline-primary,
body.theme-trueblue .chat-donation-modal .btn-outline-primary,
.trueblue .chat-donation-modal .btn-outline-primary {
  border-color: rgba(102, 171, 245, 0.55);
  color: #aad6ff;
}

.chat-donation-qr-wrap {
  width: 100%;
  min-height: min(72vh, 680px);
  border-radius: 12px;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(2, 6, 23, 0.7);
  padding: 22px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
}

.chat-donation-qr-image {
  width: min(100%, 420px);
  max-height: min(62vh, 520px);
  object-fit: contain;
  border: 8px solid #fff;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 16px 36px rgba(2, 6, 23, 0.35);
}

.chat-donation-qr-hint {
  color: rgba(226, 232, 240, 0.94);
  font-size: 0.92rem;
  text-align: center;
}

/* Leave-room topbar buttons */
.leave-room-topbar-desktop,
.leave-room-topbar-mobile {
  color: #f87171;
  border-color: rgba(239, 68, 68, 0.35);
}
.leave-room-topbar-desktop:hover,
.leave-room-topbar-mobile:hover {
  color: #fca5a5;
  background-color: rgba(239, 68, 68, 0.13);
  border-color: rgba(239, 68, 68, 0.55);
}

/* Modern channel pill */
.top-channel-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 11px 5px 9px;
  border-radius: 10px;
  background: rgba(99, 102, 241, 0.07);
  border: 1px solid rgba(99, 102, 241, 0.18);
  cursor: default;
  max-width: 260px;
  min-width: 0;
  transition:
    background 0.15s ease,
    border-color 0.15s ease;
}
.top-channel-pill:hover {
  background: rgba(99, 102, 241, 0.13);
  border-color: rgba(99, 102, 241, 0.32);
}
.top-channel-icon {
  display: flex;
  align-items: center;
  color: #818cf8;
  font-size: 0.95rem;
  flex-shrink: 0;
}
.top-channel-name {
  font-size: 0.82rem;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 160px;
  letter-spacing: 0.01em;
}
.top-channel-count {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 0.65rem;
  font-weight: 600;
  color: #10b981;
  background: rgba(16, 185, 129, 0.1);
  border-radius: 20px;
  padding: 1px 6px;
  white-space: nowrap;
  flex-shrink: 0;
}
.top-channel-count::before {
  content: "";
  display: inline-block;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #10b981;
  animation: none;
}
@keyframes topbarOnlinePulse {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
    transform: scale(0.8);
  }
}
html.theme-light .top-channel-name {
  color: #1e293b;
}
html.theme-dark .top-channel-name,
html.theme-trueblue .top-channel-name {
  color: #e2e8f0;
}

.chat-donation-mobilepay-logo {
  height: 36px;
  width: auto;
  display: block;
}

.chat-donation-shortcode {
  font-size: clamp(1.6rem, 5vw, 2.4rem);
  font-weight: 900;
  letter-spacing: 0.08em;
  color: #5bc4f5;
  text-align: center;
  line-height: 1.1;
}

.chat-donation-shortcode-label {
  font-size: 0.82rem;
  color: rgba(203, 213, 225, 0.82);
  text-align: center;
  margin-top: 2px;
}

.chat-donation-link-status {
  min-height: 20px;
}

.topbar-forum-btn--mobile {
  margin-right: 8px;
  padding: 0 10px;
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  border-radius: 999px;
  font-size: 0.72rem;
  line-height: 1;
}

.topbar-forum-btn--mobile .ti {
  font-size: 0.9rem;
  margin-right: 0;
}

@media (min-width: 992px) {
  .topbar-forum-btn--mobile {
    display: none !important;
  }
}

.mobile-donation-trigger {
  background: linear-gradient(
    135deg,
    rgba(16, 185, 129, 0.15) 0%,
    rgba(34, 197, 94, 0.1) 100%
  );
  border: 1.5px solid rgba(16, 185, 129, 0.35);
  color: #10b981;
  transition: all 0.15s ease;
}

.mobile-donation-trigger:hover,
.mobile-donation-trigger:focus {
  background: linear-gradient(
    135deg,
    rgba(16, 185, 129, 0.25) 0%,
    rgba(34, 197, 94, 0.2) 100%
  );
  border-color: rgba(16, 185, 129, 0.6);
  color: #10b981;
  box-shadow: 0 0 8px rgba(16, 185, 129, 0.2);
}

.mobile-donation-trigger .ti {
  font-size: 1.1rem;
}

.mobile-bottom-nav {
  z-index: 1200;
}

.mobile-bottom-nav .nav-item.dropup {
  position: relative;
}

.mobile-bottom-nav .nav-item.dropup .dropdown-menu {
  z-index: 12060;
  margin-bottom: 8px;
}

/* Private Chat Compact User Header - Simple */
.private-user-compact {
  margin: 0 5px 10px;
  padding: 6px 0;
}
.private-user-compact-link {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: inherit;
}
.private-user-avatar-wrap {
  position: relative;
  flex-shrink: 0;
}
.private-user-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
}
.private-user-status-dot {
  position: absolute;
  bottom: 1px;
  right: 1px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 2px solid white;
}
.private-user-status-dot.online {
  background: #10b981;
}
.private-user-status-dot.offline {
  background: #94a3b8;
}
.private-user-info {
  flex: 1;
  min-width: 0;
}
.private-user-name {
  font-size: 0.9rem;
  font-weight: 600;
  margin: 0;
  color: var(--tblr-body-color, #334155);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ── Right-panel ad slideshow ──────────────────────────────── */
.rpanel-ad-slideshow {
  position: relative;
  width: calc(100% - 14px);
  margin: 7px 7px 4px;
  overflow: hidden;
  flex-shrink: 0;
  border-radius: 10px;
  border: 1px solid var(--bs-border-color, rgba(128, 128, 128, 0.18));
  background: transparent;
}

.rpanel-ad-track {
  display: flex;
  width: 100%;
  transition: transform 1.2s cubic-bezier(0.45, 0.1, 0.25, 1);
}

.rpanel-ad-slide {
  position: relative;
  flex: 0 0 100%;
  width: 100%;
  display: block;
  text-decoration: none;
  overflow: hidden;
  color: inherit;
}

/* Portrait crop: taller than wide */
.rpanel-ad-img-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 10 / 11;
  overflow: hidden;
  background: rgba(128, 128, 128, 0.12);
  border-radius: 9px;
}

.rpanel-ad-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  display: block;
}

.rpanel-ad-img--fallback {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: currentColor;
  opacity: 0.4;
  font-size: 2.5rem;
}

/* Annonce badge — top left */
.rpanel-ad-badge {
  position: absolute;
  top: 8px;
  left: 8px;
  background: rgba(0, 0, 0, 0.52);
  color: #fff;
  font-size: 0.6rem;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 999px;
  display: flex;
  align-items: center;
  gap: 3px;
  backdrop-filter: blur(6px);
  letter-spacing: 0.02em;
  z-index: 2;
}

/* Dots — top right */
.rpanel-ad-dots {
  position: absolute;
  top: 8px;
  right: 8px;
  display: flex;
  gap: 4px;
  pointer-events: none;
  z-index: 2;
}

.rpanel-ad-dot {
  width: 5px;
  height: 5px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.45);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.4);
  transition:
    background 0.3s,
    width 0.3s;
}

.rpanel-ad-dot.is-active {
  background: #fff;
  width: 14px;
}

/* Text overlay — bottom gradient */
.rpanel-ad-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 36px 10px 10px;
  background: linear-gradient(
    to top,
    rgba(0, 0, 0, 0.82) 0%,
    rgba(0, 0, 0, 0.45) 55%,
    transparent 100%
  );
  display: flex;
  flex-direction: column;
  gap: 3px;
  z-index: 1;
}

.rpanel-ad-overlay-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  min-width: 0;
}

.rpanel-ad-name {
  font-weight: 700;
  font-size: 0.82rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: #fff;
  min-width: 0;
}

.rpanel-ad-title {
  font-size: 0.72rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: rgba(255, 255, 255, 0.8);
  min-width: 0;
}

.rpanel-ad-meta-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 3px 8px;
  font-size: 0.68rem;
  color: rgba(255, 255, 255, 0.7);
  min-width: 0;
}

.rpanel-ad-meta-item {
  display: flex;
  align-items: center;
  gap: 2px;
  white-space: nowrap;
}

.rpanel-ad-cta {
  flex-shrink: 0;
  font-size: 0.65rem;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.5);
  color: #fff !important;
  white-space: nowrap;
  line-height: 1.5;
  touch-action: manipulation;
  backdrop-filter: blur(4px);
}

/* Full right-panel scroll: avoid nested scroll traps in members view. */
#main-room .page-content-wrapper .rightbar-wrapper {
  overflow-y: auto !important;
  overflow-x: auto !important;
  -webkit-overflow-scrolling: touch;
  touch-action: pan-y;
}

/* Private chat right-panel scroll: vertically scrollable on desktop and mobile */
.private-chat .rightbar-wrapper.private-right-panel {
  overflow-y: auto !important;
  overflow-x: hidden !important;
  -webkit-overflow-scrolling: touch;
  touch-action: pan-y;
  max-height: 100%;
}

.private-chat .rightbar-wrapper.private-right-panel .height-scroll-rpanelx {
  overflow: visible !important;
  min-height: 0;
}

#main-room .page-content-wrapper .rightbar-wrapper .user-list-panel {
  min-height: 0;
}

#main-room .page-content-wrapper .rightbar-wrapper .right-panel-members-section,
#main-room
  .page-content-wrapper
  .rightbar-wrapper
  .right-panel-members-section.active {
  display: block;
  overflow: visible !important;
  min-height: 0;
}

#main-room
  .page-content-wrapper
  .rightbar-wrapper
  .height-scroll-rpanelx.room-users-row,
#main-room
  .page-content-wrapper
  .rightbar-wrapper
  .height-scroll-rpanelx.group-users-row {
  display: block;
  overflow: visible !important;
  min-height: 0;
  padding: 0 0.35rem 0;
}

#main-room
  .page-content-wrapper
  .rightbar-wrapper
  .height-scroll-rpanelx.room-users-row
  .rpanel-ad-slideshow {
  margin-bottom: 0.35rem;
}

#main-room
  .page-content-wrapper
  .rightbar-wrapper
  .height-scroll-rpanelx.room-users-row
  .user-list-card,
#main-room
  .page-content-wrapper
  .rightbar-wrapper
  .height-scroll-rpanelx.group-users-row
  .user-list-card {
  display: block;
  height: auto !important;
  min-height: 0 !important;
  flex: 0 0 auto;
}

#main-room
  .page-content-wrapper
  .rightbar-wrapper
  .height-scroll-rpanelx.room-users-row
  .user-list-content,
#main-room
  .page-content-wrapper
  .rightbar-wrapper
  .height-scroll-rpanelx.room-users-row
  .room-users,
#main-room
  .page-content-wrapper
  .rightbar-wrapper
  .height-scroll-rpanelx.group-users-row
  .user-list-content,
#main-room
  .page-content-wrapper
  .rightbar-wrapper
  .height-scroll-rpanelx.group-users-row
  .group-users {
  overflow: visible !important;
  max-height: none !important;
  min-height: 0;
}

