/* ---------- Menu drawer ---------- */

.drawer {
  position: fixed;
  inset: 0;
  z-index: 20;
  background: rgba(16, 17, 19, 0.18);
  animation: fade 0.2s ease;
}
.drawer-panel {
  position: absolute;
  inset: 0 auto 0 0;
  width: min(440px, 100%);
  background: #fff;
  display: flex;
  flex-direction: column;
  box-shadow: 8px 0 40px rgba(16, 17, 19, 0.08);
  animation: slide-in 0.28s cubic-bezier(0.3, 0.8, 0.25, 1);
}
@keyframes slide-in { from { transform: translateX(-100%); } }
@keyframes fade { from { opacity: 0; } }

.drawer-head {
  display: grid;
  grid-template-columns: 48px 1fr 48px;
  align-items: center;
  padding: calc(14px + env(safe-area-inset-top)) 16px 16px;
}
.drawer-title { grid-column: 2; text-align: center; font-size: 1.125rem; font-weight: 600; }
.drawer-head .round-btn { grid-column: 3; }

.drawer-scroll { flex: 1; overflow-y: auto; padding: 0 0 120px; scrollbar-width: none; }
.drawer-scroll::-webkit-scrollbar { display: none; }

.main-chat {
  display: flex;
  align-items: center;
  margin: 0 16px;
  height: 46px;
  padding: 0 20px;
  border-radius: 999px;
  background: var(--bubble);
  font-size: 1.0625rem;
  font-weight: 600;
  text-decoration: none;
}
.main-chat.current { background: var(--pill-active); }

.drawer-rule { height: 1px; background: var(--border); margin: 14px 0 6px; }

.side-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 18px 4px 28px;
  font-size: 1.0625rem;
  color: var(--text-3);
  font-weight: 500;
}

.side-list { display: flex; flex-direction: column; padding: 0 12px; }
.side-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 16px;
  min-height: 52px;
  border-radius: 16px;
  text-decoration: none;
  font-size: 1.0625rem;
}
.side-item:hover { background: var(--muted); }
.side-item.current { background: var(--muted); }
.side-item .title { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.side-item .unread { width: 10px; height: 10px; border-radius: 50%; background: var(--accent); flex: none; }
.side-item .row-act {
  opacity: 0;
  border: 0;
  background: none;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--text-2);
  cursor: pointer;
  padding: 6px 8px;
  border-radius: 8px;
}
.side-item:hover .row-act, .side-item:focus-within .row-act { opacity: 1; }
.side-item .row-act:hover { color: var(--text); background: #fff; }
@media (hover: none) { .side-item .row-act { opacity: 1; } }
.side-empty { padding: 12px 28px; color: var(--text-3); font-size: 0.9375rem; line-height: 1.5; }

.drawer-bottom {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 28px 16px calc(16px + env(safe-area-inset-bottom));
  background: linear-gradient(rgba(255, 255, 255, 0), #fff 30%);
}
.drawer-bottom .round-btn { flex: none; }
.search-pill {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  height: 48px;
  padding: 0 18px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid var(--border);
  box-shadow: 0 2px 10px rgba(16, 17, 19, 0.06);
  color: var(--text-2);
}
.search-pill svg { width: 22px; height: 22px; flex: none; }
.search-pill input { flex: 1; min-width: 0; border: 0; outline: 0; font: inherit; font-size: 1.0625rem; background: transparent; color: var(--text); }
.search-pill input::-webkit-search-cancel-button { display: none; }
