.forum-page { min-height: 100vh; background: #020711; }
.forum-topbar { height: 58px; padding: 0 max(20px, calc((100vw - 1100px) / 2)); display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid #173447; background: #050d18; }
.wordmark { color: #eaf8ff; font-size: 14px; font-weight: 900; text-decoration: none; }
.forum-topbar nav { display: flex; gap: 20px; }
.forum-topbar nav a, .signed-in a, .register-link { color: #67dfe9; font-size: 13px; font-weight: 700; text-decoration: none; }
.forum-shell { width: min(1100px, calc(100% - 36px)); margin: 0 auto; padding: 32px 0 42px; }
.forum-heading { display: flex; align-items: end; justify-content: space-between; padding-bottom: 24px; border-bottom: 1px solid #173447; }
.forum-heading h1 { margin: 8px 0 4px; font-size: 36px; line-height: 1; }
.forum-heading p { margin: 0; font-size: 14px; }
.public-note { padding: 7px 10px; border: 1px solid #31566e; border-radius: 5px; color: #a9c4d3; font-size: 12px; }
.forum-auth { padding: 15px 0; border-bottom: 1px solid #173447; }
.signed-in { display: flex; align-items: center; gap: 10px; min-height: 38px; font-size: 13px; }
.signed-in a { margin-left: auto; }
.online-mark { width: 8px; height: 8px; border-radius: 50%; background: #62e6ae; }
.login-form { display: grid; grid-template-columns: minmax(190px, 1fr) 170px 170px auto auto; gap: 9px; align-items: center; }
.login-form > div strong { font-size: 13px; }
.login-form > div p { margin: 3px 0 0; font-size: 12px; }
.forum-page input, .forum-page select, .forum-page textarea { min-width: 0; width: 100%; padding: 10px 11px; border: 1px solid #31566e; border-radius: 5px; color: #eaf8ff; background: #061522; font: inherit; font-size: 13px; }
.forum-page input:focus, .forum-page select:focus, .forum-page textarea:focus { outline: 2px solid #49f5ff; outline-offset: 1px; }
.forum-page button { white-space: nowrap; }
.forum-page .status { margin: 4px 0 0; font-size: 13px; }
.forum-page .status:empty { display: none; }
.compose-section { padding: 22px 0 24px; border-bottom: 1px solid #173447; }
.section-title, .board-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.section-title h2, .board-toolbar h2 { margin: 0; font-size: 18px; }
.section-title > span { color: #52e0ea; font-size: 12px; font-weight: 800; text-transform: uppercase; }
.topic-form { display: grid; gap: 10px; margin-top: 14px; }
.topic-form label { margin: 0; color: #a9c4d3; }
.topic-form-row { display: grid; grid-template-columns: minmax(0, 1fr) 220px; gap: 12px; }
.topic-form textarea { min-height: 100px; resize: vertical; line-height: 1.5; }
.form-footer { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.form-footer > span { color: #718da1; font-size: 12px; }
.form-footer button { width: auto; min-width: 132px; }
.board-toolbar { padding: 22px 0 12px; }
.board-toolbar select { width: 190px; }
.board-layout { display: grid; grid-template-columns: minmax(0, .95fr) minmax(0, 1.45fr); border: 1px solid #173447; border-radius: 6px; overflow: hidden; background: rgba(7, 21, 37, .72); }
.topic-list { min-height: 300px; max-height: 680px; overflow-y: auto; border-right: 1px solid #173447; }
.topic-row { display: block; width: 100%; padding: 14px 16px; border: 0; border-bottom: 1px solid #173447; border-radius: 0; text-align: left; background: transparent; cursor: pointer; }
.topic-row:hover, .topic-row.selected { background: #0c2438; }
.topic-row.selected { box-shadow: inset 3px 0 #49f5ff; }
.topic-meta, .thread-meta, .reply-meta { display: flex; align-items: center; gap: 8px; color: #7893a6; font-size: 11px; }
.category-label { color: #62e6ae; font-weight: 800; }
.topic-row strong { display: block; margin: 7px 0 4px; color: #eaf8ff; font-size: 14px; line-height: 1.35; }
.topic-excerpt { display: -webkit-box; overflow: hidden; color: #9cb2c5; font-size: 12px; line-height: 1.5; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.topic-count { margin-top: 9px; color: #8fa8ba; font-size: 11px; }
.thread-panel { min-width: 0; min-height: 300px; padding: 20px; }
.thread-panel h2 { margin: 0 0 9px; font-size: 21px; line-height: 1.3; }
.thread-body { margin: 16px 0; color: #c5d6e1; line-height: 1.65; white-space: pre-wrap; overflow-wrap: anywhere; }
.thread-replies { display: grid; gap: 0; border-top: 1px solid #173447; }
.thread-replies h3 { margin: 17px 0 4px; font-size: 14px; }
.reply { padding: 12px 0; border-bottom: 1px solid #173447; }
.reply p { margin: 7px 0 0; color: #c5d6e1; font-size: 13px; line-height: 1.55; white-space: pre-wrap; overflow-wrap: anywhere; }
.reply-form { display: grid; gap: 9px; margin-top: 16px; }
.reply-form textarea { min-height: 76px; resize: vertical; }
.reply-form .primary { justify-self: end; width: auto; min-width: 110px; }
.empty-state, .empty-thread { color: #8fa8ba; font-size: 13px; }
.empty-state { padding: 18px; }
.empty-thread { display: grid; min-height: 250px; align-content: center; justify-items: start; }
.empty-thread h2 { margin: 9px 0 0; font-size: 18px; color: #dcebf4; }
.empty-thread p { margin: 6px 0 0; font-size: 13px; }
.forum-footer { display: flex; justify-content: space-between; gap: 12px; padding-top: 13px; color: #718da1; font-size: 11px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.hidden { display: none !important; }
@media (max-width: 760px) {
  .forum-shell { width: min(100% - 24px, 620px); padding-top: 22px; }
  .forum-topbar { padding: 0 14px; }
  .forum-heading { align-items: start; }
  .forum-heading h1 { font-size: 30px; }
  .forum-heading p { max-width: 270px; font-size: 13px; }
  .login-form { grid-template-columns: 1fr 1fr; }
  .login-form > div { grid-column: 1 / -1; }
  .login-form button { grid-column: 1; }
  .register-link { justify-self: start; }
  .topic-form-row { grid-template-columns: 1fr; }
  .board-layout { grid-template-columns: 1fr; }
  .topic-list { min-height: 0; max-height: 360px; border-right: 0; border-bottom: 1px solid #173447; }
  .thread-panel { min-height: 240px; padding: 16px; }
}
