/* Discussier — dark theme */
:root {
  --bg: #0d1117; --bg2: #161b22; --bg3: #1c2330;
  --border: #2a313c; --text: #e6edf3; --muted: #8b949e;
  --accent: #6ea8fe; --accent2: #388bfd; --danger: #f85149;
  --radius: 10px; --maxw: 980px;
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--bg); color: var(--text);
  font: 15px/1.6 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 16px; }

/* Header */
.site-header { background: var(--bg2); border-bottom: 1px solid var(--border); position: sticky; top: 0; z-index: 10; }
.site-header .wrap { display: flex; align-items: center; gap: 16px; height: 56px; }
.brand { font-weight: 700; font-size: 18px; color: var(--text); display: inline-flex; align-items: center; gap: 7px; }
.brand:hover { text-decoration: none; }
.brand-logo { display: block; }
.site-search { flex: 1; }
.site-search input { width: 100%; max-width: 420px; background: var(--bg3); border: 1px solid var(--border);
  color: var(--text); padding: 8px 12px; border-radius: var(--radius); }
.site-nav { display: flex; align-items: center; gap: 12px; }
.nav-link, .nav-user { color: var(--muted); }
.btn { background: var(--accent2); color: #fff !important; padding: 7px 14px; border-radius: var(--radius);
  border: 0; cursor: pointer; font-size: 14px; }
.btn:hover { text-decoration: none; background: var(--accent); }

/* Content */
.content { padding: 24px 16px 64px; }
h1 { font-size: 24px; margin: 0 0 4px; }
.subtle { color: var(--muted); }
.card { background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; margin-bottom: 12px; }

/* Lists */
.forum-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.forum-tile { background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius); padding: 14px; }
.forum-tile h3 { margin: 0 0 4px; font-size: 16px; }
.forum-tile p { margin: 0; color: var(--muted); font-size: 13px; }
.thread-row { display: block; padding: 12px 14px; border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--bg2); margin-bottom: 8px; }
.thread-row h3 { margin: 0 0 2px; font-size: 16px; }
.thread-row .meta { color: var(--muted); font-size: 13px; }

/* Posts */
.post { background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; margin-bottom: 12px; }
.post .post-head { display: flex; justify-content: space-between; color: var(--muted); font-size: 13px; margin-bottom: 8px; }
.post .post-body { word-wrap: break-word; }
.post.op { border-color: var(--accent2); }
.post .post-foot { margin-top: 10px; font-size: 13px; }
.react-btn { background: var(--bg3); border: 1px solid var(--border); color: var(--muted);
  border-radius: var(--radius); padding: 3px 10px; margin-right: 6px; cursor: pointer; }
.react-btn:hover { color: var(--text); border-color: var(--accent2); }
.post-body pre { background: var(--bg3); padding: 10px; border-radius: var(--radius); overflow-x: auto; }
.post-body code { background: var(--bg3); padding: 1px 5px; border-radius: 4px; }
.post-body blockquote { border-left: 3px solid var(--border); margin: 8px 0; padding: 2px 12px; color: var(--muted); }

.empty-state { text-align: center; padding: 48px 16px; color: var(--muted); }
.breadcrumb { color: var(--muted); font-size: 13px; margin-bottom: 12px; }
.breadcrumb a { color: var(--muted); }
.also-in { position: relative; margin-left: 8px; padding: 1px 6px; border: 1px solid var(--border);
  border-radius: 999px; cursor: default; color: var(--muted); outline: none; }
.also-in:hover, .also-in:focus { color: var(--text); border-color: var(--accent2); }
.also-in-pop { display: none; position: absolute; left: 0; top: 130%; z-index: 20; min-width: 180px;
  background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 8px 10px; box-shadow: 0 6px 20px rgba(0,0,0,.4); }
.also-in:hover .also-in-pop, .also-in:focus .also-in-pop, .also-in:focus-within .also-in-pop { display: block; }
.also-in-pop strong { display: block; font-size: 11px; text-transform: uppercase; letter-spacing: .04em;
  color: var(--muted); margin-bottom: 4px; }
.also-in-pop a { display: block; padding: 3px 0; color: var(--accent); white-space: nowrap; }

/* Footer */
.site-footer { border-top: 1px solid var(--border); color: var(--muted); }
.site-footer .wrap { display: flex; justify-content: space-between; padding: 20px 16px; }
.site-footer nav a { color: var(--muted); margin-left: 14px; }

@media (max-width: 600px) {
  .site-header .wrap { flex-wrap: wrap; height: auto; padding: 8px 16px; }
  .site-search { order: 3; flex-basis: 100%; }
}
