html {
  height: 100%;
  --bg-primary: #0c0c14;
  --bg-secondary: #14141f;
  --bg-tertiary: #1c1c2e;
  --bg-elevated: #1e1e30;
  --surface: #181825;
  --text-primary: #eeeef8;
  --text-secondary: #8888aa;
  --text-muted: #666688;
  --accent: #7c6cf7;
  --accent-hover: #9280ff;
  --accent-subtle: #7c6cf722;
  --danger: #ef4444;
  --danger-hover: #ff5555;
  --success: #10b981;
  --success-hover: #34d399;
  --warning: #f59e0b;
  --warning-hover: #fbbf24;
  --border: #2a2a40;
  --border-light: #222238;
  --radius-sm: 6px;
  --radius: 10px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.3);
  --shadow: 0 4px 16px rgba(0,0,0,0.3);
  --shadow-lg: 0 12px 40px rgba(0,0,0,0.5);
  --glow: 0 0 20px rgba(124,108,247,0.15);
  --transition: 200ms ease;
  --sidebar-width: 260px;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  color-scheme: dark;
  background: var(--bg-primary);
}

*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html { height: 100%; }

html[data-theme="light"] {
  --bg-primary: #f5f6fa;
  --bg-secondary: #ffffff;
  --bg-tertiary: #eeeff5;
  --bg-elevated: #ffffff;
  --surface: #fafbfd;
  --text-primary: #000000;
  --text-secondary: #1f2937;
  --text-muted: #4b5563;
  --accent: #6c5ce7;
  --accent-hover: #5a4bd1;
  --accent-subtle: #6c5ce715;
  --danger: #dc2626;
  --danger-hover: #b91c1c;
  --success: #059669;
  --success-hover: #047857;
  --warning: #d97706;
  --warning-hover: #b45309;
  --border: #d1d5db;
  --border-light: #e5e7eb;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.1);
  --shadow: 0 4px 16px rgba(0,0,0,0.1);
  --shadow-lg: 0 12px 40px rgba(0,0,0,0.15);
  --glow: 0 0 20px rgba(108,92,231,0.1);
  color-scheme: light;
}

a { color: var(--accent); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--accent-hover); }

body {
  min-height: 100%;
  font-family: var(--font);
  background: radial-gradient(circle at top, color-mix(in srgb, var(--accent) 12%, transparent), transparent 32%), var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4, h5, h6 { color: var(--text-primary); letter-spacing: -0.02em; }
h1 { font-size: 28px; font-weight: 700; }
h2 { font-size: 22px; font-weight: 700; margin-bottom: 16px; }
h3 { font-size: 16px; font-weight: 600; margin-bottom: 12px; }

::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 2px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-muted); }

/* ─── Buttons ─── */
button { cursor: pointer; border: none; font-family: var(--font); transition: all var(--transition); line-height: 1; }
button { color: inherit; }

.btn,
.btn-primary,
.btn-secondary,
.btn-danger,
.btn-ghost,
.btn-ban,
.btn-unban,
.btn-small,
.btn-sm,
.btn-xs,
.btn-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 22px;
  font-size: 14px;
  font-weight: 600;
  border-radius: 10px;
  white-space: nowrap;
}

.btn-primary {
  background: var(--accent);
  color: #fff;
  border: 1px solid var(--accent);
  padding: 10px 24px;
}
.btn-primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); box-shadow: 0 2px 12px rgba(124,108,247,0.3); transform: translateY(-1px); }
.btn-primary:active { transform: translateY(0); opacity: 0.92; }

.btn-secondary {
  background: var(--bg-tertiary);
  color: var(--text-primary);
  border: 1px solid var(--border);
}
.btn-secondary:hover { background: color-mix(in srgb, var(--bg-tertiary) 90%, var(--accent)); border-color: var(--accent); }

.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid transparent;
  padding: 6px 10px;
  border-radius: 8px;
}
.btn-ghost:hover { background: var(--bg-tertiary); border-color: var(--border); color: var(--text-primary); }

.btn-danger {
  background: transparent;
  color: var(--danger);
  border: 1px solid var(--danger);
}
.btn-danger:hover { background: var(--danger); color: #fff; }

.btn-delete {
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid var(--border);
  padding: 6px 10px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
}
.btn-delete:hover {
  background: var(--danger);
  color: #fff;
  border-color: var(--danger);
}

.btn-ban { background: var(--danger); color: #fff; border: 1px solid var(--danger); }
.btn-ban:hover { opacity: 0.9; }
.btn-unban { background: var(--success); color: #fff; border: 1px solid var(--success); }
.btn-unban:hover { opacity: 0.9; }

.btn-small, .btn-sm { padding: 6px 14px; font-size: 12px; font-weight: 600; border-radius: 8px; }
.btn-xs { padding: 4px 10px; font-size: 11px; border-radius: 6px; }

.btn-icon { width: 36px; height: 36px; padding: 0; font-size: 16px; border-radius: 8px; }
.btn-icon.btn-ghost { padding: 0; }

/* ─── Inputs ─── */
input, textarea, select {
  font-family: var(--font);
  font-size: 14px;
  padding: 10px 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-secondary);
  color: var(--text-primary);
  outline: none;
  transition: border-color var(--transition), box-shadow var(--transition);
}
input:focus, textarea:focus, select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-subtle);
}
input::placeholder, textarea::placeholder { color: var(--text-muted); }

label { display: block; font-size: 13px; font-weight: 600; color: var(--text-secondary); margin-bottom: 6px; }

/* ─── App Shell ─── */
.app-shell {
  display: flex;
  min-height: 100vh;
  min-height: 100svh;
  background:
    radial-gradient(circle at top left, color-mix(in srgb, var(--accent) 12%, transparent), transparent 32%),
    radial-gradient(circle at bottom right, color-mix(in srgb, var(--accent) 8%, transparent), transparent 24%),
    var(--bg-primary);
  overflow: hidden;
}

.sidebar {
  width: var(--sidebar-width);
  background: color-mix(in srgb, var(--bg-secondary) 92%, transparent);
  border-right: 1px solid var(--border-light);
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  position: relative;
  z-index: 10;
  backdrop-filter: blur(18px);
  box-shadow: var(--shadow-sm);
}

.sidebar-header {
  padding: 20px 20px 16px;
  display: flex;
  gap: 10px;
  align-items: flex-start;
  justify-content: flex-start;
  flex-wrap: wrap;
  border-bottom: 1px solid var(--border-light);
}
.sidebar-header h2 {
  font-size: 20px;
  font-weight: 800;
  flex: 1 1 100%;
  min-width: 0;
  background: linear-gradient(135deg, #7c6cf7, #a855f7);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin: 0;
}
.sidebar-header-actions {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 4px;
  flex-wrap: wrap;
  min-width: 0;
  width: 100%;
}

.sidebar-nav {
  flex: 1;
  padding: 8px 10px;
  display: flex;
  flex-direction: column;
  gap: 1px;
  overflow-y: auto;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  color: var(--text-secondary);
  font-size: 13.5px;
  font-weight: 500;
  border-radius: var(--radius-sm);
  transition: all var(--transition);
  text-decoration: none;
}
.nav-item:hover { background: var(--bg-tertiary); color: var(--text-primary); }
.nav-item.active {
  background: var(--accent-subtle);
  color: var(--accent);
  font-weight: 600;
}
.nav-item .nav-icon { font-size: 16px; width: 20px; text-align: center; flex-shrink: 0; }

.sidebar-footer {
  padding: 12px 14px;
  border-top: 1px solid var(--border-light);
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.sidebar-footer button {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  text-align: left;
  padding: 8px 12px;
  background: transparent;
  color: var(--text-secondary);
  font-size: 13px;
  border-radius: var(--radius-sm);
}
.sidebar-footer button:hover { background: var(--bg-tertiary); color: var(--text-primary); }

.notif-btn { position: relative; }
.notif-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  background: var(--danger);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  border: 2px solid var(--bg-secondary);
}

.main-content {
  flex: 1;
  min-width: 0;
  min-height: 0;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  background: transparent;
  color: var(--text-primary);
}
.main-content.full {
  align-items: center;
  justify-content: center;
}

/* ─── Screen Layout ─── */
#screen-content {
  flex: 1;
  min-height: 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  animation: fadeIn 250ms ease;
}

#screen-content > div {
  flex: 1;
  min-height: 0;
  min-width: 0;
  display: flex;
}

#screen-content > div > * {
  flex: 1;
  min-height: 0;
  min-width: 0;
}
@keyframes fadeIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: translateY(0); } }

.screen { flex: 1; padding: 28px; max-width: 1120px; width: 100%; margin: 0 auto; }
.screen-wide { flex: 1; display: flex; flex-direction: column; }

.surface-card {
  background: linear-gradient(180deg, color-mix(in srgb, var(--bg-secondary) 94%, white 6%), var(--bg-secondary));
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}

.dashboard-section {
  padding: 20px;
}

.dashboard-section .section-header {
  margin-bottom: 14px;
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 16px;
  margin-bottom: 16px;
}

.section-header h2,
.section-header h3 { margin: 0; }

.section-header p {
  color: var(--text-secondary);
  font-size: 13px;
  margin-top: 4px;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(280px, 0.9fr);
  gap: 16px;
}

.hero-copy {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
  padding: 5px 10px;
  border-radius: 999px;
  background: var(--accent-subtle);
  color: var(--accent);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.hero-panel {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

.stat-pill {
  padding: 16px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: color-mix(in srgb, var(--bg-primary) 72%, transparent);
}

.stat-pill strong {
  display: block;
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.stat-pill span {
  display: block;
  color: var(--text-secondary);
  font-size: 12px;
  margin-top: 3px;
}

.quick-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
}

.quick-action {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 16px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: color-mix(in srgb, var(--bg-secondary) 90%, transparent);
  color: var(--text-primary);
  transition: transform var(--transition), border-color var(--transition), box-shadow var(--transition);
}

.quick-action:hover {
  transform: translateY(-2px);
  border-color: var(--accent);
  box-shadow: var(--shadow-sm);
}

.quick-action strong { font-size: 14px; }
.quick-action small { color: var(--text-secondary); font-size: 12px; }

.activity-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.activity-item {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 14px 16px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: color-mix(in srgb, var(--bg-secondary) 88%, transparent);
}

.activity-item.unread {
  border-color: color-mix(in srgb, var(--accent) 35%, var(--border));
  box-shadow: 0 0 0 1px var(--accent-subtle);
}

.activity-icon {
  width: 34px;
  height: 34px;
  flex-shrink: 0;
  border-radius: 10px;
  background: var(--accent-subtle);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
}

.activity-item strong {
  display: block;
  font-size: 13px;
}

.activity-item p {
  color: var(--text-secondary);
  font-size: 12px;
  margin-top: 2px;
}

.activity-item small {
  color: var(--text-muted);
  font-size: 11px;
}

/* ─── Auth Screens ─── */
.auth-screen {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  width: 100%;
  padding: 24px;
  background: radial-gradient(ellipse at top, var(--accent-subtle), transparent 60%);
}
.auth-card {
  background: linear-gradient(180deg, color-mix(in srgb, var(--bg-secondary) 96%, white 4%), var(--bg-secondary));
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 40px 36px;
  width: 100%;
  max-width: 400px;
  box-shadow: var(--shadow-lg);
  animation: slideUp 300ms ease;
}
@keyframes slideUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }
.auth-card h1 { text-align: center; margin-bottom: 4px; }
.auth-subtitle { text-align: center; color: var(--text-secondary); margin-bottom: 28px; font-size: 14px; }
.form-group { margin-bottom: 18px; }
.form-group label { display: block; margin-bottom: 6px; font-size: 13px; font-weight: 600; color: var(--text-secondary); }
.form-group input, .form-group textarea { width: 100%; }
.auth-link { text-align: center; margin-top: 20px; font-size: 13px; color: var(--text-secondary); }
.auth-link a { font-weight: 600; }
.auth-card form .btn-primary,
.auth-card form .btn-danger { width: 100%; padding: 12px 24px; font-size: 15px; }
.success-message { background: var(--success); color: #fff; padding: 12px 16px; border-radius: var(--radius); margin-bottom: 16px; font-size: 14px; font-weight: 500; }
.error-message { background: var(--danger); color: #fff; padding: 12px 16px; border-radius: var(--radius); margin-bottom: 16px; font-size: 14px; font-weight: 500; }
.info-message { background: var(--accent-subtle); color: var(--accent); border: 1px solid var(--accent); padding: 12px 16px; border-radius: var(--radius); margin-bottom: 16px; font-size: 14px; }

/* ─── Dashboard ─── */
.dashboard {
  flex: 1;
  padding: 28px;
  max-width: 1120px;
  width: 100%;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 16px;
}
.dashboard-card {
  background: linear-gradient(180deg, color-mix(in srgb, var(--bg-secondary) 96%, white 4%), var(--bg-secondary));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 20px;
  transition: all var(--transition);
  cursor: pointer;
}
.dashboard-card:hover { border-color: var(--accent); transform: translateY(-2px); box-shadow: var(--shadow); }
.dashboard-card h3 { font-size: 14px; color: var(--text-secondary); margin-bottom: 4px; }
.dashboard-card .card-value { font-size: 28px; font-weight: 800; color: var(--text-primary); margin-bottom: 8px; }
.dashboard-card p { color: var(--text-secondary); font-size: 12px; }

/* ─── Feed ─── */
.feed-screen { flex: 1; padding: 28px; max-width: 680px; width: 100%; margin: 0 auto; }
.create-post {
  background: linear-gradient(180deg, color-mix(in srgb, var(--bg-secondary) 94%, white 6%), var(--bg-secondary));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 24px;
}
.create-post textarea { width: 100%; resize: vertical; min-height: 80px; margin-bottom: 12px; }
.create-post .btn-primary { width: auto; }

.post-card {
  background: linear-gradient(180deg, color-mix(in srgb, var(--bg-secondary) 96%, white 4%), var(--bg-secondary));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 12px;
  transition: border-color var(--transition);
}
.post-card:hover { border-color: var(--border); }
.post-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.post-author { font-weight: 600; font-size: 14px; }
.post-date { color: var(--text-muted); font-size: 12px; }
.post-content { margin-bottom: 14px; line-height: 1.6; font-size: 14px; }
.post-actions { display: flex; gap: 4px; }
.post-actions button { background: transparent; color: var(--text-muted); padding: 6px 12px; border-radius: var(--radius-sm); font-size: 13px; font-weight: 500; }
.post-actions button:hover { background: var(--bg-tertiary); color: var(--text-primary); }
.post-actions button.liked { color: var(--danger); }
.comments { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--border-light); }
.comment { font-size: 13px; padding: 8px 0; }
.comment strong { color: var(--accent); margin-right: 6px; }
.comment small { color: var(--text-muted); margin-left: 8px; }

/* ─── Chat ─── */
.chat-screen { flex: 1; display: flex; overflow: hidden; }
.chat-screen {
  min-height: 0;
  min-width: 0;
}
.chat-sidebar {
  width: 280px;
  background: color-mix(in srgb, var(--bg-secondary) 92%, transparent);
  border-right: 1px solid var(--border-light);
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  min-height: 0;
}
.chat-sidebar-header { padding: 20px 16px 10px; border-bottom: 1px solid var(--border-light); }
.chat-sidebar-header h3 { margin: 0; font-size: 15px; }
.chat-sidebar-header small { color: var(--text-muted); font-size: 12px; display: block; margin-top: 4px; }
.chat-search-wrap { padding: 12px 12px 4px; }
.chat-search-wrap input { width: 100%; }
.chat-list { flex: 1; overflow-y: auto; padding: 8px; }
.chat-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: background var(--transition), border-color var(--transition), transform var(--transition);
  border: 1px solid transparent;
}
.chat-item:hover { background: var(--bg-tertiary); border-color: var(--border); }
.chat-item.active { background: var(--accent-subtle); border-color: color-mix(in srgb, var(--accent) 35%, var(--border)); }
.chat-item-avatar {
  width: 36px; height: 36px; border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), #a855f7);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 14px; font-weight: 700;
  flex-shrink: 0;
  position: relative;
}
.online-dot {
  position: absolute;
  bottom: -1px; right: -1px;
  width: 12px; height: 12px;
  border-radius: 50%;
  background: var(--success);
  border: 2px solid var(--bg-secondary);
}
.chat-item-info { flex: 1; min-width: 0; }
.chat-item-info strong { display: block; font-size: 13px; }
.chat-item-info small { color: var(--text-muted); font-size: 11px; display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chat-item-time { font-size: 10px; color: var(--text-muted); flex-shrink: 0; }
#new-chat-btn { margin: 8px 12px; width: auto; }

.chat-main {
  flex: 1;
  min-height: 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
}
.chat-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 20px;
  border-bottom: 1px solid var(--border-light);
  background: color-mix(in srgb, var(--bg-secondary) 88%, transparent);
}
.chat-header-info { display: flex; align-items: center; gap: 10px; }
.chat-header-info strong { font-size: 14px; }
.call-buttons { display: flex; gap: 4px; }

.messages {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.msg { display: flex; gap: 8px; max-width: 75%; margin-bottom: 2px; }
.msg-own { align-self: flex-end; flex-direction: row-reverse; }
.msg-other { align-self: flex-start; }

.msg-avatar {
  width: 28px; height: 28px; border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), #a855f7);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 11px; font-weight: 700;
  flex-shrink: 0;
  align-self: flex-end;
}

.msg-body { padding: 8px 14px; border-radius: 14px; font-size: 14px; line-height: 1.5; }
.msg-own .msg-body { background: var(--accent); color: #fff; border-bottom-right-radius: 4px; }
.msg-other .msg-body { background: var(--bg-tertiary); border-bottom-left-radius: 4px; }
.msg-body p { margin: 0; }
.msg-time { font-size: 10px; opacity: 0.5; display: block; margin-top: 2px; text-align: right; }

.message-input {
  display: flex;
  gap: 8px;
  padding: 14px 20px;
  border-top: 1px solid var(--border-light);
  background: color-mix(in srgb, var(--bg-secondary) 88%, transparent);
}
.message-input input { flex: 1; }
.message-input .btn-primary { width: auto; }

/* ─── Files ─── */
.files-screen { flex: 1; padding: 28px; max-width: 800px; width: 100%; margin: 0 auto; }
.file-upload {
  display: flex;
  gap: 12px; align-items: center;
  background: linear-gradient(180deg, color-mix(in srgb, var(--bg-secondary) 94%, white 6%), var(--bg-secondary));
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 24px;
}
.file-upload input[type="file"] { flex: 1; padding: 4px; border: none; background: transparent; }
.file-upload input[type="file"]::file-selector-button {
  padding: 6px 14px; border-radius: var(--radius-sm); border: 1px solid var(--border);
  background: var(--bg-tertiary); color: var(--text-primary); cursor: pointer; font-family: var(--font); font-size: 13px; font-weight: 500;
}
.file-upload input[type="file"]::file-selector-button:hover { background: var(--border); }
.file-upload .btn-primary { width: auto; }
.file-list { display: flex; flex-direction: column; gap: 6px; }
.file-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 16px;
  background: linear-gradient(180deg, color-mix(in srgb, var(--bg-secondary) 96%, white 4%), var(--bg-secondary));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: border-color var(--transition);
}
.file-item:hover { border-color: var(--text-muted); }
.file-icon { font-size: 18px; }
.file-name { flex: 1; font-weight: 500; }
.file-size { color: var(--text-muted); font-size: 12px; }
.file-item .btn-ghost { color: var(--text-muted); font-size: 16px; }
.file-item .btn-ghost:hover { color: var(--danger); background: transparent; }

/* ─── AI ─── */
.ai-screen {
  flex: 1;
  min-height: 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.ai-header { padding: 24px 28px 8px; }
.ai-header h2 { margin: 0; }
.ai-header p { margin: 2px 0 0; font-size: 13px; }

.ai-messages {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 12px 28px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.ai-msg { display: flex; gap: 12px; padding: 14px 18px; border-radius: var(--radius); max-width: 80%; }
.ai-msg.user { align-self: flex-end; background: var(--accent); color: #fff; }
.ai-msg.assistant { align-self: flex-start; background: linear-gradient(180deg, color-mix(in srgb, var(--bg-secondary) 96%, white 4%), var(--bg-secondary)); border: 1px solid var(--border); }

.ai-msg-avatar { width: 32px; height: 32px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 16px; flex-shrink: 0; background: var(--bg-tertiary); }
.ai-msg.user .ai-msg-avatar { background: rgba(255,255,255,0.15); }
.ai-msg-body { flex: 1; min-width: 0; }
.ai-msg-body p { font-size: 14px; line-height: 1.6; white-space: pre-wrap; }
.ai-msg-body .loading-spinner { display: inline-block; width: 14px; height: 14px; border-width: 2px; margin-right: 6px; vertical-align: middle; }
.ai-msg-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 4px; }
.ai-msg-header strong { font-size: 13px; }
.ai-msg-header small { font-size: 11px; opacity: 0.6; }

.ai-input {
  display: flex;
  gap: 8px;
  padding: 16px 28px;
  border-top: 1px solid var(--border-light);
  background: var(--bg-secondary);
  flex-shrink: 0;
}
.ai-input textarea { flex: 1; resize: none; min-height: 44px; max-height: 120px; padding: 10px 14px; }
.ai-input .btn-primary { width: auto; padding: 10px 20px; }

/* ─── Admin ─── */
.admin-screen { flex: 1; padding: 28px; max-width: 900px; width: 100%; margin: 0 auto; }
.stats-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-bottom: 32px; }
.stat-card {
  background: linear-gradient(180deg, color-mix(in srgb, var(--bg-secondary) 96%, white 4%), var(--bg-secondary));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 20px;
  text-align: center;
}
.stat-card h3 { font-size: 28px; color: var(--accent); margin: 0; }
.stat-card p { color: var(--text-secondary); font-size: 13px; margin-top: 4px; }
.admin-table { width: 100%; border-collapse: collapse; }
.admin-table th, .admin-table td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--border-light); font-size: 13px; }
.admin-table th { color: var(--text-secondary); font-weight: 600; font-size: 11px; text-transform: uppercase; letter-spacing: 0.05em; }
.admin-table tr:hover td { background: var(--bg-tertiary); }

/* ─── Profile ─── */
.profile-screen { flex: 1; padding: 28px; max-width: 600px; width: 100%; margin: 0 auto; }
.profile-header { text-align: center; margin-bottom: 28px; }
.profile-avatar { width: 80px; height: 80px; border-radius: 50%; background: linear-gradient(135deg, var(--accent), #a855f7); color: #fff; font-size: 32px; font-weight: 700; display: flex; align-items: center; justify-content: center; margin: 0 auto 16px; }
.profile-stats { display: flex; justify-content: center; gap: 40px; }
.profile-stats strong { display: block; text-align: center; font-size: 22px; }
.profile-stats span { display: block; text-align: center; font-size: 12px; color: var(--text-secondary); margin-top: 2px; }
.bio { color: var(--text-secondary); margin-top: 12px; font-size: 14px; }
.profile-actions {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 16px;
}

.follow-btn { margin-top: 16px; }

/* ─── Turnstile ─── */
.turnstile-container { display: flex; justify-content: center; margin: 16px 0; min-height: 65px; }

/* ─── Search ─── */
.search-screen { flex: 1; padding: 28px; max-width: 800px; width: 100%; margin: 0 auto; }
.search-bar { display: flex; gap: 8px; margin-bottom: 20px; }
.search-bar input { flex: 1; }
.search-tabs { display: flex; gap: 4px; margin-bottom: 20px; flex-wrap: wrap; }
.tab-btn {
  padding: 6px 14px;
  background: color-mix(in srgb, var(--bg-secondary) 94%, transparent);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  transition: all var(--transition);
}
.tab-btn:hover { border-color: var(--accent); color: var(--accent); }
.tab-btn.active { background: var(--accent); border-color: var(--accent); color: #fff; font-weight: 500; }
.search-results { display: flex; flex-direction: column; gap: 6px; }
.search-item {
  display: flex;
  gap: 12px;
  padding: 12px 16px;
  background: linear-gradient(180deg, color-mix(in srgb, var(--bg-secondary) 96%, white 4%), var(--bg-secondary));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
  transition: all var(--transition);
}
.search-item:hover { border-color: var(--accent); }
.search-item-avatar { width: 36px; height: 36px; border-radius: 50%; background: linear-gradient(135deg, var(--accent), #a855f7); color: #fff; display: flex; align-items: center; justify-content: center; flex-shrink: 0; font-weight: 700; }
.search-item-info { flex: 1; min-width: 0; }
.search-item-info strong { display: block; font-size: 14px; }
.search-item-info small { color: var(--text-muted); font-size: 12px; }
.search-item-info p { color: var(--text-secondary); font-size: 13px; margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ─── Notes ─── */
.notes-screen { flex: 1; display: flex; overflow: hidden; }
.notes-sidebar {
  width: 260px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  background: color-mix(in srgb, var(--bg-secondary) 92%, transparent);
  border-right: 1px solid var(--border-light);
}
.notes-sidebar-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 16px 14px 10px;
  border-bottom: 1px solid var(--border-light);
  gap: 12px;
}
.notes-sidebar-header h3 { margin: 0; font-size: 15px; }
.notes-sidebar-header small { color: var(--text-muted); font-size: 12px; display: block; margin-top: 3px; }
.notes-search-wrap { padding: 10px 12px; }
.notes-search-wrap input { width: 100%; }
.notes-filters {
  display: flex;
  gap: 6px;
  padding: 0 12px 10px;
}
.notes-filters .tab-btn {
  flex: 1;
  text-align: center;
}
.notes-list { flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: 2px; padding: 6px 8px; }
.note-item {
  padding: 10px 12px;
  background: var(--bg-primary);
  border-radius: var(--radius-sm);
  cursor: pointer;
  border-left: 3px solid var(--border);
  transition: all var(--transition);
}
.note-item:hover { background: var(--bg-tertiary); }
.note-item.active { background: var(--accent-subtle); border-left-color: var(--accent); }
.note-item strong { display: block; font-size: 13px; }
.note-item small { color: var(--text-muted); font-size: 11px; }
.note-editor {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 24px 28px;
}
.note-editor input[type="text"] { font-size: 22px; font-weight: 700; border: none; background: transparent; color: var(--text-primary); outline: none; padding: 0; }
.note-editor textarea { flex: 1; resize: none; border: none; background: transparent; color: var(--text-primary); font-size: 15px; line-height: 1.7; outline: none; padding: 0; }
.note-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0 0;
  border-top: 1px solid var(--border-light);
}
.note-toolbar-left, .note-toolbar-right { display: flex; gap: 6px; align-items: center; }
.color-label { display: flex; align-items: center; cursor: pointer; }
.color-label input[type="color"] { width: 30px; height: 30px; border: 1px solid var(--border); border-radius: var(--radius-sm); cursor: pointer; padding: 2px; background: transparent; }

/* ─── Projects ─── */
.projects-screen { flex: 1; padding: 28px; max-width: 1000px; width: 100%; margin: 0 auto; }
.projects-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; }
.projects-header h2 { margin: 0; }
.project-form {
  background: linear-gradient(180deg, color-mix(in srgb, var(--bg-secondary) 96%, white 4%), var(--bg-secondary));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 24px;
}
.project-form .form-row { display: flex; gap: 12px; }
.project-form .form-row > * { flex: 1; }
.project-form .form-actions { display: flex; gap: 8px; margin-top: 4px; }
.projects-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.project-card {
  background: linear-gradient(180deg, color-mix(in srgb, var(--bg-secondary) 96%, white 4%), var(--bg-secondary));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  cursor: pointer;
  transition: all var(--transition);
}
.project-card:hover { border-color: var(--accent); transform: translateY(-2px); box-shadow: var(--shadow); }
.project-card h3 { font-size: 16px; margin-bottom: 6px; }
.project-card p { color: var(--text-secondary); font-size: 13px; margin-bottom: 12px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.project-meta { display: flex; justify-content: space-between; align-items: center; }
.status-badge { padding: 3px 10px; border-radius: 20px; font-size: 11px; font-weight: 600; text-transform: capitalize; }
.status-badge.active { background: #10b98122; color: var(--success); }
.status-badge.completed { background: #3b82f622; color: #3b82f6; }
.status-badge.on-hold { background: #f59e0b22; color: var(--warning); }
.project-detail-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.6); display: flex; align-items: center; justify-content: center; z-index: 100; backdrop-filter: blur(4px); animation: fadeIn 200ms ease; }
.project-detail {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  max-width: 600px;
  width: 90%;
  max-height: 80vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
  animation: slideUp 250ms ease;
}
.detail-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }
.task-form { display: flex; gap: 8px; margin: 16px 0; }
.task-form input { flex: 1; }
.task-list { display: flex; flex-direction: column; gap: 4px; }
.task-item { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--border-light); }
.task-title.done { text-decoration: line-through; color: var(--text-muted); }
.priority-badge { padding: 2px 8px; border-radius: 10px; font-size: 10px; font-weight: 600; text-transform: uppercase; }
.priority-badge.low { background: #10b98122; color: var(--success); }
.priority-badge.medium { background: #f59e0b22; color: var(--warning); }
.priority-badge.high { background: #ef444422; color: var(--danger); }

/* ─── Calendar ─── */
.calendar-screen { flex: 1; padding: 28px; max-width: 960px; width: 100%; margin: 0 auto; }
.cal-nav { display: flex; align-items: center; gap: 8px; margin-bottom: 20px; flex-wrap: wrap; }
.cal-nav h3 { flex: 1; margin: 0; }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; margin-bottom: 24px; }
.cal-header { text-align: center; font-size: 11px; font-weight: 600; color: var(--text-muted); padding: 8px 0; text-transform: uppercase; letter-spacing: 0.05em; }
.cal-day {
  min-height: 80px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  padding: 6px;
  cursor: pointer;
  font-size: 12px;
  transition: all var(--transition);
}
.cal-day:hover { border-color: var(--accent); }
.cal-day.empty { background: transparent; border: none; cursor: default; }
.cal-day.today { border-color: var(--accent); background: var(--accent-subtle); }
.cal-day.selected { background: var(--bg-tertiary); border-color: var(--accent); }
.cal-day-num { font-weight: 600; display: block; margin-bottom: 2px; font-size: 13px; }
.cal-dot { display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); margin: 1px; }
.cal-event-title { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 10px; color: var(--text-secondary); }
.day-events {
  background: linear-gradient(180deg, color-mix(in srgb, var(--bg-secondary) 96%, white 4%), var(--bg-secondary));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
}
.day-events h4 { margin-bottom: 12px; font-size: 15px; }
.event-card {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 12px 16px;
  background: var(--bg-primary);
  border-radius: var(--radius);
  margin-bottom: 8px;
  border-left: 4px solid var(--accent);
}
.event-card strong { display: block; font-size: 14px; }
.event-card small { color: var(--text-muted); font-size: 12px; }
.event-card p { color: var(--text-secondary); font-size: 13px; margin-top: 4px; }
.event-actions { display: flex; gap: 4px; flex-shrink: 0; }
.event-form-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.6); display: flex; align-items: center; justify-content: center; z-index: 100; backdrop-filter: blur(4px); animation: fadeIn 200ms ease; }
.event-form {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  max-width: 420px;
  width: 90%;
  display: flex;
  flex-direction: column;
  gap: 12px;
  box-shadow: var(--shadow-lg);
  animation: slideUp 250ms ease;
}
.event-form .form-actions { display: flex; gap: 8px; }

/* ─── Settings ─── */
.settings-screen { flex: 1; padding: 28px; max-width: 600px; width: 100%; margin: 0 auto; }
.settings-section {
  background: linear-gradient(180deg, color-mix(in srgb, var(--bg-secondary) 96%, white 4%), var(--bg-secondary));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  margin-bottom: 20px;
}
.settings-section h3 { margin-bottom: 16px; }
.danger-zone { border-color: var(--danger); }
.danger-zone h3 { color: var(--danger); }

/* ─── Post Detail ─── */
.post-detail-screen { flex: 1; padding: 28px; max-width: 680px; width: 100%; margin: 0 auto; }
.back-link { display: inline-flex; align-items: center; gap: 4px; color: var(--accent); margin-bottom: 20px; font-size: 14px; font-weight: 500; }
.back-link:hover { gap: 8px; }
.full-post { margin-bottom: 28px; }
.post-media { max-width: 100%; border-radius: var(--radius); margin-top: 12px; }
.comments-section h3 { margin-bottom: 16px; }
.add-comment { display: flex; gap: 8px; margin-bottom: 20px; }
.add-comment textarea { flex: 1; resize: none; }
.add-comment .btn-primary { width: auto; }

/* ─── Call Overlay ─── */
.call-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.85); display: flex; align-items: center; justify-content: center; z-index: 999; backdrop-filter: blur(8px); animation: fadeIn 300ms ease; }
.call-container { text-align: center; max-width: 600px; width: 90%; }
.call-header h3 { font-size: 24px; margin-bottom: 4px; color: #fff; }
.call-header p { color: rgba(255,255,255,0.6); margin-bottom: 24px; }
.call-videos { position: relative; margin-bottom: 24px; border-radius: var(--radius-lg); overflow: hidden; background: #000; }
.remote-video { width: 100%; max-height: 400px; display: block; }
.local-video { position: absolute; bottom: 16px; right: 16px; width: 160px; border-radius: var(--radius); border: 2px solid var(--accent); background: #000; }
.call-controls { display: flex; justify-content: center; gap: 16px; }
.call-btn { width: 56px; height: 56px; border-radius: 50%; border: none; cursor: pointer; font-size: 20px; display: flex; align-items: center; justify-content: center; transition: all var(--transition); }
.call-btn:hover { transform: scale(1.1); }
.call-btn.accept { background: var(--success); color: #fff; }
.call-btn.accept:hover { background: var(--success-hover); }
.call-btn.reject { background: var(--danger); color: #fff; }
.call-btn.reject:hover { background: var(--danger-hover); }
.call-btn.off { opacity: 0.5; }
.call-btn.off:hover { opacity: 0.8; }

/* ─── Notification Dropdown ─── */
.notif-dropdown {
  position: fixed;
  background: color-mix(in srgb, var(--bg-elevated) 92%, transparent);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  z-index: 1000;
  display: flex;
  flex-direction: column;
  animation: slideDown 200ms ease;
  overflow: hidden;
}
@keyframes slideDown { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: translateY(0); } }

.notif-dropdown-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border-light);
}
.notif-dropdown-header h4 { font-size: 14px; margin: 0; }
.notif-dropdown-header button { font-size: 12px; background: none; color: var(--accent); font-weight: 600; padding: 4px 8px; border-radius: var(--radius-sm); }
.notif-dropdown-header button:hover { background: var(--bg-tertiary); }

.notif-list { flex: 1; overflow-y: auto; }
.notif-item {
  display: flex;
  gap: 10px;
  padding: 12px 16px;
  cursor: pointer;
  transition: background var(--transition);
  border-bottom: 1px solid var(--border-light);
}
.notif-item:hover { background: var(--bg-tertiary); }
.notif-item.unread { background: var(--accent-subtle); }
.notif-icon { font-size: 16px; flex-shrink: 0; margin-top: 2px; }
.notif-body { flex: 1; min-width: 0; }
.notif-body strong { display: block; font-size: 13px; }
.notif-body p { font-size: 12px; color: var(--text-secondary); margin-top: 1px; }
.notif-body small { font-size: 10px; color: var(--text-muted); }
.notif-empty { padding: 32px 16px; text-align: center; color: var(--text-muted); font-size: 13px; }

/* ─── Command Palette ─── */
.cmd-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  z-index: 200;
  padding-top: 12vh;
  backdrop-filter: blur(4px);
  animation: fadeIn 150ms ease;
}
.cmd-palette {
  width: 100%;
  max-width: 560px;
  background: color-mix(in srgb, var(--bg-elevated) 92%, transparent);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  animation: slideDown 150ms ease;
}
.cmd-input-wrapper {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border-light);
}
.cmd-input-wrapper .cmd-icon { color: var(--text-muted); font-size: 16px; }
.cmd-input-wrapper input {
  flex: 1;
  border: none;
  background: transparent;
  font-size: 16px;
  color: var(--text-primary);
  outline: none;
  padding: 0;
}
.cmd-input-wrapper input::placeholder { color: var(--text-muted); }
.cmd-results { max-height: 360px; overflow-y: auto; padding: 6px; }
.cmd-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: background var(--transition);
}
.cmd-item:hover, .cmd-item.selected { background: var(--bg-tertiary); }
.cmd-item-icon { width: 32px; height: 32px; border-radius: var(--radius-sm); background: var(--accent-subtle); color: var(--accent); display: flex; align-items: center; justify-content: center; font-size: 14px; flex-shrink: 0; }
.cmd-item-info { flex: 1; min-width: 0; }
.cmd-item-info strong { display: block; font-size: 13px; }
.cmd-item-info small { color: var(--text-muted); font-size: 11px; }
.cmd-empty { padding: 24px; text-align: center; color: var(--text-muted); font-size: 13px; }
.cmd-footer {
  padding: 8px 18px;
  border-top: 1px solid var(--border-light);
  display: flex;
  gap: 16px;
  font-size: 11px;
  color: var(--text-muted);
}
.cmd-footer kbd {
  display: inline-block;
  padding: 1px 5px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border);
  border-radius: 3px;
  font-family: var(--font);
  font-size: 10px;
  color: var(--text-secondary);
}

/* ─── Loading ─── */
.loading-screen { display: flex; align-items: center; justify-content: center; min-height: 200px; gap: 10px; }
.loading-spinner {
  width: 20px; height: 20px;
  border: 2px solid var(--border);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 600ms linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.loading-screen p { color: var(--text-secondary); font-size: 14px; }

/* ─── Error ─── */
.error-screen { text-align: center; padding: 60px 28px; }
.error-screen h2 { margin-bottom: 8px; color: var(--danger); }

/* ─── Shortcuts Help ─── */
.shortcuts-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,0.5);
  display: flex; align-items: center; justify-content: center;
  z-index: 200; backdrop-filter: blur(4px);
  animation: fadeIn 150ms ease;
}
.shortcuts-modal {
  background: color-mix(in srgb, var(--bg-elevated) 92%, transparent);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  width: 100%; max-width: 480px;
  max-height: 80vh; overflow-y: auto;
  animation: slideUp 200ms ease;
}
.shortcuts-header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 20px 24px; border-bottom: 1px solid var(--border-light);
}
.shortcuts-header h3 { margin: 0; font-size: 18px; }
.shortcuts-body { padding: 16px 24px 24px; }
.shortcut-group { margin-bottom: 20px; }
.shortcut-group:last-child { margin-bottom: 0; }
.shortcut-group h4 { font-size: 11px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-muted); margin-bottom: 8px; font-weight: 600; }
.shortcut-row {
  display: flex; justify-content: space-between; align-items: center;
  padding: 8px 0; border-bottom: 1px solid var(--border-light);
  font-size: 13px;
}
.shortcut-row:last-child { border-bottom: none; }
.shortcut-keys { display: flex; gap: 4px; }
.shortcut-keys kbd {
  display: inline-block;
  padding: 2px 7px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border);
  border-radius: 5px;
  font-family: var(--font);
  font-size: 11px;
  color: var(--text-secondary);
  font-weight: 600;
}

/* ─── Utility ─── */
.empty-state { text-align: center; color: var(--text-muted); padding: 48px 24px; }
.empty-state .empty-icon { font-size: 40px; margin-bottom: 12px; }
.empty-state p { font-size: 14px; }

@media (max-width: 1100px) {
  .app-shell {
    flex-direction: column;
  }

  .sidebar {
    width: 100%;
    border-right: none;
    border-bottom: 1px solid var(--border-light);
  }

  .sidebar-header {
    align-items: flex-start;
  }

  .sidebar-nav {
    max-height: 240px;
  }

  .chat-screen,
  .notes-screen {
    flex-direction: column;
  }

  .chat-sidebar,
  .notes-sidebar {
    width: 100%;
    max-height: 360px;
  }

  .hero-grid {
    grid-template-columns: 1fr;
  }

  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 720px) {
  .screen,
  .dashboard,
  .feed-screen,
  .files-screen,
  .ai-header,
  .ai-messages,
  .ai-input,
  .admin-screen,
  .profile-screen,
  .search-screen,
  .notes-screen,
  .projects-screen,
  .calendar-screen,
  .settings-screen,
  .post-detail-screen {
    padding-left: 18px;
    padding-right: 18px;
  }

  .sidebar-header,
  .sidebar-footer,
  .chat-header,
  .message-input {
    padding-left: 16px;
    padding-right: 16px;
  }

  .sidebar-header {
    flex-wrap: wrap;
  }

  .sidebar-header-actions {
    width: 100%;
    justify-content: flex-start;
  }

  .sidebar-header-actions .btn-icon {
    width: 32px;
    height: 32px;
  }

  .dashboard-grid,
  .projects-grid,
  .quick-grid,
  .stats-grid {
    grid-template-columns: 1fr;
  }

  .hero-actions .btn-primary,
  .hero-actions .btn-secondary,
  .hero-actions .btn-ghost {
    flex: 1 1 100%;
  }
}

.flex { display: flex; }
.flex-col { display: flex; flex-direction: column; }
.gap-2 { gap: 8px; }
.gap-4 { gap: 16px; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.flex-1 { flex: 1; }
.mb-2 { margin-bottom: 8px; }
.mb-4 { margin-bottom: 16px; }
.text-center { text-align: center; }
.text-muted { color: var(--text-muted); }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
