:root {
  --bg: #313338;
  --bg-dark: #1e1f22;
  --panel: #2b2d31;
  --text: #f2f3f5;
  --muted: #b5bac1;
  --accent: #5865f2;
  --accent-h: #4752c4;
  --green: #23a55a;
  --red: #da373c;
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body {
  background: var(--bg);
  color: var(--text);
  font: 14.5px/1.4 "Segoe UI", system-ui, -apple-system, sans-serif;
  overflow: hidden;
}
.hidden { display: none !important; }
.muted { color: var(--muted); }

/* Discord Özel İnce Kaydırma Çubuğu */
* {
  scrollbar-width: thin;
  scrollbar-color: rgba(0, 0, 0, 0.4) transparent;
}
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, 0.4);
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(0, 0, 0, 0.65);
}

button {
  font: inherit; cursor: pointer; border: 0; color: inherit;
  transition: background .12s ease, transform .08s ease, color .12s ease;
}
button:active { transform: scale(0.98); }

input {
  font: inherit; color: var(--text); background: var(--bg-dark);
  border: 1px solid rgba(255, 255, 255, 0.08); border-radius: 8px;
  padding: 11px 14px; outline: none; width: 100%;
  transition: border-color .15s ease, box-shadow .15s ease;
}
input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px rgba(88, 101, 242, 0.25);
}

/* ---------- Kartlar (ana sayfa / giriş) */
.view { height: 100%; }
.center { display: grid; place-items: center; padding: 16px; }
.card {
  background: rgba(43, 45, 49, 0.95);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  padding: 36px 32px; border-radius: 16px; width: min(390px, 100%);
  display: flex; flex-direction: column; gap: 16px; text-align: center;
  box-shadow: 0 20px 60px rgba(0, 0, 0, .45);
  border: 1px solid rgba(255, 255, 255, 0.08);
}
.logo { margin: 0; font-size: 38px; font-weight: 800; letter-spacing: -1.2px; }
.logo span { color: var(--accent); }
.logo.small { font-size: 20px; letter-spacing: -0.5px; }
.primary {
  background: var(--accent); border-radius: 8px; padding: 10px 18px; font-weight: 600; color: #fff;
  transition: background .15s ease, box-shadow .15s ease, transform .08s ease;
}
.primary:hover {
  background: var(--accent-h);
  box-shadow: 0 4px 18px rgba(88, 101, 242, 0.45);
}
.big { padding: 13px; font-size: 15.5px; }
.ghost {
  background: transparent; padding: 8px 12px; border-radius: 8px;
  display: flex; align-items: center; gap: 6px; color: var(--muted);
  transition: background .12s, color .12s;
}
.ghost:hover { background: rgba(255, 255, 255, .07); color: var(--text); }
.warn {
  background: rgba(218, 55, 60, .14); border: 1px solid rgba(218, 55, 60, 0.5);
  border-radius: 8px; padding: 10px 14px; font-size: 13px; text-align: left;
}

/* ---------- Oda düzeni */
#view-room { display: flex; flex-direction: column; }
.topbar {
  display: flex; align-items: center; gap: 16px; padding: 10px 16px;
  background: var(--panel); border-bottom: 1px solid rgba(0, 0, 0, .3);
  flex-shrink: 0;
}
.room-info { flex: 1; color: var(--muted); font-size: 14px; }
.stage { flex: 1; display: flex; min-height: 0; min-width: 0; overflow: hidden; }

.stage-wrap {
  flex: 1; display: flex; flex-direction: column; min-height: 0; min-width: 0;
  height: 100%; overflow: hidden; position: relative;
}

/* Galeri modu (odak yokken) */
.grid {
  flex: 1; padding: 16px; display: flex; flex-wrap: wrap; gap: 14px;
  align-items: center; justify-content: center; align-content: center;
  overflow: auto; width: 100%; height: 100%; box-sizing: border-box;
}

/* Tek kişi olduğunda (Oda içi tek katılımcı düzeltmesi) */
.grid:has(.tile:only-child) {
  display: flex;
  align-items: center;
  justify-content: center;
}
.grid .tile:only-child,
.grid:has(.tile:only-child) .tile {
  flex: 0 1 840px !important;
  width: 100% !important;
  max-width: min(840px, 94%) !important;
  max-height: min(520px, calc(100% - 24px)) !important;
  aspect-ratio: 16 / 9;
  margin: auto !important;
}

/* Odak modu (ekran paylaşımı veya odaklanmış katılımcı) */
.focus-layout {
  flex: 1; display: flex; flex-direction: column; min-height: 0; min-width: 0;
  height: 100%; overflow: hidden;
}

.focus-stage {
  flex: 1; min-height: 0; min-width: 0; display: flex; align-items: center; justify-content: center;
  padding: 10px 14px 4px; position: relative; overflow: hidden;
}

.focus-stage .tile {
  width: 100%; height: 100%; max-width: 100%; max-height: 100%;
  aspect-ratio: auto; min-height: 0; min-width: 0; border-radius: 12px;
}

/* Filmstrip (alttaki katılımcı çubuğu) */
.filmstrip {
  height: 124px; min-height: 124px; max-height: 124px;
  display: flex; gap: 10px; padding: 4px 14px 10px;
  overflow-x: auto; overflow-y: hidden; flex-shrink: 0;
  align-items: center; justify-content: center;
}
.filmstrip:empty { display: none !important; }

.filmstrip .tile {
  height: 100%; width: auto; aspect-ratio: 16 / 9; flex-shrink: 0;
  cursor: pointer; border-radius: 10px;
}
.filmstrip .tile video { object-fit: cover !important; }
.filmstrip .tile .avatar span { width: 48px; height: 48px; font-size: 22px; }

/* ---------- Kutucuklar */
.tile {
  position: relative; background: var(--bg-dark); border-radius: 12px; overflow: hidden;
  aspect-ratio: 16 / 9; cursor: pointer; min-height: 0; min-width: 0;
  display: flex; align-items: center; justify-content: center;
  flex: 1 1 360px;
  max-width: 680px;
  max-height: calc(100% - 20px);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

/* Yeşil Konuşma Çerçevesi — Titremesiz, net ve sabit (Discord stili) */
.tile .speaking-ring {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  border: 2.5px solid transparent;
  pointer-events: none;
  z-index: 10;
  transition: border-color 0.12s ease;
}
.tile.speaking .speaking-ring {
  border-color: #23a55a !important;
  box-shadow: none !important;
}
.tile.speaking .avatar span {
  box-shadow: 0 0 0 3px #23a55a;
}

.tile video { width: 100%; height: 100%; object-fit: cover; display: block; background: #000; }
.tile:not(.has-video) video { display: none; }
.tile.mirror video { transform: scaleX(-1); }

/* Ekran paylaşımı varsayılan: içeriğin tamamını ekrana sığdır (contain) */
.tile.screen video { object-fit: contain; }
.focus-stage .tile video { object-fit: contain; }

/* Ekrana tam doldurma modu (cover - siyah kenar istemeyenler için) */
.tile.fill-mode video, .focus-stage .tile.fill-mode video { object-fit: cover !important; }
.tile:fullscreen video { object-fit: contain; }

.tile .avatar { position: absolute; inset: 0; display: grid; place-items: center; pointer-events: none; }
.tile.has-video .avatar { display: none; }
.tile .avatar span {
  width: 84px; height: 84px; border-radius: 50%; display: grid; place-items: center;
  font-size: 36px; font-weight: 700; color: #fff; transition: box-shadow .15s ease, transform .15s ease;
  overflow: hidden; position: relative; background-color: var(--accent); user-select: none;
}
.tile .avatar span img {
  width: 100%; height: 100%; object-fit: cover; border-radius: 50%; display: block;
}
.focus-stage .tile .avatar span {
  width: 120px; height: 120px; font-size: 48px;
}

/* Kutucuk içi buton grubu (sağ üst) */
.tile .tile-actions {
  position: absolute;
  top: 8px;
  right: 8px;
  display: flex;
  align-items: center;
  gap: 6px;
  z-index: 12;
  opacity: 0;
  transition: opacity 0.15s ease;
  pointer-events: none;
}
.tile:hover .tile-actions,
.tile .tile-actions:focus-within {
  opacity: 1;
  pointer-events: auto;
}
@media (hover: none) {
  .tile .tile-actions {
    opacity: 1;
    pointer-events: auto;
  }
}

.tile .action-btn {
  width: 28px;
  height: 28px;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.65);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #dbdee1;
  cursor: pointer;
  border: 0;
  backdrop-filter: blur(8px);
  transition: background 0.12s ease, color 0.12s ease, transform 0.1s ease;
  padding: 0;
  flex-shrink: 0;
}
.tile .action-btn svg {
  width: 15px;
  height: 15px;
  display: block;
}
.tile .action-btn:hover {
  background: rgba(0, 0, 0, 0.9);
  color: #fff;
  transform: scale(1.06);
}
.tile .action-btn:active {
  transform: scale(0.96);
}
.tile .action-btn.active {
  background: var(--accent);
  color: #fff;
}

/* 1. unfocus-btn (✕): SADECE odaklanmış (focus) modda görünür, normal galeride gizlidir */
.tile .action-btn.unfocus-btn {
  display: none !important;
}
.tile.focus .action-btn.unfocus-btn,
.focus-stage .tile .action-btn.unfocus-btn {
  display: inline-flex !important;
}
.tile .action-btn.unfocus-btn:hover {
  background: rgba(218, 55, 60, 0.85);
  color: #fff;
}

/* 2. fit-btn: SADECE kamera veya ekran yayını (has-video) varken görünür */
.tile .action-btn.fit-btn {
  display: none !important;
}
.tile.has-video .action-btn.fit-btn {
  display: inline-flex !important;
}

/* 3. fs-btn (Tam ekran): SADECE video yayını veya odak modunda görünür */
.tile:not(.has-video):not(.focus) .action-btn.fs-btn {
  display: none !important;
}

.tile .label {
  position: absolute; left: 8px; bottom: 8px; max-width: calc(100% - 16px);
  background: rgba(0, 0, 0, .65); padding: 3px 8px; border-radius: 6px; font-size: 13px;
  display: flex; gap: 4px; align-items: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  z-index: 11; backdrop-filter: blur(4px);
}
.tile .label svg { width: 16px; height: 16px; color: var(--red); }
.tile .mic-off { display: none; }
.tile.muted .mic-off { display: inline-flex; }
.tile.connecting::after {
  content: "bağlanıyor…"; position: absolute; top: 8px; left: 8px; font-size: 12px;
  background: rgba(0, 0, 0, .6); padding: 2px 8px; border-radius: 6px; color: var(--muted);
  z-index: 11;
}

/* ---------- Sohbet */
.chat { width: 320px; background: var(--panel); display: flex; flex-direction: column; border-left: 1px solid rgba(0, 0, 0, .3); }
.chat-head { padding: 12px 16px; font-weight: 600; border-bottom: 1px solid rgba(0, 0, 0, .3); }
.chat-log { flex: 1; overflow-y: auto; padding: 12px 16px; display: flex; flex-direction: column; gap: 10px; }
.chat-form { padding: 12px; }
.msg-head { display: flex; gap: 8px; align-items: baseline; }
.msg-head .time { font-size: 11px; color: var(--muted); }
.msg-body { word-wrap: break-word; white-space: pre-wrap; }
.msg-body a { color: #00a8fc; }
.msg.sys { color: var(--muted); font-size: 13px; font-style: italic; }

/* ---------- Kontroller */
.controls { display: flex; justify-content: center; gap: 12px; padding: 12px; background: var(--bg-dark); }
.ctl {
  position: relative; width: 52px; height: 52px; border-radius: 50%;
  background: #383a40; display: grid; place-items: center; transition: background .12s;
}
.ctl:hover { background: #4e5058; }
.ctl.off { background: rgba(218, 55, 60, .25); color: #ff8a8d; }
.ctl.active { background: var(--green); }
.ctl.danger { background: var(--red); width: 64px; border-radius: 26px; }
.ctl.danger:hover { background: #a12d2f; }
.ic { display: inline-flex; }
.badge {
  position: absolute; top: -2px; right: -2px; min-width: 20px; height: 20px; padding: 0 5px;
  border-radius: 10px; background: var(--red); font-size: 12px; font-weight: 700; display: grid; place-items: center;
}

/* ---------- Bildirim */
.toast {
  position: fixed; left: 50%; bottom: 96px; transform: translateX(-50%) translateY(20px);
  background: #111214; padding: 10px 16px; border-radius: 8px; opacity: 0; pointer-events: none;
  transition: opacity .2s, transform .2s; box-shadow: 0 6px 20px rgba(0, 0, 0, .4); z-index: 10;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

@media (max-width: 720px) {
  .chat { position: fixed; inset: 0 0 76px 0; width: auto; z-index: 5; }
  .grid { grid-template-columns: 1fr; padding: 8px; }
  .topbar .ghost { font-size: 0; gap: 0; }
}

/* ================================================================ v2: menüler, ayarlar */

/* Etiketteki durum ikonları */
.tile .st { display: none; }
.tile.muted .st-mic, .tile.deaf .st-deaf, .tile.local-muted .st-lmute { display: inline-flex; }
.tile .st-lmute svg { color: #f0b232; }
.tile .vol-tag { font-size: 11px; color: var(--muted); }

/* Popover & Kullanıcı Profil Menüsü */
.pop {
  position: fixed; z-index: 50; width: 260px; background: #18191c; border-radius: 12px; padding: 12px;
  display: flex; flex-direction: column; gap: 8px; box-shadow: 0 12px 36px rgba(0, 0, 0, .65);
  border: 1px solid rgba(255, 255, 255, .08);
}
.pop-header {
  display: flex; align-items: center; gap: 10px; padding-bottom: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, .08);
}
.pop-header-info { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.pop-title {
  font-size: 14px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.pop-sub { font-size: 11px; }
.pop-close {
  background: transparent; padding: 2px 6px; font-size: 14px; color: var(--muted); cursor: pointer; border-radius: 4px;
}
.pop-close:hover { background: rgba(255, 255, 255, .08); color: var(--text); }
.pop-section { display: flex; flex-direction: column; gap: 6px; }
.pop-divider { height: 1px; background: rgba(255, 255, 255, .06); margin: 2px 0; }
.mini-btn-text { font-size: 12px; padding: 4px; justify-content: center; width: 100%; }

.pop-actions { display: flex; flex-direction: column; gap: 3px; }
.pop-action-btn {
  display: flex; align-items: center; gap: 10px; padding: 7px 10px; border-radius: 6px;
  background: transparent; color: #dbdee1; font-size: 13px; font-weight: 500;
  cursor: pointer; transition: background .12s, color .12s; text-align: left;
}
.pop-action-btn:hover {
  background: rgba(88, 101, 242, .18); color: #fff;
}
.pop-action-btn.danger-act:hover {
  background: rgba(218, 55, 60, .2); color: #ff8a8d;
}
.pop-action-btn.is-active {
  background: rgba(88, 101, 242, .25); color: #fff; font-weight: 600;
}
.pop-action-btn.is-active.danger-act {
  background: rgba(218, 55, 60, .25); color: #ff8a8d;
}
.act-icon { font-size: 15px; }

.row { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.check { display: flex; align-items: center; gap: 8px; cursor: pointer; padding: 3px 0; }
.check input { width: 16px; height: 16px; accent-color: var(--accent); margin: 0; }

input[type=range] { padding: 0; width: 100%; accent-color: var(--accent); background: transparent; border: 0; }

select {
  font: inherit; color: var(--text); background: var(--bg-dark); border: 1px solid transparent;
  border-radius: 8px; padding: 9px 10px; width: 100%; outline: none;
}
select:focus { border-color: var(--accent); }

/* Ayarlar penceresi & Modallar */
.modal {
  position: fixed; inset: 0; z-index: 9000;
  background: rgba(0, 0, 0, .72);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  display: grid; place-items: center; padding: 16px;
}
@keyframes modalPop {
  0% { opacity: 0; transform: scale(0.96) translateY(-8px); }
  100% { opacity: 1; transform: scale(1) translateY(0); }
}
.modal:not(.hidden) .modal-card {
  animation: modalPop 0.16s cubic-bezier(0.18, 0.89, 0.32, 1.28) forwards;
}
.modal-card {
  background: var(--panel); border-radius: 14px; width: min(520px, 100%); max-height: 90vh;
  display: flex; flex-direction: column; box-shadow: 0 24px 64px rgba(0, 0, 0, .6);
  border: 1px solid rgba(255, 255, 255, 0.08);
}
.modal-head { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; border-bottom: 1px solid rgba(0, 0, 0, .3); }
.modal-head h2 { margin: 0; font-size: 18px; }
.x { background: transparent; font-size: 18px; color: var(--muted); padding: 4px 8px; border-radius: 6px; }
.x:hover { background: rgba(255, 255, 255, .08); color: var(--text); }
.modal-body { padding: 4px 20px 20px; overflow-y: auto; display: flex; flex-direction: column; gap: 10px; }
.modal-body h3 { margin: 14px 0 0; font-size: 12px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.field { display: flex; flex-direction: column; gap: 6px; font-size: 14px; }
.modal-body small { font-size: 12px; line-height: 1.35; }

.seg {
  display: flex; background: #1e1f22; border-radius: 8px; padding: 4px;
  border: 1px solid rgba(255, 255, 255, 0.08); gap: 4px;
}
.seg button {
  flex: 1; padding: 9px 12px; border-radius: 6px; background: transparent;
  color: #949ba4; font-weight: 600; font-size: 13.5px; transition: all .15s ease;
}
.seg button:hover { color: #dbdee1; background: rgba(255, 255, 255, 0.04); }
.seg button.on {
  background: var(--accent); color: #fff; box-shadow: 0 2px 8px rgba(88, 101, 242, 0.4);
}
#vad-box, #ptt-box { display: flex; flex-direction: column; gap: 8px; }

.meter { position: relative; height: 10px; border-radius: 5px; background: var(--bg-dark); overflow: hidden; }
.meter > div:first-child { position: absolute; inset: 0 auto 0 0; width: 0; background: #80848e; transition: width .05s linear; }
.meter > div.hot { background: var(--green); }
#meter-thr { position: absolute; top: 0; bottom: 0; width: 2px; background: #f0b232; }

.keycap {
  background: #1e1f22; border: 1px solid #4e5058; border-bottom-width: 3px; border-radius: 6px;
  padding: 7px 16px; min-width: 100px; font-family: Consolas, monospace; font-weight: 700;
  font-size: 13px; color: #dbdee1; cursor: pointer; display: inline-flex; align-items: center;
  justify-content: center; transition: all .12s ease;
}
.keycap:hover { background: #2b2d31; border-color: #6d6f78; }
.keycap.listening {
  border-color: var(--accent); color: var(--accent);
  box-shadow: 0 0 10px rgba(88, 101, 242, 0.4);
  animation: pulseKey 1s infinite alternate;
}
@keyframes pulseKey {
  0% { transform: scale(1); }
  100% { transform: scale(1.03); }
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: 100%;
  box-sizing: border-box;
}
.auth-form .field {
  width: 100%;
}
.auth-form button[type="submit"] {
  width: 100%;
  margin-top: 6px;
}

/* ================================================================ v3: Discord Arayüzü & Topluluklar */

/* Karşılama Sayfası */
.home-topbar {
  position: absolute; top: 0; left: 0; right: 0; height: 64px;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 32px; z-index: 10;
}
.auth-bar { display: flex; align-items: center; gap: 12px; }
.auth-chip {
  display: flex; align-items: center; gap: 10px; background: var(--panel);
  padding: 6px 14px; border-radius: 20px; font-size: 14px; cursor: pointer;
  border: 1px solid rgba(255, 255, 255, .08); transition: background .15s;
}
.auth-chip:hover { background: #383a40; }
.highlight-btn {
  background: var(--accent); color: #fff;
  box-shadow: 0 0 16px rgba(88, 101, 242, 0.45); font-weight: 700;
}
.highlight-btn:hover {
  background: var(--accent-h); box-shadow: 0 0 22px rgba(88, 101, 242, 0.7);
}
.secondary { background: #4e5058; border-radius: 8px; padding: 10px 16px; font-weight: 600; color: #fff; }
.secondary:hover { background: #6d6f78; }

/* Discord Ana Düzeni */
.discord-layout {
  display: flex; width: 100vw; height: 100vh; overflow: hidden; background: var(--bg);
}

/* 1. Sol Sunucu Şeridi (Rail) */
.server-rail {
  width: 72px; background: #1e1f22; display: flex; flex-direction: column;
  align-items: center; padding: 12px 0; gap: 8px; flex-shrink: 0; z-index: 5;
}
.rail-separator { width: 32px; height: 2px; background: #35363c; border-radius: 1px; margin: 4px 0; }
.rail-servers { display: flex; flex-direction: column; gap: 8px; overflow-y: auto; overflow-x: hidden; width: 100%; align-items: center; }

.rail-item {
  position: relative; width: 48px; height: 48px; border-radius: 24px;
  background: #313338; color: #dbdee1; display: grid; place-items: center;
  font-weight: 700; font-size: 17px; transition: border-radius .2s cubic-bezier(0.2, 0, 0, 1), background .2s, color .2s;
  cursor: pointer; overflow: visible; user-select: none; flex-shrink: 0;
}
.rail-item::before {
  content: '';
  position: absolute;
  left: -12px;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 0;
  background: #fff;
  border-radius: 0 4px 4px 0;
  transition: height 0.2s cubic-bezier(0.2, 0, 0, 1);
  pointer-events: none;
}
.rail-item:hover::before { height: 20px; }
.rail-item.active::before { height: 40px; }
.rail-item:hover, .rail-item.active {
  border-radius: 16px; background: var(--accent); color: #fff;
}
.rail-item.home-item { background: #313338; font-size: 20px; }
.rail-item.home-item:hover, .rail-item.home-item.active { background: var(--green); }
.rail-item.action-item { background: #313338; color: var(--green); font-size: 22px; }
.rail-item.action-item:hover { background: var(--green); color: #fff; }
.rail-badge { display: grid; place-items: center; }

/* 2. Kanal Kenar Çubuğu */
.channel-sidebar {
  width: 248px; background: #2b2d31; display: flex; flex-direction: column;
  flex-shrink: 0; border-right: 1px solid rgba(0, 0, 0, .2); z-index: 4;
  height: 100%; max-height: 100vh; overflow: hidden; position: relative;
}
.server-header {
  height: 48px; padding: 0 12px 0 16px; display: flex; align-items: center; justify-content: space-between;
  border-bottom: 1px solid rgba(0, 0, 0, .25); box-shadow: 0 1px 2px rgba(0, 0, 0, .2);
  gap: 8px; flex-shrink: 0;
}
.server-header h2 {
  margin: 0; font-size: 15px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  flex: 1; min-width: 0;
}
.server-header-actions { display: flex; align-items: center; gap: 3px; flex-shrink: 0; }
.mini-btn {
  background: transparent; width: 28px; height: 28px; border-radius: 4px; font-size: 14px; color: var(--muted);
  display: inline-flex; align-items: center; justify-content: center; padding: 0; cursor: pointer; border: none;
  transition: all .12s ease;
}
.mini-btn:hover { background: rgba(255, 255, 255, .08); color: var(--text); }

.channels-list {
  flex: 1; min-height: 0; overflow-y: auto; overflow-x: hidden;
  padding: 12px 8px 74px 8px !important; display: flex; flex-direction: column; gap: 16px;
}
.channel-category { display: flex; flex-direction: column; gap: 3px; }
.cat-label {
  font-size: 11px; font-weight: 700; letter-spacing: .04em; color: #949ba4;
  padding: 4px 8px; user-select: none;
}
.channel-group { display: flex; flex-direction: column; gap: 2px; }

.channel-item {
  display: flex; align-items: center; gap: 8px; padding: 7px 10px; border-radius: 6px;
  color: #949ba4; font-size: 14px; font-weight: 500; cursor: pointer; transition: background .1s, color .1s;
}
.channel-item:hover { background: rgba(255, 255, 255, .05); color: #dbdee1; }
.channel-item.active { background: rgba(255, 255, 255, .1); color: #fff; font-weight: 600; }
.channel-item.voice-connected { color: var(--green); font-weight: 600; }
.channel-icon { font-size: 17px; opacity: .8; }

/* Aktif Ses Dock'u (Kullanıcı Paneli Üstünde Sabit Katman) */
.voice-dock {
  position: absolute;
  bottom: 54px;
  left: 0;
  right: 0;
  background: rgba(35, 36, 40, 0.96);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  padding: 8px 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 -3px 10px rgba(0, 0, 0, 0.35);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
  z-index: 29;
  box-sizing: border-box;
}
.voice-dock-info { display: flex; align-items: center; gap: 10px; }
.voice-wave { font-size: 18px; }
.voice-status-text { font-size: 13px; font-weight: 700; color: var(--green); }
.voice-dock-btn {
  width: 32px; height: 32px; border-radius: 6px; display: grid; place-items: center;
  background: var(--red); color: #fff; font-size: 14px;
}
.voice-dock-btn:hover { background: #b82a2e; }

/* Kullanıcı Dock'u (Z-Index Olarak En Üst Katmanda, Kayan Kanalların Üzerinde) */
.user-dock {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 54px;
  background: rgba(35, 36, 40, 0.94);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  padding: 0 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.45);
  gap: 6px;
  flex-shrink: 0;
  z-index: 30; /* Z-index olarak kanalların üstünde süzülsün */
  box-sizing: border-box;
}

/* Ses bağlıyken kanal ve DM listesine ekstra alt boşluk */
.channel-sidebar:has(#voice-connected-dock:not(.hidden)) .channels-list,
.channel-sidebar:has(#voice-connected-dock:not(.hidden)) .dm-category {
  padding-bottom: 128px !important;
}
.user-dock-profile {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 6px;
  border-radius: 6px;
  cursor: pointer;
  min-width: 0;
  flex: 1; /* sidebara doğru tam genişlesin */
  overflow: hidden;
  transition: background .12s ease;
}
.user-dock-profile:hover { background: rgba(255, 255, 255, .08); }
.user-dock-names { display: flex; flex-direction: column; min-width: 0; flex: 1; overflow: hidden; }
.user-dock-names b {
  font-size: 14px; font-weight: 600; color: #f2f3f5;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; line-height: 1.25;
}
.user-dock-names small {
  font-size: 11.5px; color: #949ba4;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; line-height: 1.2;
}

.user-dock-controls { display: flex; gap: 3px; align-items: center; flex-shrink: 0; }
.dock-ctl {
  width: 32px; height: 32px; border-radius: 5px; background: transparent;
  display: inline-flex; align-items: center; justify-content: center; color: var(--muted);
  border: none; cursor: pointer; padding: 0; transition: background .12s, color .12s;
}
.dock-ctl .ic { display: inline-flex; align-items: center; justify-content: center; width: 100%; height: 100%; }
.dock-ctl .ic svg { width: 19px; height: 19px; display: block; }
.dock-ctl:hover { background: rgba(255, 255, 255, .08); color: var(--text); }
.dock-ctl.off { color: #f23f43; }
.dock-ctl.off:hover { background: rgba(242, 63, 67, .15); }
.dock-ctl.danger-ctl { font-size: 16px; }
.dock-ctl.danger-ctl:hover { background: rgba(218, 55, 60, .2); color: var(--red); }

/* Ses Kanalına Bağlı Kullanıcılar */
.channel-voice-users {
  display: flex; flex-direction: column; gap: 2px; padding: 2px 0 6px 18px;
}
.channel-voice-users:empty { display: none; }
.voice-user-item {
  display: flex; align-items: center; gap: 8px; padding: 3px 6px; border-radius: 4px;
  font-size: 12.5px; color: #dbdee1; transition: background .1s;
}
.voice-user-item:hover { background: rgba(255, 255, 255, .05); }
.voice-user-avatar {
  width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center;
  font-size: 10px; font-weight: 700; color: #fff; overflow: hidden; flex-shrink: 0;
}
.voice-user-avatar img { width: 100%; height: 100%; object-fit: cover; }
.voice-user-name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; flex: 1; }
.voice-user-icons { display: flex; gap: 4px; font-size: 11px; color: var(--muted); }

/* 3. Ana Bölüm (Discord Main) */
.discord-main {
  flex: 1; display: flex; flex-direction: column; background: #313338; min-width: 0; min-height: 0; position: relative;
}
.channel-topbar {
  height: 48px; padding: 0 16px; display: flex; align-items: center; gap: 10px;
  border-bottom: 1px solid rgba(0, 0, 0, .2); flex-shrink: 0; box-shadow: 0 1px 2px rgba(0, 0, 0, .2);
  min-width: 0; overflow: hidden;
}
.chan-hash { font-size: 18px; color: var(--muted); font-weight: 700; flex-shrink: 0; }
.channel-topbar h3 { margin: 0; font-size: 15px; font-weight: 700; white-space: nowrap; flex-shrink: 0; }
.chan-divider { color: rgba(255, 255, 255, .15); flex-shrink: 0; }
.chan-topic { font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }

.channel-pane { flex: 1; display: flex; flex-direction: column; min-height: 0; }

/* Metin Sohbet Akışı (Discord Stili) */
.server-chat-log {
  flex: 1;
  overflow-y: auto;
  padding: 16px 16px 12px 16px;
  display: flex;
  flex-direction: column;
  gap: 0;
}
.server-msg {
  position: relative;
  display: flex;
  padding: 2px 16px 2px 16px;
  margin: 0 -16px;
  line-height: 1.4;
  transition: background-color 0.08s ease;
}
.server-msg:hover {
  background-color: rgba(255, 255, 255, 0.045);
}
.server-msg.full {
  margin-top: 14px;
  padding-top: 4px;
  padding-bottom: 2px;
}
.server-msg.full:first-child {
  margin-top: 0;
}
.server-msg.stacked {
  margin-top: 0;
  min-height: 22px;
}

/* Full avatar & body */
.server-msg .msg-avatar-wrap {
  width: 40px;
  height: 40px;
  margin-right: 14px;
  flex-shrink: 0;
}
.server-msg-body {
  flex: 1;
  min-width: 0;
}
.server-msg-head {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 3px;
}
.server-msg-head b {
  font-size: 14.5px;
  font-weight: 600;
}
.server-msg-head .time {
  font-size: 11px;
  color: var(--muted, #949ba4);
}

/* Stacked gutter with hover-only timestamp */
.server-msg.stacked .msg-gutter {
  width: 40px;
  margin-right: 14px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  user-select: none;
}
.server-msg.stacked .stacked-time {
  font-size: 10px;
  color: #949ba4;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.1s ease;
  font-variant-numeric: tabular-nums;
}
.server-msg.stacked:hover .stacked-time {
  opacity: 0.75;
  visibility: visible;
}

/* Message text & links */
.server-msg-text {
  word-wrap: break-word;
  white-space: pre-wrap;
  font-size: 14.5px;
  color: #dbdee1;
}
.server-msg-text a {
  color: #00a8fc;
  text-decoration: none;
}
.server-msg-text a:hover {
  text-decoration: underline;
}
.edited-badge {
  font-size: 10px;
  color: #949ba4;
  margin-left: 5px;
  user-select: none;
}

/* Action Bar on Message Hover (top right) */
.msg-actions-bar {
  position: absolute;
  top: -14px;
  right: 20px;
  display: none;
  align-items: center;
  background: #313338;
  border: 1px solid #232428;
  border-radius: 6px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.4);
  z-index: 10;
  overflow: hidden;
}
.server-msg:hover .msg-actions-bar {
  display: flex;
}
.msg-action-btn {
  background: transparent;
  border: 0;
  color: #b5bac1;
  padding: 5px 9px;
  cursor: pointer;
  font-size: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  transition: background-color 0.1s, color 0.1s;
}
.msg-action-btn:hover {
  background: #3b3e45;
  color: #fff;
}
.msg-action-btn.delete-btn:hover {
  background: #da373c;
  color: #fff;
}

/* Shift key held down -> Instant Delete indicator */
body.shift-down .msg-action-btn.delete-btn {
  background: rgba(218, 55, 60, 0.25);
  color: #ff7878;
}
body.shift-down .msg-action-btn.delete-btn:hover {
  background: #da373c;
  color: #fff;
}
body.shift-down .msg-action-btn.delete-btn::after {
  content: " (Hızlı Sil)";
  font-size: 10px;
  font-weight: 700;
}

/* Inline edit form */
.msg-edit-form {
  margin-top: 4px;
  width: 100%;
}
.msg-edit-textarea {
  width: 100%;
  background: #383a40;
  border: 1px solid #4e5058;
  border-radius: 6px;
  padding: 8px 12px;
  color: #dbdee1;
  font-family: inherit;
  font-size: 14.5px;
  line-height: 1.4;
  resize: none;
  box-sizing: border-box;
  outline: none;
}
.msg-edit-textarea:focus {
  border-color: #5865f2;
}
.msg-edit-hint {
  font-size: 11px;
  color: #949ba4;
  margin-top: 4px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.msg-edit-hint span {
  color: #00a8fc;
  cursor: pointer;
}
.msg-edit-hint span:hover {
  text-decoration: underline;
}

.server-msg-text.jumboji {
  font-size: 38px !important;
  line-height: 1.25 !important;
  display: block;
}

/* Attachments in Chat */
.server-msg-attachment {
  margin-top: 6px;
  margin-bottom: 2px;
}
.server-msg-img-wrap {
  display: inline-block;
  max-width: 440px;
  max-height: 320px;
  border-radius: 8px;
  overflow: hidden;
  background: #1e1f22;
  border: 1px solid rgba(255, 255, 255, 0.08);
  cursor: zoom-in;
  transition: transform 0.12s ease;
}
.server-msg-img-wrap:hover {
  transform: scale(1.01);
}
.server-msg-img-wrap img {
  max-width: 100%;
  max-height: 320px;
  object-fit: contain;
  display: block;
}

/* Voice message player */
.server-msg-voice-card {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background: #2b2d31;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 8px 14px;
  min-width: 250px;
  max-width: 360px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}
.voice-play-btn {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #5865f2;
  border: 0;
  color: #fff;
  font-size: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.15s, transform 0.1s;
}
.voice-play-btn:hover {
  background: #4752c4;
  transform: scale(1.05);
}
.voice-play-btn:active {
  transform: scale(0.95);
}
.voice-player-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.voice-waveform-bar {
  width: 100%;
  height: 16px;
  display: flex;
  align-items: center;
  gap: 2px;
  cursor: pointer;
}
.voice-bar-item {
  flex: 1;
  background: #4e5058;
  border-radius: 2px;
  height: 40%;
  transition: height 0.1s, background 0.1s;
}
.voice-bar-item.played {
  background: #5865f2;
}
.voice-player-meta {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: #949ba4;
  font-variant-numeric: tabular-nums;
}

/* Discord Chat Form Bar */
.discord-chat-form {
  padding: 0 16px 20px;
  flex-shrink: 0;
  position: relative;
}
.discord-chat-bar {
  background: #383a40;
  border-radius: 8px;
  display: flex;
  align-items: center;
  padding: 0 12px;
  gap: 8px;
  min-height: 44px;
}
.discord-chat-bar input {
  flex: 1;
  background: transparent;
  border: 0;
  padding: 11px 0;
  color: #dbdee1;
  font-size: 14.5px;
  outline: none;
}
.discord-chat-bar input::placeholder {
  color: #80848e;
}
.chat-action-btn {
  background: transparent;
  border: 0;
  color: #b5bac1;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: color 0.1s, background-color 0.1s;
  flex-shrink: 0;
}
.chat-action-btn:hover {
  color: #dbdee1;
  background: rgba(255, 255, 255, 0.08);
}
.chat-action-btn.btn-gif {
  font-weight: 800;
  font-size: 11px;
  letter-spacing: 0.5px;
  border-radius: 4px;
  width: auto;
  padding: 4px 6px;
}
.chat-bar-right-actions {
  display: flex;
  align-items: center;
  gap: 4px;
}

/* Attachment preview above chat input */
.chat-attachment-box {
  background: #2b2d31;
  border-radius: 8px 8px 0 0;
  padding: 10px 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  display: flex;
  align-items: center;
  gap: 12px;
}
.chat-attachment-thumb {
  width: 48px;
  height: 48px;
  border-radius: 6px;
  object-fit: cover;
  background: #1e1f22;
}
.chat-attachment-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}
.chat-attachment-name {
  font-size: 13px;
  font-weight: 600;
  color: #f2f3f5;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.chat-attachment-size {
  font-size: 11px;
  color: #949ba4;
}
.chat-attachment-remove {
  background: transparent;
  border: 0;
  color: #949ba4;
  font-size: 16px;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 4px;
}
.chat-attachment-remove:hover {
  color: #da373c;
  background: rgba(218, 55, 60, 0.1);
}

/* Live Voice Recording Bar */
.voice-record-bar {
  background: #2b2d31;
  border-radius: 8px;
  padding: 8px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 6px;
  border: 1px solid #da373c;
  animation: pulse-border 1.5s infinite;
}
@keyframes pulse-border {
  0% { border-color: rgba(218, 55, 60, 0.4); }
  50% { border-color: rgba(218, 55, 60, 1); }
  100% { border-color: rgba(218, 55, 60, 0.4); }
}
.voice-rec-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #da373c;
  animation: rec-blink 1s infinite alternate;
}
@keyframes rec-blink {
  from { opacity: 0.3; }
  to { opacity: 1; }
}
.voice-rec-timer {
  font-weight: 700;
  font-size: 14px;
  color: #da373c;
  font-variant-numeric: tabular-nums;
}
.voice-rec-label {
  flex: 1;
  font-size: 13px;
  color: #dbdee1;
}
.voice-rec-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}
.btn-voice-cancel {
  background: #3b3e45;
  border: 0;
  color: #dbdee1;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  transition: background 0.15s, transform 0.1s;
}
.btn-voice-cancel:hover {
  background: #da373c;
  color: #fff;
  transform: scale(1.08);
}
.btn-voice-send {
  background: #23a55a;
  border: 0;
  color: #fff;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  transition: background 0.15s, transform 0.1s;
}
.btn-voice-send:hover {
  background: #1b8547;
  transform: scale(1.08);
}
.chat-action-btn.btn-voice-rec.recording {
  color: #da373c !important;
  animation: rec-blink 1s infinite alternate;
}

/* GIF Picker Modal / Popover */
.gif-picker-card {
  width: 480px;
  max-width: 92vw;
  height: 520px;
  background: #2b2d31;
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.08);
}
.gif-picker-header {
  padding: 12px 14px;
  background: #1e1f22;
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.gif-search-box {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 8px;
  background: #383a40;
  padding: 6px 12px;
  border-radius: 6px;
}
.gif-search-ic {
  font-size: 14px;
}
.gif-search-box input {
  flex: 1;
  background: transparent;
  border: 0;
  color: #dbdee1;
  font-size: 13px;
  outline: none;
}
.gif-categories {
  padding: 8px 12px;
  display: flex;
  gap: 6px;
  overflow-x: auto;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  background: #232428;
}
.gif-categories::-webkit-scrollbar {
  height: 4px;
}
.gif-cat-pill {
  white-space: nowrap;
  background: #313338;
  border: 0;
  color: #b5bac1;
  padding: 5px 10px;
  border-radius: 12px;
  font-size: 12px;
  cursor: pointer;
  transition: all 0.12s;
}
.gif-cat-pill:hover, .gif-cat-pill.active {
  background: #5865f2;
  color: #fff;
}
.gif-grid {
  flex: 1;
  overflow-y: auto;
  padding: 10px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 8px;
}
.gif-grid::-webkit-scrollbar {
  width: 6px;
}
.gif-item {
  width: 100%;
  height: 110px;
  border-radius: 6px;
  overflow: hidden;
  cursor: pointer;
  background: #1e1f22;
  position: relative;
  transition: transform 0.1s, box-shadow 0.1s;
}
.gif-item:hover {
  transform: scale(1.03);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
  z-index: 2;
}
.gif-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Lightbox Modal */
.modal-lightbox {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
}
.modal-lightbox.hidden {
  display: none;
}
.lightbox-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(4px);
}
.lightbox-content {
  position: relative;
  z-index: 2;
  max-width: 90vw;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.lightbox-content img {
  max-width: 90vw;
  max-height: 82vh;
  object-fit: contain;
  border-radius: 8px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.6);
}
.lightbox-toolbar {
  margin-top: 12px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.lightbox-btn {
  background: #313338;
  color: #dbdee1;
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 6px 14px;
  border-radius: 6px;
  font-size: 13px;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s;
}
.lightbox-btn:hover {
  background: #3b3e45;
  color: #fff;
}
.lightbox-btn.close {
  background: #da373c;
  color: #fff;
  border: 0;
}
.lightbox-btn.close:hover {
  background: #b82d32;
}

/* Ses Sahnesi Barındırıcı */
.app-stage-host {
  flex: 1; display: flex; flex-direction: column; min-height: 0; min-width: 0; position: relative;
}

/* 4. Sağ Üye Kenar Çubuğu */
.member-sidebar {
  width: 240px; background: #2b2d31; display: flex; flex-direction: column;
  flex-shrink: 0; border-left: 1px solid rgba(0, 0, 0, .2); padding: 16px 12px;
}
.member-sidebar-head {
  font-size: 11px; font-weight: 700; letter-spacing: .04em; color: #949ba4;
  margin-bottom: 10px; user-select: none;
}
.members-list { flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: 4px; }
.member-row {
  display: flex; align-items: center; gap: 10px; padding: 6px 8px; border-radius: 6px;
  cursor: pointer; transition: background .1s;
}
.member-row:hover { background: rgba(255, 255, 255, .06); }
.member-name { font-size: 14px; font-weight: 500; color: #dbdee1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.member-role-badge { font-size: 13px; }

/* Avatarlar & Durum İkonları */
.user-avatar-wrap { position: relative; width: 34px; height: 34px; flex-shrink: 0; }
.avatar-circle {
  width: 100%; height: 100%; border-radius: 50%; display: grid; place-items: center;
  font-weight: 700; font-size: 15px; color: #fff; background-size: cover; background-position: center;
  background-color: var(--accent); user-select: none; overflow: hidden;
}
.avatar-circle.big { width: 72px; height: 72px; font-size: 30px; }
.avatar-circle img { width: 100%; height: 100%; object-fit: cover; }

.status-dot {
  position: absolute; right: -1px; bottom: -1px; width: 11px; height: 11px;
  border-radius: 50%; border: 2px solid #232428; background: #80848e;
}
.status-dot.online { background: var(--green); }

/* Avatar Seçici */
.avatar-picker { display: flex; align-items: center; gap: 18px; padding: 10px 0; }
.avatar-picker-controls { display: flex; flex-direction: column; gap: 8px; }

/* Kanal Türü Seçici */
.channel-type-selector { display: flex; flex-direction: column; gap: 8px; margin-top: 6px; }
.type-opt {
  display: flex; align-items: center; gap: 12px; background: var(--bg-dark);
  padding: 10px 14px; border-radius: 8px; cursor: pointer; border: 1px solid transparent;
}
.type-opt:has(input:checked) { border-color: var(--accent); background: rgba(88, 101, 242, .08); }
.type-opt input { width: 18px; height: 18px; margin: 0; accent-color: var(--accent); }

.danger-text { color: var(--red) !important; }

/* ================================================================ Sunucu Ayarları Modalı */
.modal-card-wide {
  max-width: 820px; width: 94vw; max-height: 88vh; display: flex; flex-direction: column;
  overflow: hidden; box-sizing: border-box;
}
.server-settings-layout {
  display: flex; gap: 20px; flex: 1; min-height: 0; padding: 16px 20px 20px;
  overflow: hidden; box-sizing: border-box;
}
.server-settings-tabs {
  width: 195px; display: flex; flex-direction: column; gap: 6px;
  border-right: 1px solid rgba(255, 255, 255, .08); padding-right: 14px; flex-shrink: 0;
  overflow-y: auto; overflow-x: hidden;
}
.srv-tab-btn {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 9px 12px; border-radius: 6px; background: transparent; color: #b5bac1;
  font-size: 13.5px; font-weight: 600; text-align: left; cursor: pointer; transition: background .12s, color .12s;
}
.srv-tab-btn:hover { background: rgba(255, 255, 255, .05); color: #dbdee1; }
.srv-tab-btn.active { background: rgba(255, 255, 255, .1); color: #fff; }
.srv-tab-btn.danger-tab:hover, .srv-tab-btn.danger-tab.active { color: var(--red); }
.tab-badge {
  font-size: 11px; background: rgba(255, 255, 255, .14); color: #fff; padding: 2px 7px;
  border-radius: 10px; font-weight: 700; display: inline-block;
}

.server-settings-content {
  flex: 1; min-width: 0; display: flex; flex-direction: column; overflow: hidden;
}
.srv-pane {
  display: none; flex-direction: column; gap: 14px; height: 100%;
  overflow-y: auto; overflow-x: hidden; padding-right: 6px; box-sizing: border-box; width: 100%;
}
.srv-pane.active { display: flex; }
.pane-title { margin: 0 0 4px 0; font-size: 16px; font-weight: 700; color: #fff; }
.pane-header-row {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 8px;
}
.mini-search {
  max-width: 180px; padding: 6px 10px; background: var(--bg-dark); border: 1px solid rgba(255, 255, 255, .1);
  border-radius: 6px; font-size: 13px; color: #fff;
}

/* Genel Bakış İkonu */
.srvset-icon-row { display: flex; align-items: center; gap: 16px; margin-bottom: 12px; }
.srvset-icon-controls { flex: 1; }

.info-card {
  background: var(--bg-dark); border-radius: 8px; padding: 12px 16px;
  display: flex; flex-direction: column; gap: 8px; border: 1px solid rgba(255, 255, 255, .05);
  margin-bottom: 12px;
}
.info-row { display: flex; justify-content: space-between; font-size: 13.5px; }

.invite-code-group {
  display: flex; gap: 8px; margin-top: 4px;
}
.invite-code-group input {
  flex: 1; background: var(--bg-dark); border: 1px solid rgba(255, 255, 255, .1);
  border-radius: 6px; padding: 8px 12px; font-family: monospace; font-size: 14px;
}

/* Üyeler Tablosu (Kim ne zaman katıldı) */
.srv-members-table, .srv-bans-table {
  display: flex; flex-direction: column; gap: 6px; overflow-y: auto; max-height: 380px;
}
.srv-member-card, .srv-ban-card {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 10px 12px; background: rgba(0, 0, 0, .18); border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, .04); transition: background .12s;
}
.srv-member-card:hover, .srv-ban-card:hover { background: rgba(255, 255, 255, .03); }
.srv-member-left { display: flex; align-items: center; gap: 12px; min-width: 0; }
.srv-member-info { display: flex; flex-direction: column; min-width: 0; }
.srv-member-title { display: flex; align-items: center; gap: 6px; }
.srv-member-name { font-size: 14px; font-weight: 600; color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.srv-role-tag {
  font-size: 10.5px; font-weight: 700; padding: 2px 6px; border-radius: 4px; text-transform: uppercase;
}
.srv-role-tag.owner { background: #e09f24; color: #111; }
.srv-role-tag.member { background: rgba(255, 255, 255, .12); color: #dbdee1; }
.srv-member-joined { font-size: 12px; color: var(--muted); }

.srv-member-actions { display: flex; gap: 6px; }
.btn-kick, .btn-ban, .btn-unban {
  padding: 5px 10px; border-radius: 5px; font-size: 12px; font-weight: 600; cursor: pointer;
}
.btn-kick { background: rgba(255, 255, 255, .08); color: #dbdee1; }
.btn-kick:hover { background: rgba(240, 178, 50, .2); color: #f0b232; }
.btn-ban { background: rgba(218, 55, 60, .15); color: #ff787b; }
.btn-ban:hover { background: var(--red); color: #fff; }
.btn-unban { background: rgba(35, 165, 89, .15); color: #57f287; }
.btn-unban:hover { background: var(--green); color: #fff; }

/* Yasak Kartı */
.ban-reason-text { font-size: 12px; color: #f0b232; margin-top: 2px; }
.ban-meta-text { font-size: 11px; color: var(--muted); }

/* Tehlikeli Bölge */
.danger-box {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 14px 18px; border: 1px solid rgba(218, 55, 60, .35); border-radius: 8px;
  background: rgba(218, 55, 60, .06); margin-bottom: 12px;
  box-sizing: border-box; width: 100%;
}
.danger-box-info { flex: 1; min-width: 0; }
.danger-box-info b { font-size: 14.5px; color: #ff787b; display: block; }
.danger-box-info p { margin: 4px 0 0 0; font-size: 12.5px; color: var(--muted); line-height: 1.4; }
.danger-fill {
  background: var(--red); color: #fff; font-weight: 600; padding: 9px 18px; border-radius: 6px;
  cursor: pointer; white-space: nowrap; flex-shrink: 0; min-width: fit-content; border: none;
  font-size: 13.5px; transition: background .12s ease, transform .08s ease;
}
.danger-fill:hover { background: #b82a2e; }

/* ================================================================ Kullanıcı Ayarları Modalı */
.user-settings-card {
  max-width: 820px;
  width: 94vw;
  min-height: 520px;
}
.user-settings-tabs {
  width: 205px;
}
.userset-tab-btn {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 6px;
  background: transparent;
  color: #b5bac1;
  font-size: 13.5px;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
  transition: background .12s, color .12s;
}
.userset-tab-btn:hover {
  background: rgba(255, 255, 255, .06);
  color: #dbdee1;
}
.userset-tab-btn.active {
  background: rgba(255, 255, 255, .1);
  color: #fff;
}
.profile-banner-card {
  background: linear-gradient(135deg, rgba(88, 101, 242, 0.22) 0%, rgba(35, 165, 90, 0.16) 100%), #1e1f22;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 20px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
}
.profile-banner-head {
  display: flex;
  align-items: center;
  gap: 18px;
}
.profile-banner-info {
  display: flex;
  flex-direction: column;
  gap: 6px;
  position: relative;
}
.profile-banner-name {
  font-size: 22px;
  font-weight: 700;
  color: #fff;
}
.profile-tag {
  display: inline-flex;
  align-items: center;
  font-size: 11.5px;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 12px;
  background: rgba(35, 165, 90, 0.18);
  color: #57f287;
  border: 1px solid rgba(35, 165, 90, 0.4);
  width: fit-content;
}

/* ================================================================ Rol Sistemi & Özel Odalar */
.custom-role-badge {
  display: inline-flex;
  align-items: center;
  font-size: 10.5px;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 4px;
  border: 1px solid currentColor;
  white-space: nowrap;
  line-height: 1.3;
  margin-left: 4px;
}

.chan-roles-box {
  margin-top: 10px;
  padding: 10px 12px;
  background: var(--bg-dark);
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, .06);
}
.chan-roles-hint {
  font-size: 11px;
  font-weight: 700;
  color: var(--muted);
  display: block;
  margin-bottom: 8px;
  letter-spacing: .03em;
}
.roles-selector-checklist {
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-height: 140px;
  overflow-y: auto;
}
.role-checkbox-opt {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: #dbdee1;
  cursor: pointer;
  padding: 4px 6px;
  border-radius: 4px;
}
.role-checkbox-opt:hover {
  background: rgba(255, 255, 255, .04);
}
.role-checkbox-opt input {
  accent-color: var(--accent);
  width: 16px;
  height: 16px;
}

/* Kanal Öğeleri & Düzenle Butonu */
.channel-item {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.chan-item-left {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  flex: 1;
}
.chan-item-name {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.chan-lock-icon {
  font-size: 12px;
  opacity: .85;
}
.chan-edit-btn {
  display: none;
  background: transparent;
  border: none;
  color: var(--muted);
  cursor: pointer;
  padding: 2px 5px;
  border-radius: 4px;
  font-size: 13px;
  margin-left: auto;
  flex-shrink: 0;
}
.channel-item:hover .chan-edit-btn {
  display: inline-flex;
}
.chan-edit-btn:hover {
  color: #fff;
  background: rgba(255, 255, 255, .1);
}

/* Rol Yöneticisi Arayüzü */
.roles-manager-layout {
  display: flex;
  gap: 16px;
  height: 100%;
  min-height: 400px;
}
.roles-sidebar {
  width: 200px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  border-right: 1px solid rgba(255, 255, 255, .08);
  padding-right: 12px;
  flex-shrink: 0;
}
.roles-sidebar-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11px;
  font-weight: 700;
  color: #949ba4;
  letter-spacing: .04em;
}
.roles-nav-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
  overflow-y: auto;
  flex: 1;
}
.role-nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 6px;
  cursor: pointer;
  color: #dbdee1;
  font-size: 13.5px;
  font-weight: 500;
  transition: background .12s, color .12s;
}
.role-nav-item:hover {
  background: rgba(255, 255, 255, .06);
  color: #fff;
}
.role-nav-item.active {
  background: rgba(255, 255, 255, .12);
  color: #fff;
  font-weight: 600;
}
.role-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  flex-shrink: 0;
}
.role-editor-pane {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  padding-left: 6px;
}
.roles-empty-state {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  text-align: center;
  font-size: 14px;
  padding: 40px 20px;
}
.role-edit-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.role-color-picker-row {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 6px;
}
.role-color-native-input {
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 8px;
  background: transparent;
  cursor: pointer;
  padding: 0;
}
.role-color-hex {
  font-family: monospace;
  font-size: 13px;
  color: #dbdee1;
  font-weight: 600;
}
.role-color-presets {
  display: flex;
  gap: 6px;
  align-items: center;
}
.color-preset-circle {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 2px solid transparent;
  cursor: pointer;
  padding: 0;
  transition: transform .12s, border-color .12s;
}
.color-preset-circle:hover {
  transform: scale(1.2);
  border-color: #fff;
}
.role-perms-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 6px;
}
.perm-checkbox-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 10px 14px;
  background: var(--bg-dark);
  border-radius: 8px;
  cursor: pointer;
  border: 1px solid rgba(255, 255, 255, .05);
  transition: background .12s;
}
.perm-checkbox-row:hover {
  background: rgba(255, 255, 255, .04);
}
.perm-checkbox-row input {
  width: 18px;
  height: 18px;
  margin-top: 2px;
  accent-color: var(--accent);
}
.perm-checkbox-row b {
  font-size: 13.5px;
  color: #fff;
  display: block;
}
.perm-checkbox-row p {
  margin: 3px 0 0 0;
  font-size: 12px;
  line-height: 1.4;
}
.role-editor-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid rgba(255, 255, 255, .08);
}

/* Üye Listesi & Roller */
.srv-member-roles-list {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 4px;
}
.srv-member-role-pill {
  font-size: 10.5px;
  font-weight: 600;
  padding: 1px 7px;
  border-radius: 10px;
  background: rgba(255, 255, 255, .08);
  color: #dbdee1;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.srv-member-role-pill .role-pill-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
}
.srv-member-role-pill .remove-role-btn {
  background: transparent;
  border: none;
  color: var(--muted);
  cursor: pointer;
  font-size: 11px;
  padding: 0 2px;
  line-height: 1;
}
.srv-member-role-pill .remove-role-btn:hover {
  color: #fff;
}
.btn-assign-role {
  padding: 2px 8px;
  font-size: 11px;
  border-radius: 10px;
  background: rgba(88, 101, 242, .15);
  color: #5865f2;
  border: 1px dashed rgba(88, 101, 242, .4);
  cursor: pointer;
  font-weight: 600;
}
.btn-assign-role:hover {
  background: rgba(88, 101, 242, .3);
  color: #fff;
}

/* Popover Roller Bölümü */
.pop-roles-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  min-height: 24px;
}
.pop-role-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 2px 8px;
  border-radius: 12px;
  background: rgba(255, 255, 255, .08);
  font-size: 11.5px;
  font-weight: 600;
}
.pop-role-chip .role-dot {
  width: 8px;
  height: 8px;
}
.pop-role-remove-btn {
  background: transparent;
  border: none;
  cursor: pointer;
  color: var(--muted);
  padding: 0;
  font-size: 12px;
  line-height: 1;
}
.pop-role-remove-btn:hover {
  color: var(--red);
}
.pop-role-picker-row {
  display: flex;
  gap: 6px;
  margin-top: 8px;
  align-items: center;
}
.pop-role-select {
  flex: 1;
  background: var(--bg-dark);
  border: 1px solid rgba(255, 255, 255, .1);
  border-radius: 6px;
  padding: 5px 8px;
  font-size: 12px;
  color: #fff;
}

/* Üye Kenar Çubuğu Rol Başlıkları */
.member-role-group-header {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .04em;
  color: #949ba4;
  padding: 10px 8px 4px 8px;
  text-transform: uppercase;
  user-select: none;
}

/* ========================================================== Home / Arkadaşlar / DM / Özel Arama */
.rail-item {
  position: relative;
}
.rail-notification-badge {
  position: absolute;
  top: -2px;
  right: -2px;
  background: var(--red);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  min-width: 18px;
  height: 18px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  padding: 0 4px;
  border: 2px solid var(--bg-rail);
  box-shadow: 0 2px 5px rgba(0,0,0,0.4);
}

.sidebar-subview {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  overflow: hidden;
}
.home-sidebar-header {
  padding: 14px 16px;
  border-bottom: 1px solid rgba(0,0,0,0.2);
  display: flex;
  align-items: center;
  height: 48px;
}
.home-header-title {
  font-weight: 700;
  font-size: 15px;
  color: #fff;
}
.home-nav-group {
  padding: 10px 8px;
}
.home-nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 10px 12px;
  border-radius: 6px;
  background: transparent;
  border: none;
  color: var(--muted);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all .15s ease;
  text-align: left;
}
.home-nav-item:hover {
  background: rgba(255,255,255,0.06);
  color: #dbdee1;
}
.home-nav-item.active {
  background: rgba(255,255,255,0.1);
  color: #fff;
}
.home-nav-icon {
  font-size: 18px;
}
.home-nav-text {
  flex: 1;
}
.badge-count {
  background: var(--red);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 10px;
}
.dm-category {
  padding: 0 8px 24px 8px;
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
}
.dm-category-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 8px 4px 8px;
}
.mini-btn-ghost {
  background: transparent;
  border: none;
  color: var(--muted);
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 4px;
}
.mini-btn-ghost:hover {
  color: #fff;
  background: rgba(255,255,255,0.1);
}
.dm-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 6px;
  cursor: pointer;
  color: var(--muted);
  transition: all .15s ease;
  position: relative;
  user-select: none;
}
.dm-item:hover {
  background: rgba(255,255,255,0.05);
  color: #dbdee1;
}
.dm-item.active {
  background: rgba(255,255,255,0.1);
  color: #fff;
}
.dm-item-names {
  flex: 1;
  min-width: 0;
}
.dm-item-username {
  font-weight: 600;
  font-size: 14px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: block;
}
.dm-item-lastmsg {
  font-size: 11px;
  color: #949ba4;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: block;
}
.dm-item-close {
  display: none;
  background: transparent;
  border: none;
  color: var(--muted);
  font-size: 13px;
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 4px;
}
.dm-item:hover .dm-item-close {
  display: inline-block;
}
.dm-item-close:hover {
  color: #fff;
}

/* Arkadaşlar Paneli & Sekmeler */
.friends-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  height: 48px;
  border-bottom: 1px solid rgba(0,0,0,0.2);
}
.friends-topbar-left {
  display: flex;
  align-items: center;
  gap: 12px;
}
.friends-head-icon {
  font-size: 20px;
}
.friends-tabs {
  display: flex;
  align-items: center;
  gap: 8px;
}
.friends-tab {
  background: transparent;
  border: none;
  color: var(--muted);
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all .15s ease;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.friends-tab:hover {
  background: rgba(255,255,255,0.06);
  color: #dbdee1;
}
.friends-tab.on {
  background: rgba(255,255,255,0.12);
  color: #fff;
}
.friends-tab.add-btn {
  background: #23a55a;
  color: #fff;
}
.friends-tab.add-btn:hover {
  background: #1f9450;
}
.friends-tab.add-btn.on {
  background: transparent;
  color: #23a55a;
  border: 1px solid #23a55a;
}
.friends-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  padding: 20px 24px;
}
.friends-search-wrap {
  margin-bottom: 16px;
}
.friends-search-wrap input {
  width: 100%;
  background: var(--bg-dark);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 6px;
  padding: 9px 14px;
  color: #fff;
  font-size: 14px;
  outline: none;
}
.friends-search-wrap input:focus {
  border-color: var(--accent);
}
.friends-list-header {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .03em;
  color: #949ba4;
  margin-bottom: 10px;
  text-transform: uppercase;
}
.friends-list-items {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.friend-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  border-radius: 8px;
  border-top: 1px solid rgba(255,255,255,0.04);
  transition: background .15s ease;
}
.friend-row:hover {
  background: rgba(255,255,255,0.05);
}
.friend-row-left {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}
.friend-row-info {
  display: flex;
  flex-direction: column;
}
.friend-row-name {
  font-weight: 600;
  font-size: 15px;
  color: #fff;
}
.friend-row-status {
  font-size: 12px;
  color: #949ba4;
}
.friend-row-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}
.friend-act-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: var(--bg-surface);
  color: var(--muted);
  display: grid;
  place-items: center;
  font-size: 16px;
  cursor: pointer;
  transition: all .15s ease;
}
.friend-act-btn:hover {
  background: rgba(255,255,255,0.12);
  color: #fff;
}
.friend-act-btn.call-btn:hover {
  background: #23a55a;
  color: #fff;
}
.friend-act-btn.remove-btn:hover {
  background: var(--red);
  color: #fff;
}

/* Bekleyen İstekler */
.pending-section-head {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .03em;
  color: #949ba4;
  margin-bottom: 8px;
}
.pending-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.pending-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  border-radius: 8px;
  border-top: 1px solid rgba(255,255,255,0.04);
  transition: background .15s ease;
}
.pending-item:hover {
  background: rgba(255,255,255,0.05);
}
.pending-item-left {
  display: flex;
  align-items: center;
  gap: 12px;
}
.pending-item-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}
.btn-req-accept {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: rgba(35, 165, 90, 0.15);
  color: #23a55a;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: all .15s ease;
}
.btn-req-accept:hover {
  background: #23a55a;
  color: #fff;
}
.btn-req-reject {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: rgba(242, 63, 67, 0.15);
  color: #f23f43;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: all .15s ease;
}
.btn-req-reject:hover {
  background: #f23f43;
  color: #fff;
}

/* Arkadaş Ekle Kartı */
.add-friend-card {
  max-width: 600px;
}
.add-friend-card h2 {
  font-size: 17px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 6px;
}
.add-friend-input-box {
  display: flex;
  align-items: center;
  background: var(--bg-dark);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 8px;
  padding: 4px 6px 4px 14px;
  margin-top: 14px;
  transition: border-color .15s ease;
}
.add-friend-input-box:focus-within {
  border-color: var(--accent);
}
.add-friend-input-box input {
  flex: 1;
  background: transparent;
  border: none;
  color: #fff;
  font-size: 14px;
  outline: none;
}
.add-friend-status {
  margin-top: 10px;
  font-size: 13px;
  padding: 8px 12px;
  border-radius: 6px;
}
.add-friend-status.success {
  background: rgba(35, 165, 90, 0.15);
  color: #23a55a;
}
.add-friend-status.error {
  background: rgba(242, 63, 67, 0.15);
  color: #f23f43;
}

/* DM Başlığı & Butonlar */
.dm-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
}
.dm-topbar-info {
  display: flex;
  align-items: center;
  gap: 10px;
}
.dm-status-text {
  font-size: 12px;
}
.dm-topbar-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}
.mini-btn-topbar {
  background: transparent;
  border: none;
  font-size: 18px;
  padding: 6px 8px;
  border-radius: 6px;
  cursor: pointer;
  color: var(--muted);
  transition: all .15s ease;
}
.mini-btn-topbar:hover {
  background: rgba(255,255,255,0.1);
  color: #fff;
}

/* Discord Tarzı DM Görüşme Üst Sahnesi (Video/Ses Üstte, Sohbet Altta) */
.dm-call-stage-host {
  position: relative;
  width: 100%;
  height: 380px;
  min-height: 240px;
  max-height: 48vh;
  flex-shrink: 0;
  background: #111214;
  border-bottom: 2px solid rgba(0, 0, 0, 0.45);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.dm-call-stage-host.hidden {
  display: none !important;
}

.dm-call-stage-host .stage-wrap {
  flex: 1;
  width: 100%;
  height: 100%;
  min-height: 0;
}

.dm-call-stage-host .grid {
  padding: 12px 14px;
  gap: 12px;
  height: 100%;
  width: 100%;
  align-items: center;
  justify-content: center;
}

.dm-call-stage-host .grid .tile {
  max-height: calc(100% - 24px);
  aspect-ratio: 16 / 9;
}

/* DM Sahnesi Kontrolleri (Discord stili altta yüzen kontrol hapı) */
.dm-call-stage-host .controls {
  position: absolute;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 25;
  background: rgba(30, 31, 35, 0.94);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  padding: 6px 14px;
  border-radius: 28px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  gap: 10px;
}

.dm-call-stage-host .controls #btn-chat {
  display: none !important;
}

.dm-call-stage-host .controls .ctl {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.dm-calling-overlay {
  position: absolute;
  top: 14px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 26;
  background: rgba(17, 18, 20, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  padding: 6px 16px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.1);
  pointer-events: none;
  display: flex;
  align-items: center;
  gap: 8px;
}

.call-pulse-ic {
  display: inline-block;
  animation: pulseCall 1.2s infinite ease-in-out;
}
@keyframes pulseCall {
  0% { transform: scale(1); }
  50% { transform: scale(1.2); }
  100% { transform: scale(1); }
}

/* Discord Tarzı Kayan & Sürüklenebilir Mini Ses/Video Ekranı (Picture-in-Picture) */
.voice-pip-overlay {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 320px;
  height: 220px;
  background: #111214;
  border-radius: 12px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.75), 0 0 0 1px rgba(255, 255, 255, 0.12);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  z-index: 1000;
  touch-action: none;
  user-select: none;
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.2s ease;
}

.voice-pip-overlay.is-dragging {
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.9), 0 0 0 2px var(--accent);
  transition: none !important;
  cursor: grabbing !important;
}

.voice-pip-overlay.is-dragging * {
  cursor: grabbing !important;
  pointer-events: none !important;
}

.voice-pip-overlay.hidden {
  display: none !important;
}

.voice-pip-header {
  height: 34px;
  background: #1e1f22;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 10px;
  cursor: grab;
  user-select: none;
  flex-shrink: 0;
}

.voice-pip-header:active {
  cursor: grabbing;
}

.voice-pip-title {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  color: #f2f3f5;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  pointer-events: none;
}

.voice-pip-title .voice-pip-icon {
  font-size: 13px;
  color: var(--green);
}

.voice-pip-header-actions {
  display: flex;
  align-items: center;
  gap: 4px;
}

.pip-action-btn {
  background: transparent;
  border: none;
  color: #b5bac1;
  font-size: 14px;
  padding: 2px 6px;
  border-radius: 4px;
  cursor: pointer;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease, color 0.15s ease, opacity 0.15s ease;
}

.pip-action-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

.pip-close-btn {
  font-size: 13px;
  opacity: 0.65;
}

.voice-pip-overlay:hover .pip-close-btn {
  opacity: 1;
}

.pip-close-btn:hover {
  background: rgba(242, 63, 67, 0.25) !important;
  color: #f23f43 !important;
}

.voice-pip-stage-host {
  flex: 1;
  width: 100%;
  min-height: 0;
  background: #000;
  position: relative;
  overflow: hidden;
  cursor: pointer;
  display: flex;
}

/* Mini ekrandayken sahne ve grid düzeni */
.voice-pip-stage-host .stage-wrap {
  width: 100%;
  height: 100%;
  flex: 1;
  min-height: 0;
}

.voice-pip-stage-host .grid {
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: wrap !important;
  padding: 6px !important;
  gap: 6px !important;
  width: 100% !important;
  height: 100% !important;
  box-sizing: border-box !important;
  align-items: center !important;
  justify-content: center !important;
}

.voice-pip-stage-host .tile {
  flex: 1 1 calc(50% - 6px) !important;
  width: auto !important;
  height: auto !important;
  max-width: 100% !important;
  max-height: 100% !important;
  border-radius: 8px !important;
  aspect-ratio: 16 / 9;
  margin: 0 !important;
}

.voice-pip-stage-host .grid:has(.tile:only-child) .tile,
.voice-pip-stage-host .grid .tile:only-child {
  flex: 1 1 100% !important;
  width: 100% !important;
  height: 100% !important;
  max-width: 100% !important;
  max-height: 100% !important;
  border-radius: 6px !important;
  aspect-ratio: auto !important;
  margin: 0 !important;
}

.voice-pip-stage-host .tile video {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
}

.voice-pip-stage-host .tile .avatar span {
  width: 38px !important;
  height: 38px !important;
  font-size: 16px !important;
}

.voice-pip-stage-host .tile .name {
  font-size: 10px !important;
  padding: 2px 6px !important;
  bottom: 4px !important;
  left: 4px !important;
}

.voice-pip-stage-host .tile .tile-actions {
  display: none !important;
}

/* Odak modu (ekran paylaşımı mini ekrandayken) */
.voice-pip-stage-host .focus-layout {
  flex: 1;
  height: 100%;
  width: 100%;
}

.voice-pip-stage-host .focus-stage {
  padding: 4px !important;
}

.voice-pip-stage-host .filmstrip {
  height: 48px !important;
  min-height: 48px !important;
  max-height: 48px !important;
  padding: 2px 4px !important;
  gap: 4px !important;
}

.voice-pip-stage-host .filmstrip .tile {
  border-radius: 4px !important;
}

.voice-pip-stage-host .filmstrip .tile .avatar span {
  width: 24px !important;
  height: 24px !important;
  font-size: 11px !important;
}

/* Mini Ekran Alt Kontrolleri */
.voice-pip-footer {
  height: 40px;
  background: #1e1f22;
  border-top: 1px solid rgba(255, 255, 255, 0.07);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 10px;
  flex-shrink: 0;
}

.pip-btn {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: none;
  background: #2b2d31;
  color: #dbdee1;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.pip-btn:hover {
  background: #35373c;
  color: #fff;
}

.pip-btn.off {
  background: var(--red) !important;
  color: #fff !important;
}

.pip-btn.active {
  background: var(--green) !important;
  color: #fff !important;
}

.pip-btn.danger {
  background: var(--red);
  color: #fff;
}

.pip-btn.danger:hover {
  background: #da373c;
}

.pip-btn .ic {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
}

.pip-btn svg {
  width: 16px;
  height: 16px;
}

/* Gelen Arama Modalı */
.incoming-call-card {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 32px 24px;
  gap: 12px;
  max-width: 340px;
}
.incoming-call-avatar-wrap {
  position: relative;
  width: 72px;
  height: 72px;
  margin-bottom: 8px;
}
.incoming-call-pulse {
  position: absolute;
  inset: -8px;
  border-radius: 50%;
  border: 2px solid #23a55a;
  animation: ringPulse 1.4s infinite cubic-bezier(0.2, 0.8, 0.2, 1);
  pointer-events: none;
}
@keyframes ringPulse {
  0% { transform: scale(0.9); opacity: 1; }
  100% { transform: scale(1.4); opacity: 0; }
}
.incoming-call-actions {
  display: flex;
  gap: 16px;
  margin-top: 14px;
  width: 100%;
}
.call-action-btn {
  flex: 1;
  padding: 12px 16px;
  border-radius: 8px;
  border: none;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  transition: transform .1s ease, filter .15s ease;
}
.call-action-btn.accept {
  background: #23a55a;
  color: #fff;
}
.call-action-btn.accept:hover {
  filter: brightness(1.1);
}
.call-action-btn.decline {
  background: #f23f43;
  color: #fff;
}
.call-action-btn.decline:hover {
  filter: brightness(1.1);
}

/* ========================================================== Zengin Bildirimler (Toasts & Ayarlar) */
.notif-toast-container {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 99999;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
  max-width: 380px;
  width: calc(100% - 32px);
}

.notif-toast {
  pointer-events: auto;
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(30, 31, 34, 0.95);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-left: 4px solid var(--accent);
  border-radius: 8px;
  padding: 12px 14px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5), 0 2px 6px rgba(0, 0, 0, 0.25);
  cursor: pointer;
  animation: notifSlideIn 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  transition: transform 0.15s ease, opacity 0.2s ease;
  user-select: none;
}

.notif-toast:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.6);
}

.notif-toast.notif-friend {
  border-left-color: #23a55a;
}
.notif-toast.notif-mention {
  border-left-color: #f0b232;
}
.notif-toast.notif-call {
  border-left-color: #23a55a;
}

.notif-toast.fade-out {
  animation: notifSlideOut 0.25s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes notifSlideIn {
  0% { transform: translateX(110%); opacity: 0; }
  100% { transform: translateX(0); opacity: 1; }
}

@keyframes notifSlideOut {
  0% { transform: translateX(0); opacity: 1; }
  100% { transform: translateX(110%); opacity: 0; }
}

.notif-toast-av {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  border-radius: 50%;
  overflow: hidden;
}

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

.notif-toast-title {
  font-weight: 700;
  font-size: 14px;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.notif-toast-body {
  font-size: 13px;
  color: #dbdee1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-top: 2px;
}

.notif-toast-close {
  background: transparent;
  border: none;
  color: var(--muted);
  font-size: 13px;
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  line-height: 1;
  flex-shrink: 0;
  transition: color 0.15s ease;
}

.notif-toast-close:hover {
  color: #fff;
}

/* Bildirim Ayarları Paneli */
.notif-permission-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  background: var(--bg-dark);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  padding: 14px 16px;
  margin-top: 6px;
}

.notif-perm-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.notif-perm-info b {
  font-size: 14px;
  color: #fff;
}

.checkbox-options-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 6px;
}

.notif-check-opt {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.15s ease;
}

.notif-check-opt:hover {
  background: rgba(255, 255, 255, 0.06);
}

.notif-check-opt input {
  accent-color: var(--accent);
  width: 18px;
  height: 18px;
  margin-top: 2px;
  cursor: pointer;
}

.notif-check-opt div {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.notif-check-opt b {
  font-size: 14px;
  color: #fff;
}

/* Okunmamış Rozetleri (Badges) */
.unread-badge {
  background: var(--red);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 10px;
  min-width: 16px;
  text-align: center;
  margin-left: auto;
}

.channel-item.has-unread .channel-icon {
  color: #fff;
  font-weight: bold;
}
.channel-item.has-unread {
  color: #fff;
  font-weight: 600;
}
.channel-item.has-unread::before {
  content: '';
  position: absolute;
  left: -6px;
  width: 4px;
  height: 8px;
  border-radius: 0 4px 4px 0;
  background: #fff;
}

/* ==================================================================
   Gelişmiş Discord Özellikleri: Tepkiler, Yanıtlar, Pin, Yazıyor, Soundboard & Arama
================================================================== */

/* Topbar Sağ Eylemler & Arama */
.channel-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.channel-topbar-left {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}
.channel-topbar-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}
.topbar-search-wrap {
  position: relative;
  display: flex;
  align-items: center;
}
.topbar-search-input {
  background: #1e1f22;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 4px;
  padding: 5px 10px;
  font-size: 13px;
  color: #dbdee1;
  width: 130px;
  transition: width 0.2s ease, border-color 0.15s;
  outline: none;
}
.topbar-search-input:focus {
  width: 180px;
  border-color: #5865f2;
}
.soundboard-btn {
  background: #5865f2 !important;
  color: #fff !important;
  font-size: 12px;
  font-weight: 600;
  padding: 5px 12px;
  border-radius: 4px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.soundboard-btn:hover {
  background: #4752c4 !important;
}

/* Mesaj Tepkileri (Emoji Reactions) */
.server-msg-reactions {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 4px;
}
.msg-reaction-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: #2b2d31;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  padding: 2px 7px;
  font-size: 12px;
  cursor: pointer;
  user-select: none;
  transition: all 0.1s;
  color: #b5bac1;
}
.msg-reaction-badge:hover {
  background: #35373c;
  border-color: rgba(255, 255, 255, 0.2);
}
.msg-reaction-badge.my-reaction {
  background: rgba(88, 101, 242, 0.2) !important;
  border-color: #5865f2 !important;
  color: #c9cdfb !important;
}
.msg-reaction-badge.add-reaction-badge {
  padding: 2px 7px;
  opacity: 0.7;
  font-size: 11px;
}
.msg-reaction-badge.add-reaction-badge:hover {
  opacity: 1;
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.25);
}
.msg-reaction-emoji {
  font-size: 14px;
}
.msg-reaction-count {
  font-weight: 600;
  font-size: 11.5px;
}

/* Hızlı Tepki Ekle Popover */
.quick-emoji-popover {
  position: fixed;
  z-index: 10000;
  background: #2b2d31;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
  padding: 4px 6px;
}
.quick-emoji-bar {
  display: flex;
  align-items: center;
  gap: 4px;
}
.quick-emoji-btn {
  background: transparent;
  border: 0;
  font-size: 18px;
  padding: 4px 6px;
  cursor: pointer;
  border-radius: 4px;
  transition: transform 0.1s, background-color 0.1s;
}
.quick-emoji-btn:hover {
  transform: scale(1.2);
  background: rgba(255, 255, 255, 0.1);
}
.quick-emoji-btn.btn-more-emojis {
  font-size: 13px;
  color: #949ba4;
  margin-left: 2px;
  padding-left: 6px;
  border-left: 1px solid rgba(255, 255, 255, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
}
.quick-emoji-btn.btn-more-emojis:hover {
  color: #fff;
  transform: scale(1.15);
}

/* Mesaj Yanıtlama (Reply) */
.server-msg-reply-quote {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: #949ba4;
  margin-bottom: 2px;
  cursor: pointer;
  user-select: none;
}
.server-msg-reply-quote:hover {
  color: #dbdee1;
}
.reply-spine {
  color: #4e5058;
  font-weight: bold;
}
.reply-author-badge {
  font-weight: 600;
  color: #dbdee1;
}
.reply-snippet {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 360px;
  font-style: italic;
}
.chat-reply-preview-bar {
  background: #2b2d31;
  border-radius: 8px 8px 0 0;
  padding: 6px 14px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.reply-spine-ic {
  color: #949ba4;
  font-weight: bold;
}
.reply-target-text {
  color: #dbdee1;
  flex: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.btn-cancel-reply {
  background: transparent;
  border: 0;
  color: #949ba4;
  cursor: pointer;
  font-size: 14px;
  padding: 2px 6px;
  border-radius: 4px;
}
.btn-cancel-reply:hover {
  color: #da373c;
  background: rgba(218, 55, 60, 0.1);
}

/* Canlı "Yazıyor..." Göstergesi (Typing Indicator) */
.chat-typing-indicator {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 3px 20px;
  font-size: 12px;
  color: #949ba4;
  height: 20px;
  user-select: none;
}
.typing-dots {
  display: flex;
  align-items: center;
  gap: 3px;
}
.typing-dots span {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #949ba4;
  animation: typing-wave 1.4s infinite ease-in-out;
}
.typing-dots span:nth-child(1) { animation-delay: 0s; }
.typing-dots span:nth-child(2) { animation-delay: 0.2s; }
.typing-dots span:nth-child(3) { animation-delay: 0.4s; }

@keyframes typing-wave {
  0%, 60%, 100% { transform: translateY(0); opacity: 0.4; }
  30% { transform: translateY(-4px); opacity: 1; }
}

/* Sabitlenmiş Mesajlar Paneli */
.pinned-messages-card {
  width: 480px;
  max-width: 92vw;
  max-height: 82vh;
  display: flex;
  flex-direction: column;
}
.pinned-messages-list {
  flex: 1;
  overflow-y: auto;
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.pinned-message-item {
  background: #1e1f22;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  padding: 10px 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  transition: border-color 0.15s;
}
.pinned-message-item:hover {
  border-color: rgba(255, 255, 255, 0.2);
}
.pinned-message-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
}
.pinned-message-author {
  font-weight: 600;
  color: #fff;
}
.pinned-message-time {
  color: #949ba4;
  font-size: 11px;
}
.pinned-message-text {
  font-size: 14px;
  color: #dbdee1;
  word-wrap: break-word;
}
.pinned-message-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 4px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  padding-top: 6px;
}
.pinned-message-jump {
  background: transparent;
  border: 0;
  color: #00a8fc;
  font-size: 12px;
  cursor: pointer;
  padding: 2px 4px;
}
.pinned-message-jump:hover {
  text-decoration: underline;
}
.pinned-message-unpin {
  background: transparent;
  border: 0;
  color: #da373c;
  font-size: 12px;
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 4px;
}
.pinned-message-unpin:hover {
  background: rgba(218, 55, 60, 0.15);
}

/* Ses Tahtası (Soundboard) */
.soundboard-card {
  width: 500px;
  max-width: 92vw;
  max-height: 80vh;
  display: flex;
  flex-direction: column;
}
.soundboard-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 12px;
  padding: 12px 16px 20px;
  overflow-y: auto;
}
.soundboard-item {
  background: #1e1f22;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  padding: 14px 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  transition: all 0.12s ease;
  user-select: none;
}
.soundboard-item:hover {
  background: #5865f2;
  border-color: #5865f2;
  transform: translateY(-2px);
  box-shadow: 0 6px 14px rgba(88, 101, 242, 0.4);
}
.soundboard-emoji {
  font-size: 28px;
}
.soundboard-name {
  font-size: 12.5px;
  font-weight: 600;
  color: #dbdee1;
  text-align: center;
}
.soundboard-item:hover .soundboard-name {
  color: #fff;
}

/* @mention ve #kanal Otomatik Tamamlama Menüsü */
.autocomplete-popover {
  position: absolute;
  bottom: 60px;
  left: 20px;
  width: 260px;
  background: #2b2d31;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.5);
  z-index: 100;
  max-height: 220px;
  overflow-y: auto;
}
.autocomplete-item {
  padding: 8px 12px;
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  font-size: 13.5px;
  color: #dbdee1;
  transition: background 0.1s;
}
.autocomplete-item:hover, .autocomplete-item.active {
  background: #5865f2;
  color: #fff;
}

/* Arama Vurgulama & Mesaja Atlama Animasyonu */
.search-highlight {
  background: rgba(250, 166, 26, 0.4);
  color: #fff;
  border-radius: 2px;
  padding: 0 2px;
}
.server-msg.highlighted-jump {
  background: rgba(88, 101, 242, 0.3) !important;
  transition: background 1.5s ease;
}

/* Kullanıcı Özel Durum & Bio */
.user-custom-status {
  font-size: 11.5px;
  color: #949ba4;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 140px;
}
.user-bio-text {
  font-size: 13px;
  color: #b5bac1;
  white-space: pre-wrap;
  line-height: 1.4;
  margin-top: 8px;
}





/* ========================================================
   DISCORD REVERSE-ENGINEERED ENHANCEMENTS (REA INTEGRATION)
   ======================================================== */

/* --- Discord Spoilers, Quotes, Codeblocks --- */
.spoiler-text {
  background: #202225;
  color: transparent !important;
  border-radius: 4px;
  padding: 0 4px;
  cursor: pointer;
  user-select: none;
  transition: background 0.15s ease, color 0.15s ease;
  position: relative;
  display: inline-block;
}
.spoiler-text:hover:not(.revealed) {
  background: #27292d;
}
.spoiler-text.revealed {
  background: rgba(255, 255, 255, 0.1) !important;
  color: inherit !important;
  user-select: text;
  cursor: text;
}

.discord-blockquote {
  display: flex;
  margin: 4px 0;
  padding: 2px 0;
}
.discord-blockquote-bar {
  width: 4px;
  border-radius: 4px;
  background: #4e5058;
  margin-right: 10px;
  flex-shrink: 0;
}
.discord-blockquote-content {
  color: #dbdee1;
  font-size: 14px;
  line-height: 1.4;
  word-break: break-word;
}

.discord-codeblock {
  background: #1e1f22;
  border: 1px solid #27292d;
  border-radius: 6px;
  margin: 6px 0;
  overflow: hidden;
  font-family: 'Consolas', 'Courier New', monospace;
}
.discord-codeblock-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #18191c;
  padding: 5px 12px;
  font-size: 11.5px;
  color: #949ba4;
  border-bottom: 1px solid #27292d;
  text-transform: uppercase;
  font-weight: 600;
  letter-spacing: 0.5px;
}
.discord-codeblock-copy-btn {
  background: none;
  border: none;
  color: #b5bac1;
  font-size: 11px;
  cursor: pointer;
  padding: 2px 8px;
  border-radius: 3px;
  display: flex;
  align-items: center;
  gap: 4px;
  transition: color 0.15s, background 0.15s;
}
.discord-codeblock-copy-btn:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
}
.discord-codeblock-content {
  padding: 10px 14px;
  font-size: 13px;
  line-height: 1.45;
  color: #dbdee1;
  white-space: pre-wrap;
  word-break: break-all;
  margin: 0;
  overflow-x: auto;
}

/* Strikethrough & Underline */
.server-msg-content s, .server-msg-content del {
  text-decoration: line-through;
  opacity: 0.85;
}
.server-msg-content u {
  text-decoration: underline;
}

/* --- Collapsible Categories --- */
.category-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 10px 4px 10px;
  cursor: pointer;
  user-select: none;
  font-size: 11.5px;
  font-weight: 700;
  color: #949ba4;
  letter-spacing: 0.02em;
  transition: color 0.15s ease;
}
.category-header:hover {
  color: #dbdee1;
}
.cat-header-title {
  display: flex;
  align-items: center;
  gap: 6px;
}
.cat-chevron {
  display: inline-flex;
  align-items: center;
  transition: transform 0.2s ease;
}
.category-header.collapsed .cat-chevron {
  transform: rotate(-90deg);
}
.cat-add-btn {
  color: #949ba4 !important;
  background: transparent !important;
  border: none !important;
  cursor: pointer !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 0 !important;
  width: 22px !important;
  height: 22px !important;
  min-width: 22px !important;
  border-radius: 4px !important;
  font-size: 18px !important;
  font-weight: 600 !important;
  line-height: 1 !important;
  box-shadow: none !important;
  outline: none !important;
  transition: color 0.15s, background 0.15s, transform 0.1s !important;
}
.cat-add-btn:hover {
  color: #fff !important;
  background: rgba(255, 255, 255, 0.1) !important;
  transform: scale(1.15) !important;
}
.channel-group.collapsed {
  display: none !important;
}

/* --- 4-State Status Indicator & Picker --- */
.user-status-dot-badge {
  position: absolute;
  bottom: -2px;
  right: -2px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 3px solid #232428;
  box-sizing: content-box;
}
.status-badge-online {
  background-color: #23a55a !important;
}
.status-badge-idle {
  background-color: #f0b232 !important;
}
.status-badge-dnd {
  background-color: #f23f43 !important;
}
.status-badge-invisible, .status-badge-offline {
  background-color: #80848e !important;
}

.status-picker-popover {
  position: absolute;
  bottom: 60px;
  left: 12px;
  width: 240px;
  background: #111214;
  border-radius: 8px;
  padding: 6px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
  z-index: 1000;
  border: 1px solid #1e1f22;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.status-picker-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 10px;
  border-radius: 5px;
  cursor: pointer;
  transition: background 0.12s ease;
  color: #dbdee1;
}
.status-picker-item:hover {
  background: #232428;
  color: #fff;
}
.status-picker-item.active {
  background: rgba(88, 101, 242, 0.2);
}
.status-picker-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  flex-shrink: 0;
}
.status-picker-info {
  display: flex;
  flex-direction: column;
  gap: 1px;
}
.status-picker-title {
  font-size: 13.5px;
  font-weight: 500;
  line-height: 1.2;
}
.status-picker-sub {
  font-size: 11px;
  color: #949ba4;
  line-height: 1.2;
}

/* Quick Switcher Button in Sidebar (Home Search Bar) */
.home-sidebar-header {
  padding: 10px 10px 8px 10px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}
.home-search-btn, .home-quick-switcher-btn {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  width: 100% !important;
  background: #1e1f22 !important;
  border: 1px solid #232428 !important;
  border-radius: 4px !important;
  padding: 6px 10px !important;
  color: #949ba4 !important;
  cursor: pointer !important;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease !important;
  outline: none !important;
  box-sizing: border-box !important;
  text-decoration: none !important;
  font-size: 13px !important;
}
.home-search-btn:hover, .home-quick-switcher-btn:hover {
  background: #2b2d31 !important;
  border-color: #383a40 !important;
  color: #dbdee1 !important;
}
.home-search-placeholder {
  font-size: 13px !important;
  color: #949ba4 !important;
  font-weight: 500 !important;
  display: flex !important;
  align-items: center !important;
  gap: 6px !important;
}
.home-search-placeholder::before {
  content: '🔍';
  font-size: 11px;
  opacity: 0.8;
}
.home-search-kbd, .home-quick-switcher-btn kbd {
  background: #111214 !important;
  border: 1px solid #35373c !important;
  border-radius: 3px !important;
  padding: 1px 5px !important;
  font-size: 10.5px !important;
  font-family: inherit !important;
  color: #80848e !important;
  box-shadow: inset 0 -1px 0 #232428 !important;
}

/* --- Quick Switcher Modal (Ctrl+K) --- */
.quick-switcher-card {
  width: 560px;
  max-width: 90vw;
  background: #2b2d31;
  border-radius: 8px;
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.65);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  max-height: 80vh;
  border: 1px solid #35373c;
  animation: qsFadeIn 0.15s ease-out;
}
@keyframes qsFadeIn {
  from { opacity: 0; transform: scale(0.97); }
  to { opacity: 1; transform: scale(1); }
}
.quick-switcher-input-wrap {
  padding: 14px 18px;
  border-bottom: 1px solid #1f2023;
  display: flex;
  align-items: center;
  gap: 12px;
  background: #1e1f22;
}
.quick-switcher-input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  color: #f2f3f5;
  font-size: 17px;
  font-weight: 400;
}
.quick-switcher-results {
  overflow-y: auto;
  padding: 8px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  max-height: 380px;
}
.quick-switcher-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-radius: 6px;
  cursor: pointer;
  color: #949ba4;
  transition: background 0.1s, color 0.1s;
}
.quick-switcher-item:hover, .quick-switcher-item.selected {
  background: #35373c;
  color: #f2f3f5;
}
.quick-switcher-item.selected .qs-badge {
  background: #5865f2;
  color: #fff;
}
.qs-icon {
  font-size: 16px;
  width: 22px;
  text-align: center;
  color: #80848e;
  display: flex;
  align-items: center;
  justify-content: center;
}
.quick-switcher-item.selected .qs-icon {
  color: #f2f3f5;
}
.qs-content {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 8px;
  overflow: hidden;
}
.qs-name {
  font-size: 14.5px;
  font-weight: 500;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.qs-parent {
  font-size: 12px;
  color: #80848e;
}
.qs-badge {
  font-size: 11px;
  padding: 2px 7px;
  border-radius: 3px;
  background: #1e1f22;
  color: #b5bac1;
  font-weight: 600;
  text-transform: uppercase;
}
.quick-switcher-footer {
  padding: 10px 16px;
  background: #232428;
  border-top: 1px solid #1f2023;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 11.5px;
  color: #949ba4;
}
.quick-switcher-footer kbd {
  background: #1e1f22;
  border: 1px solid #35373c;
  border-radius: 3px;
  padding: 2px 5px;
  font-size: 10.5px;
  color: #dbdee1;
}

/* --- Discord Message Context Menu --- */
.discord-context-menu {
  position: fixed;
  width: 200px;
  background: #111214;
  border: 1px solid #232428;
  border-radius: 6px;
  padding: 5px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 2px;
  animation: cmFadeIn 0.1s ease-out;
}
@keyframes cmFadeIn {
  from { opacity: 0; transform: scale(0.96); }
  to { opacity: 1; transform: scale(1); }
}
.context-menu-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 10px;
  border-radius: 4px;
  font-size: 13px;
  color: #dbdee1;
  cursor: pointer;
  transition: background 0.12s, color 0.12s;
  user-select: none;
}
.context-menu-item:hover {
  background: #5865f2;
  color: #fff;
}
.context-menu-item svg {
  flex-shrink: 0;
}
.context-menu-item.danger {
  color: #f23f43;
}
.context-menu-item.danger:hover {
  background: #da373c;
  color: #fff;
}
.context-menu-separator {
  height: 1px;
  background: #232428;
  margin: 4px 6px;
}

/* --- User Profile Popout Card --- */
.user-popout-card {
  width: 330px;
  background: #232428;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.7);
  position: relative;
  border: 1px solid #1b1c1e;
  animation: popoutIn 0.15s ease-out;
}
@keyframes popoutIn {
  from { opacity: 0; transform: scale(0.95); }
  to { opacity: 1; transform: scale(1); }
}
.user-popout-banner {
  height: 85px;
  width: 100%;
  background: #5865f2;
  position: relative;
}
.user-popout-avatar-wrap {
  position: absolute;
  top: 48px;
  left: 16px;
  width: 74px;
  height: 74px;
  border-radius: 50%;
  border: 6px solid #232428;
  background: #2b2d31;
  box-sizing: content-box;
}
.user-popout-avatar-img {
  width: 74px;
  height: 74px;
  border-radius: 50%;
  object-fit: cover;
  display: block;
}
.user-popout-status-badge {
  position: absolute;
  bottom: 0px;
  right: 0px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 3px solid #232428;
}
.user-popout-body {
  margin: 44px 12px 14px 12px;
  padding: 14px;
  background: #111214;
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.user-popout-header {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.user-popout-name {
  font-size: 17px;
  font-weight: 700;
  color: #f2f3f5;
  line-height: 1.2;
}
.user-popout-tag {
  font-size: 12.5px;
  color: #949ba4;
}
.user-popout-divider {
  height: 1px;
  background: #232428;
}
.user-popout-section-title {
  font-size: 11px;
  font-weight: 700;
  color: #b5bac1;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}
.user-popout-roles-list {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 4px;
}
.user-popout-role-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: #2b2d31;
  padding: 3px 8px;
  border-radius: 4px;
  font-size: 11px;
  color: #dbdee1;
  font-weight: 500;
}
.user-popout-dm-input {
  width: 100%;
  background: #1e1f22;
  border: 1px solid #2b2d31;
  border-radius: 4px;
  padding: 7px 10px;
  color: #dbdee1;
  font-size: 12.5px;
  outline: none;
  transition: border-color 0.15s;
}
.user-popout-dm-input:focus {
  border-color: #5865f2;
}

/* --- Keyboard Shortcuts Modal --- */
.keyboard-shortcuts-card {
  width: 580px;
  max-width: 90vw;
  background: #313338;
  border-radius: 8px;
  padding: 22px;
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.7);
  max-height: 85vh;
  overflow-y: auto;
  border: 1px solid #3f4147;
}
.shortcuts-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 14px;
}
.shortcut-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.shortcut-name {
  font-size: 13px;
  color: #dbdee1;
}
.shortcut-keys {
  display: flex;
  gap: 4px;
}
.shortcut-keys kbd {
  background: #1e1f22;
  border: 1px solid #3f4147;
  border-radius: 3px;
  padding: 2px 7px;
  font-size: 11px;
  font-family: inherit;
  font-weight: 600;
  color: #dbdee1;
  box-shadow: inset 0 -1px 0 #2b2d31;
}

/* --- Global Textarea & Profile Bio Styling (Fix white background) --- */
textarea,
.field textarea,
#profile-bio-input {
  background: #1e1f22 !important;
  border: 1px solid #2b2d31 !important;
  border-radius: 6px !important;
  color: #dbdee1 !important;
  padding: 10px 12px !important;
  font-family: inherit !important;
  font-size: 14px !important;
  line-height: 1.4 !important;
  resize: vertical;
  outline: none !important;
  transition: border-color 0.15s ease, box-shadow 0.15s ease !important;
  width: 100%;
  box-sizing: border-box;
}
textarea:focus,
.field textarea:focus,
#profile-bio-input:focus {
  border-color: #5865f2 !important;
  box-shadow: 0 0 0 2px rgba(88, 101, 242, 0.25) !important;
}
textarea::placeholder,
.field textarea::placeholder,
#profile-bio-input::placeholder {
  color: #80848e !important;
}

/* --- Channel Category Add Buttons & Plus Icons (Fix white square buttons) --- */
.btn-cat-add-channel,
#btn-add-text-channel,
#btn-add-voice-channel,
.cat-add-btn {
  background: transparent !important;
  border: none !important;
  color: #949ba4 !important;
  cursor: pointer !important;
  font-size: 17px !important;
  line-height: 1 !important;
  padding: 2px 5px !important;
  border-radius: 4px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  outline: none !important;
  transition: color 0.15s ease, background 0.15s ease, transform 0.12s ease !important;
  user-select: none !important;
}
.btn-cat-add-channel:hover,
#btn-add-text-channel:hover,
#btn-add-voice-channel:hover,
.cat-add-btn:hover {
  color: #ffffff !important;
  background: rgba(255, 255, 255, 0.1) !important;
  transform: scale(1.18) !important;
}

/* --- Home Sidebar Quick Switcher Bar --- */
#btn-home-quick-switcher,
.home-search-btn,
.home-quick-switcher-btn {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  width: 100% !important;
  background: #1e1f22 !important;
  border: 1px solid #232428 !important;
  border-radius: 4px !important;
  padding: 7px 10px !important;
  color: #949ba4 !important;
  cursor: pointer !important;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease !important;
  outline: none !important;
  box-sizing: border-box !important;
  font-size: 13px !important;
}
#btn-home-quick-switcher:hover,
.home-search-btn:hover,
.home-quick-switcher-btn:hover {
  background: #2b2d31 !important;
  border-color: #383a40 !important;
  color: #dbdee1 !important;
}

/* --- Discord Chat Emoji Picker Popover --- */
.chat-emoji-picker-popover {
  position: fixed;
  z-index: 99999;
  width: 320px;
  height: 360px;
  background: #2b2d31;
  border: 1px solid #1f2023;
  border-radius: 10px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(255, 255, 255, 0.05);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: emojiPop 0.15s cubic-bezier(0.16, 1, 0.3, 1);
}
@keyframes emojiPop {
  from { opacity: 0; transform: translateY(6px) scale(0.97); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
.chat-emoji-picker-popover.hidden {
  display: none !important;
}
.emoji-picker-header {
  padding: 10px 10px 6px 10px;
  background: #2b2d31;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.emoji-picker-search {
  width: 100%;
  background: #1e1f22;
  border: 1px solid #1b1c1e;
  border-radius: 4px;
  padding: 7px 10px;
  font-size: 13px;
  color: #dbdee1;
  outline: none;
  box-sizing: border-box;
  transition: border-color 0.15s;
}
.emoji-picker-search:focus {
  border-color: #5865f2;
}
.emoji-picker-tabs {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 6px 10px;
  background: #232428;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}
.emoji-tab-btn {
  background: transparent;
  border: none;
  font-size: 16px;
  padding: 4px 6px;
  border-radius: 4px;
  cursor: pointer;
  opacity: 0.65;
  transition: opacity 0.12s, background 0.12s;
  line-height: 1;
}
.emoji-tab-btn:hover {
  opacity: 1;
  background: rgba(255, 255, 255, 0.08);
}
.emoji-tab-btn.active {
  opacity: 1;
  background: rgba(88, 101, 242, 0.25);
  box-shadow: inset 0 -2px 0 #5865f2;
}
.emoji-picker-grid {
  flex: 1;
  overflow-y: auto;
  padding: 8px;
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
  align-content: start;
}
.emoji-picker-item {
  background: transparent;
  border: none;
  font-size: 20px;
  padding: 6px 4px;
  border-radius: 6px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  transition: transform 0.12s ease, background 0.12s ease;
  user-select: none;
}
.emoji-picker-item:hover {
  background: rgba(255, 255, 255, 0.12);
  transform: scale(1.25);
}

/* Chat Action Buttons (Emoji, GIF, Mic) */
.chat-action-btn.btn-emoji {
  font-size: 18px;
  padding: 4px 6px;
  cursor: pointer;
  border: none;
  background: transparent;
  color: #b5bac1;
  border-radius: 4px;
  transition: transform 0.15s ease, filter 0.15s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}
.chat-action-btn.btn-emoji:hover {
  transform: scale(1.15);
  filter: brightness(1.2);
}

/* Quick Room Item on Server Rail */
.rail-item.quick-room-item {
  background: #2b2d31;
  color: #23a55a;
  font-size: 18px;
  border-radius: 50%;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}
.rail-item.quick-room-item:hover {
  background: #23a55a;
  color: #ffffff;
  border-radius: 16px;
  transform: scale(1.05);
}

/* Return to Discord App Button on Home View */
#home-btn-return-app {
  background: #5865f2 !important;
  color: #fff !important;
  border: none !important;
  border-radius: 6px !important;
  padding: 12px 18px !important;
  font-size: 15px !important;
  font-weight: 600 !important;
  cursor: pointer !important;
  box-shadow: 0 4px 14px rgba(88, 101, 242, 0.4) !important;
  transition: background 0.15s ease, transform 0.1s ease !important;
}
#home-btn-return-app:hover {
  background: #4752c4 !important;
  transform: translateY(-1px) !important;
}

/* Modern Discord Fluid Enhancements */
* {
  scrollbar-width: thin;
  scrollbar-color: #1a1b1e transparent;
}
::-webkit-scrollbar {
  width: 7px;
  height: 7px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: #1a1b1e;
  border-radius: 10px;
}
::-webkit-scrollbar-thumb:hover {
  background: #2b2d31;
}

/* Server Rail Hover Indicators (Discord Pill) */
.rail-item {
  position: relative;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}
.rail-item::before {
  content: '';
  position: absolute;
  left: -12px;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 0;
  border-radius: 0 4px 4px 0;
  background: #fff;
  transition: height 0.2s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.2s ease;
  opacity: 0;
}
.rail-item:hover::before {
  height: 20px;
  opacity: 1;
}
.rail-item.active::before {
  height: 40px;
  opacity: 1;
}
