/* The forum page (site/forum/): the palette, plates and buttons of site.css,
   the list of topics and the messages on top of them */
.forum-page .top-logo { opacity: 1; }
.forum-page .top-links a[aria-current="page"] { color: var(--rust); }
.forum { padding-top: 72px; min-height: 80vh; }
.forum section { padding: 0; }
.forum-head { padding: 24px 0 8px !important; }
.forum-head h2 { margin-bottom: 12px; }
.forum-lead { margin: 0 0 8px; color: var(--bone-dim); max-width: 70ch; }
.forum-note {
  margin: 12px 0 0;
  padding: 10px 14px;
  border-left: 3px solid var(--rust);
  background: rgba(8, 6, 5, 0.7);
}
.forum-view { padding-bottom: 40px !important; }
.hint { margin: 0; font-size: 14px; color: var(--bone-dim); }

.btn-small { min-height: 40px; padding: 10px 18px; font-size: 15px; }
.btn-danger:hover, .btn-danger:focus-visible { color: #ff6a5a; box-shadow: inset 0 0 0 1px #ff6a5a, 0 6px 18px rgba(0, 0, 0, 0.6); }
.mini {
  font: 500 13px/1 var(--head);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--bone-dim);
  background: rgba(18, 13, 11, 0.6);
  border: 1px solid var(--line-2);
  padding: 7px 10px;
  cursor: pointer;
  transition: color 0.15s, border-color 0.15s;
}
.mini:hover { color: var(--rust); border-color: var(--rust); }

/* who is logged in, in the top bar */
.who { margin-left: 8px; }
.who-btn { display: inline-flex; align-items: center; gap: 8px; max-width: 200px; padding: 4px 10px 4px 4px; }
.who-btn:not(:has(.ava)) { padding: 8px 12px; }
.who-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-transform: none; letter-spacing: 0; font-family: var(--body); }
@media (max-width: 640px) {
  .who { margin-left: auto; }
  .lang { margin-left: 0; }
  .who-name { max-width: 90px; }
}

/* the sections */
.cats { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0 14px; }
.cats a {
  font: 700 16px/1 var(--head);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--bone-dim);
  background: var(--rivets), linear-gradient(var(--steel-2), var(--steel));
  border: 1px solid #000;
  box-shadow: inset 0 0 0 1px var(--line);
  padding: 14px 20px;
}
.cats a:hover { color: var(--rust); }
.cats a[aria-selected="true"] { color: var(--bone); background: var(--rivets), linear-gradient(#5a2410, #3a160a); box-shadow: inset 0 0 0 1px var(--rust); }
.list-bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 14px; }
.cat-lead { margin: 0; color: var(--bone-dim); font-size: 15px; }

/* the list */
.topics, .posts { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.topic-row { display: flex; align-items: center; gap: 16px; padding: 14px 18px; background-image: linear-gradient(var(--steel-2), var(--steel)); }
.topic-row.is-pinned { box-shadow: inset 3px 0 0 var(--rust), inset 0 0 0 1px var(--line), 0 10px 30px rgba(0, 0, 0, 0.5); }
.topic-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.topic-link { font: 600 18px/1.3 var(--body); text-decoration: none; overflow-wrap: anywhere; }
.topic-link:hover { color: var(--rust); }
.flag { align-self: flex-start; font: 500 12px/1 var(--head); letter-spacing: 0.1em; text-transform: uppercase; color: var(--rust); }
.flag-dim { color: var(--bone-dim); }
.topic-nums { display: flex; gap: 8px; flex: none; }
.num { display: flex; flex-direction: column; align-items: center; min-width: 64px; padding: 6px 8px; background: rgba(8, 6, 5, 0.55); border: 1px solid var(--line); }
.num strong { font: 700 20px/1.1 var(--head); }
.num span { font-size: 12px; color: var(--bone-dim); }
.num-vote strong { color: var(--rust); }
.empty { color: var(--bone-dim); }
.pager { display: flex; justify-content: space-between; margin-top: 16px; }
.pager #next { margin-left: auto; }

.author { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; color: var(--bone-dim); flex-wrap: wrap; }
.ava {
  display: inline-flex; align-items: center; justify-content: center; flex: none;
  width: 26px; height: 26px; border-radius: 50%;
  font: 700 14px/1 var(--head); color: var(--bone);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.5);
}
.name { color: var(--bone); font-weight: 600; }
.name.gone { color: var(--bone-dim); font-style: italic; font-weight: 400; }
.dev-badge {
  font: 700 11px/1 var(--head); letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--bone); background: var(--blood-dark); border: 1px solid var(--blood);
  padding: 4px 6px;
}
.when::before { content: "·"; margin-right: 8px; }

/* a topic */
.back { display: inline-block; margin: 8px 0 14px; color: var(--bone-dim); text-decoration: none; font-size: 15px; }
.back:hover { color: var(--rust); }
.topic-head { display: flex; align-items: flex-start; gap: 16px; }
.topic-head h1 { flex: 1; margin: 0; font: 700 clamp(24px, 3.4vw, 34px)/1.15 var(--head); letter-spacing: 0.03em; overflow-wrap: anywhere; text-shadow: 0 2px 12px rgba(0, 0, 0, 0.8); }
.vote {
  display: flex; flex-direction: column; align-items: center; gap: 2px; flex: none;
  min-width: 64px; padding: 8px 10px;
  font: 700 20px/1 var(--head); color: var(--bone);
  background: var(--rivets), linear-gradient(var(--steel-3), var(--steel));
  border: 1px solid #000; box-shadow: inset 0 0 0 1px var(--line-2);
  cursor: pointer;
}
.vote:hover { color: var(--rust); box-shadow: inset 0 0 0 1px var(--rust); }
.vote[aria-pressed="true"] { background: var(--rivets), linear-gradient(#5a2410, #3a160a); box-shadow: inset 0 0 0 1px var(--rust); }
.vote[aria-pressed="true"] .vote-arrow { color: var(--rust); }
.vote-arrow { font-size: 14px; }
.topic-flags { margin: 8px 0 0; font-size: 14px; color: var(--rust); min-height: 1px; }
.admin-bar { display: flex; gap: 6px; margin: 10px 0 0; }
.posts { margin-top: 18px; }
.post { padding: 16px 20px 12px; background-image: linear-gradient(var(--steel-2), var(--steel)); }
.post.by-dev { box-shadow: inset 3px 0 0 var(--blood), inset 0 0 0 1px var(--line), 0 10px 30px rgba(0, 0, 0, 0.5); }
.post.is-first { background-image: linear-gradient(var(--steel-3), var(--steel)); }
.post.is-hidden { opacity: 0.45; }
.post-body { margin: 10px 0 6px; white-space: pre-wrap; overflow-wrap: anywhere; }
.post-body a { color: var(--rust); }
.post-tools { display: flex; gap: 6px; justify-content: flex-end; flex-wrap: wrap; }
.post-tools .report { border-color: transparent; background: none; }
.edit-form { display: flex; flex-direction: column; gap: 8px; margin: 10px 0 6px; }
.edit-form input, .edit-form textarea, .field select {
  width: 100%; font: 400 16px/1.5 var(--body); color: var(--bone);
  background: rgba(8, 6, 5, 0.7); border: 1px solid var(--line-2); padding: 10px 12px; border-radius: 0;
}
.edit-form .btn { align-self: flex-start; }
.post-form { margin-top: 18px; padding: 22px; display: flex; flex-direction: column; gap: 14px; }
.post-form .field textarea { min-height: 110px; }
.captcha:empty { display: none; }
.reply-note { margin: 18px 0 0; display: flex; align-items: center; gap: 12px; flex-wrap: wrap; color: var(--bone-dim); }

/* the account */
.me-box { padding: 22px; display: flex; flex-direction: column; gap: 12px; max-width: 640px; }
.me-box p { margin: 0; }
.rename { display: flex; align-items: flex-end; gap: 10px; }
.rename .field { flex: 1; }
.me-actions { display: flex; gap: 10px; flex-wrap: wrap; }

/* the login */
.login { color: var(--bone); padding: 24px; max-width: 420px; width: calc(100% - 32px); }
.login::backdrop { background: rgba(0, 0, 0, 0.7); }
.login h3 { margin: 0 0 8px; font: 700 24px/1.2 var(--head); letter-spacing: 0.05em; text-transform: uppercase; }
.login-btns { display: flex; flex-direction: column; gap: 10px; margin: 18px 0; }
.login-btns .btn { width: 100%; }
.login form { margin-top: 14px; text-align: right; }

@media (max-width: 640px) {
  .list-bar { flex-direction: column; align-items: stretch; }
  .cats a { flex: 1; text-align: center; padding: 12px 8px; font-size: 14px; }
  .topic-row { flex-direction: column; align-items: stretch; gap: 10px; padding: 14px; }
  .topic-nums { justify-content: flex-start; }
  .num { flex-direction: row; gap: 6px; min-width: 0; }
  .post { padding: 14px 14px 10px; }
  .rename { flex-direction: column; align-items: stretch; }
}

/* the privacy page */
.doc { max-width: 760px; padding-top: 88px; }
.doc h3 { font: 700 20px/1.3 var(--head); letter-spacing: 0.05em; text-transform: uppercase; margin: 28px 0 8px; }
.doc p, .doc li { color: var(--bone-dim); }
.doc strong { color: var(--bone); }
