/* ══════════════════════════════════════════
   PushPig — CSS
   Design: dark theme, Neon Noir palette
══════════════════════════════════════════ */

[hidden] { display: none !important; }

:root {
  --bg:          #0a0a0a;
  --bg-2:        #111111;
  --bg-3:        #1a1a1a;
  --card:        #111111;
  --card-hover:  #1a1a1a;
  --border:      #2d2d2d;
  --border-2:    #3d3d3d;

  --pink:        #bf00ff;
  --pink-dark:   #9900cc;
  --pink-light:  #e066ff;
  --pink-glow:   rgba(191, 0, 255, 0.15);

  --violet:      #2cff05;
  --violet-dark: #1ecc00;

  --text:        #f0f0f0;
  --text-2:      #aaaaaa;
  --text-3:      #666666;

  --success:     #22c55e;
  --warning:     #f59e0b;
  --danger:      #ef4444;
  --info:        #38bdf8;

  --radius:      10px;
  --radius-lg:   16px;
  --radius-full: 9999px;

  --shadow:      0 4px 24px rgba(0,0,0,0.6);
  --shadow-pink: 0 0 24px rgba(191,0,255,0.25);

  --sidebar-w:   240px;
  --transition:  200ms ease;
}

/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; }
body {
  font-family: 'Inter', system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }
input, select, textarea {
  font-family: inherit;
  font-size: 0.9375rem;
  color: var(--text);
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.625rem 0.875rem;
  width: 100%;
  outline: none;
  transition: border-color var(--transition), box-shadow var(--transition);
}
input:focus, select:focus, textarea:focus {
  border-color: var(--pink);
  box-shadow: 0 0 0 3px var(--pink-glow);
}
textarea { resize: vertical; }
select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23666666' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 0.875rem center; padding-right: 2.5rem; }
label { display: block; font-size: 0.8125rem; font-weight: 500; color: var(--text-2); margin-bottom: 0.375rem; }
code { font-family: 'Courier New', monospace; }


/* ══════════════════════════════════════════
   BUTTONS
══════════════════════════════════════════ */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  padding: 0.625rem 1.25rem;
  border-radius: var(--radius);
  font-size: 0.9375rem; font-weight: 500;
  transition: all var(--transition);
  white-space: nowrap;
}
.btn-primary {
  background: linear-gradient(135deg, var(--pink) 0%, var(--violet) 100%);
  color: #fff;
  box-shadow: 0 2px 12px rgba(191,0,255,0.3);
}
.btn-primary:hover { filter: brightness(1.1); box-shadow: 0 4px 20px rgba(191,0,255,0.5); }
.btn-primary:active { transform: scale(0.97); }

.btn-outline {
  border: 1px solid var(--border-2);
  color: var(--text-2);
  background: transparent;
}
.btn-outline:hover { border-color: var(--pink); color: var(--pink); background: var(--pink-glow); }

.btn-ghost { color: var(--text-2); }
.btn-ghost:hover { background: var(--bg-3); color: var(--text); }

.btn-danger { background: var(--danger); color: #fff; }
.btn-danger:hover { filter: brightness(1.1); }

.btn-full { width: 100%; }
.btn-sm { padding: 0.375rem 0.75rem; font-size: 0.8125rem; }

.btn-icon { width: 1.1em; height: 1.1em; flex-shrink: 0; }

.btn-icon-only {
  display: flex; align-items: center; justify-content: center;
  width: 2.25rem; height: 2.25rem; border-radius: var(--radius);
  color: var(--text-3);
  transition: all var(--transition);
}
.btn-icon-only:hover { background: var(--bg-3); color: var(--pink); }
.btn-icon-only svg { width: 1.1rem; height: 1.1rem; }

/* Spinner inside button */
.btn-spinner {
  width: 1rem; height: 1rem;
  border: 2px solid rgba(255,255,255,0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }


/* ══════════════════════════════════════════
   FORM ELEMENTS
══════════════════════════════════════════ */
.form-group { margin-bottom: 1rem; }
.form-row { display: flex; align-items: center; gap: 1rem; margin-top: 1rem; }
.form-check { display: flex; align-items: center; gap: 0.5rem; margin-bottom: 1rem; }
.form-check input[type=checkbox] { width: auto; }
.optional { font-weight: 400; color: var(--text-3); font-size: 0.75rem; }


/* ══════════════════════════════════════════
   AUTH OVERLAY
══════════════════════════════════════════ */
.auth-overlay {
  position: fixed; inset: 0;
  display: flex; align-items: center; justify-content: center;
  background: radial-gradient(ellipse at 30% 20%, #1a0033 0%, var(--bg) 70%);
  z-index: 100;
  padding: 1rem;
}

.auth-card {
  width: 100%; max-width: 420px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  box-shadow: var(--shadow), var(--shadow-pink);
  animation: slideUp 0.3s ease;
}
@keyframes slideUp { from { opacity: 0; transform: translateY(16px); } }

.auth-logo {
  display: flex; align-items: center; gap: 1rem;
  margin-bottom: 1.75rem;
}
.auth-logo-img { width: 56px; height: 56px; }
.auth-title { font-size: 1.75rem; font-weight: 700; color: var(--text); }
.auth-subtitle { font-size: 0.8125rem; color: var(--text-3); margin-top: 0.125rem; }

.auth-tabs {
  display: flex; border-bottom: 1px solid var(--border);
  margin-bottom: 1.5rem;
}
.auth-tab {
  flex: 1; padding: 0.625rem 0;
  font-size: 0.9375rem; font-weight: 500;
  color: var(--text-3);
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  transition: all var(--transition);
}
.auth-tab.active { color: var(--pink); border-bottom-color: var(--pink); }
.auth-tab:hover:not(.active) { color: var(--text); }

.auth-divider {
  display: flex; align-items: center; gap: 0.75rem;
  color: var(--text-3); font-size: 0.8125rem;
  margin: 1.25rem 0;
}
.auth-divider::before, .auth-divider::after {
  content: ''; flex: 1; height: 1px; background: var(--border);
}

.auth-error {
  margin-top: 0.75rem; padding: 0.625rem 0.875rem;
  background: rgba(239,68,68,0.1); border: 1px solid rgba(239,68,68,0.3);
  border-radius: var(--radius); color: #fca5a5; font-size: 0.875rem;
}


/* ══════════════════════════════════════════
   APP LAYOUT
══════════════════════════════════════════ */
.app {
  display: flex;
  min-height: 100vh;
}


/* ── SIDEBAR ── */
.sidebar {
  width: var(--sidebar-w);
  background: var(--bg-2);
  border-right: 1px solid var(--border);
  display: flex; flex-direction: column;
  position: fixed; top: 0; left: 0; bottom: 0;
  z-index: 50;
}

.sidebar-header {
  display: flex; align-items: center; gap: 0.75rem;
  padding: 1.25rem 1rem 1rem;
  border-bottom: 1px solid var(--border);
}
.sidebar-logo-img { width: 36px; height: 36px; }
.sidebar-logo-text { font-size: 1.125rem; font-weight: 700; background: linear-gradient(135deg, var(--pink), var(--violet)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }

.sidebar-nav {
  flex: 1; padding: 0.75rem 0.625rem;
  display: flex; flex-direction: column; gap: 0.125rem;
  overflow-y: auto;
}
.nav-item {
  display: flex; align-items: center; gap: 0.75rem;
  padding: 0.625rem 0.875rem;
  border-radius: var(--radius);
  font-size: 0.9375rem; font-weight: 500;
  color: var(--text-3);
  transition: all var(--transition);
}
.nav-item svg { width: 1.125rem; height: 1.125rem; flex-shrink: 0; }
.nav-item:hover { background: var(--bg-3); color: var(--text); }
.nav-item.active { background: var(--pink-glow); color: var(--pink); }

.sidebar-footer {
  padding: 0.75rem;
  border-top: 1px solid var(--border);
  display: flex; align-items: center; gap: 0.5rem;
}
.sidebar-user { flex: 1; display: flex; align-items: center; gap: 0.625rem; min-width: 0; }
.user-avatar {
  width: 2rem; height: 2rem; border-radius: 50%;
  background: linear-gradient(135deg, var(--pink), var(--violet));
  display: flex; align-items: center; justify-content: center;
  font-size: 0.8125rem; font-weight: 700; color: #fff; flex-shrink: 0;
  overflow: hidden;
}
.user-avatar img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }
.user-info { min-width: 0; }
.user-name { display: block; font-size: 0.875rem; font-weight: 600; truncate: ellipsis; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-status { display: block; font-size: 0.6875rem; color: var(--text-3); }


/* ── MAIN CONTENT ── */
.main-content {
  margin-left: var(--sidebar-w);
  flex: 1;
  padding: 2rem;
  max-width: calc(100vw - var(--sidebar-w));
  overflow-x: hidden;
}

.view-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 1.5rem;
}
.view-header h2 { font-size: 1.5rem; font-weight: 700; }
.view-header-left { display: flex; align-items: center; gap: 1rem; }
.view-header-left h2 { margin: 0; }

/* ── Channel Detail ── */
.channel-detail-layout {
  display: flex;
  gap: 1.5rem;
  align-items: flex-start;
}
.channel-detail-feed-wrap {
  flex: 1 1 0;
  min-width: 0;
  padding: 0;
}
.channel-detail-members-wrap {
  flex: 0 0 350px;
  width: 350px;
  padding: 0;
}
.feed-item--new { animation: feedSlideIn 0.25s ease; }
@keyframes feedSlideIn {
  from { opacity: 0; transform: translateY(-6px); }
  to   { opacity: 1; transform: translateY(0); }
}

.view { display: none; }
.view.active { display: block; }


/* ── SSE STATUS BADGE ── */
.sse-badge {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.375rem 0.875rem;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-full);
  font-size: 0.8125rem; color: var(--text-2);
}
.sse-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--text-3);
  transition: background var(--transition);
}
.sse-dot.connected { background: var(--success); animation: pulse 2s infinite; }
.sse-dot.error { background: var(--danger); }
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.4; } }


/* ── STATS ── */
.stats-row {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}
.stat-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  display: flex; align-items: center; gap: 1rem;
}
.stat-icon {
  width: 2.75rem; height: 2.75rem; border-radius: var(--radius);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.stat-icon svg { width: 1.125rem; height: 1.125rem; }
.stat-icon--pink  { background: rgba(191,0,255,0.15); color: var(--pink); }
.stat-icon--violet{ background: rgba(44,255,5,0.12); color: var(--violet); }
.stat-value { font-size: 1.5rem; font-weight: 700; color: var(--text); }
.stat-label { font-size: 0.75rem; color: var(--text-3); margin-top: 0.125rem; }


/* ── CARDS ── */
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-bottom: 1.5rem;
}
.card--narrow { max-width: 540px; padding: 1.5rem; }
.card-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--border);
  font-weight: 600;
}


/* ── NOTIFICATION FEED ── */
.feed-filter-bar {
  display: flex; flex-wrap: wrap; gap: 0.375rem;
  padding: 0.625rem 1rem; border-bottom: 1px solid var(--border);
}
.feed-filter-btn {
  padding: 0.2rem 0.625rem; border-radius: 999px; font-size: 0.75rem;
  border: 1px solid var(--border); background: transparent; color: var(--text-3);
  cursor: pointer; transition: all 0.15s;
}
.feed-filter-btn:hover { border-color: var(--pink); color: var(--pink); }
.feed-filter-btn.active { background: var(--pink); border-color: var(--pink); color: #fff; }

.feed { max-height: 480px; overflow-y: auto; }
.feed-empty {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 3rem 1rem; gap: 1rem; color: var(--text-3); text-align: center;
}
.feed-empty-img { width: 64px; height: 64px; opacity: 0.4; }

.feed-item {
  display: flex; gap: 1rem;
  padding: 0.875rem 1.25rem;
  border-bottom: 1px solid var(--border);
  animation: fadeIn 0.25s ease;
  transition: background var(--transition);
}
.feed-item:last-child { border-bottom: none; }
.feed-item:hover { background: var(--card-hover); }
@keyframes fadeIn { from { opacity: 0; transform: translateY(-6px); } }

.feed-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--pink); margin-top: 0.4rem; flex-shrink: 0;
}
.feed-content { flex: 1; min-width: 0; }
.feed-channel { font-size: 0.6875rem; color: var(--text-3); text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 0.2rem; }
.feed-title { font-weight: 600; font-size: 0.9375rem; margin-bottom: 0.25rem; }
.feed-body { color: var(--text-2); font-size: 0.875rem; line-height: 1.5; white-space: pre-wrap; word-break: break-word; }
.feed-time { font-size: 0.6875rem; color: var(--text-3); margin-top: 0.375rem; }


/* ── CHANNELS GRID ── */
.channels-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1rem;
}
.channel-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  display: flex; flex-direction: column; gap: 0.75rem;
  transition: all var(--transition);
}
.channel-card:hover { border-color: var(--border-2); background: var(--card-hover); }
.channel-card-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 0.5rem; }
.channel-name { font-weight: 600; font-size: 1rem; transition: color var(--transition); }
.channel-name[data-members-btn]:hover { color: var(--pink); cursor: pointer; }
.channel-slug { font-size: 0.75rem; color: var(--text-3); font-family: monospace; }
.channel-desc { font-size: 0.875rem; color: var(--text-2); line-height: 1.5; }
.channel-meta { display: flex; align-items: center; justify-content: space-between; }
.channel-subs { font-size: 0.75rem; color: var(--text-3); }
.channel-badge {
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-full);
  font-size: 0.6875rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em;
}
.channel-badge--public  { background: rgba(34,197,94,0.15); color: var(--success); }
.channel-badge--private { background: rgba(245,158,11,0.15); color: var(--warning); }
.channel-actions { display: flex; gap: 0.5rem; align-items: center; }
.channel-actions .channel-sub-btn { flex: 1; }
.channel-delete-btn { color: var(--text-3); padding: 0.4rem; border-radius: var(--radius); }
.channel-delete-btn:hover { color: var(--danger); background: rgba(239,68,68,0.1); }
.subscribed .channel-sub-btn { background: transparent; border: 1px solid var(--border-2); color: var(--text-2); }
.subscribed .channel-sub-btn:hover { border-color: var(--danger); color: var(--danger); }


/* ── SETTINGS ── */
.settings-section { padding: 1.5rem; margin-bottom: 1.5rem; }
.settings-heading {
  display: flex; align-items: center; gap: 0.625rem;
  font-size: 1rem; font-weight: 600; margin-bottom: 0.75rem;
}
.settings-heading svg { width: 1rem; height: 1rem; color: var(--pink); }
.settings-desc { font-size: 0.875rem; color: var(--text-2); margin-bottom: 1rem; }
.settings-hint { font-size: 0.8125rem; color: var(--text-3); margin-bottom: 0.5rem; }
.settings-divider { border: none; border-top: 1px solid var(--border); margin: 1.25rem 0; }

/* ── Help / Markdown ── */
.help-content h1, .help-content h2 { font-weight: 700; margin: 1.5rem 0 0.75rem; color: var(--text-1); }
.help-content h1 { font-size: 1.5rem; border-bottom: 1px solid var(--border); padding-bottom: 0.5rem; }
.help-content h2 { font-size: 1.125rem; color: var(--pink); }
.help-content h3 { font-size: 1rem; font-weight: 600; margin: 1rem 0 0.5rem; }
.help-content p  { color: var(--text-2); margin-bottom: 0.75rem; line-height: 1.6; }
.help-content code { background: var(--bg-3); border: 1px solid var(--border); border-radius: 4px; padding: 0.1em 0.35em; font-size: 0.875em; color: var(--pink); }
.help-content pre { background: var(--bg-3); border: 1px solid var(--border); border-radius: var(--radius); padding: 1rem; overflow-x: auto; margin-bottom: 1rem; }
.help-content pre code { background: none; border: none; padding: 0; color: var(--text-1); }
.help-content table { width: 100%; border-collapse: collapse; margin-bottom: 1rem; font-size: 0.875rem; }
.help-content th { background: var(--bg-3); color: var(--text-1); font-weight: 600; text-align: left; padding: 0.5rem 0.75rem; border: 1px solid var(--border); }
.help-content td { padding: 0.5rem 0.75rem; border: 1px solid var(--border); color: var(--text-2); }
.help-content hr { border: none; border-top: 1px solid var(--border); margin: 1.5rem 0; }
.help-content ul, .help-content ol { padding-left: 1.5rem; margin-bottom: 0.75rem; color: var(--text-2); }

.qr-wrap {
  display: inline-block;
  background: #fff; border-radius: var(--radius);
  padding: 0.75rem; margin-bottom: 1rem;
}
.secret-code {
  display: block;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.625rem 0.875rem;
  font-size: 0.875rem;
  color: var(--pink-light);
  word-break: break-all;
  margin-bottom: 1rem;
  letter-spacing: 0.1em;
}

.passkeys-list { display: flex; flex-direction: column; gap: 0.5rem; }
.passkey-item {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0.75rem 1rem;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.passkey-name { font-weight: 500; font-size: 0.9375rem; }
.passkey-meta { font-size: 0.75rem; color: var(--text-3); margin-top: 0.125rem; }
.passkey-delete { color: var(--text-3); }
.passkey-delete:hover { color: var(--danger); }
.passkey-delete svg { width: 1rem; height: 1rem; }


/* ── SEND ── */
.send-result { font-size: 0.875rem; }
.send-result.success { color: var(--success); }
.send-result.error   { color: var(--danger); }


/* ── MODAL ── */
.modal-overlay {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(0,0,0,0.65);
  display: flex; align-items: center; justify-content: center;
  padding: 1rem;
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
  animation: fadeIn 0.15s ease;
}
.modal {
  width: 100%; max-width: 460px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  animation: slideUp 0.2s ease;
}
.modal-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--border);
  font-weight: 600;
}
.modal-close { color: var(--text-3); padding: 0.25rem; border-radius: 4px; }
.modal-close:hover { color: var(--text); }
.modal-body { padding: 1.5rem; }
.modal-footer {
  display: flex; justify-content: flex-end; gap: 0.75rem;
  padding: 1rem 1.5rem;
  border-top: 1px solid var(--border);
}


/* ── TOASTS ── */
#toast-container {
  position: fixed; bottom: 1.5rem; right: 1.5rem;
  display: flex; flex-direction: column; gap: 0.625rem;
  z-index: 999;
}
.toast {
  display: flex; align-items: center; gap: 0.75rem;
  padding: 0.75rem 1.125rem;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  font-size: 0.875rem;
  max-width: 340px;
  animation: slideRight 0.25s ease;
}
@keyframes slideRight { from { opacity: 0; transform: translateX(24px); } }
.toast-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.toast.success .toast-dot { background: var(--success); }
.toast.error   .toast-dot { background: var(--danger); }
.toast.info    .toast-dot { background: var(--info); }


/* ── LOADING ── */
.loading-spinner-wrap { display: flex; justify-content: center; padding: 2rem; }
.loading-spinner {
  width: 32px; height: 32px; border-radius: 50%;
  border: 3px solid var(--border);
  border-top-color: var(--pink);
  animation: spin 0.7s linear infinite;
}


/* ── AVATAR UPLOAD ── */
.avatar-upload-row {
  display: flex; align-items: center; gap: 1.25rem;
  margin-bottom: 1rem;
}
.avatar-upload-preview {
  width: 4.5rem; height: 4.5rem; border-radius: 50%; flex-shrink: 0;
  background: linear-gradient(135deg, var(--pink), var(--violet));
  display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem; font-weight: 700; color: #fff;
  overflow: hidden;
  border: 2px solid var(--border);
}
.avatar-upload-preview img { width: 100%; height: 100%; object-fit: cover; }
.avatar-upload-info { display: flex; flex-direction: column; gap: 0.375rem; }
.btn-sm { padding: 0.375rem 0.875rem; font-size: 0.875rem; }


/* ── MOBILE TOPBAR ── */
.mobile-topbar {
  display: none;
}

.hamburger {
  display: flex; flex-direction: column; justify-content: center; gap: 5px;
  width: 2.25rem; height: 2.25rem;
  background: none; border: none; cursor: pointer; padding: 0.25rem; flex-shrink: 0;
}
.hamburger span {
  display: block; height: 2px; border-radius: 2px;
  background: var(--text);
  transition: transform var(--transition), opacity var(--transition);
}

.sidebar-overlay {
  display: none;
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.5);
  z-index: 49;
}

/* ── RESPONSIVE ── */
@media (max-width: 680px) {
  :root { --sidebar-w: 0px; }

  .mobile-topbar {
    display: flex; align-items: center; gap: 0.625rem;
    position: fixed; top: 0; left: 0; right: 0; height: 3.25rem;
    padding: 0 1rem;
    background: var(--bg-2);
    border-bottom: 1px solid var(--border);
    z-index: 60;
  }

  .sidebar {
    position: fixed; top: 0; left: 0; bottom: 0;
    width: 16rem;
    transform: translateX(-100%);
    transition: transform 0.25s ease;
    z-index: 50;
    display: flex;
  }

  .sidebar.is-open {
    transform: translateX(0);
  }

  .sidebar-overlay.is-open {
    display: block;
  }

  .main-content {
    margin-left: 0;
    padding: 1rem;
    padding-top: calc(3.25rem + 1rem);
    max-width: 100vw;
  }

  .channel-detail-layout { flex-direction: column; }
  .channel-detail-members-wrap { width: 100%; flex: unset; }
}
