@import url("https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;500;600&family=Lexend:wght@400;500;600&display=swap");

:root {
  --bg: #101014;
  --surface: #141519;
  --surface-raised: #191a1f;
  --surface-soft: #1e2027;
  --fg: #c8d3db;
  --heading: #cbe1f0;
  --muted: #697786;
  --border: #343b49;
  --accent: #718edf;
  --accent-hover: #8ca0e5;
  --brand: #28e6ff;
  --sticky: #292111;
  --sticky-border: #604b1d;
  --deleted: #3c1710;
  --deleted-fg: #ffe7e1;
  --mono: "JetBrains Mono", "SF Mono", "Monaco", "Inconsolata", monospace;
  --sans: "Lexend", system-ui, sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.5;
  color: var(--fg);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

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

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

code {
  font-family: var(--mono);
}

.wrap {
  max-width: 960px;
  margin: 0 auto;
  padding: 1rem 1.25rem 3rem;
}

header.site {
  border-bottom: 1px solid var(--border);
  background: var(--surface);
  margin-bottom: 1.5rem;
}

header.site .inner {
  max-width: 960px;
  margin: 0 auto;
  padding: 0.75rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

header.site h1 {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--heading);
}

header.site h1 a {
  color: inherit;
}

header.site nav a {
  margin-right: 1rem;
}

header.site nav a:last-child {
  margin-right: 0;
}

.breadcrumb {
  font-size: 0.9rem;
  color: var(--muted);
  margin-bottom: 1rem;
}

.breadcrumb a {
  color: var(--muted);
}

.breadcrumb a:hover {
  color: var(--accent-hover);
}

h2.room-title {
  margin: 0 0 0.25rem;
  font-size: 1.35rem;
  color: var(--heading);
}

p.meta,
.topic-meta {
  color: var(--muted);
  font-size: 0.88rem;
  margin: 0 0 1rem;
}

.room-id {
  color: var(--muted);
  font-size: 0.85rem;
}

.banner {
  padding: 0.6rem 0.85rem;
  border-radius: 6px;
  margin-bottom: 1rem;
  font-size: 0.9rem;
}

.banner.deleted {
  background: var(--deleted);
  border: 1px solid #752119;
  color: var(--deleted-fg);
}

.room-groups {
  display: grid;
  gap: 2rem;
}

.board-categories {
  display: grid;
  gap: 1.75rem;
}

@media (min-width: 720px) {
  .board-categories {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.25rem 2rem;
  }
}

.board-category {
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 1rem 1.15rem 1.05rem;
}

.board-category-title {
  margin: 0 0 0.65rem;
  font-size: 0.92rem;
  font-weight: 650;
  color: var(--heading);
  letter-spacing: 0.02em;
}

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

.board-category-list li {
  padding: 0.4rem 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.95rem;
}

.board-category-list li:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

@media (min-width: 720px) {
  .room-groups {
    grid-template-columns: 1fr 1fr;
  }
}

.room-groups h3 {
  margin: 0 0 0.5rem;
  font-size: 1rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.room-groups ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.room-groups li {
  padding: 0.35rem 0;
  border-bottom: 1px solid var(--border);
}

.topic-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
}

.topic-table th,
.topic-table td {
  text-align: left;
  padding: 0.55rem 0.75rem;
  border-bottom: 1px solid var(--border);
}

.topic-table th {
  background: var(--surface-soft);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--muted);
}

.topic-table tr:last-child td {
  border-bottom: none;
}

.topic-table tr.sticky {
  background: var(--sticky);
}

.topic-table tr.sticky td {
  border-color: var(--sticky-border);
}

.badge {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 600;
  padding: 0.12rem 0.4rem;
  border-radius: 4px;
  background: #cbe1f0;
  color: #191a1f;
  margin-right: 0.35rem;
  vertical-align: middle;
}

.badge.deleted {
  background: var(--deleted);
  color: var(--deleted-fg);
}

.pagination {
  margin-top: 1rem;
  font-size: 0.9rem;
  color: var(--muted);
}

.pagination a {
  margin-right: 0.75rem;
}

.topic-head h2 {
  margin: 0 0 0.35rem;
  font-size: 1.4rem;
  color: var(--heading);
}

.topic-body {
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1rem 1.1rem;
  margin-bottom: 1.5rem;
}

.topic-body .text {
  word-break: break-word;
}

.topic-body .text p,
.comment .text p {
  margin: 0 0 0.75rem;
}

.topic-body .text p:last-child,
.comment .text p:last-child {
  margin-bottom: 0;
}

.topic-body .text h1,
.topic-body .text h2,
.topic-body .text h3,
.topic-body .text h4,
.topic-body .text h5,
.topic-body .text h6,
.comment .text h1,
.comment .text h2,
.comment .text h3,
.comment .text h4,
.comment .text h5,
.comment .text h6 {
  margin: 1rem 0 0.5rem;
  font-weight: 600;
  line-height: 1.25;
  color: var(--heading);
}

.topic-body .text h1,
.comment .text h1 {
  font-size: 1.35rem;
}

.topic-body .text h2,
.comment .text h2 {
  font-size: 1.2rem;
}

.topic-body .text h3,
.comment .text h3 {
  font-size: 1.08rem;
}

.topic-body .text ul,
.topic-body .text ol,
.comment .text ul,
.comment .text ol {
  margin: 0 0 0.75rem;
  padding-left: 1.35rem;
}

.topic-body .text blockquote,
.comment .text blockquote {
  margin: 0 0 0.75rem;
  padding-left: 0.85rem;
  border-left: 3px solid var(--brand);
  color: var(--muted);
}

.topic-banner-image {
  margin-bottom: 0.75rem;
}

.embed-image-link {
  display: inline-block;
  max-width: 100%;
}

.embed-image {
  display: block;
  max-width: 100%;
  height: auto;
  border-radius: 6px;
  border: 1px solid var(--border);
}

.topic-body code {
  font-size: 0.85em;
  background: var(--surface-soft);
  color: var(--heading);
  padding: 0.1rem 0.25rem;
  border-radius: 4px;
}

.comments h3 {
  font-size: 1rem;
  margin: 0 0 0.75rem;
  color: var(--heading);
}

.comment {
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.75rem 1rem;
  margin-bottom: 0.65rem;
}

.comment.reply {
  margin-left: 1.5rem;
  border-left: 3px solid var(--accent);
}

.comment .who {
  font-size: 0.88rem;
  margin-bottom: 0.35rem;
}

.comment .when {
  color: var(--muted);
  font-size: 0.8rem;
}

.comment .text {
  word-break: break-word;
}

.comment .log {
  font-size: 0.85rem;
  color: var(--muted);
  font-style: italic;
  margin-top: 0.35rem;
}

footer.site {
  margin-top: 2.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
  font-size: 0.85rem;
  color: var(--muted);
}
