@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@300;400;500;600;700&family=DM+Mono:wght@400;500&display=swap');

/* Nie - nie Space Grotesk. Uzyjmy czegos innego */
@import url('https://fonts.googleapis.com/css2?family=Bricolage+Grotesque:opsz,wght@12..96,200..800&family=Inter:wght@300;400;500;600&family=JetBrains+Mono:wght@400;500&display=swap');

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

:root {
  /* Core - bardzo ciemny, prawie czarny z subtelnym niebieskim */
  --bg:     #08090e;
  --bg2:    #0f1018;
  --bg3:    #161720;
  --bg4:    #1e1f2c;
  --bg5:    #262738;
  
  /* Borders */
  --border:  #1a1b28;
  --border2: #252638;
  --border3: #343550;
  
  /* Text */
  --text:  #f0f0f8;
  --text2: #8b8ca8;
  --text3: #454560;
  
  /* Accent - elektryczny fiolet zamiast teal */
  --accent:       #7c6fff;
  --accent2:      #a090ff;
  --accent3:      #6358e0;
  --accent-glow:  rgba(124,111,255,.25);
  --accent-glow2: rgba(124,111,255,.08);
  
  /* Drugi akcent - neonowa zielen (mniej dominujaca) */
  --green2:  #39e5b0;
  --green2g: rgba(57,229,176,.15);

  /* Status */
  --green:  #2de87a;
  --red:    #ff3b5c;
  --yellow: #ffc93c;
  --orange: #ff6b35;
  
  /* Geometry */
  --radius:    8px;
  --radius-lg: 14px;
  --radius-xl: 18px;
  --shadow:    0 4px 24px rgba(0,0,0,.6);
  --shadow-lg: 0 12px 48px rgba(0,0,0,.8);
  --t: .16s cubic-bezier(.4,0,.2,1);
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* Subtelny noise texture overlay */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.03'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 0;
  opacity: .4;
}

/* Glow w tle */
body::after {
  content: '';
  position: fixed;
  top: -30%;
  left: 50%;
  transform: translateX(-50%);
  width: 900px;
  height: 600px;
  background: radial-gradient(ellipse, rgba(124,111,255,.06) 0%, transparent 65%);
  pointer-events: none;
  z-index: 0;
}

body > * { position: relative; z-index: 1; }

a { color: var(--accent2); text-decoration: none; transition: color var(--t); }
a:hover { color: #fff; }

/* Animations */
@keyframes fadeUp    { from{opacity:0;transform:translateY(12px)} to{opacity:1;transform:translateY(0)} }
@keyframes fadeIn    { from{opacity:0;transform:translateY(-6px)} to{opacity:1;transform:translateY(0)} }
@keyframes slideIn   { from{opacity:0;transform:translateX(20px) scale(.97)} to{opacity:1;transform:translateX(0) scale(1)} }
@keyframes pulse     { 0%,100%{opacity:1} 50%{opacity:.3} }
@keyframes rotate    { to{transform:rotate(360deg)} }

.main-content > * { animation: fadeUp .4s ease both; }
.main-content > *:nth-child(2) { animation-delay:.06s; }
.main-content > *:nth-child(3) { animation-delay:.12s; }

/* NAVBAR */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(8,9,14,.9);
  backdrop-filter: blur(20px) saturate(160%);
  border-bottom: 1px solid var(--border);
}

.navbar::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  opacity: .2;
}

.nav-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1.25rem;
  height: 56px;
  display: flex;
  align-items: center;
  gap: 1rem;
}

/* Logo - mocna typografia */
.nav-logo {
  display: flex;
  align-items: center;
  gap: .5rem;
  font-family: 'Bricolage Grotesque', sans-serif;
  font-size: 1.15rem;
  font-weight: 800;
  color: #fff;
  letter-spacing: -.03em;
  flex-shrink: 0;
}

.logo-mark {
  width: 26px; height: 26px;
  background: var(--accent);
  border-radius: 7px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .75rem;
  font-weight: 900;
  color: #fff;
  letter-spacing: 0;
  transition: all var(--t);
  box-shadow: 0 0 14px var(--accent-glow);
}

.nav-logo:hover .logo-mark {
  transform: rotate(-8deg) scale(1.08);
  box-shadow: 0 0 22px rgba(124,111,255,.5);
}

.logo-name { color: #fff; }

.nav-links { display: flex; gap: 0; flex-shrink: 0; }

.nav-link {
  padding: .35rem .6rem;
  border-radius: 7px;
  font-size: .82rem;
  font-weight: 500;
  color: var(--text2);
  transition: all var(--t);
  white-space: nowrap;
  position: relative;
}
.nav-link:hover { color: var(--text); background: var(--bg3); }
.nav-link.active { color: var(--accent2); background: rgba(124,111,255,.1); }

.nav-actions { display: flex; align-items: center; gap: .4rem; }

.nav-icon-btn {
  position: relative;
  width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 8px;
  color: var(--text2);
  cursor: pointer;
  transition: all var(--t);
  border: none; background: transparent;
}
.nav-icon-btn:hover { background: var(--bg3); color: var(--accent2); }

.badge {
  position: absolute;
  top: 2px; right: 2px;
  background: var(--accent);
  color: #fff;
  font-size: .58rem;
  font-weight: 800;
  min-width: 15px; height: 15px;
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  padding: 0 3px;
  border: 2px solid var(--bg);
}

.nav-user {
  display: flex; align-items: center; gap: .5rem;
  padding: .3rem .7rem .3rem .3rem;
  border-radius: 24px;
  cursor: pointer;
  transition: all var(--t);
  position: relative;
  border: 1px solid transparent;
}
.nav-user:hover { background: var(--bg3); border-color: var(--border2); }

.nav-avatar {
  width: 28px; height: 28px;
  border-radius: 50%; object-fit: cover;
  border: 2px solid var(--accent3);
}

.nav-username { font-size: .82rem; font-weight: 600; }

/* Dropdowns */
.user-dropdown, .notif-dropdown {
  position: absolute;
  top: calc(100% + 8px); right: 0;
  background: var(--bg2);
  border: 1px solid var(--border2);
  border-radius: var(--radius-xl);
  padding: .4rem;
  min-width: 190px;
  box-shadow: var(--shadow-lg);
  opacity: 0; visibility: hidden;
  transform: translateY(-6px) scale(.97);
  transition: all .18s cubic-bezier(.34,1.56,.64,1);
  z-index: 200;
}
.nav-user:hover .user-dropdown,
.nav-icon-btn:hover .notif-dropdown,
.nav-icon-btn.open .notif-dropdown {
  opacity: 1; visibility: visible; transform: translateY(0) scale(1);
}

.user-dropdown a {
  display: flex; align-items: center; gap: .55rem;
  padding: .55rem .7rem;
  border-radius: 8px;
  font-size: .83rem;
  color: var(--text2);
  transition: all var(--t);
}
.user-dropdown a:hover { background: var(--bg3); color: var(--text); }
.user-dropdown a.danger:hover { background: rgba(255,59,92,.1); color: var(--red); }
.dropdown-divider { height: 1px; background: var(--border); margin: .3rem .4rem; }

.notif-dropdown { min-width: 300px; right: -70px; padding: 0; overflow: hidden; }
.notif-header { padding: .7rem 1rem; font-weight: 600; font-size: .83rem; border-bottom: 1px solid var(--border); }
.notif-item { padding: .7rem 1rem; border-bottom: 1px solid var(--border); font-size: .8rem; color: var(--text2); cursor: pointer; transition: background var(--t); }
.notif-item:hover { background: var(--bg3); }
.notif-item.unread { color: var(--text); background: rgba(124,111,255,.04); }
.notif-loading { padding: 1rem; text-align: center; color: var(--text3); font-size: .82rem; }

/* LAYOUT */
.main-content { flex: 1; max-width: 1280px; width: 100%; margin: 0 auto; padding: 2rem 1.25rem; }
.page-header { margin-bottom: 1.75rem; }
.page-title {
  font-family: 'Bricolage Grotesque', sans-serif;
  font-size: 1.7rem;
  font-weight: 800;
  letter-spacing: -.04em;
  line-height: 1.15;
  color: var(--text);
}
.page-subtitle { color: var(--text2); margin-top: .3rem; font-size: .9rem; }
.layout-grid { display: grid; grid-template-columns: 1fr 280px; gap: 1.5rem; align-items: start; }
@media(max-width:900px){.layout-grid{grid-template-columns:1fr}}

/* CARDS */
.card {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  overflow: hidden;
  transition: border-color var(--t);
}
.card:hover { border-color: var(--border2); }
.card-header {
  padding: .875rem 1.25rem;
  border-bottom: 1px solid var(--border);
  display: flex; align-items: center; justify-content: space-between;
}
.card-title { font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: var(--text3); }
.card-body { padding: 1.25rem; }

/* CATEGORIES */
.categories-grid { display: flex; flex-direction: column; gap: .35rem; }
.category-item {
  display: flex; align-items: center; gap: .875rem;
  padding: .875rem 1rem;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  transition: all var(--t);
  cursor: pointer; text-decoration: none; color: inherit;
  position: relative; overflow: hidden;
}
.category-item::before {
  content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 0;
  transition: width var(--t);
}
.category-item:hover { border-color: var(--border2); background: var(--bg3); transform: translateX(3px); color: inherit; }
.category-item:hover::before { width: 3px; background: var(--accent); }
.category-icon { width: 40px; height: 40px; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 1.2rem; flex-shrink: 0; transition: transform var(--t); }
.category-item:hover .category-icon { transform: scale(1.05); }
.category-info { flex: 1; min-width: 0; }
.category-name { font-weight: 600; font-size: .9rem; }
.category-desc { font-size: .78rem; color: var(--text2); margin-top: 1px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.category-stats { text-align: right; flex-shrink: 0; }
.stat-num { font-family: 'Bricolage Grotesque', sans-serif; font-size: 1rem; font-weight: 700; color: var(--text); display: block; }
.stat-label { font-size: .68rem; color: var(--text3); }

/* THREADS */
.threads-list { display: flex; flex-direction: column; }
.thread-item {
  display: flex; align-items: center; gap: .875rem;
  padding: .875rem 1.25rem;
  border-bottom: 1px solid var(--border);
  transition: background var(--t);
}
.thread-item:last-child { border-bottom: none; }
.thread-item:hover { background: rgba(124,111,255,.025); }
.thread-avatar img { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; border: 2px solid var(--border2); }
.thread-info { flex: 1; min-width: 0; }
.thread-title-row { display: flex; align-items: center; gap: .4rem; margin-bottom: .2rem; }
.thread-title { font-weight: 600; font-size: .88rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--text); transition: color var(--t); }
.thread-title:hover { color: var(--accent2); }
.tag { font-size: .62rem; font-weight: 700; padding: 2px 6px; border-radius: 4px; text-transform: uppercase; letter-spacing: .05em; flex-shrink: 0; }
.tag-pinned { background: rgba(255,201,60,.1); color: var(--yellow); }
.tag-locked { background: rgba(255,59,92,.1); color: var(--red); }
.tag-new { background: rgba(124,111,255,.12); color: var(--accent2); }
.thread-meta { font-size: .74rem; color: var(--text3); display: flex; align-items: center; gap: .4rem; }
.thread-meta a { color: var(--text2); }
.thread-meta a:hover { color: var(--accent2); }
.thread-stats { display: flex; gap: 1.25rem; text-align: center; flex-shrink: 0; }
.thread-stat .num { font-family: 'Bricolage Grotesque', sans-serif; font-size: .95rem; font-weight: 700; display: block; }
.thread-stat .lbl { color: var(--text3); font-size: .67rem; }

/* POSTS */
.post {
  display: flex; gap: 1.25rem;
  padding: 1.5rem; border-bottom: 1px solid var(--border);
  transition: background var(--t); position: relative;
}
.post:last-child { border-bottom: none; }
.post:target { background: rgba(124,111,255,.04); }
.post-sidebar { width: 110px; flex-shrink: 0; text-align: center; }
.post-author-avatar {
  width: 58px; height: 58px;
  border-radius: 50%; object-fit: cover;
  border: 2px solid var(--border2);
  margin-bottom: .5rem;
  transition: all var(--t);
}
.post-author-avatar:hover { border-color: var(--accent); box-shadow: 0 0 14px var(--accent-glow); }
.post-author-name { font-weight: 600; font-size: .83rem; display: block; color: var(--text); }
.post-author-name:hover { color: var(--accent2); }
.post-author-role { font-size: .67rem; padding: 2px 7px; border-radius: 4px; margin-top: .2rem; display: inline-block; }
.role-ceo { background: rgba(255,215,0,.12); color: #ffd700; }
.role-admin { background: rgba(255,59,92,.1); color: var(--red); }
.role-moderator { background: rgba(124,111,255,.12); color: var(--accent2); }
.role-user { background: var(--bg4); color: var(--text3); }
.post-count-label { font-size: .68rem; color: var(--text3); margin-top: .25rem; }
.post-main { flex: 1; min-width: 0; }
.post-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: .875rem; padding-bottom: .75rem; border-bottom: 1px solid var(--border); }
.post-date { font-size: .76rem; color: var(--text3); }
.post-actions { display: flex; gap: .2rem; }
.post-action-btn { padding: .28rem .55rem; border-radius: 6px; font-size: .73rem; color: var(--text3); background: transparent; border: none; cursor: pointer; transition: all var(--t); }
.post-action-btn:hover { background: var(--bg3); color: var(--accent2); }
.post-content { font-size: .9rem; line-height: 1.8; color: var(--text); word-break: break-word; }
.post-content blockquote.forum-quote { border-left: 3px solid var(--accent3); padding: .5rem 0 .5rem 1rem; margin: .75rem 0; color: var(--text2); background: rgba(124,111,255,.04); border-radius: 0 8px 8px 0; }
.post-footer { margin-top: .875rem; display: flex; align-items: center; gap: .35rem; flex-wrap: wrap; }
.reaction-btn {
  padding: .28rem .65rem; border-radius: 20px;
  border: 1px solid var(--border); background: var(--bg3);
  color: var(--text2); font-size: .78rem; cursor: pointer;
  transition: all var(--t); display: flex; align-items: center; gap: .25rem;
}
.reaction-btn:hover { border-color: var(--accent); color: var(--accent2); }
.reaction-btn.active { border-color: var(--accent); background: var(--accent-glow2); color: var(--accent2); }

/* REPLY BOX */
.reply-box { background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius-xl); overflow: hidden; margin-top: 1.5rem; }
.reply-box-header { padding: .875rem 1.25rem; border-bottom: 1px solid var(--border); font-weight: 600; font-size: .875rem; }
.reply-box-body { padding: 1.25rem; }
.editor-toolbar { display: flex; gap: .2rem; margin-bottom: .5rem; flex-wrap: wrap; }
.toolbar-btn { padding: .28rem .6rem; border-radius: 6px; border: 1px solid var(--border); background: var(--bg3); color: var(--text2); font-size: .76rem; cursor: pointer; transition: all var(--t); font-family: 'JetBrains Mono', monospace; }
.toolbar-btn:hover { border-color: var(--accent); color: var(--accent2); }

/* FORMS */
.form-group { margin-bottom: 1.1rem; }
.form-label { display: block; font-size: .78rem; font-weight: 600; margin-bottom: .35rem; color: var(--text2); letter-spacing: .01em; }
.form-input, .form-textarea, .form-select {
  width: 100%; padding: .65rem .9rem;
  background: var(--bg3); border: 1px solid var(--border2);
  border-radius: var(--radius); color: var(--text);
  font-family: 'Inter', sans-serif; font-size: .9rem;
  transition: border-color var(--t), box-shadow var(--t); outline: none;
}
.form-input:focus, .form-textarea:focus, .form-select:focus {
  border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-glow2);
}
.form-textarea { min-height: 160px; resize: vertical; }
.form-input::placeholder, .form-textarea::placeholder { color: var(--text3); }
.form-hint { font-size: .73rem; color: var(--text3); margin-top: .28rem; }
.form-error { font-size: .73rem; color: var(--red); margin-top: .28rem; }

/* BUTTONS */
.btn {
  display: inline-flex; align-items: center; gap: .4rem;
  padding: .55rem 1.15rem;
  border-radius: var(--radius);
  font-weight: 600; font-size: .85rem;
  cursor: pointer; border: none;
  transition: all var(--t);
  text-decoration: none;
  font-family: 'Inter', sans-serif;
}
.btn-primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 2px 14px rgba(124,111,255,.35);
}
.btn-primary:hover {
  background: var(--accent2); color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 4px 22px rgba(124,111,255,.5);
}
.btn-ghost { background: transparent; color: var(--text2); border: 1px solid var(--border2); }
.btn-ghost:hover { background: var(--bg3); color: var(--text); border-color: var(--border3); }
.btn-danger { background: rgba(255,59,92,.1); color: var(--red); border: 1px solid rgba(255,59,92,.2); }
.btn-danger:hover { background: rgba(255,59,92,.2); }
.btn-sm { padding: .35rem .8rem; font-size: .78rem; }
.btn-lg { padding: .8rem 1.75rem; font-size: .95rem; }
.btn-full { width: 100%; justify-content: center; }

/* AUTH */
.auth-container {
  min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 2rem;
  background: radial-gradient(ellipse 70% 50% at 50% 0%, rgba(124,111,255,.1) 0%, transparent 55%);
}
.auth-box {
  width: 100%; max-width: 420px;
  background: var(--bg2); border: 1px solid var(--border2);
  border-radius: var(--radius-xl); padding: 2.25rem;
  box-shadow: var(--shadow-lg), 0 0 60px rgba(124,111,255,.04);
}
.auth-logo { text-align: center; margin-bottom: 1.75rem; }
.auth-logo h1 { font-family: 'Bricolage Grotesque', sans-serif; font-size: 1.5rem; font-weight: 800; margin-top: .6rem; letter-spacing: -.03em; }
.auth-logo p { color: var(--text2); font-size: .88rem; margin-top: .2rem; }
.auth-footer { text-align: center; margin-top: 1.25rem; font-size: .85rem; color: var(--text2); }

/* PROFILE */
.profile-header {
  background: var(--bg2); border: 1px solid var(--border2);
  border-radius: var(--radius-xl); padding: 1.75rem;
  display: flex; gap: 1.5rem; align-items: flex-start;
  margin-bottom: 1.5rem; position: relative; overflow: hidden;
}
.profile-header::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, var(--accent), var(--green2), transparent);
}
.profile-avatar { width: 90px; height: 90px; border-radius: 50%; object-fit: cover; border: 2px solid var(--accent3); box-shadow: 0 0 24px var(--accent-glow); }
.profile-info h1 { font-family: 'Bricolage Grotesque', sans-serif; font-size: 1.4rem; font-weight: 800; letter-spacing: -.03em; }
.profile-role { display: inline-block; margin-top: .35rem; font-size: .75rem; padding: 2px 9px; border-radius: 4px; }
.profile-stats { display: flex; gap: 2rem; margin-top: .875rem; }
.profile-stat-num { font-family: 'Bricolage Grotesque', sans-serif; font-size: 1.3rem; font-weight: 800; }
.profile-stat-lbl { font-size: .72rem; color: var(--text3); }
.profile-bio { margin-top: .6rem; color: var(--text2); font-size: .88rem; }

/* FLASH */
.flash {
  position: fixed; top: 65px; right: 1.25rem; z-index: 500;
  padding: .8rem 1.1rem;
  border-radius: var(--radius-lg);
  display: flex; align-items: center; gap: .6rem;
  font-size: .84rem; font-weight: 500;
  box-shadow: var(--shadow-lg);
  animation: slideIn .3s cubic-bezier(.34,1.56,.64,1);
  max-width: 340px;
}
.flash-success { background: rgba(45,232,122,.1); border: 1px solid rgba(45,232,122,.25); color: var(--green); }
.flash-error   { background: rgba(255,59,92,.1);  border: 1px solid rgba(255,59,92,.25);  color: var(--red); }
.flash-info    { background: rgba(124,111,255,.1); border: 1px solid rgba(124,111,255,.25); color: var(--accent2); }
.flash button { background: none; border: none; cursor: pointer; color: inherit; margin-left: auto; }

/* PAGINATION */
.pagination { display: flex; justify-content: center; gap: .35rem; padding: 1.5rem 0; }
.page-btn {
  width: 34px; height: 34px; display: flex; align-items: center; justify-content: center;
  border-radius: 7px; border: 1px solid var(--border2); background: var(--bg2);
  color: var(--text2); font-size: .84rem; cursor: pointer; transition: all var(--t); text-decoration: none;
}
.page-btn:hover { border-color: var(--accent); color: var(--accent2); }
.page-btn.active { background: var(--accent); border-color: var(--accent); color: #fff; box-shadow: 0 0 14px var(--accent-glow); }

/* WIDGETS */
.widget { background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius-xl); overflow: hidden; margin-bottom: 1rem; }
.widget-header { padding: .75rem .875rem; border-bottom: 1px solid var(--border); font-size: .71rem; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: var(--text3); display: flex; align-items: center; justify-content: space-between; }
.widget-body { padding: .6rem; }
.user-item { display: flex; align-items: center; gap: .55rem; padding: .4rem .5rem; border-radius: 8px; transition: background var(--t); }
.user-item:hover { background: var(--bg3); }
.user-item img { width: 28px; height: 28px; border-radius: 50%; object-fit: cover; }
.user-item-name { font-size: .82rem; font-weight: 500; flex: 1; }
.user-item-count { font-size: .7rem; color: var(--text3); }

/* MEMBERS */
.members-grid { display: grid; grid-template-columns: repeat(auto-fill,minmax(165px,1fr)); gap: 1rem; }
.member-card { background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius-xl); padding: 1.35rem; text-align: center; transition: all var(--t); cursor: pointer; text-decoration: none; color: inherit; display: block; }
.member-card:hover { border-color: var(--accent); transform: translateY(-3px); box-shadow: 0 10px 32px rgba(124,111,255,.12); color: inherit; }
.member-card img { width: 60px; height: 60px; border-radius: 50%; object-fit: cover; margin: 0 auto .65rem; border: 2px solid var(--border2); transition: all var(--t); }
.member-card:hover img { border-color: var(--accent); box-shadow: 0 0 14px var(--accent-glow); }
.member-card-name { font-weight: 700; font-size: .88rem; }
.member-card-role { font-size: .72rem; margin-top: .25rem; }
.member-card-posts { font-size: .72rem; color: var(--text3); margin-top: .3rem; }

/* FEED */
.feed-wrap { display: grid; grid-template-columns: 1fr 280px; gap: 1.5rem; align-items: start; }
@media(max-width:1024px){.feed-wrap{grid-template-columns:1fr}}

.post-card {
  background: var(--bg2); border: 1px solid var(--border);
  border-radius: var(--radius-xl); overflow: hidden;
  transition: all var(--t); margin-bottom: .6rem;
  display: flex;
}
.post-card:hover { border-color: var(--border2); transform: translateX(2px); }

.post-vote {
  width: 42px; flex-shrink: 0;
  display: flex; flex-direction: column; align-items: center;
  padding: .875rem .35rem;
  background: var(--bg3); gap: .15rem;
}
.vote-btn {
  width: 26px; height: 26px; border-radius: 6px;
  border: none; background: transparent;
  color: var(--text3); cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: all var(--t); font-size: .9rem;
}
.vote-btn:hover { background: var(--bg4); color: var(--accent2); }
.vote-count { font-family: 'Bricolage Grotesque', sans-serif; font-size: .76rem; font-weight: 700; color: var(--text2); }

.post-body { flex: 1; padding: .875rem 1rem; min-width: 0; }
.post-card-top { display: flex; align-items: center; gap: .45rem; margin-bottom: .45rem; font-size: .74rem; color: var(--text3); flex-wrap: wrap; }
.post-cat {
  display: flex; align-items: center; gap: .25rem;
  background: var(--bg3); border: 1px solid var(--border2);
  border-radius: 20px; padding: 2px 8px;
  font-weight: 600; font-size: .71rem; color: var(--text2);
  text-decoration: none; transition: all var(--t);
}
.post-cat:hover { border-color: var(--accent); color: var(--accent2); }
.post-author-link { color: var(--text2); font-weight: 500; }
.post-author-link:hover { color: var(--accent2); }
.post-card-title {
  font-family: 'Bricolage Grotesque', sans-serif;
  font-size: 1rem; font-weight: 700;
  letter-spacing: -.02em;
  color: var(--text); margin-bottom: .45rem;
  line-height: 1.3; display: block;
  transition: color var(--t);
}
.post-card-title:hover { color: var(--accent2); }
.post-card-preview {
  font-size: .83rem; color: var(--text2);
  line-height: 1.6; margin-bottom: .6rem;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.post-card-footer { display: flex; align-items: center; gap: .75rem; font-size: .75rem; color: var(--text3); }
.post-card-footer a { color: var(--text3); display: flex; align-items: center; gap: .25rem; transition: color var(--t); }
.post-card-footer a:hover { color: var(--accent2); }
.post-tag { font-size: .62rem; font-weight: 700; padding: 2px 6px; border-radius: 4px; text-transform: uppercase; letter-spacing: .05em; }
.post-tag-pin { background: rgba(255,201,60,.1); color: var(--yellow); }
.post-tag-lock { background: rgba(255,59,92,.1); color: var(--red); }

/* Sidebar */
.sb-card { background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius-xl); overflow: hidden; margin-bottom: 1rem; }
.sb-card-header { padding: .7rem .875rem; border-bottom: 1px solid var(--border); font-size: .7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: var(--text3); display: flex; align-items: center; justify-content: space-between; }
.sb-card-body { padding: .875rem; }
.stats-grid { display: grid; grid-template-columns: 1fr 1fr; gap: .6rem; }
.stat-box { text-align: center; padding: .6rem; background: var(--bg3); border-radius: 8px; }
.stat-box-num { font-family: 'Bricolage Grotesque', sans-serif; font-size: 1.25rem; font-weight: 800; color: var(--accent2); }
.stat-box-lbl { font-size: .67rem; color: var(--text3); margin-top: 1px; }
.sb-cat { display: flex; align-items: center; gap: .55rem; padding: .5rem .875rem; transition: background var(--t); text-decoration: none; color: inherit; }
.sb-cat:hover { background: var(--bg3); }
.sb-cat-ico { width: 28px; height: 28px; border-radius: 7px; display: flex; align-items: center; justify-content: center; font-size: .9rem; flex-shrink: 0; }
.sb-cat-name { font-size: .83rem; font-weight: 600; flex: 1; }
.sb-cat-count { font-size: .7rem; color: var(--text3); }
.new-post-btn { display: flex; align-items: center; gap: .75rem; background: var(--bg2); border: 1px solid var(--border2); border-radius: var(--radius-xl); padding: .65rem .875rem; cursor: pointer; transition: all var(--t); text-decoration: none; margin-bottom: 1.1rem; }
.new-post-btn:hover { border-color: var(--accent); background: var(--bg3); }
.new-post-av { width: 34px; height: 34px; border-radius: 50%; object-fit: cover; border: 2px solid var(--border2); flex-shrink: 0; }
.new-post-placeholder { flex: 1; padding: .4rem .75rem; background: var(--bg3); border: 1px solid var(--border2); border-radius: 7px; color: var(--text3); font-size: .86rem; }
.sort-tabs { display: flex; gap: .25rem; margin-bottom: 1.1rem; background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: .3rem; width: fit-content; }
.sort-tab { padding: .38rem .875rem; border-radius: 7px; font-size: .82rem; font-weight: 600; color: var(--text2); text-decoration: none; transition: all var(--t); display: flex; align-items: center; gap: .3rem; }
.sort-tab:hover { color: var(--text); background: var(--bg3); }
.sort-tab.active { background: var(--accent); color: #fff; }
.sb-update { display: block; padding: .6rem .875rem; border-bottom: 1px solid var(--border); text-decoration: none; transition: background var(--t); }
.sb-update:last-child { border-bottom: none; }
.sb-update:hover { background: var(--bg3); }

/* UTILITIES */
.text-center{text-align:center}.mt-1{margin-top:.5rem}.mt-2{margin-top:1rem}.mt-3{margin-top:1.5rem}
.text-muted{color:var(--text2)}.text-xs{font-size:.76rem}
.empty-state{text-align:center;padding:3rem 1rem;color:var(--text3)}
.empty-state-icon{font-size:2.75rem;margin-bottom:.875rem}
.empty-state h3{color:var(--text2);margin-bottom:.5rem;font-family:'Bricolage Grotesque',sans-serif}
.online-dot{width:7px;height:7px;background:var(--green);border-radius:50%;display:inline-block;margin-right:4px;box-shadow:0 0 6px var(--green);animation:pulse 2s infinite}
.live-badge{display:inline-flex;align-items:center;gap:.3rem;font-size:.65rem;font-weight:700;background:rgba(124,111,255,.1);color:var(--accent2);padding:2px 8px;border-radius:20px;text-transform:uppercase;letter-spacing:.06em}
.live-badge::before{content:'';width:5px;height:5px;border-radius:50%;background:var(--accent2);animation:pulse 1.5s infinite}
.replies-menu.show{display:block!important;animation:fadeIn .15s ease}

/* FOOTER */
.footer{border-top:1px solid var(--border);margin-top:auto}
.footer-inner{max-width:1280px;margin:0 auto;padding:1.1rem 1.25rem;display:flex;align-items:center;justify-content:space-between}
.footer-brand{display:flex;align-items:center;gap:.5rem;font-family:'Bricolage Grotesque',sans-serif;font-weight:700;font-size:.95rem}
.footer-copy{font-size:.76rem;color:var(--text3)}

code,.inline-code{font-family:'JetBrains Mono',monospace;background:var(--bg4);padding:2px 6px;border-radius:4px;font-size:.82em;color:var(--accent2);border:1px solid var(--border2)}

::-webkit-scrollbar{width:5px;height:5px}
::-webkit-scrollbar-track{background:transparent}
::-webkit-scrollbar-thumb{background:var(--bg5);border-radius:3px}
::-webkit-scrollbar-thumb:hover{background:var(--accent)}

/* Hamburger */
.nav-hamburger{display:none;flex-direction:column;justify-content:center;gap:5px;width:36px;height:36px;border-radius:8px;cursor:pointer;background:transparent;border:none;padding:8px;flex-shrink:0;transition:background var(--t)}
.nav-hamburger:hover{background:var(--bg3)}
.nav-hamburger span{display:block;height:2px;background:var(--text2);border-radius:2px;transition:all .22s ease}
.nav-hamburger.open span:nth-child(1){transform:translateY(7px) rotate(45deg)}
.nav-hamburger.open span:nth-child(2){opacity:0;transform:scaleX(0)}
.nav-hamburger.open span:nth-child(3){transform:translateY(-7px) rotate(-45deg)}

.nav-mobile-drawer{display:none;position:fixed;top:56px;left:0;right:0;background:rgba(8,9,14,.97);backdrop-filter:blur(20px);border-bottom:1px solid var(--border);padding:.875rem 1.25rem 1.25rem;z-index:99;flex-direction:column;gap:.2rem;animation:fadeIn .18s ease}
.nav-mobile-drawer.open{display:flex}
.nav-mobile-drawer .nav-link{padding:.7rem .875rem;border-radius:9px;font-size:.92rem;display:block;border-bottom:1px solid var(--border)}
.nav-mobile-drawer .nav-link:last-child{border-bottom:none}
.nav-mobile-search{margin-bottom:.6rem;padding-bottom:.6rem;border-bottom:1px solid var(--border)}
.nav-mobile-search input{width:100%;padding:.55rem .875rem;background:var(--bg3);border:1px solid var(--border2);border-radius:20px;color:var(--text);font-family:'Inter',sans-serif;font-size:.88rem;outline:none}

/* Responsive */
@media(max-width:1100px){.nav-link.nav-hide-md{display:none}}
@media(max-width:900px){.nav-links{display:none}.nav-hamburger{display:flex}.nav-inner>form{display:none}.main-content{padding:1.25rem 1rem}.thread-stats{display:none}}
@media(max-width:600px){.footer-inner{flex-direction:column;gap:.5rem;text-align:center}.auth-box{padding:1.5rem}.post{flex-direction:column}.post-sidebar{width:100%;display:flex;align-items:center;gap:.875rem;text-align:left;padding-bottom:.875rem;border-bottom:1px solid var(--border)}.post-author-avatar{width:42px;height:42px;margin-bottom:0}.members-grid{grid-template-columns:repeat(auto-fill,minmax(130px,1fr))}.feed-wrap>div:last-child{display:none}.sort-tabs{width:100%}.flash{top:62px;right:.875rem;left:.875rem;max-width:none}}
@media(hover:none) and (pointer:coarse){.btn{min-height:42px}.btn-sm{min-height:36px}.reaction-btn{min-height:34px;padding:.38rem .7rem}.nav-icon-btn{width:42px;height:42px}.category-item:hover{transform:none}.member-card:hover{transform:none}.btn-primary:hover{transform:none}}
