.board-posts,
.board-thread,
.board-conversation,
.board-replies {
  display: grid;
  gap: 14px;
}

.board-post {
  display: grid;
  gap: 8px;
  padding: 18px 18px 16px;
  box-shadow: none;
}

.board-post-top,
.board-author {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.board-post-top {
  justify-content: space-between;
  flex-wrap: wrap;
}

.board-author .avatar {
  width: 34px;
  height: 34px;
  flex: none;
}

.board-author strong {
  overflow-wrap: anywhere;
  font-size: 15px;
}

.board-author time {
  flex: none;
  color: var(--muted);
  font-size: 15px;
}

.board-post-category {
  justify-self: start;
  flex: none;
  white-space: nowrap;
}

.board-post h2 { margin: 0; font-size: clamp(19px, 3vw, 23px); }
.board-post p { margin: 0; color: var(--muted); overflow-wrap: anywhere; }
.board-post h2,
.board-topic h1 { overflow-wrap: anywhere; }

.board-post-count {
  display: flex;
  align-items: center;
  gap: 7px;
  color: var(--brand-dark);
  font-size: 15px;
  font-weight: 700;
}

.board-post-count .icon,
.board-reply-action .icon {
  width: 17px;
  height: 17px;
}

.board-topic,
.board-composer {
  padding: clamp(16px, 3vw, 24px);
}

.board-topic h1 {
  margin: 10px 0 12px;
  font-size: clamp(25px, 6.7vw, 32px);
  text-wrap: pretty;
}
.board-topic .board-author { margin-bottom: 14px; }

.board-message {
  margin: 8px 0 4px;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
}

.board-conversation > h2 { font-size: 21px; }
.board-conversation > h2 span { margin-left: 2px; }

.board-replies {
  padding: 0;
  margin: 0;
  list-style: none;
}

.board-reply {
  --indent-unit: clamp(14px, 2.5vw, 24px);
  min-width: 0;
}

.board-reply[data-depth="1"] { margin-inline-start: var(--indent-unit); }
.board-reply[data-depth="2"] { margin-inline-start: calc(var(--indent-unit) * 2); }

.board-reply > article {
  padding: 12px 14px 6px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
}

.board-reply > article:target { border-color: var(--brand); }
.board-reply .board-message:last-child { margin-bottom: 8px; }

.board-replies-more {
  width: min(100%, 300px);
  justify-self: center;
}

.board-replies-more[hidden] { display: none; }

.board-reply > article,
.board-composer { scroll-margin: 84px 0 92px; }

.board-reply-action,
.board-target-clear {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 44px;
  padding: 0 8px;
  color: var(--brand-dark);
  font-size: 15px;
  font-weight: 700;
}

.board-reply-action { margin-left: -8px; }

.board-quote,
.board-compose-target {
  padding: 8px 12px;
  border-left: 3px solid var(--brand);
  border-radius: 10px;
  background: var(--brand-soft);
  font-size: 15px;
  overflow-wrap: anywhere;
}

.board-quote {
  display: grid;
  gap: 2px;
  margin-top: 10px;
  color: var(--brand-dark);
}

.board-quote span,
[data-board-target-text] {
  color: var(--muted);
  text-wrap: balance;
}

.board-compose-target {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: var(--brand-dark);
}

.board-compose-target > div {
  display: grid;
  flex: 1;
  min-width: 0;
  gap: 2px;
}

.board-target-clear {
  flex: none;
  min-width: 44px;
}

.board-target-clear[hidden] { display: none; }
.board-empty { text-align: center; font-weight: 700; }
.board-empty p { margin: 0; }

.board-select {
  position: relative;
  display: block;
}

.board-post-form .board-select select {
  appearance: none;
  width: 100%;
  padding-right: 34px;
}

.board-select > .icon {
  position: absolute;
  top: 50%;
  right: 12px;
  width: 16px;
  height: 16px;
  transform: translateY(-50%);
  color: var(--muted);
  pointer-events: none;
}

@media (hover: hover) and (pointer: fine) {
  .board-post:hover h2 { color: var(--brand-dark); }
  .board-post:hover { border-color: var(--brand); }
  .board-reply-action:hover,
  .board-target-clear:hover { text-decoration: underline; }
}
