:root{
      --bg-dark:#202225;
      --bg-sidebar:#2f3136;
      --bg-chat:#36393f;
      --accent:#5865F2;
      --danger:#ED4245;
      --success:#3ba55c;
      --warning:#faa61a;
      --text:#dcddde;
      --mention-bg: rgba(88, 101, 242, 0.28);
      --mention-text:#dee0fc;
      --vvs-color:#ff4fd8;
      --hacker:#00ffae;
    }
    *{ box-sizing:border-box; }
    html,body{ height:100%; margin:0; font-family:'Segoe UI', system-ui, Arial, sans-serif; background:var(--bg-dark); color:var(--text); overflow:hidden; }

    /* ================= LOGIN ================= */
    #login-overlay{
      position:fixed; inset:0;
      display:flex; align-items:center; justify-content:center;
      background:
        radial-gradient(1200px 600px at 20% 10%, rgba(88,101,242,.35), transparent 60%),
        radial-gradient(900px 500px at 80% 90%, rgba(255,79,216,.22), transparent 55%),
        linear-gradient(180deg, #0f1115, #1b1e25);
      z-index:10002;
      padding:24px;
    }
    .login-box{
      width:420px; max-width:94vw;
      border-radius:18px;
      padding:26px;
      background:rgba(32,34,37,.85);
      border:1px solid rgba(0,255,170,.15);
      box-shadow:0 20px 60px rgba(0,0,0,.6);
      backdrop-filter: blur(10px);
      position:relative;
      overflow:hidden;
    }
    .glitch{
      position:relative;
      color:#eafff7;
      text-shadow:0 0 18px rgba(0,255,170,.25);
      font-weight: 1000;
      font-size: 24px;
      margin-bottom: 10px;
    }
    .login-err{ min-height:16px; margin-top:10px; color:var(--danger); font-size:12px; font-weight:700; }

    /* ================= COMMON UI ================= */
    .btn{
      padding:10px 14px;
      border:none;
      border-radius:4px;
      cursor:pointer;
      font-weight:700;
      color:#fff;
      transition:.15s;
      width:100%;
      font-size: 14px;
    }
    .btn:hover{ transform: translateY(-1px); opacity:.96; }
    .btn-primary{ background: var(--accent); }
    .btn-danger{ background: var(--danger); }
    .btn-muted{ background:#4f545c; }
    .btn-success{ background:var(--success); }
    .btn-warning{ background:var(--warning); color:#000; }

    .modal-input,.modal-select,.modal-textarea{
      width:100%;
      padding:10px;
      border-radius:4px;
      background:#202225;
      border:1px solid rgba(255,255,255,.08);
      color:#fff;
      outline:none;
      font-weight:500;
      margin-bottom: 10px;
    }
    .modal-input:focus{ border-color:var(--accent); }
    .modal-label{
      display:block;
      margin:12px 0 4px;
      font-size:12px;
      color:#b9bbbe;
      font-weight:700;
      text-transform:uppercase;
    }

    /* SOSYAL MEDYA INPUTLARI */
    .social-input-wrapper {
        display: flex; align-items: center; background: #202225;
        border: 1px solid rgba(255,255,255,.08); border-radius: 4px; margin-bottom: 8px; padding-left: 10px; transition: border-color 0.2s;
    }
    .social-input-wrapper:focus-within { border-color: var(--accent); }
    .social-input-wrapper i { width: 20px; text-align: center; font-size: 16px; }
    .social-input-wrapper input { flex: 1; border: none; background: transparent; color: #fff; padding: 10px; outline: none; font-weight: 500; }
    
    .fa-instagram { color: #E1306C; } .fa-twitter { color: #1DA1F2; } .fa-youtube { color: #FF0000; } .fa-discord { color: #5865F2; } .fa-globe { color: #4CAF50; }

    /* PROFİL KARTINDAKİ İKONLAR */
    .profile-socials { display: flex; gap: 12px; margin-top: 16px; margin-bottom: 16px; flex-wrap: wrap; padding-top: 10px; border-top: 1px solid rgba(255,255,255,0.06); }
    .social-btn { display: flex; align-items: center; justify-content: center; width: 38px; height: 38px; background: rgba(0,0,0,0.3); border: 1px solid rgba(255,255,255,0.1); border-radius: 50%; color: #b9bbbe; font-size: 18px; text-decoration: none; transition: all 0.2s; cursor: pointer; }
    .social-btn:hover { transform: translateY(-3px) scale(1.1); color: #fff; border-color: transparent; }
    .social-btn.instagram:hover { background: #E1306C; box-shadow: 0 4px 12px rgba(225,48,108,0.4); }
    .social-btn.twitter:hover { background: #1DA1F2; box-shadow: 0 4px 12px rgba(29,161,242,0.4); }
    .social-btn.youtube:hover { background: #FF0000; box-shadow: 0 4px 12px rgba(255,0,0,0.4); }
    .social-btn.discord:hover { background: #5865F2; box-shadow: 0 4px 12px rgba(88,101,242,0.4); }
    .social-btn.website:hover { background: #4CAF50; box-shadow: 0 4px 12px rgba(76,175,80,0.4); }

    .custom-modal{ position:fixed; inset:0; display:none; align-items:center; justify-content:center; background: rgba(0,0,0,.85); z-index:10001; padding:18px; }
    #flash-admin-modal{ z-index: 10060; }
    .modal-box{ width:520px; max-width:96vw; background: #36393f; border-radius:5px; box-shadow:0 0 0 1px rgba(32,34,37,.6), 0 2px 10px 0 rgba(0,0,0,.2); padding:24px; position:relative; max-height: 90vh; overflow-y: auto; }
    .modal-title{ font-size: 20px; font-weight: 700; color: #fff; margin-bottom: 20px; text-align: center; }
    .close-modal-btn{ position:absolute; right:16px; top:16px; color:#b9bbbe; cursor:pointer; font-size: 24px; z-index: 10; background: rgba(0,0,0,0.3); width: 32px; height: 32px; border-radius: 50%; display: flex; align-items: center; justify-content: center; transition: all 0.2s; }
    .close-modal-btn:hover { background: rgba(0,0,0,0.6); color: #fff; }

    /* AI LOADING */
    #ai-loading { position: absolute; inset: 0; background: rgba(0,0,0,0.7); display: none; align-items: center; justify-content: center; flex-direction: column; z-index: 20000; border-radius: 5px; }
    .ai-spinner { width: 40px; height: 40px; border: 4px solid var(--vvs-color); border-top-color: transparent; border-radius: 50%; animation: spin 1s linear infinite; }
    @keyframes spin { to { transform: rotate(360deg); } }

    /* ================= APP LAYOUT ================= */
    #app{ display:none; height:100vh; height:100dvh; width:100vw; position:relative; }
    .rooms-panel, .users-panel{ width:240px; background: var(--bg-sidebar); display:flex; flex-direction:column; }
    .users-panel{ padding: 0; }
    .section-title{ padding: 16px 16px 8px 16px; font-size:12px; color:#96989d; font-weight:700; text-transform:uppercase; display:flex; align-items:center; justify-content:space-between; }
    .room-list, .dm-list, .user-list-scroll{ padding: 0 8px; display:flex; flex-direction:column; gap:2px; overflow-y: auto; }
    .room-item{ padding:6px 8px; border-radius:4px; cursor:pointer; color:#8e9297; display:flex; align-items:center; gap:10px; font-weight: 500; }
    .room-item:hover{ background: rgba(79,84,92,0.16); color:#dcddde; }
    .room-item.active, .room-item.dm-active{ background: rgba(79,84,92,0.32); color:#fff; }
    
    .u-avatar-small { width: 24px; height: 24px; border-radius: 50%; position: relative; flex-shrink: 0; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: bold; color: #fff; }
    .u-avatar-small img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; display: block; }
    .u-status-dot { position: absolute; bottom: -2px; right: -2px; width: 10px; height: 10px; border-radius: 50%; background: #747f8d; border: 2px solid var(--bg-sidebar); }
    .online .u-status-dot { background: var(--success); }

    .current-user-bar{ margin-top:auto; background: #292b2f; padding:10px; display:flex; align-items:center; gap:8px; height: 52px; }
    .mini-name{ font-weight:600; font-size:14px; color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 90px; }
    .settings-btn{ background:none; border:none; color:#b9bbbe; cursor:pointer; padding:6px; border-radius:4px; }
    .settings-btn:hover{ background: rgba(79,84,92,0.32); color:#dcddde; }

    /* CHAT */
    .chat-panel{ flex:1; background: var(--bg-chat); display:flex; flex-direction:column; min-width:0; position: relative; }
    .chat-header{ display:flex; align-items:center; gap:10px; padding:0 16px; border-bottom:1px solid rgba(0,0,0,0.2); color:#fff; font-weight:700; height:48px; box-shadow: 0 1px 2px rgba(0,0,0,0.1); }
    .messages-area{ flex:1; overflow-y:auto; padding:8px 0 10px; display:flex; flex-direction:column; gap: 0; }
    .message-row { display: flex; padding: 1px 16px; margin-top: 0 !important; margin-bottom: 0 !important; position: relative; }
.message-row.compact-msg{ padding-top: 0 !important; padding-bottom: 0 !important; }
.message-row + .message-row.compact-msg{ margin-top: 0 !important; }
.message-row.compact-msg .msg-avatar{
  width:0 !important;
  height:0 !important;
  margin:0 !important;
  border:0 !important;
  overflow:hidden !important;
  pointer-events:none;
  background:transparent !important;
}
.message-row.compact-msg .msg-header{ display:none; }
.message-row.compact-msg .msg-content{ padding-top: 0; margin-left: 56px; }
.message-row.compact-msg .msg-text{ margin-top: 0 !important; }
.message-row.compact-msg .msg-actions{ top: 2px; }
.message-row:not(.compact-msg){ margin-top: 3px !important; }
.message-row:first-child{ margin-top: 0 !important; }
    .message-row:hover { background-color: rgba(4, 4, 5, 0.07); }
    .msg-avatar { width: 40px; height: 40px; border-radius: 50%; margin-top: 2px; margin-right: 16px; flex-shrink: 0; cursor: pointer; background-color: #36393f; }
    .msg-avatar img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; }
    .msg-content { flex: 1; min-width: 0; }
    .msg-header { display: flex; align-items: baseline; gap: 8px; line-height: 1.375rem; }
    .msg-username { font-size: 16px; font-weight: 500; color: #fff; cursor: pointer; }
    .msg-username:hover { text-decoration: underline; }
    .msg-time { font-size: 0.75rem; color: #72767d; font-weight: 400; }
    .msg-text { font-size: 16px; line-height: 1.375rem; color: #dcddde; white-space: pre-wrap; word-wrap: break-word; margin-top: 0 !important; }
    .msg-media { margin-top: 6px; max-width: 500px; border-radius: 4px; overflow: hidden; }
    .chat-img, .chat-video, .chat-audio { max-width: 100%; max-height: 350px; border-radius: 4px; cursor: pointer; }

    .chat-audio{ width: 100%; max-width: 100%; cursor: default; }
.chat-audio-shell{
  width:min(390px, 100%);
  padding:12px;
  border-radius:20px;
  background:
    radial-gradient(circle at top left, rgba(107,119,255,.24), transparent 38%),
    linear-gradient(180deg, rgba(19,22,31,.98), rgba(31,35,47,.96));
  border:1px solid rgba(109,126,255,.22);
  box-shadow: 0 14px 34px rgba(0,0,0,.28);
}
.chat-audio-head{
  display:flex;
  align-items:center;
  gap:12px;
  margin-bottom:10px;
}
.chat-audio-icon{
  width:42px;
  height:42px;
  border-radius:14px;
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:18px;
  color:#eef1ff;
  background: linear-gradient(135deg, rgba(88,101,242,.95), rgba(130,114,255,.95));
  box-shadow: 0 10px 24px rgba(88,101,242,.28);
  flex-shrink:0;
}
.chat-audio-copy{ min-width:0; }
.chat-audio-title{
  color:#ffffff;
  font-size:14px;
  font-weight:800;
  line-height:1.1;
}
.chat-audio-sub{
  margin-top:4px;
  color:#aeb6da;
  font-size:12px;
  font-weight:600;
}
.chat-audio-shell .chat-audio{
  display:block;
  width:100%;
  min-width:0;
  border-radius:14px;
  overflow:hidden;
}
.chat-audio-shell audio::-webkit-media-controls-panel{
  background: linear-gradient(180deg, #f7f8ff, #e9edff);
}
.message-row.own-msg .chat-audio-shell{
  border-color: rgba(88,101,242,.34);
  box-shadow: 0 14px 34px rgba(88,101,242,.16);
}
@media (max-width: 640px){
  .chat-audio-shell{ width:100%; }
}
.input-area{ padding: 0 16px calc(24px + env(safe-area-inset-bottom)) 16px; margin-top: 8px; background: transparent; position: relative; }
.chat-pending-bar{ margin-bottom:10px; }
.chat-pending-card{
  border-radius:18px;
  padding:12px;
  background: linear-gradient(180deg, rgba(26,30,40,.96), rgba(18,20,28,.96));
  border:1px solid rgba(255,255,255,.08);
  box-shadow: 0 14px 34px rgba(0,0,0,.25);
}
.chat-pending-card.is-audio{
  border-color: rgba(109,126,255,.22);
  background:
    radial-gradient(circle at top left, rgba(107,119,255,.20), transparent 42%),
    linear-gradient(180deg, rgba(21,24,33,.98), rgba(16,18,25,.98));
}
.chat-pending-top{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  margin-bottom:10px;
}
.chat-pending-label{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:6px 10px;
  border-radius:999px;
  font-size:12px;
  font-weight:800;
  color:#eef1ff;
  background: rgba(88,101,242,.16);
  border:1px solid rgba(88,101,242,.24);
}
.chat-pending-remove{
  width:34px;
  height:34px;
  border:none;
  border-radius:12px;
  cursor:pointer;
  background: rgba(255,255,255,.06);
  color:#d8dcf6;
}
.chat-pending-remove:hover{ background: rgba(255,255,255,.12); }
.chat-pending-body{ display:flex; flex-direction:column; gap:10px; }
.pending-preview-thumb{
  position:relative;
  width:100%;
  max-width:200px;
  border-radius:16px;
  overflow:hidden;
  border:1px solid rgba(255,255,255,.08);
}
.pending-preview-thumb img,
.pending-preview-thumb video{
  display:block;
  width:100%;
  height:140px;
  object-fit:cover;
}
.pending-preview-badge{
  position:absolute;
  right:10px;
  bottom:10px;
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding:6px 10px;
  border-radius:999px;
  font-size:12px;
  font-weight:800;
  color:#fff;
  background: rgba(0,0,0,.48);
  border:1px solid rgba(255,255,255,.16);
}
.pending-audio-card{
  padding:12px;
  border-radius:18px;
  background: linear-gradient(180deg, rgba(17,20,29,.98), rgba(25,29,40,.98));
  border:1px solid rgba(109,126,255,.22);
}
.pending-audio-head{ display:flex; align-items:center; gap:12px; margin-bottom:10px; }
.pending-audio-icon{
  width:42px;
  height:42px;
  border-radius:14px;
  display:flex;
  align-items:center;
  justify-content:center;
  color:#fff;
  font-size:18px;
  background: linear-gradient(135deg, #5865f2, #8a5cf6);
  box-shadow: 0 10px 20px rgba(88,101,242,.28);
}
.pending-audio-copy{ min-width:0; }
.pending-audio-title{ color:#fff; font-size:14px; font-weight:800; }
.pending-audio-sub{ color:#aeb6da; font-size:12px; font-weight:600; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; max-width:240px; }
.pending-audio-player{ display:block; width:100%; border-radius:14px; overflow:hidden; }
.pending-audio-player::-webkit-media-controls-panel{ background: linear-gradient(180deg, #f7f8ff, #e9edff); }
.pending-file-box{
  display:flex;
  align-items:center;
  gap:10px;
  padding:12px;
  border-radius:14px;
  background: rgba(255,255,255,.05);
  color:#eef1ff;
}
.chat-pending-meta{
  color:#aeb6da;
  font-size:12px;
  font-weight:600;
}
    .chat-input-wrapper { background-color: #40444b; border-radius: 14px; display: flex; align-items: center; gap: 2px; padding: 0 10px 0 12px; }
    .chat-input{ flex:1; padding:11px 0; background: transparent; border:none; color:#dcddde; outline:none; font-size: 16px; max-height: 50vh; resize: none; }
    .btn-icon { background: transparent; border: none; color: #b9bbbe; cursor: pointer; padding: 10px; font-size: 20px; transition: color 0.1s; }
.chat-send-btn{
  width:42px;
  height:42px;
  border:none;
  border-radius:14px;
  display:flex;
  align-items:center;
  justify-content:center;
  margin-left:2px;
  cursor:pointer;
  color:#e6e9fb;
  background: linear-gradient(135deg, rgba(88,101,242,.26), rgba(128,108,255,.26));
  opacity:.55;
  transform: scale(.98);
  transition: opacity .15s ease, transform .15s ease, box-shadow .15s ease;
}
.chat-send-btn.is-ready{
  opacity:1;
  transform: scale(1);
  box-shadow: 0 10px 24px rgba(88,101,242,.24);
}
.chat-send-btn:disabled{ cursor:default; }
.chat-send-btn:not(:disabled):hover{ transform: translateY(-1px); }
    .btn-icon:hover { color: #dcddde; }

    
    .btn-icon.recording { color: var(--danger); }
    .btn-icon.recording:hover { color: var(--danger); }

    .admin-action-grid{ display:flex; gap:5px; flex-wrap:wrap; }
#ai-tools-menu { position: absolute; bottom: 65px; right: 10px; background: #2f3136; border: 1px solid rgba(255,255,255,0.1); border-radius: 8px; box-shadow: 0 8px 24px rgba(0,0,0,0.6); display: none; flex-direction: column; overflow: hidden; z-index: 10005; width: 230px; }
    .ai-tool-item { padding: 12px 16px; cursor: pointer; color: #dcddde; font-size: 14px; display: flex; align-items: center; gap: 12px; border-bottom: 1px solid rgba(255,255,255,0.05); }
    .ai-tool-item:last-child { border-bottom: none; }
    .ai-tool-item:hover { background: #40444b; color: #fff; }
    .ai-tool-item i { width: 20px; text-align: center; color: var(--vvs-color); font-size: 16px; }

    .user-card{ display:flex; align-items:center; gap:12px; padding:6px 8px; margin: 1px 8px; border-radius:4px; cursor:pointer; opacity: 0.7; }
    .user-card:hover{ background: rgba(79,84,92,0.16); opacity: 1; }
    .user-card.online { opacity: 1; }
    
    #flash-overlay{ position:fixed; inset:0; display:none; align-items:center; justify-content:center; z-index:10050; background: rgba(0,0,0,.86); backdrop-filter: blur(6px); }
    .flash-box{ max-width:92vw; padding:28px 30px; border-radius:18px; border:2px solid var(--danger); background: rgba(32,34,37,.65); color:#fff; font-weight:1000; font-size:28px; text-align:center; animation: flashBlink .22s linear infinite alternate; box-shadow: 0 0 40px rgba(237,66,69,.25); }
    @keyframes flashBlink{ from{opacity:1;} to{opacity:.65;} }

    #intro-overlay{ position:fixed; inset:0; z-index:10070; display:none; align-items:center; justify-content:center; background:#000; }
    #intro-video { width: 100%; height: 100%; object-fit: cover; }
    .intro-skip { position: absolute; bottom: 50px; right: 50px; color: #fff; border: 1px solid #fff; padding: 10px 20px; cursor: pointer; z-index: 10080; font-weight: bold; background: rgba(0,0,0,0.5); }

    .story-ring{ padding: 2px; background: linear-gradient(45deg, #f09433 0%,#e6683c 25%,#dc2743 50%,#cc2366 75%,#bc1888 100%); border-radius: 50%; }
    .story-ring img { border: 2px solid var(--bg-sidebar); }
    .role-admin { color: var(--danger) !important; }
    .role-vvs{
      color: var(--vvs-color) !important;
      font-weight: 800;
      text-shadow: 0 0 10px rgba(255,79,216,0.55), 0 0 18px rgba(88,101,242,0.28);
      background: linear-gradient(90deg, rgba(255,79,216,1), rgba(88,101,242,1), rgba(255,79,216,1));
      background-size: 200% 100%;
      -webkit-background-clip: text;
      background-clip: text;
      -webkit-text-fill-color: transparent;
      animation: vvsShimmer 2.2s linear infinite;
    }
    @keyframes vvsShimmer{ 0%{background-position:0% 50%} 100%{background-position:200% 50%} }

    /* VVS banner chip */
    .vvs-banner-chip{
      position:absolute;
      top:10px; right:12px;
      display:none;
      align-items:center;
      gap:8px;
      padding:6px 10px;
      border-radius:999px;
      font-size:12px;
      font-weight:800;
      letter-spacing:.4px;
      color:#fff;
      background: linear-gradient(90deg, rgba(255,79,216,.85), rgba(88,101,242,.85));
      box-shadow: 0 8px 20px rgba(0,0,0,.35);
      border: 1px solid rgba(255,255,255,.10);
      backdrop-filter: blur(6px);
      user-select:none;
    }
    .vvs-banner{
      overflow:hidden;
    }
    .vvs-banner::before{
      content:'';
      position:absolute;
      inset:-40px;
      background: radial-gradient(circle at 20% 30%, rgba(255,79,216,.22), transparent 55%),
                  radial-gradient(circle at 80% 20%, rgba(88,101,242,.22), transparent 55%),
                  radial-gradient(circle at 55% 90%, rgba(255,79,216,.18), transparent 60%);
      pointer-events:none;
    }
    

    .toast-wrap { position: fixed; bottom: 20px; right: 20px; z-index: 10090; display: flex; flex-direction: column; gap: 10px; }
    .toast { background: #36393f; border-left: 4px solid var(--accent); padding: 12px; color: #fff; width: 300px; box-shadow: 0 5px 15px rgba(0,0,0,0.3); border-radius: 4px; animation: slideIn 0.3s; }
    @keyframes slideIn { from{ transform: translateX(100%); } to{ transform: translateX(0); } }
.toast-clickable{ cursor: pointer; }
    .toast-mention{ border-left-color: var(--vvs-color) !important; }
    .room-item.has-unread .room-label{ font-weight: 800; }
    .mention-btn{ position: relative; }
    .mini-badge{
      position:absolute;
      top:-4px; right:-4px;
      min-width:18px; height:18px;
      padding:0 5px;
      display:inline-flex; align-items:center; justify-content:center;
      background: var(--danger);
      color:#fff;
      font-size:11px;
      border-radius:999px;
      border:2px solid #2f3136;
      box-shadow: 0 6px 18px rgba(0,0,0,.35);
      line-height: 1;
    }

    /* STORY VIEWER (INSTAGRAM STYLE) */
    #insta-story-modal { position: fixed; inset: 0; background: #000; z-index: 20000; display: flex; align-items: center; justify-content: center; }
    .story-container { width: 100%; height: 100%; max-width: 480px; position: relative; background: #1a1a1a; display: flex; flex-direction: column; }
    .story-progress-wrapper { position: absolute; top: 10px; left: 10px; right: 10px; display: flex; gap: 4px; z-index: 20001; }
    .story-progress-bar { flex: 1; height: 2px; background: rgba(255,255,255,0.3); border-radius: 2px; overflow: hidden; }
    .story-progress-fill { height: 100%; background: #fff; width: 0%; transition: width linear; }
    
    .story-header { position: absolute; top: 20px; left: 10px; right: 10px; display: flex; align-items: center; gap: 10px; z-index: 20001; color: #fff; text-shadow: 0 1px 2px rgba(0,0,0,0.5); }
    .story-header img { width: 32px; height: 32px; border-radius: 50%; object-fit: cover; }
    .story-header span { font-weight: bold; font-size: 14px; }
    .close-story { margin-left: auto; cursor: pointer; font-size: 20px; padding: 5px; }

    .story-media-wrapper { flex: 1; display: flex; align-items: center; justify-content: center; background: #000; overflow: hidden; }
    .story-media-wrapper img, .story-media-wrapper video { width: 100%; height: 100%; object-fit: contain; }

    .story-nav { position: absolute; top: 50px; bottom: 0; width: 30%; z-index: 20002; }
    .story-nav.left { left: 0; }
    .story-nav.right { right: 0; }

    /* === SCROLLBAR (GÜNCELLENDİ: DISCORD TARZI ENTEGRE) === */
    ::-webkit-scrollbar {
        width: 12px;
        height: 12px;
    }
    ::-webkit-scrollbar-track {
        background-color: #2b2d31; /* Track rengi (koyu gri) */
        border-radius: 0;
    }
    ::-webkit-scrollbar-thumb {
        background-color: #1a1b1e; /* Thumb rengi (daha koyu) */
        border-radius: 6px;
        border: 3px solid #2b2d31; /* Kenarlık ile yüzen efekt */
        background-clip: content-box;
    }
    ::-webkit-scrollbar-thumb:hover {
        background-color: #111214;
    }
  
/* ===== PATCH: Message edit/delete + lvl/badge/tag ===== */
.message-row{ position:relative; }
.msg-actions{ position:absolute; right:8px; top:8px; opacity:.85; transition:opacity .15s; }
.message-row:hover .msg-actions{ opacity:1; }
.message-row.own-msg .msg-actions{ opacity:1; }
.msg-actions-btn{
  background:transparent; border:0; color:#a8acb6; cursor:pointer;
  font-size:16px; padding:4px 6px; border-radius:6px;
}
.msg-actions-btn:hover{ background: rgba(255,255,255,0.06); }
.msg-menu{
  position:absolute; right:0; top:26px; background:#111317; border:1px solid rgba(255,255,255,.08);
  border-radius:10px; min-width:160px; z-index:9999; overflow:hidden; box-shadow: 0 10px 30px rgba(0,0,0,.45);
}
.msg-menu button{
  width:100%; text-align:left; padding:10px 12px; border:0; background:transparent; color:#dcddde; cursor:pointer;
  font-size:13px;
}
.msg-menu button:hover{ background: rgba(255,255,255,0.06); }
.msg-deleted{ color:#a8acb6; font-style:italic; }
.msg-edited{ color:#a8acb6; font-size:11px; margin-left:6px; }
.profile-tagline{ color:#a8acb6; font-size:12px; margin-top:4px; display:flex; gap:10px; flex-wrap:wrap; }
.profile-level{ margin-top:8px; }
.lvl-bar{ width:100%; height:8px; background: rgba(255,255,255,0.08); border-radius:999px; overflow:hidden; }
.lvl-fill{ height:100%; background: var(--accent); width:0%; }
.badge-pill{
  display:inline-flex; align-items:center; gap:6px; padding:4px 8px; border-radius:999px;
  background: rgba(255,255,255,0.06); color:#dcddde; font-size:12px;
}


    /* ===== PATCH V7: Profile layout + Mobile drawers ===== */
    #profile-modal .modal-box{ overflow-x:hidden; }
    #view-badges{ flex-wrap:wrap !important; }
    .profile-tagline{ display:flex; flex-wrap:wrap; gap:8px; margin-top:6px; }
    #view-banner{ overflow:visible; }

    /* ===== PATCH V11: Discord-like profile header (tek parça banner + avatar yarı taşma) ===== */
    #profile-modal .modal-box{ overflow-x:hidden !important; overflow-y:auto !important; }
    #profile-modal #view-banner{
      height: 208px !important;
      margin: -24px -24px 0 -24px !important;
      border-radius: 12px 12px 0 0 !important;
      position: relative !important;
      overflow: visible !important;
      background-position: center !important;
      background-size: cover !important;
      background-repeat: no-repeat !important;
    }
    /* Banner üstüne hafif karartma (metin okunurluğu) */
    #profile-modal #view-banner::before{
      content:"";
      position:absolute; inset:0;
      background: linear-gradient(180deg, rgba(0,0,0,.10), rgba(0,0,0,.35));
      pointer-events:none;
    }
    #profile-modal #view-avatar-cont{
      width: 96px !important;
      height: 96px !important;
      position: absolute !important;
      left: 22px !important;
      bottom: -48px !important; /* yarısı aşağıda */
      padding: 6px !important;
      border-radius: 999px !important;
      background: #2f3136 !important;
      box-shadow: 0 12px 28px rgba(0,0,0,.45);
      z-index: 20 !important;
    }
    #profile-modal #view-avatar{
      width: 100% !important;
      height: 100% !important;
      border-radius: 999px !important;
      object-fit: cover !important;
    }
    
    /* ===== PATCH V12.1: Profile story ring fix ===== */
    #profile-modal #view-avatar-cont.has-story{
      background: linear-gradient(45deg, #f09433 0%,#e6683c 25%,#dc2743 50%,#cc2366 75%,#bc1888 100%) !important;
      cursor: pointer;
    }
    #profile-modal #view-avatar-cont.has-story #view-avatar{
      border: 3px solid #2f3136;
    }
#profile-modal #view-vvs-banner{ z-index: 25 !important; }
    #profile-modal .close-modal-btn{ z-index: 30 !important; }

    /* Banner bittiği anda içerik başlasın, avatar için üstten boşluk */
    #profile-modal #view-header-body{
      margin-top: 0 !important;
      padding-top: 68px !important;
    }

    @media (max-width: 560px){
      #profile-modal #view-banner{ height: 148px !important; }
      #profile-modal #view-avatar-cont{
        width: 76px !important;
        height: 76px !important;
        bottom: -38px !important;
        left: 14px !important;
        padding: 5px !important;
      }
      #profile-modal #view-header-body{ padding-top: 46px !important; }
    }


    /* Banner boşluğu doldurma (profil header) */
    #view-banner{
      background-position:center;
      background-size:cover;
      background-repeat:no-repeat;
    }
#view-avatar-cont{ z-index:6; }
    #view-vvs-banner{ z-index:7; }
    .vvs-banner-chip{ top:12px; right:60px; }

    .mobile-only{ display:none; }

    @media (max-width: 560px){
      .custom-modal{ padding:10px; }
      .modal-box{ padding:16px; border-radius:10px; }
      #profile-modal .modal-box{ width:96vw; }
      #profile-modal #view-banner{
        height:136px !important;
        margin:-16px -16px 0 -16px !important;
      }
      #profile-modal #view-avatar-cont{ width:72px !important; height:72px !important; bottom:-36px !important; left:14px !important; }
      #profile-modal #view-header-body{ padding-top:46px !important; margin-top:0 !important; }
      #profile-modal #view-username{ font-size:20px !important; }
      .close-modal-btn{ right:10px; top:10px; }
      .vvs-banner-chip{ right:52px; top:10px; padding:6px 10px; font-size:12px; }
      .admin-action-grid{ gap:6px; }
      .admin-action-grid .btn{ font-size:11px !important; padding:8px 10px !important; }
    }

    @media (max-width: 900px){
      #app{ width:100%; }
      .mobile-only{ display:inline-flex !important; }
      .rooms-panel, .users-panel{
        position:fixed; top:0; bottom:0;
        width:min(320px, 84vw);
        /* IMPORTANT: bazı tarayıcılarda fixed paneller flex layout'ta yine de yer kaplayabiliyor.
           Mobilde sağda boş alan oluşmaması için flex-basis'i 0'a kilitliyoruz. */
        flex: 0 0 0 !important;
        max-width: min(320px, 84vw);
        z-index:10030;
        transition: transform .2s ease;
        box-shadow: 0 12px 40px rgba(0,0,0,.55);
      }
      .rooms-panel{ left:0; transform: translateX(-105%); }
      .users-panel{ right:0; transform: translateX(105%); }
      body.mobile-rooms-open .rooms-panel{ transform: translateX(0); }
      body.mobile-users-open .users-panel{ transform: translateX(0); }
      .chat-panel{ width:100vw; flex: 1 1 auto !important; }
      #mobile-drawer-backdrop{
        position:fixed; inset:0;
        /* Mobilde sağ/sol drawer açılınca arka planın gri/blur görünmesini ve
           herhangi bir tıklamada drawer'ın kapanmasını istemiyoruz.
           Backdrop sadece z-index katmanı olarak kalsın, etkileşim yakalamasın. */
        background: transparent;
        pointer-events: none;
        z-index:10025;
        display:none;
      }
      body.mobile-rooms-open #mobile-drawer-backdrop,
      body.mobile-users-open #mobile-drawer-backdrop{ display:block; }
    }


/* ===== Nick Effects (30) ===== */
.profile-name{ font-size:22px; font-weight:800; line-height:1.1; }

/* Gradient/Animated group (daha parlak, daha modern) */
.nickfx-rainbow, .nickfx-aurora, .nickfx-ocean, .nickfx-lava, .nickfx-candy, .nickfx-sunset,
.nickfx-plasma, .nickfx-toxic, .nickfx-chrome, .nickfx-blood, .nickfx-cyber, .nickfx-vvs,
.nickfx-holo, .nickfx-galaxy, .nickfx-electric, .nickfx-diamond, .nickfx-liquid{
  background-size: 420% 320%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent !important;
  -webkit-text-fill-color: transparent;
  -webkit-text-stroke: 0.35px rgba(255,255,255,.14);
  filter: drop-shadow(0 4px 12px rgba(0,0,0,.55)) drop-shadow(0 0 16px rgba(255,255,255,.10));
  animation: nickShift 2.4s ease-in-out infinite;
}
@keyframes nickShift{
  0%{ background-position:0% 50%; }
  50%{ background-position:100% 50%; }
  100%{ background-position:0% 50%; }
}

.nickfx-rainbow{ background-image: linear-gradient(90deg,#ff4d4d,#ffd24d,#7CFF4D,#4DFFEA,#4D7CFF,#B44DFF,#ff4d8d); }
.nickfx-aurora{ background-image: linear-gradient(90deg,#00ffd5,#00ff7b,#7c4dff,#ff4db8); }
.nickfx-ocean{ background-image: linear-gradient(90deg,#00c6ff,#0072ff,#00ffd5,#00c6ff); }
.nickfx-lava{ background-image: linear-gradient(90deg,#ff512f,#dd2476,#ffb347,#ff512f); }
.nickfx-candy{ background-image: linear-gradient(90deg,#ff5acd,#7c4dff,#4dffea,#ff5acd); }
.nickfx-sunset{ background-image: linear-gradient(90deg,#ff512f,#f09819,#ff4db8,#7c4dff); }
.nickfx-plasma{ background-image: linear-gradient(90deg,#ff00cc,#3333ff,#00ffd5,#ff00cc); }
.nickfx-toxic{ background-image: linear-gradient(90deg,#d8ff00,#00ff6a,#00ffd5,#d8ff00); }
.nickfx-chrome{ background-image: linear-gradient(90deg,#ffffff,#9ea7b3,#ffffff,#4b5563); }
.nickfx-blood{ background-image: linear-gradient(90deg,#ff0033,#990012,#ff0033,#ff4d4d); }
.nickfx-cyber{ background-image: linear-gradient(90deg,#00ffd5,#5865F2,#ff4fd8,#00ffd5); }
.nickfx-vvs{
  background-image: linear-gradient(90deg,#ff4fd8,#9b5cff,#4d7cff,#ff4fd8);
  filter: drop-shadow(0 4px 12px rgba(0,0,0,.55)) drop-shadow(0 0 18px rgba(255,79,216,.20)) drop-shadow(0 0 18px rgba(155,92,255,.16));
}

/* Yeni – daha ilgi çekici 5 efekt */
.nickfx-holo{
  background-image: linear-gradient(90deg,#7c4dff,#00ffd5,#ff4fd8,#ffd24d,#7c4dff);
  background-size: 520% 320%;
  animation-duration: 2.1s;
}
.nickfx-galaxy{
  background-image: linear-gradient(90deg,#0b1028,#5b21b6,#ec4899,#22d3ee,#0b1028);
  background-size: 620% 320%;
  animation-duration: 3.0s;
}
.nickfx-electric{
  background-image: linear-gradient(90deg,#00e5ff,#5865F2,#ffd24d,#00ff6a,#00e5ff);
  animation-timing-function: linear;
  animation-duration: 1.8s;
}
.nickfx-diamond{
  background-image: linear-gradient(90deg,#ffffff,#b9f3ff,#9b5cff,#ffffff);
  filter: drop-shadow(0 0 12px rgba(185,243,255,.22)) drop-shadow(0 0 18px rgba(155,92,255,.16)) drop-shadow(0 4px 12px rgba(0,0,0,.55));
}
.nickfx-liquid{
  background-image: linear-gradient(135deg,#ff4fd8,#5865F2,#00ffd5,#ff4fd8);
  background-size: 260% 260%;
  animation: nickLiquid 1.9s ease-in-out infinite;
}
@keyframes nickLiquid{
  0%{ background-position:0% 0%; }
  50%{ background-position:100% 100%; }
  100%{ background-position:0% 0%; }
}

/* Solid glow styles */
.nickfx-neon{
  color:#fff !important;
  text-shadow: 0 0 6px rgba(88,101,242,.95), 0 0 18px rgba(88,101,242,.45);
}
.nickfx-gold{
  color:#ffd24d !important;
  text-shadow: 0 0 10px rgba(255,210,77,.38);
}
.nickfx-ice{
  color:#b9f3ff !important;
  text-shadow: 0 0 10px rgba(185,243,255,.38);
}
.nickfx-fire{
  color:#ff7a18 !important;
  text-shadow: 0 0 10px rgba(255,122,24,.50), 0 0 18px rgba(255,81,47,.28);
}
.nickfx-matrix{
  color:#00ff6a !important;
  text-shadow: 0 0 10px rgba(0,255,106,.38);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
}

/* Glitch (daha agresif) */
.nickfx-glitch{
  position:relative;
  color:#fff !important;
  text-shadow: -2px 0 rgba(255,79,216,.65), 2px 0 rgba(88,101,242,.65);
  animation: nickGlitch 0.95s steps(2,end) infinite;
}
@keyframes nickGlitch{
  0%,100%{ transform: translateX(0); }
  12%{ transform: translateX(-1px) skewX(2deg); }
  24%{ transform: translateX(2px) skewX(-2deg); }
  48%{ transform: translateX(-2px); }
  72%{ transform: translateX(2px); }
}

/* Diğerleri */
.nickfx-shadow{
  color:#fff !important;
  text-shadow: 0 6px 18px rgba(0,0,0,.68);
}
.nickfx-outline{
  color:transparent !important;
  -webkit-text-stroke: 1px rgba(255,255,255,.86);
  text-shadow: none;
}
.nickfx-wave{
  background-image: linear-gradient(90deg, rgba(255,255,255,.25), rgba(255,255,255,1), rgba(255,255,255,.25));
  background-size: 240% 100%;
  -webkit-background-clip:text; background-clip:text;
  color: transparent !important;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 4px 12px rgba(0,0,0,.55));
  animation: nickWave 1.7s linear infinite;
}
@keyframes nickWave{ 0%{ background-position:0% 50%; } 100%{ background-position:240% 50%; } }

.nickfx-sparkle{
  color:#fff !important;
  text-shadow: 0 0 6px rgba(255,255,255,.55), 0 0 18px rgba(255,79,216,.22);
  animation: nickPulse 1.45s ease-in-out infinite;
}
.nickfx-pulse{
  color:#fff !important;
  animation: nickPulse 1.1s ease-in-out infinite;
}
@keyframes nickPulse{ 0%,100%{ opacity:1; } 50%{ opacity:.65; } }

.nickfx-noir{
  color:#e5e7eb !important;
  letter-spacing: .6px;
  text-transform: uppercase;
}


    /* ===== MENTION PICKER (@ etiketleme) ===== */
    .mention-picker{
      position:absolute;
      left: 16px;
      right: 16px;
      bottom: 70px;
      background:#1f2126;
      border:1px solid rgba(255,255,255,.08);
      border-radius:12px;
      box-shadow: 0 14px 40px rgba(0,0,0,.45);
      max-height: 240px;
      overflow-y:auto;
      display:none;
      z-index: 9999;
      padding:8px;
    }
    .mention-item{
      display:flex;
      align-items:center;
      gap:10px;
      padding:10px 10px;
      border-radius:10px;
      cursor:pointer;
      color: var(--text);
    }
    .mention-item:hover, .mention-item.active{
      background: rgba(88, 101, 242, 0.18);
    }
    .mention-item .mi-ava{
      width:26px;height:26px;border-radius:50%;
      display:flex;align-items:center;justify-content:center;
      background:#5865F2;
      font-weight:800;
      overflow:hidden;
      flex:0 0 auto;
    }
    .mention-item .mi-ava img{ width:100%; height:100%; object-fit:cover; }
    .mention-item .mi-name{ font-weight:800; }
    .mention-hint{
      font-size:12px;color:#a8acb6;padding:8px 10px;
    }



    /* ===== VOICE CHAT (BETA) ===== */
    .voice-bar{ position: fixed; left: 18px; bottom: 18px; z-index: 10085; display:flex; align-items:center; gap:10px;
      background: rgba(47,49,54,0.98); border:1px solid rgba(0,0,0,0.35); border-radius: 14px; padding: 10px 12px;
      box-shadow: 0 10px 30px rgba(0,0,0,0.45); }
    .voice-title{ color:#fff; font-weight: 800; display:flex; align-items:center; gap:8px; }
    .voice-pill{ background:#202225; color:#dcddde; border:1px solid rgba(255,255,255,0.08); padding:4px 10px;
      border-radius:999px; font-size:12px; }
    @media (max-width: 820px){
      .voice-bar{ left: 10px; right: 10px; }
    }

    /* ===== Voice Rooms ===== */
    .voice-room-list .room-item{ display:flex; align-items:center; justify-content:space-between; }
    .voice-room-list .room-left{ display:flex; align-items:center; gap:10px; min-width:0; }
    .voice-room-list .room-name{ white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
    .voice-room-list .room-count{ font-size:12px; opacity:.85; background: rgba(255,255,255,.07); padding: 2px 8px; border-radius: 999px; }
    .voice-room-list .room-actions{ display:flex; align-items:center; gap:8px; }
    .voice-room-list .room-actions .btn-icon{ width:28px; height:28px; }
    .voice-room-list .room-item.active{ outline: 1px solid rgba(88,101,242,.55); }

    /* Discord-like inline members under voice channels */
    .voice-room-list .voice-room-item{ flex-direction:column; align-items:stretch; cursor:pointer; }
    .voice-room-list .voice-room-head{ width:100%; display:flex; align-items:center; justify-content:space-between; gap:10px; }
    .voice-room-list .voice-members-inline{ margin-left: 26px; margin-top: 6px; display:flex; flex-direction:column; gap:6px; }
    .voice-room-list .voice-member-row{ display:flex; align-items:center; gap:8px; padding:2px 4px; border-radius:6px; opacity:.92; }
    .voice-room-list .voice-member-row:hover{ background: rgba(255,255,255,0.05); opacity:1; }
    .voice-room-list .voice-member-row.me{ font-weight:800; }
    .voice-room-list .voice-member-name{ white-space:nowrap; overflow:hidden; text-overflow:ellipsis; max-width: 160px; }
    .voice-room-list .voice-empty{ font-size:12px; opacity:.65; padding:2px 4px; }


    /* Invite toast buttons */
    .toast .toast-actions{ margin-top:8px; display:flex; gap:8px; }
    .toast .toast-actions button{ flex:1; padding:8px 10px; border:none; border-radius:6px; cursor:pointer; font-weight:700; }
    .toast .toast-actions .accept{ background: var(--success); color:#fff; }
    .toast .toast-actions .decline{ background: var(--danger); color:#fff; }


/* ===================== CHAT GRID BACKGROUND (RESTORE) ===================== */
.chat-panel::before{
  content:"";
  position:absolute;
  inset:0;
  pointer-events:none;
  opacity:0.12;
  background-image:
    linear-gradient(rgba(255,255,255,0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.06) 1px, transparent 1px);
  background-size: 40px 40px;
  z-index:0;
}
.chat-panel > *{ position:relative; z-index:1; }

/* ===================== SETTINGS (NEW UI) ===================== */
.settings-modal-box{ width:min(1100px, 96vw) !important; max-height: 90vh !important; padding:0 !important; overflow:hidden; }
.icon-x{
  position:absolute; top:14px; right:14px;
  width:36px; height:36px; border-radius:999px;
  background: rgba(255,255,255,0.06);
  border:1px solid rgba(255,255,255,0.08);
  color:#fff; display:flex; align-items:center; justify-content:center;
  cursor:pointer; z-index:10;
}
.icon-x:hover{ background: rgba(255,255,255,0.10); }

.settings-shell{ display:flex; width:100%; height:90vh; max-height:90vh; background: #2f3136; }
.settings-nav{
  width: 260px; flex:0 0 260px;
  background: rgba(0,0,0,0.18);
  border-right:1px solid rgba(255,255,255,0.06);
  padding:16px 12px;
  display:flex; flex-direction:column; gap:6px;
}
.settings-brand{ display:flex; gap:10px; padding:10px 10px 14px; align-items:center; }
.brand-dot{ width:40px; height:40px; border-radius:12px; background: linear-gradient(135deg, #5865F2, #B794F4); }
.brand-title{ font-weight:800; color:#fff; line-height:1.1; }
.brand-sub{ font-size:12px; color: rgba(255,255,255,0.65); margin-top:2px; }

.nav-item{
  width:100%; border:none; cursor:pointer;
  background: transparent;
  color: rgba(255,255,255,0.86);
  display:flex; align-items:center; gap:10px;
  padding:10px 12px; border-radius:10px;
  font-weight:600;
}
.nav-item i{ width:18px; text-align:center; opacity:0.9; }
.nav-item:hover{ background: rgba(255,255,255,0.06); }
.nav-item.active{ background: rgba(88,101,242,0.22); outline:1px solid rgba(88,101,242,0.35); }
.nav-item.danger{ background: rgba(237,66,69,0.12); }
.nav-item.danger:hover{ background: rgba(237,66,69,0.18); }

.nav-sep{ height:1px; background: rgba(255,255,255,0.06); margin:8px 8px; }
.nav-grow{ flex:1; }

.settings-main{ flex:1; display:flex; flex-direction:column; min-width:0; }
.settings-head{ padding:18px 22px 10px; border-bottom:1px solid rgba(255,255,255,0.06); }
.settings-title{ font-size:20px; font-weight:800; color:#fff; }
.settings-desc{ font-size:12.5px; color: rgba(255,255,255,0.66); margin-top:4px; }

.settings-grid{
  display:grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap:16px;
  padding:16px 22px 18px;
  overflow:hidden;
  flex:1;
}
.settings-content{
  min-width:0;
  overflow:auto;
  padding-right:6px;
}
.settings-preview{
  background: rgba(255,255,255,0.03);
  border:1px solid rgba(255,255,255,0.06);
  border-radius:14px;
  padding:14px;
  overflow:auto;
}
.preview-title{ font-weight:800; color:#fff; margin-bottom:10px; }
.preview-card{
  border-radius:14px;
  overflow:hidden;
  border:1px solid rgba(255,255,255,0.08);
  background: rgba(0,0,0,0.18);
}
.prev-banner{ height:90px; background: rgba(255,255,255,0.06); background-size:cover; background-position:center; }
.prev-body{ padding:12px; position:relative; }
.prev-avatar{
  width:58px; height:58px; border-radius:50%;
  background: rgba(255,255,255,0.10);
  border:3px solid #2f3136;
  position:absolute; top:-28px; left:12px;
  overflow:hidden; background-size:cover; background-position:center;
}
.prev-name{ margin-top:24px; font-weight:900; color:#fff; }
.prev-tag{ font-size:12px; color: rgba(255,255,255,0.70); margin-top:2px; }
.prev-bio{ margin-top:10px; color: rgba(255,255,255,0.85); font-size:13px; }
.prev-note{ margin-top:6px; color: rgba(255,255,255,0.60); font-size:12px; font-style:italic; }

.preview-hint{ margin-top:10px; font-size:12px; color: rgba(255,255,255,0.65); line-height:1.4; }

.form-card{
  background: rgba(255,255,255,0.03);
  border:1px solid rgba(255,255,255,0.06);
  border-radius:14px;
  padding:14px;
}
.card-title{ font-weight:900; color:#fff; margin-bottom:10px; }
.card-subtitle{ margin-top:14px; font-weight:800; color: rgba(255,255,255,0.85); font-size:13px; }

.f-label{ display:block; margin:10px 0 6px; font-size:12px; color: rgba(255,255,255,0.70); font-weight:800; }
.f-input, .f-textarea{
  width:100%;
  background: rgba(0,0,0,0.25);
  border:1px solid rgba(255,255,255,0.08);
  color:#fff;
  border-radius:10px;
  padding:10px 12px;
  outline:none;
}
.f-textarea{ resize:vertical; min-height:70px; }
.f-input:focus, .f-textarea:focus{ border-color: rgba(88,101,242,0.45); box-shadow: 0 0 0 3px rgba(88,101,242,0.18); }

.f-row{ display:flex; gap:10px; }
.f-col{ flex:1; min-width:0; }

.social-grid{ display:flex; flex-direction:column; gap:8px; margin-top:8px; }
.social-line{ display:flex; align-items:center; gap:10px; padding:10px 12px; border-radius:10px;
  background: rgba(0,0,0,0.20); border:1px solid rgba(255,255,255,0.06);
}
.social-line i{ width:18px; text-align:center; opacity:0.9; }
.social-line input{ flex:1; background: transparent; border:none; color:#fff; outline:none; }

.actions-row{ display:flex; gap:10px; margin-top:14px; }
.btn-soft{
  flex:1; padding:10px 12px; border-radius:12px;
  border:1px solid rgba(255,255,255,0.08);
  background: rgba(255,255,255,0.06);
  color:#fff; font-weight:900; cursor:pointer;
}
.btn-soft:hover{ background: rgba(255,255,255,0.09); }
.btn-primary{
  flex:1; padding:10px 12px; border-radius:12px;
  border:none;
  background: linear-gradient(135deg, #5865F2, #8B5CF6);
  color:#fff; font-weight:900; cursor:pointer;
}
.btn-primary:hover{ filter: brightness(1.03); }

.tab-pane{ display:none; }
.tab-pane.active{ display:block; }

.toggle-row{ display:flex; align-items:center; justify-content:space-between; gap:10px;
  padding:10px 12px; border-radius:10px; background: rgba(0,0,0,0.20); border:1px solid rgba(255,255,255,0.06);
  color: rgba(255,255,255,0.85);
}
.switch{ position:relative; width:44px; height:24px; display:inline-block; }
.switch input{ display:none; }
.slider{ position:absolute; inset:0; background: rgba(255,255,255,0.12); border-radius:999px; transition: .18s; border:1px solid rgba(255,255,255,0.12); }
.slider:before{ content:""; position:absolute; width:18px; height:18px; left:3px; top:2px; border-radius:50%; background:#fff; transition:.18s; }
.switch input:checked + .slider{ background: rgba(88,101,242,0.55); border-color: rgba(88,101,242,0.55); }
.switch input:checked + .slider:before{ transform: translateX(20px); }

.range{ width:100%; margin-top:6px; }
.hint{ font-size:12px; color: rgba(255,255,255,0.62); margin-top:6px; }

/* Mobile: stack preview under content */
@media (max-width: 860px){
  .settings-shell{ height: 92vh; }
  .settings-nav{ width: 220px; flex-basis:220px; }
  .settings-grid{ grid-template-columns: 1fr; }
  .settings-preview{ order:2; }
}
@media (max-width: 560px){
  .settings-shell{ flex-direction:column; height: 94vh; }
  .settings-nav{ width:100%; flex-basis:auto; flex-direction:row; overflow:auto; gap:6px; padding:10px; }
  .settings-brand{ display:none; }
  .nav-item{ white-space:nowrap; }
  .nav-grow, .nav-sep{ display:none; }
  .settings-head{ padding:14px 14px 10px; }
  .settings-grid{ padding:12px 14px 14px; }
  .f-row{ flex-direction:column; }
}

/* ===================== STORY SIDEBAR ===================== */
.story-title-row{ display:flex; align-items:center; justify-content:space-between; gap:10px; }
.story-plus-btn{ width:34px; height:34px; border-radius:10px; background: rgba(255,255,255,0.06); border:1px solid rgba(255,255,255,0.07); }
.story-plus-btn:hover{ background: rgba(255,255,255,0.10); }
.story-list{ padding: 8px 10px 12px; display:flex; flex-direction:column; gap:10px; max-height: 220px; overflow:auto; }
.story-item{ display:flex; align-items:center; gap:10px; cursor:pointer; padding:8px 8px; border-radius:12px; }
.story-item:hover{ background: rgba(255,255,255,0.05); }
.story-ava{
  width:38px; height:38px; border-radius:50%;
  padding:2px;
  background: rgba(255,255,255,0.10);
  flex:0 0 auto;
}
.story-ava.unseen{ background: linear-gradient(135deg, #f58529, #dd2a7b, #8134af, #515bd4); }
.story-ava.seen{ background: rgba(255,255,255,0.12); }
.story-ava img{ width:100%; height:100%; border-radius:50%; object-fit:cover; border:2px solid #2f3136; }
.story-meta{ min-width:0; }
.story-name{ font-weight:900; color:#fff; font-size:13px; line-height:1.1; }
.story-sub{ font-size:11px; color: rgba(255,255,255,0.62); margin-top:3px; }

/* user list ring: default seen, add .story-unseen for gradient */
.u-avatar-small.story-ring{ padding:2px; background: rgba(255,255,255,0.12); border-radius:50%; }
.u-avatar-small.story-ring.story-unseen{ background: linear-gradient(135deg, #f58529, #dd2a7b, #8134af, #515bd4); }

/* ===================== STORY UPLOAD MODAL ===================== */
.story-upload-box{ width:min(760px, 94vw) !important; }
.story-upload-grid{ display:grid; grid-template-columns: 1fr 1fr; gap:12px; }
.uploader-drop{ border:1px dashed rgba(255,255,255,0.18); padding:14px; border-radius:14px; background: rgba(255,255,255,0.03); }
.uploader-drop input{ width:100%; color:#fff; }
.uploader-help{ margin-top:8px; font-size:12px; color: rgba(255,255,255,0.65); }
.preview-mini{ height:220px; border-radius:14px; border:1px solid rgba(255,255,255,0.08); background: rgba(0,0,0,0.20); display:flex; align-items:center; justify-content:center; overflow:hidden; }
.preview-mini img, .preview-mini video{ width:100%; height:100%; object-fit:cover; }
@media (max-width: 700px){
  .story-upload-grid{ grid-template-columns:1fr; }
  .preview-mini{ height:260px; }
}

.story-empty{ color: rgba(255,255,255,0.65); font-size:12px; padding:8px 2px; }


/* ===== FOLLOW / FRIEND UI (Profile) ===== */
.profile-follow-wrap{ margin-top: 14px; display:flex; flex-direction:column; gap:10px; }
.profile-follow-stats{ display:flex; gap:10px; flex-wrap:wrap; }
.pill-btn{
  background:#2b2d31;
  border:1px solid rgba(255,255,255,0.08);
  color:#e7e7e7;
  padding:8px 10px;
  border-radius:999px;
  cursor:pointer;
  font-weight:600;
  font-size:13px;
}
.pill-btn:hover{ filter:brightness(1.1); }
.profile-follow-actions{ display:flex; gap:10px; flex-wrap:wrap; }
.profile-friend-req{ display:flex; gap:10px; flex-wrap:wrap; }

.userlist-row{
  display:flex;
  align-items:center;
  gap:10px;
  padding:8px;
  border-radius:10px;
  background:#202225;
  border:1px solid rgba(255,255,255,0.06);
}
.userlist-row img{
  width:38px;
  height:38px;
  border-radius:50%;
  object-fit:cover;
}
.userlist-row .meta{ display:flex; flex-direction:column; }
.userlist-row .meta .u{ font-weight:700; }
.userlist-row .meta .d{ font-size:12px; color:#a8acb6; }


/* ================= MEDIA CHANNEL (Twitter-like) ================= */
.media-channel{ padding:12px; height:100%; overflow:auto; }
.media-composer{ background:rgba(255,255,255,0.04); border:1px solid rgba(255,255,255,0.08); border-radius:14px; padding:12px; margin:10px 0 14px; }
.media-composer-top{ display:flex; align-items:center; justify-content:space-between; margin-bottom:10px; }
.media-composer-title{ font-weight:700; display:flex; align-items:center; gap:10px; }
.media-post-text{ width:100%; min-height:84px; resize:vertical; border-radius:12px; padding:10px 12px; border:1px solid rgba(255,255,255,0.10); background:rgba(0,0,0,0.25); color:var(--text); outline:none; }
.media-composer-bottom{ display:flex; gap:10px; align-items:center; margin-top:10px; flex-wrap:wrap; }
.media-file-chip{ font-size:12px; opacity:.9; padding:6px 10px; border-radius:999px; border:1px solid rgba(255,255,255,0.12); background:rgba(0,0,0,0.25); }
.media-feed{ display:flex; flex-direction:column; gap:12px; padding-bottom:40px; }
.media-post{ background:rgba(255,255,255,0.03); border:1px solid rgba(255,255,255,0.08); border-radius:16px; padding:12px; }
.media-post-header{ display:flex; align-items:center; justify-content:space-between; gap:12px; }
.media-post-user{ display:flex; align-items:center; gap:10px; min-width:0; }
.media-post-user .name{ font-weight:800; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.media-post-time{ font-size:12px; opacity:.65; }
.media-post-content{ margin-top:10px; white-space:pre-wrap; line-height:1.35; }
.media-post-media{ margin-top:10px; border-radius:14px; overflow:hidden; border:1px solid rgba(255,255,255,0.10); }
.media-post-media img, .media-post-media video{ width:100%; height:auto; display:block; }
.media-post-actions{ display:flex; gap:14px; margin-top:10px; align-items:center; flex-wrap:wrap; }
.media-act{ cursor:pointer; user-select:none; display:flex; align-items:center; gap:8px; font-size:13px; opacity:.9; }
.media-act:hover{ opacity:1; }
.media-act .count{ opacity:.75; }
.media-comments{ margin-top:10px; border-top:1px dashed rgba(255,255,255,0.10); padding-top:10px; display:none; }
.media-comment{ padding:8px 10px; border-radius:12px; background:rgba(0,0,0,0.18); border:1px solid rgba(255,255,255,0.06); margin-top:8px; }
.media-comment .meta{ font-size:12px; opacity:.75; display:flex; gap:10px; align-items:center; flex-wrap:wrap; }
.media-comment .text{ margin-top:6px; white-space:pre-wrap; }
.media-reply{ margin-left:18px; }
.media-comment-actions{ margin-top:6px; display:flex; gap:12px; font-size:12px; opacity:.9; }
.media-comment-actions span{ cursor:pointer; }
.media-comment-box{ margin-top:10px; display:flex; gap:10px; align-items:flex-start; flex-wrap:wrap; }
.media-comment-box textarea{ flex:1; min-width:220px; min-height:44px; resize:vertical; border-radius:12px; padding:10px 12px; border:1px solid rgba(255,255,255,0.10); background:rgba(0,0,0,0.25); color:var(--text); outline:none; }
.media-post-token{ font-size:12px; opacity:.8; padding:8px 10px; border-radius:12px; border:1px solid rgba(255,255,255,0.10); background:rgba(0,0,0,0.22); margin-top:8px; }

/* =========================================================
   NAXCORE LAYOUT FIX (Timeline + Chat çakışma düzeltmesi)
   - Sidebar sabit, orta alan column
   - Media/Timeline: height:100% yerine flex:1 + min-height:0
   - Post kartları max-height + overflow
   - Input bar sticky + z-index + padding
   ========================================================= */

:root{
  --rooms-w: 240px;
  --users-w: 240px;

  --chat-header-h: 48px;

  /* sticky input / safe area */
  --input-safe: calc(8px + env(safe-area-inset-bottom));
  --input-reserved: calc(10px + var(--input-safe));
  --input-shadow: 0 -10px 30px rgba(0,0,0,0.35);

  /* timeline/post kart limitleri */
  --post-card-max-h: 560px;
  --post-media-max-h: 420px;
}

/* Ana hiyerarşi: 3 panel */
#app{
  width:100vw;
  height:100vh;
  height:100dvh;
  overflow:hidden;
}

/* Paneller: shrink/scroll sorunlarını kes */
.rooms-panel,
.users-panel,
.chat-panel{
  height:100%;
  min-height:0;
}

/* Desktop: orta panel members ile çakışmasın */
@media (min-width: 901px){
  .rooms-panel{
    flex:0 0 var(--rooms-w);
    width:var(--rooms-w);
    overflow:hidden;
  }
  .users-panel{
    flex:0 0 var(--users-w);
    width:var(--users-w);
    overflow:hidden;
  }
  .chat-panel{
    flex:1 1 auto;
    min-width:0;
    width: calc(100vw - var(--rooms-w) - var(--users-w));
    overflow:hidden;
    display:flex;
    flex-direction:column;
  }
}

/* Mobile: mevcut drawer mantığını bozma */
@media (max-width: 900px){
  .chat-panel{
    width:100vw;
    display:flex;
    flex-direction:column;
    overflow:hidden;
    min-width:0;
  }
}

@media (max-width: 900px){
  .messages-area{
    padding-bottom: 8px !important;
  }
  .input-area{
    padding-top: 6px !important;
  }
  .chat-pending-card{
    padding:10px;
    border-radius:16px;
  }
  .pending-preview-thumb{
    max-width:100%;
  }
  .pending-preview-thumb img,
  .pending-preview-thumb video{
    height:120px;
  }
  .pending-audio-sub{
    max-width:180px;
  }
  .chat-send-btn{
    width:40px;
    height:40px;
    border-radius:12px;
  }
  .message-row{
    padding-left: 12px;
    padding-right: 12px;
  }
  .msg-avatar{
    margin-right: 12px;
  }
  .message-row.compact-msg .msg-content{
    margin-left: 52px;
  }
}

/* Chat header sabit z-order */
.chat-header{
  flex:0 0 var(--chat-header-h);
  position:relative;
  z-index:30;
}

/* Mesaj alanı scroll */
.messages-area{
  flex:1 1 auto;
  min-height:0;
  overflow-y:auto;
  padding-bottom: 10px !important;
}

/* Timeline/Media channel: height:100% yerine flex */
#media-channel.media-channel,
.media-channel{
  flex:1 1 auto;
  min-height:0;
  height:auto !important;
  overflow-y:auto;
  display:flex;
  flex-direction:column;
  /* input yokken bile içerik rahat olsun */
  padding-bottom: 18px;
}

/* Input bar altta sabit + üstüne binme yok */
.input-area{
  flex:0 0 auto;

  position:sticky;
  bottom:0;
  z-index:40;

  margin-top:0 !important;
  padding:8px 16px var(--input-safe) 16px !important;

  background: var(--bg-chat) !important;
  border-top:1px solid rgba(255,255,255,0.06);
  box-shadow: var(--input-shadow);
}

/* ===== Medya/Timeline composer sıkışma fix ===== */
.media-composer{
  position:relative;
  z-index:10;
  display:flex;
  flex-direction:column;
  gap:10px;
}

/* Top row + bottom row gap */
.media-composer-top{
  gap:12px;
  flex-wrap:wrap;
}
.media-composer-bottom{
  gap:10px !important;
  flex-wrap:wrap;
}

/* Paylaş butonu / sekmeler üst üste binmesin */
.media-composer .btn,
.media-composer-actions .btn{
  position:relative;
  z-index:12;
}

/* ===== Post kartları: çok uzamasın, scroll olsun ===== */
.media-post{
  max-height: var(--post-card-max-h);
  overflow-y:auto;
  overscroll-behavior: contain;
}

/* Medya: sabit çerçeve içinde, kırpma yok (contain) */
.media-post-media{
  max-height: var(--post-media-max-h);
  overflow:hidden;
}
.media-post-media img,
.media-post-media video,
.media-post-media .media-fit{
  max-height: var(--post-media-max-h);
  object-fit: contain;
}

/* Aksiyonlar arası boşluk */
.media-post-actions{
  gap:12px !important;
}

/* Sağ panelin tıklanabilirliği garanti */
.users-panel{
  position:relative;
  z-index:50;
  pointer-events:auto;
}



/* =========================================================
   DASHBOARD (ANA MENÜ)
   - Sadece activeView==='dashboard' iken görünür
   ========================================================= */
.dashboard-view{
  flex:1 1 auto;
  min-height:0;
  overflow-y:auto;
  padding:18px 18px calc(18px + env(safe-area-inset-bottom)) 18px;
  /* Daha "kurumsal + gaming" hava: hafif neon glow / gradient */
  background:
    radial-gradient(1200px circle at 15% 10%, rgba(114,137,218,0.18), transparent 55%),
    radial-gradient(1000px circle at 85% 0%, rgba(255,105,180,0.10), transparent 50%);
}
.dash-wrap{
  max-width:1100px;
  margin:0 auto;
  display:flex;
  flex-direction:column;
  gap:16px;
}
.dash-header{
  display:flex;
  flex-direction:column;
  gap:6px;
  padding:4px 2px;
}
.dash-title{
  font-size:18px;
  font-weight:800;
  letter-spacing:.2px;
}
.dash-user{
  color: var(--primary);
}
.dash-sub{
  font-size:12px;
  opacity:.75;
}

.dash-cards{
  display:grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap:12px;
}
.dash-card{
  background: rgba(255,255,255,0.035);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius:14px;
  padding:14px 14px 12px 14px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.25);
  backdrop-filter: blur(10px);
  transition: transform .15s ease, border-color .15s ease, filter .15s ease;
}

.dash-card:hover{
  transform: translateY(-1px);
  border-color: rgba(114,137,218,0.22);
  filter: brightness(1.02);
}
.dash-card-label{
  font-size:12px;
  opacity:.75;
  margin-bottom:6px;
}
.dash-card-value{
  font-size:26px;
  font-weight:900;
  line-height:1;
}
.dash-card-mini{
  margin-top:8px;
  font-size:12px;
  opacity:.7;
}

.dash-grid{
  display:grid;
  grid-template-columns: 1fr 1fr;
  gap:12px;
}
.dash-panel{
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius:14px;
  padding:14px;
  min-height:220px;
  display:flex;
  flex-direction:column;
  gap:10px;
}
.dash-panel-title{
  font-size:13px;
  font-weight:800;
  opacity:.9;
}
.dash-actions{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
}
.dash-actions .btn{
  border-radius:12px;
  padding:10px 12px;
}

.dash-activity{
  flex:1 1 auto;
  min-height:0;
  overflow-y:auto;
  display:flex;
  flex-direction:column;
  gap:10px;
  padding-right:6px;
}
.dash-act-row{
  background: rgba(0,0,0,0.18);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius:12px;
  padding:10px 12px;
  display:flex;
  flex-direction:column;
  gap:6px;
}
.dash-act-meta{
  font-size:12px;
  opacity:.85;
  display:flex;
  gap:8px;
  flex-wrap:wrap;
}
.dash-act-room{
  color: var(--primary);
  font-weight:800;
}
.dash-act-user{
  font-weight:700;
  opacity:.95;
}
.dash-act-text{
  font-size:13px;
  opacity:.95;
  word-break:break-word;
}
.dash-act-time{
  font-size:11px;
  opacity:.65;
}

/* Main nav (Dashboard/Timeline) */
#main-nav .room-item.active{
  background: rgba(114, 137, 218, 0.18);
  border-left: 3px solid var(--primary);
}

/* Sidebar'da 2 tane Timeline görünmesini engelle
   - Sidebar Plus zaten "ANA MENÜ" altına Timeline ekliyor
   - Eski üstteki TIMELINE butonu kalsın ama görünmesin (duplicate fix)
*/
.rooms-panel .timeline-nav-btn{
  display:none !important;
}

@media (max-width: 900px){
  .dash-cards{ grid-template-columns: 1fr; }
  .dash-grid{ grid-template-columns: 1fr; }
}

/* ===== Arkadaşlar paneli layout (Friends) ===== */
.friends-panel{
  flex:1;
  overflow-x:hidden;
  overflow-y:auto;
  min-width:0;
  padding:26px 24px 24px 24px;
  background:
    radial-gradient(1200px 600px at 0% 0%, rgba(88,101,242,.22), transparent 60%),
    radial-gradient(900px 500px at 100% 100%, rgba(255,79,216,.16), transparent 55%),
    linear-gradient(180deg, #181a21, #111218);
}
.friends-inner{
  width:100%;
  max-width:min(1100px,100%);
  margin:0 auto;
  display:flex;
  flex-direction:column;
  gap:18px;
  min-width:0;
  box-sizing:border-box;
}
.friends-two-col{
  display:grid;
  grid-template-columns:1.2fr 1fr;
  gap:20px;
  min-height:0;
  min-width:0;
}
.friends-story-section,
.friends-col-dm.friends-dm-section,
.friends-col-friends.friends-list-section{
  border-radius:16px;
  background:#1f222a;
  border:1px solid rgba(255,255,255,.04);
  box-shadow:0 14px 38px rgba(0,0,0,.7);
  padding:16px 18px 14px 18px;
}
.friends-col-dm.friends-dm-section{
  background:#1c2027;
  display:flex;
  flex-direction:column;
  min-height:240px;
}
.friends-col-dm .dm-list.friends-dm-list{
  flex:1;
  min-height:0;
  overflow-y:auto;
}
.friends-col-friends.friends-list-section{
  background:#1c2027;
  display:flex;
  flex-direction:column;
  min-height:240px;
}
.friends-col-friends .friends-list{
  flex:1;
  min-height:0;
  overflow-y:auto;
}
.friends-story-strip-shell{
  margin-top:6px;
  padding:6px 6px 4px 6px;
  border-radius:12px;
  background: radial-gradient(circle at 0 0, rgba(88,101,242,.22), transparent 55%),
             radial-gradient(circle at 100% 100%, rgba(255,79,216,.20), transparent 55%),
             rgba(18,20,28,.98);
}
.friends-story-strip-shell .story-strip{
  padding-top:4px;
  padding-bottom:6px;
}

.friends-dm-list{
  padding:4px 2px 2px 2px;
  gap:6px;
}
.friends-dm-list .room-item{
  display:flex;
  align-items:center;
  gap:10px;
  padding:8px 10px;
  margin:0;
  border-radius:10px;
  background:#23262f;
  border:1px solid transparent;
  color:#e4e7ff;
  box-shadow:0 8px 24px rgba(0,0,0,.55);
  cursor:pointer;
  transition: background .14s ease, box-shadow .14s ease, border-color .14s ease, transform .14s ease;
}
.friends-dm-list .room-item:hover{
  background:linear-gradient(135deg,#2a2e3a,#232733);
  transform:translateY(-1px);
  box-shadow:0 12px 32px rgba(0,0,0,.7);
  border-color:rgba(146,164,255,.4);
}
.friends-dm-list .room-item.dm-active{
  border-color:rgba(88,101,242,.95);
  background:linear-gradient(135deg,#2b2f3d,#22253a);
  box-shadow:0 14px 38px rgba(0,0,0,.85);
}
.friends-dm-list .room-item.has-unread{
  border-color:rgba(255,79,216,.7);
}
.friends-dm-text{
  display:flex;
  flex-direction:column;
  min-width:0;
}
.friends-dm-name-row{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:8px;
  margin-bottom:2px;
}
.friends-dm-name{
  font-size:14px;
  font-weight:700;
}
.friends-dm-badge{
  min-width:18px;
  height:18px;
  padding:0 6px;
  border-radius:999px;
  background:var(--danger);
  color:#fff;
  font-size:11px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  box-shadow:0 6px 16px rgba(0,0,0,.7);
}
.friends-dm-sub{
  font-size:12px;
  color:rgba(210,214,240,.9);
  opacity:.9;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}

.friends-dm-list .room-item img,
.friends-dm-list .room-item .u-avatar-small{
  transition: transform .14s ease;
}
.friends-dm-list .room-item:hover img,
.friends-dm-list .room-item:hover .u-avatar-small{
  transform: scale(1.04);
}

@media (max-width: 900px){
  .friends-panel{
    padding:18px 12px 20px 12px;
    overflow-x:hidden;
  }
  .friends-inner,
  .friends-two-col,
  .friends-col-dm,
  .friends-col-friends,
  .friends-dm-text,
  .friends-section-header{
    min-width:0;
    overflow-wrap:break-word;
  }
  .friends-dm-name-row,
  .friends-section-main{
    min-width:0;
  }
  .friends-inner{
    gap:14px;
  }
  .friends-two-col{
    grid-template-columns:1fr;
    gap:14px;
  }
  .friends-story-section,
  .friends-col-dm.friends-dm-section,
  .friends-col-friends.friends-list-section{
    padding:12px 10px 10px 10px;
    border-radius:14px;
  }
  .friends-header-actions{
    margin-top:4px;
  }
}

/* Arkadaşlar paneli başlıkları (Storyler / Özel Mesajlar) – kurumsal stil */
.friends-section-header{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  margin-bottom:10px;
}
.friends-section-main{
  display:flex;
  align-items:baseline;
  gap:6px;
  min-width:0;
}
.friends-section-title{
  display:flex;
  align-items:center;
  gap:8px;
  font-size:13px;
  font-weight:800;
  text-transform:uppercase;
  letter-spacing:.08em;
  color:#e3e6ff;
}
.friends-section-title .friends-section-icon{
  width:18px;
  text-align:center;
  color:#9ca9ff;
}
.friends-section-sub{
  font-size:11px;
  color:rgba(198,202,230,.9);
}

/* Arkadaşlar paneli header actions: + ve bell */
.friends-list-header .friends-section-header{
  flex-wrap:wrap;
}
.friends-header-actions{
  display:flex;
  align-items:center;
  gap:8px;
  flex-shrink:0;
}
.friends-dropdown-wrap{
  position:relative;
}
.friends-btn-icon{
  width:36px;
  height:36px;
  border-radius:10px;
  border:1px solid rgba(255,255,255,.12);
  background:#23262f;
  color:#9ca9ff;
  cursor:pointer;
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:14px;
  transition:background .14s ease, border-color .14s ease, color .14s ease, transform .08s ease;
}
.friends-btn-icon:hover{
  background:linear-gradient(135deg,#2a2e3a,#25293a);
  border-color:rgba(146,164,255,.4);
  color:#b8c4ff;
}
.friends-btn-icon:active{
  transform:scale(0.96);
}
.friends-btn-bell{
  position:relative;
}
.friends-badge{
  position:absolute;
  top:-4px;
  right:-4px;
  min-width:18px;
  height:18px;
  padding:0 5px;
  border-radius:999px;
  background:linear-gradient(135deg,#ff4fd8,#e6399a);
  color:#fff;
  font-size:11px;
  font-weight:700;
  display:flex;
  align-items:center;
  justify-content:center;
  box-shadow:0 4px 12px rgba(255,79,216,.5);
}
.friends-add-dropdown,
.friends-requests-dropdown{
  position:absolute;
  top:100%;
  right:0;
  margin-top:8px;
  padding:14px;
  border-radius:14px;
  background:#1f222a;
  border:1px solid rgba(255,255,255,.08);
  box-shadow:0 20px 50px rgba(0,0,0,.85), 0 0 0 1px rgba(0,0,0,.5);
  z-index:100;
  min-width:280px;
  max-width:360px;
}
.friends-add-dropdown .friends-add-by-id-wrap{
  flex-direction:column;
  align-items:stretch;
}
.friends-add-dropdown .friends-add-by-id-input{
  width:100%;
  max-width:none;
}
.friends-dropdown-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  margin-bottom:12px;
  padding-bottom:10px;
  border-bottom:1px solid rgba(255,255,255,.08);
  font-size:13px;
  font-weight:700;
  color:#e4e7ff;
}
.friends-dropdown-sub{
  font-size:11px;
  color:rgba(198,202,230,.9);
  font-weight:500;
}
.friends-requests-dropdown .friends-requests-list{
  max-height:320px;
  overflow-y:auto;
  margin-top:0;
}

/* Özel Mesajlar header arama alanı */
.friends-dm-tools{
  width:auto;
  display:flex;
  align-items:center;
  justify-content:flex-end;
}

.friends-dm-search{
  width:100%;
  max-width:260px;
  padding:7px 32px 7px 12px;
  border-radius:999px;
  border:1px solid rgba(255,255,255,.10);
  background-color:#15171d;
  color:#e5e7ff;
  font-size:12px;
  outline:none;
  box-shadow:0 0 0 1px rgba(0,0,0,.75);
  transition:border-color .12s ease, box-shadow .12s ease, background-color .12s ease;
}

.friends-dm-search::placeholder{
  color:rgba(155,160,190,.9);
}

.friends-dm-search:focus{
  border-color:rgba(88,101,242,.95);
  box-shadow:0 0 0 1px rgba(88,101,242,.65), 0 0 18px rgba(0,0,0,.8);
  background-color:#13151b;
}

/* ===== Arkadaşlar paneli + dropdown içerikleri ===== */
.friends-section{
  border-radius:16px;
  background:#1f222a;
  border:1px solid rgba(255,255,255,.04);
  box-shadow:0 14px 38px rgba(0,0,0,.7);
  padding:16px 18px 14px 18px;
}

.friends-add-by-id-wrap{
  display:flex;
  align-items:center;
  gap:10px;
  flex-wrap:wrap;
}
.friends-add-by-id-input{
  width:180px;
  padding:8px 14px;
  border-radius:10px;
  border:1px solid rgba(255,255,255,.10);
  background:#15171d;
  color:#e5e7ff;
  font-size:13px;
  outline:none;
  transition:border-color .12s ease, box-shadow .12s ease;
}
.friends-add-by-id-input::placeholder{
  color:rgba(155,160,190,.9);
}
.friends-add-by-id-input:focus{
  border-color:rgba(88,101,242,.95);
  box-shadow:0 0 0 1px rgba(88,101,242,.5);
}
.friends-add-by-id-btn{
  font-size:12px;
  padding:8px 14px;
  border-radius:10px;
  white-space:nowrap;
}

.friends-requests-list{
  display:flex;
  flex-direction:column;
  gap:8px;
  margin-top:10px;
  padding:4px 0;
}
.friends-request-card{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding:10px 12px;
  border-radius:12px;
  background:#23262f;
  border:1px solid transparent;
  box-shadow:0 8px 24px rgba(0,0,0,.55);
  transition:background .14s ease, box-shadow .14s ease, border-color .14s ease, transform .14s ease;
}
.friends-request-card:hover{
  background:linear-gradient(135deg,#2a2e3a,#232733);
  transform:translateY(-1px);
  box-shadow:0 12px 32px rgba(0,0,0,.7);
  border-color:rgba(146,164,255,.25);
}
.friends-request-left{
  display:flex;
  align-items:center;
  gap:12px;
  flex:1;
  min-width:0;
  cursor:pointer;
}
.friends-request-avatar{
  width:44px;
  height:44px;
  border-radius:50%;
  object-fit:cover;
  flex-shrink:0;
  transition:transform .14s ease;
}
.friends-request-card:hover .friends-request-avatar{
  transform:scale(1.04);
}
.friends-request-meta{
  min-width:0;
}
.friends-request-name{
  font-size:14px;
  font-weight:700;
  color:#e4e7ff;
  margin-bottom:2px;
  line-height:1.3;
}
.friends-request-tag{
  font-size:12px;
  color:rgba(198,202,230,.9);
  font-weight:600;
}
.friends-request-sub{
  font-size:11px;
  color:rgba(170,176,210,.9);
}
.friends-request-actions{
  display:flex;
  gap:8px;
  flex-shrink:0;
}
.friends-request-actions .btn{
  font-size:11px;
  padding:6px 12px;
  border-radius:8px;
}

.friends-requests-empty,
.friends-list-empty{
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:10px;
  padding:24px 16px;
  color:rgba(170,176,210,.9);
  font-size:13px;
  text-align:center;
}
.friends-empty-icon{
  font-size:28px;
  opacity:.6;
}

.friends-list{
  display:flex;
  flex-direction:column;
  gap:6px;
  margin-top:10px;
  padding:4px 0;
}
.friends-list-item{
  display:flex;
  align-items:center;
  gap:10px;
  padding:8px 10px;
  margin:0;
  border-radius:10px;
  background:#23262f;
  border:1px solid transparent;
  color:#e4e7ff;
  box-shadow:0 8px 24px rgba(0,0,0,.55);
  cursor:pointer;
  transition:background .14s ease, box-shadow .14s ease, border-color .14s ease, transform .14s ease;
}
.friends-list-item:hover{
  background:linear-gradient(135deg,#2a2e3a,#232733);
  transform:translateY(-1px);
  box-shadow:0 12px 32px rgba(0,0,0,.7);
  border-color:rgba(146,164,255,.4);
}
.friends-list-item img{
  width:36px;
  height:36px;
  border-radius:50%;
  object-fit:cover;
  transition:transform .14s ease;
}
.friends-list-item:hover img{
  transform:scale(1.04);
}

/* Presence: status dot in DM/friends lists */
.u-avatar-wrapper{ position:relative; flex-shrink:0; }
.u-avatar-wrapper .u-status-dot{
  position:absolute; bottom:-1px; right:-1px; width:8px; height:8px; border-radius:50%;
  background:#747f8d; border:2px solid #1c2027;
}
.u-avatar-wrapper.online .u-status-dot{ background:#43b581; }
.u-status-dot-md{
  position:absolute; bottom:-2px; right:-2px; width:10px; height:10px; border-radius:50%;
  background:#747f8d; border:2px solid #1c2027;
}
.u-avatar-wrapper.online .u-status-dot-md{ background:#43b581; }

/* DM typing indicator */
.dm-typing-indicator{
  padding:6px 16px; font-size:12px; color:rgba(155,160,190,.95);
  background:rgba(20,22,30,.6); border-bottom:1px solid rgba(255,255,255,.04);
}

@media (max-width: 900px){
  .friends-add-by-id-wrap{
    width:100%;
  }
  .friends-add-by-id-input{
    flex:1;
    min-width:0;
  }
  .friends-request-card{
    flex-direction:column;
    align-items:stretch;
  }
  .friends-request-actions{
    justify-content:flex-end;
  }
}
