:root {
  --sunburst: #4570a4;
  --theme-page: #0b111c;
  --theme-deep: #0b111c;
  --theme-shell: #172131;
  --theme-panel: #202d40;
  --theme-panel-alt: #1c293b;
  --theme-panel-hover: #2a3a50;
  --theme-header: #34445a;
  --theme-header-dark: #29384c;
  --theme-input: #111b29;
  --theme-border: #526175;
  --theme-border-strong: #607188;
  --theme-accent: #77c9e7;
  --theme-accent-2: #f2c36a;
  --theme-muted: #aab7c6;
  --theme-text: #d9e0e9;
  color-scheme: dark;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  background: #0b111c;
  color: #d9e0e9;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

* {
  box-sizing: border-box;
}

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  padding: 28px 18px 36px;
  background:
    radial-gradient(ellipse at 50% 0, rgba(28, 58, 91, 0.52), transparent 52%),
    repeating-linear-gradient(135deg, rgba(255, 255, 255, 0.012) 0, rgba(255, 255, 255, 0.012) 1px, transparent 1px, transparent 5px),
    #0b111c;
  color: #d9e0e9;
  font-size: 13px;
  line-height: 1.5;
}

a {
  color: #77c9e7;
  text-decoration: none;
  transition: color 120ms ease, text-shadow 120ms ease;
}

a:hover,
a:focus-visible {
  color: #b0e9ff;
  text-decoration: underline;
}

a:active {
  color: #f2c36a;
}

a:focus-visible {
  outline: 2px solid #f2b84b;
  outline-offset: 3px;
}

button {
  transition: background-color 120ms ease, border-color 120ms ease, box-shadow 120ms ease, color 120ms ease, transform 90ms ease;
}

button:focus-visible {
  outline: 2px solid #f2b84b;
  outline-offset: 3px;
}

button:active,
.main-nav a:active {
  transform: translateY(1px);
}

button:active {
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.35);
}

.site-shell {
  width: min(100%, 1100px);
  margin: 0 auto;
  overflow: hidden;
  border: 1px solid #4c596a;
  background: #172131;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.52), inset 0 1px rgba(255, 255, 255, 0.1);
}

.masthead {
  position: relative;
  isolation: isolate;
  padding: 21px 28px 0;
  background: linear-gradient(180deg, #283548 0%, #1b2637 63%, #111b2a 100%);
  border-bottom: 1px solid #0a111b;
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.16);
}

.masthead::before {
  position: absolute;
  z-index: -1;
  inset: 0;
  background:
    radial-gradient(circle at 50% 130%, color-mix(in srgb, var(--sunburst) 28%, transparent) 0 4%, transparent 4.5%),
    repeating-conic-gradient(
      from -90deg at 50% 130%,
      color-mix(in srgb, var(--sunburst) 24%, transparent) 0deg 4deg,
      color-mix(in srgb, var(--sunburst) 3.5%, transparent) 4deg 8deg
    );
  -webkit-mask-image: radial-gradient(ellipse 72% 150% at 50% 130%, #000 18%, transparent 100%);
  mask-image: radial-gradient(ellipse 72% 150% at 50% 130%, #000 18%, transparent 100%);
  content: "";
  pointer-events: none;
}

.masthead-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.brand {
  display: flex;
  min-width: 0;
  flex-direction: column;
  align-items: flex-start;
  max-width: 100%;
}

.logo {
  display: block;
  width: min(570px, 100%);
  height: auto;
  image-rendering: auto;
}

.site-title {
  margin: 5px 0 14px 3px;
  color: #9daec0;
  font-size: 11px;
  letter-spacing: 0.08em;
}

.account-links {
  align-self: flex-start;
  display: flex;
  flex: 0 0 auto;
  gap: 9px;
  align-items: center;
  color: #8794a6;
  font-size: 11px;
}

.tagline {
  margin: 4px 0 18px 3px;
  color: #9daec0;
  font-size: 11px;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.main-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 3px;
  margin: 0 -3px;
}

.main-nav a {
  position: relative;
  display: block;
  padding: 10px 17px 9px;
  border: 1px solid transparent;
  border-bottom: 0;
  color: #bac5d2;
  font-size: 12px;
  font-weight: bold;
  text-shadow: 0 1px #111;
}

.main-nav a:hover {
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
  text-shadow: 0 0 10px rgba(176, 233, 255, 0.4);
  text-decoration: none;
}

.main-nav a.active {
  top: 1px;
  border-color: #526174;
  background: #172131;
  color: #fff;
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.12);
}

.page-content {
  padding: 0 27px 25px;
  background: #172131;
}

.content-grid {
  display: grid;
  grid-template-columns: minmax(190px, 0.72fr) minmax(0, 2fr) minmax(190px, 0.72fr);
  align-items: start;
  gap: 22px;
  margin-top: 22px;
}

.section-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin: 0 0 10px;
}

.section-heading h2,
.side-panel h2 {
  margin: 0;
  color: #f0f3f7;
  font-size: 15px;
  text-shadow: 0 1px #080d14;
}

.heading-note {
  color: #8796a9;
  font-size: 10px;
}

.forum-table-wrap {
  overflow: hidden;
  border: 1px solid #526175;
  background: #202d40;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.23);
}

.forum-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  text-align: left;
}

.forum-table thead {
  background: linear-gradient(#3d4c60, #2b394c);
}

.forum-table thead th {
  padding: 8px 10px;
  border-right: 1px solid #506076;
  border-bottom: 1px solid #172131;
  color: #d5dce5;
  font-size: 10px;
  font-weight: bold;
  text-shadow: 0 1px #111;
}

.forum-table thead th:first-child {
  padding-left: 14px;
}

.forum-table thead th:last-child {
  border-right: 0;
}

.forum-table .count-column {
  width: 60px;
  text-align: center;
}

.forum-table .last-post-column {
  width: 183px;
}

.forum-table tbody tr:not(.category-row) {
  background: #202d40;
}

.forum-table tbody tr:not(.category-row):nth-child(odd) {
  background: #1c293b;
}

.forum-table tbody tr:not(.category-row) {
  transition: background-color 120ms ease;
}

.forum-table tbody tr:not(.category-row):hover {
  background: #2a3a50;
}

.forum-table tbody tr:not(.category-row) > td {
  border-top: 1px solid #334257;
}

.forum-table .category-row th {
  padding: 7px 12px;
  border-top: 1px solid #607188;
  border-bottom: 1px solid #344357;
  background: linear-gradient(#34445a, #29384c);
  color: #e9bb65;
  font-size: 10px;
  font-weight: bold;
  letter-spacing: 0.12em;
  text-align: left;
  text-shadow: 0 1px #101722;
}

.forum-name-cell {
  min-height: 66px;
  padding: 8px 10px;
  vertical-align: middle;
}

.forum-name {
  color: #8dd7f2;
  font-size: 12px;
  font-weight: bold;
}

.forum-description,
.board-description {
  margin: 3px 0 0;
  color: #aab7c6;
  font-size: 10px;
  line-height: 1.45;
}

.board-description {
  max-width: 680px;
  margin: 4px 0 12px;
  font-size: 11px;
}

.forum-table td.count-column {
  color: #bbc5d1;
  font-size: 11px;
}

.last-post-column {
  padding: 8px 9px;
  color: #c1cbd6;
  font-size: 10px;
  line-height: 1.55;
}

.last-post-column > a {
  display: block;
  overflow: hidden;
  color: #92d2eb;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.last-post-column span {
  display: block;
  color: #8593a5;
}

.last-post-column span a {
  color: #b7c6d5;
}

.forum-footnote {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-top: 9px;
  color: #8796a8;
  font-size: 10px;
}

.status-light {
  display: inline-block;
  flex: 0 0 7px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #8ac76a;
  box-shadow: 0 0 5px rgba(138, 199, 106, 0.42);
}

.sidebar {
  display: grid;
  gap: 13px;
}

.side-panel {
  padding: 12px;
  border: 1px solid #45566c;
  background: linear-gradient(145deg, #253348, #1c293b 80%);
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.08), 0 2px 4px rgba(0, 0, 0, 0.18);
}

.side-panel h2 {
  margin: -12px -12px 10px;
  padding: 8px 11px;
  border-bottom: 1px solid #4b5d73;
  background: linear-gradient(#3c4c61, #2b394d);
  font-size: 12px;
}

.silk-icon {
  display: inline-block;
  width: 16px;
  height: 16px;
  margin-right: 6px;
  vertical-align: -3px;
}

.panel-action .silk-icon,
.primary-button .silk-icon {
  vertical-align: -4px;
}

.stats-list {
  margin: 0;
}

.stats-list div {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  padding: 5px 0;
  border-bottom: 1px dotted #445267;
}

.stats-list div:last-child {
  border-bottom: 0;
}

.stats-list dt {
  color: #aab7c6;
}

.stats-list dd {
  margin: 0;
  color: #e7edf3;
  font-weight: bold;
  text-align: right;
}

.online-note {
  display: flex;
  align-items: center;
  gap: 7px;
  margin: 9px 0 0;
  padding-top: 8px;
  border-top: 1px solid #3a495d;
  color: #a8b6c4;
  font-size: 10px;
}

.notification-control {
  display: inline-flex;
  align-items: center;
  gap: 2px;
}

.notification-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 2px;
  border: 0;
  background: transparent;
  font: inherit;
  cursor: pointer;
}

.notification-icon .silk-icon {
  width: 16px;
  height: 16px;
  margin-right: 0;
  vertical-align: -3px;
}

.notification-count {
  display: inline-block;
  min-width: 15px;
  padding: 1px 4px;
  border-radius: 8px;
  background: #b64a43;
  color: #fff;
  font-size: 9px;
  font-weight: bold;
  line-height: 1.3;
  text-align: center;
}

.notification-count[hidden] {
  display: none;
}

.notification-button:active {
  transform: none;
  box-shadow: none;
}

.latest-discussions {
  margin: 0;
  padding: 0;
  list-style: none;
}

.latest-discussions li {
  padding: 8px 0;
  border-bottom: 1px dotted #445267;
}

.latest-discussions li:first-child {
  padding-top: 0;
}

.latest-discussions li:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.latest-topic-title,
.latest-topic-meta {
  display: block;
}

.latest-topic-title {
  overflow-wrap: anywhere;
  font-size: 11px;
  font-weight: bold;
}

.latest-topic-meta,
.latest-empty {
  margin-top: 3px;
  color: #9dabb9;
  font-size: 10px;
}

.latest-reply-preview {
  display: -webkit-box;
  overflow: hidden;
  margin: 5px 0 0;
  color: #c1cbd6;
  font-size: 10px;
  line-height: 1.4;
  overflow-wrap: anywhere;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.latest-empty {
  margin: 0;
}

.featured-topic-badge {
  display: inline-block;
  margin: 0 5px 3px 0;
  padding: 2px 5px;
  border: 1px solid #947746;
  background: #3b3540;
  color: #f2c36a;
  font-size: 9px;
  font-weight: bold;
  text-transform: uppercase;
  vertical-align: 1px;
}

.latest-featured-topic {
  background: rgba(119, 91, 51, 0.12);
}

.daily-question-title {
  display: block;
  overflow-wrap: anywhere;
  font-size: 12px;
  font-weight: bold;
}

.daily-question-meta,
.daily-question-archive {
  display: block;
  margin-top: 5px;
  color: #9dabb9;
  font-size: 10px;
}

.daily-question-archive {
  padding-top: 7px;
  border-top: 1px dotted #445267;
}

.daily-question-open,
.daily-question-closed {
  margin: 8px 0;
  padding: 8px 10px;
  border: 1px solid #536a79;
  background: rgba(68, 115, 131, 0.18);
  color: #b9dce6;
  font-size: 11px;
}

.daily-question-closed {
  border-color: #6b5a43;
  background: rgba(119, 91, 51, 0.18);
  color: #e2c999;
}

.bulletin {
  display: flex;
  gap: 9px;
  align-items: flex-start;
}

.bulletin-date {
  flex: 0 0 43px;
  padding: 5px 3px;
  border: 1px solid #796744;
  background: #3b3540;
  color: #f2c36a;
  font-size: 9px;
  font-weight: bold;
  text-align: center;
}

.bulletin a,
.panel-link {
  font-size: 11px;
  font-weight: bold;
}

.bulletin p,
.members-panel > p {
  margin: 5px 0 0;
  color: #9dabb9;
  font-size: 10px;
}

.forum-news-editor:not([hidden]) {
  display: grid;
  gap: 9px;
  margin-top: 10px;
}

.forum-news-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.panel-link {
  display: inline-block;
  margin-top: 11px;
  font-size: 10px;
}

.new-member {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-top: 10px;
}

.member-avatar {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 1px solid #7689a0;
  background: linear-gradient(135deg, #596e86, #33445a);
  color: #f0c66f;
  font-size: 16px;
  font-weight: bold;
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.2);
}

.new-member strong,
.new-member small {
  display: block;
}

.new-member strong {
  font-size: 11px;
}

.new-member small {
  color: #8e9bad;
  font-size: 10px;
}

.site-footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 18px;
  padding: 14px 27px 12px;
  border-top: 1px solid #0b121c;
  background: linear-gradient(#202d3f, #172131);
  color: #8e9bac;
  font-size: 10px;
}

.site-footer strong {
  color: #bdc7d3;
}

.site-footer a {
  color: #9fcfe2;
}

.icon-credit {
  color: #8e9bac;
}

.footer-divider {
  margin: 0 9px;
  color: #586779;
}

.site-footer p {
  flex-basis: 100%;
  margin: 2px 0 0;
  padding-top: 8px;
  border-top: 1px solid #344154;
  color: #748397;
  font-size: 9px;
  text-align: center;
}

.text-button {
  padding: 0;
  border: 0;
  background: transparent;
  color: #77c9e7;
  font: inherit;
  cursor: pointer;
}

.text-button:hover {
  color: #b0e9ff;
  text-decoration: underline;
}

.account-name {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #f4bc59;
  font-weight: bold;
}

.account-avatar {
  position: relative;
  display: grid;
  width: 24px;
  height: 24px;
  flex: 0 0 24px;
  place-items: center;
  overflow: hidden;
  border: 1px solid #647990;
  background: linear-gradient(135deg, #596e86, #33445a);
  color: #f0c66f;
  font-size: 11px;
  font-weight: bold;
}

.account-avatar img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.empty-state {
  padding: 18px 12px !important;
  color: #aab6c5;
  font-size: 11px;
  text-align: center;
}

.error-message {
  color: #ff9c91 !important;
}

.forum-view {
  margin-top: 15px;
  padding: 15px;
  border: 1px solid #45566c;
  background: linear-gradient(145deg, #253348, #1c293b 80%);
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.06), 0 2px 4px rgba(0, 0, 0, 0.18);
}

.view-title {
  margin: 9px 0 4px;
  color: #f0f3f7;
  font-size: 18px;
}

.back-link {
  font-size: 10px;
}

.small-button,
.primary-button,
.panel-action {
  display: inline-block;
  padding: 7px 11px;
  border: 1px solid #60738b;
  border-radius: 2px;
  background: linear-gradient(#40536b, #2d3d53);
  color: #e7edf4;
  font: bold 11px "MS Sans Serif", Tahoma, Arial, sans-serif;
  text-shadow: 0 1px #121a26;
  cursor: pointer;
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.13), 0 1px #101722;
}

.small-button:hover,
.primary-button:hover,
.panel-action:hover {
  border-color: #7c91aa;
  background: linear-gradient(#4b6380, #354b65);
  color: #fff;
}

.small-button:disabled,
.primary-button:disabled {
  opacity: 0.6;
  cursor: wait;
}

.primary-button,
.panel-action {
  border-color: #856f43;
  background: linear-gradient(#8d7549, #675331);
  color: #fff2d2;
}

.primary-button:hover,
.panel-action:hover {
  border-color: #b0955c;
  background: linear-gradient(#a08856, #75603a);
}

.topic-list {
  margin-top: 14px;
  border: 1px solid #3c4c62;
  background: #1b283a;
}

.topic-sort-control {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
  color: #aab7c6;
  font-size: 11px;
}

.topic-sort-select {
  max-width: 100%;
  padding: 5px 7px;
  border: 1px solid #52647b;
  border-radius: 2px;
  background: #202d40;
  color: #e0e7ef;
  font: inherit;
}

.topic-list-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 11px 12px;
  border-bottom: 1px solid #3c4c62;
}

.topic-list-item:last-child {
  border-bottom: 0;
}

.member-list {
  display: grid;
  gap: 5px;
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
  counter-reset: none;
}

.member-list-item {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr) auto;
  align-items: center;
  gap: 6px 10px;
  min-width: 0;
  padding: 9px 10px;
  border: 1px solid #344357;
  background: #202d40;
}

.member-number {
  color: #e9bb65;
  font-size: 11px;
  font-weight: bold;
  font-variant-numeric: tabular-nums;
}

.member-list-identity {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.member-list-name {
  min-width: 0;
  color: #8dd7f2;
  font-size: 12px;
  overflow-wrap: anywhere;
}

.member-list-avatar {
  position: relative;
  display: grid;
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  place-items: center;
  overflow: hidden;
  border: 1px solid #647990;
  background: linear-gradient(135deg, #596e86, #33445a);
  color: #f0c66f;
  font-size: 14px;
  font-weight: bold;
}

.member-list-avatar img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.member-list-date {
  color: #8998aa;
  font-size: 10px;
}

.member-list-item .member-labels {
  margin-top: 0;
}

.member-list-summary {
  margin: 0;
  color: #9dabb9;
  font-size: 11px;
}

.member-pagination {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 14px;
}

.member-pagination a {
  text-decoration: none;
}

.member-page-count {
  color: #aab7c6;
  font-size: 11px;
}

.topic-list-title {
  font-size: 12px;
  font-weight: bold;
}

.topic-vote-rating {
  display: inline-block;
  margin-left: 8px;
  color: #e9bb65;
  font-size: 10px;
  font-weight: bold;
  white-space: nowrap;
}

.post-score {
  color: #e9bb65;
  font-size: 10px;
  font-weight: bold;
  white-space: nowrap;
}

.post-rating-label {
  color: #aab7c6;
  font-size: 10px;
}

.post-rating-choice {
  min-width: 26px;
  padding: 3px 7px;
  font-size: 15px;
  line-height: 1;
}

.post-rating-choice.selected {
  border-color: #8ac76a;
  background: linear-gradient(#3e6347, #2b4833);
  color: #e5f4df;
}

.topic-pinned-badge {
  display: inline-block;
  margin-right: 6px;
  padding: 1px 5px;
  border: 1px solid #b18b45;
  background: #4a3c25;
  color: #f4d17b;
  font-size: 9px;
  font-weight: bold;
  text-transform: uppercase;
}

.moderation-feature {
  margin: 5px 5px 0 0;
  border-color: #947746;
  color: #f2c36a;
}

.moderation-pin {
  margin-top: 5px;
  padding: 3px 7px;
  font-size: 10px;
}

.topic-list-image-link {
  display: block;
  flex: 0 0 80px;
  width: 80px;
  height: 80px;
  overflow: hidden;
  border: 1px solid #52647b;
  background: #111b29;
}

.topic-list-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 140ms ease;
}

.topic-list-image-link:hover .topic-list-image {
  transform: scale(1.06);
}

.topic-list-details {
  min-width: 0;
}

.member-labels {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 5px;
}


.moderator-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 16px;
  padding: 1px 5px;
  border: 1px solid #70c6d2;
  border-radius: 3px;
  background: linear-gradient(#286779, #194454);
  box-shadow: inset 0 1px rgba(203, 247, 255, 0.18), 0 1px 2px rgba(0, 0, 0, 0.3);
  color: #e0fbff;
  line-height: 1;
}

.moderator-badge-text {
  font-size: 8px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-shadow: 0 1px #12303a;
}

.account-moderator-badge {
  margin-left: 3px;
}

.post-author .member-labels {
  justify-content: center;
}

.topic-meta {
  margin: 3px 0;
  color: #8998aa;
  font-size: 10px;
}

.topic-preview {
  margin: 6px 0 0;
  color: #bdc7d3;
  font-size: 11px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.forum-post {
  display: grid;
  grid-template-columns: 145px minmax(0, 1fr);
  margin-top: 10px;
  border: 1px solid #3c4c62;
  background: #1b283a;
}

.reply-parent-context {
  margin: 0 0 8px;
  padding: 6px 8px;
  border-left: 2px solid #6b829b;
  background: rgba(10, 17, 28, 0.35);
  color: #aab7c6;
  font-size: 10px;
  overflow-wrap: anywhere;
}

.reply-target-notice {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
  padding: 6px 8px;
  border-left: 2px solid #77c9e7;
  background: rgba(28, 58, 91, 0.35);
  color: #c6e9f4;
  font-size: 10px;
}

.reply-target-notice[hidden] {
  display: none;
}

.reply-to-button {
  padding: 3px 7px;
  font-size: 10px;
}

.notification-list {
  display: grid;
  gap: 8px;
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
}

.notification-item {
  padding: 10px 12px;
  border: 1px solid #3c4c62;
  background: #1b283a;
}

.notification-unread {
  border-left: 3px solid #e9bb65;
}

.notification-summary,
.notification-reply-body {
  margin: 0;
}

.notification-summary {
  color: #b6c2d0;
  font-size: 11px;
}

.notification-topic-link {
  font-weight: bold;
}

.notification-reply-body {
  margin-top: 7px;
  padding: 7px 9px;
  background: rgba(10, 17, 28, 0.35);
  color: #e0e7ef;
  font-size: 11px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.notification-read-button {
  margin-top: 8px;
}

.post-author {
  display: flex;
  min-width: 0;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 12px 9px;
  border-right: 1px solid #3c4c62;
  background: #202d40;
  text-align: center;
}

.post-join-date {
  color: #9aa9bb;
  font-size: 9px;
  line-height: 1.3;
}

.post-avatar {
  position: relative;
  display: grid;
  width: 58px;
  height: 58px;
  flex: 0 0 58px;
  place-items: center;
  overflow: hidden;
  border: 1px solid #647990;
  background: linear-gradient(135deg, #596e86, #33445a);
  color: #f0c66f;
  font-size: 25px;
  font-weight: bold;
}

.topic-vote-summary,
.post-vote-group {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.topic-vote-summary {
  margin-left: 8px;
  vertical-align: middle;
}

.post-vote-group {
  margin-left: auto;
}

.post-avatar img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.post-author-name {
  max-width: 100%;
  overflow-wrap: anywhere;
  color: #8dd7f2;
  font-size: 11px;
}

.post-profile-link {
  font-size: 10px;
}

.post-signature {
  width: 100%;
  margin: 2px 0 0;
  padding-top: 6px;
  border-top: 1px solid #3c4c62;
  color: #aab7c6;
  font-size: 10px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.post-content {
  min-width: 0;
}

.post-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 7px 10px;
  border-bottom: 1px solid #3c4c62;
  background: linear-gradient(#34445a, #29384c);
  color: #8dd7f2;
  font-size: 10px;
}

.post-vote {
  white-space: nowrap;
}

.moderation-delete {
  margin-left: auto;
  padding: 3px 7px;
  font-size: 10px;
}

.post-header time {
  color: #9aa9bb;
  font-weight: normal;
  text-align: right;
}

.post-body {
  margin: 0;
  padding: 11px;
  color: #d2dbe5;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.post-emoji {
  display: inline-block;
  width: auto;
  height: auto;
  max-width: 48px;
  max-height: 48px;
  vertical-align: middle;
}

.post-image {
  display: block;
  max-width: calc(100% - 22px);
  max-height: 600px;
  width: auto;
  height: auto;
  margin: 0 11px 11px;
  border: 1px solid #3c4c62;
}

.post-form {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.emoji-picker {
  width: fit-content;
}

.emoji-picker-toggle {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 10px;
  border: 1px solid #5e9fb2;
  background: linear-gradient(#294b60, #1d374a);
  color: #d3f3ff;
  font-size: 11px;
  font-weight: bold;
  list-style: none;
  cursor: pointer;
}

.emoji-picker-toggle::-webkit-details-marker {
  display: none;
}

.emoji-picker-toggle::after {
  content: "+";
  margin-left: 3px;
  color: #9fcfe2;
}

.emoji-picker[open] .emoji-picker-toggle::after {
  content: "−";
}

.emoji-picker-toggle:hover,
.emoji-picker-toggle:focus-visible {
  border-color: #9de3f5;
  background: linear-gradient(#365e75, #26475c);
  outline: 1px solid #82cde7;
}

.emoji-picker-toggle img {
  width: auto;
  height: auto;
  max-width: 20px;
  max-height: 20px;
}

.emoji-picker[open] {
  border: 1px solid #3c4c62;
  background: #172233;
}

.emoji-picker[open] .emoji-picker-toggle {
  border: 0;
  background: transparent;
  color: #9fcfe2;
}

.emoji-picker[open] .emoji-picker-toggle:hover,
.emoji-picker[open] .emoji-picker-toggle:focus-visible {
  background: #22344a;
}

.emoji-picker[open] .emoji-grid {
  border-top: 1px solid #3c4c62;
}

.emoji-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(40px, 1fr));
  gap: 4px;
  max-height: 220px;
  overflow: auto;
  padding: 7px;
}

.emoji-picker-toggle:focus-visible {
  outline-offset: 1px;
}

.emoji-picker-toggle span {
  color: inherit;
  font-size: 11px;
}

.emoji-choice {
  display: grid;
  min-width: 0;
  min-height: 38px;
  place-items: center;
  padding: 3px;
  border: 1px solid #3c4c62;
  background: #202e41;
  cursor: pointer;
}

.emoji-choice:hover,
.emoji-choice:focus-visible {
  border-color: #82cde7;
  background: #2d4359;
}

.emoji-choice img {
  max-width: 32px;
  max-height: 32px;
}

.form-heading {
  margin: 0;
  color: #e9eef4;
  font-size: 13px;
}

.form-field {
  display: grid;
  gap: 5px;
  color: #b7c3d1;
  font-size: 11px;
  font-weight: bold;
}

.form-field input,
.form-field textarea {
  width: 100%;
  min-width: 0;
  padding: 8px 9px;
  border: 1px solid #54667d;
  border-radius: 2px;
  background: #111b29;
  color: #e0e7ef;
  font: 12px "MS Sans Serif", Tahoma, Arial, sans-serif;
}

.form-field input:focus,
.form-field textarea:focus {
  border-color: #82cde7;
  outline: 1px solid #82cde7;
}

.form-field textarea {
  resize: vertical;
}

.form-field small {
  color: #8998aa;
  font-size: 10px;
  font-weight: normal;
}

.form-message {
  min-height: 0;
  margin: 0;
  color: #aab6c5;
  font-size: 11px;
}

.form-message:empty {
  display: none;
}

.panel-copy {
  margin: 0 0 9px;
  color: #aab7c6;
  font-size: 10px;
}

.panel-action {
  margin-top: 4px;
}

.site-dialog {
  width: min(92vw, 420px);
  max-width: 420px;
  padding: 0;
  border: 1px solid #63768d;
  background: #1c293b;
  color: #d9e0e9;
  box-shadow: 0 15px 60px rgba(0, 0, 0, 0.7), inset 0 1px rgba(255, 255, 255, 0.1);
}

.site-dialog::backdrop {
  background: rgba(5, 9, 15, 0.78);
}

.dialog-card {
  padding: 16px;
}

.dialog-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: -16px -16px 12px;
  padding: 9px 13px;
  border-bottom: 1px solid #4b5d73;
  background: linear-gradient(#3c4c61, #2b394d);
}

.dialog-heading h2 {
  margin: 0;
  color: #f0f3f7;
  font-size: 14px;
}

.close-button {
  padding: 0 3px;
  border: 0;
  background: none;
  color: #d1dae4;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}

.dialog-copy {
  margin: 0;
  color: #aab7c6;
  font-size: 11px;
}

.dialog-card .form-field {
  margin-top: 11px;
}

.dialog-card [hidden] {
  display: none !important;
}

.dialog-card .primary-button {
  width: 100%;
}

.switch-button {
  display: block;
  margin: 12px auto 0;
  font-size: 11px;
}

@media (max-width: 850px) {
  .content-grid {
    grid-template-columns: minmax(0, 1fr) 220px;
    gap: 15px;
  }

  .page-content {
    padding-right: 19px;
    padding-left: 19px;
  }

  .forum-table .last-post-column {
    width: 155px;
  }

  .forum-table .count-column {
    width: 49px;
  }
}

@media (max-width: 900px) {
  .content-grid {
    grid-template-columns: 1fr;
  }

  .forum-column {
    order: -1;
  }

  .sidebar {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .members-panel {
    grid-column: span 2;
  }
}

@media (max-width: 680px) {
  body {
    padding: 0;
  }

  .site-shell {
    border-right: 0;
    border-left: 0;
  }

  .masthead {
    padding: 16px 16px 0;
  }

  .masthead-top {
    align-items: flex-start;
  }

  .account-links {
    gap: 6px;
    padding-top: 3px;
    font-size: 10px;
  }

  .site-title {
    margin-top: 4px;
    font-size: 9px;
  }

  .tagline {
    margin-top: 6px;
  }

  .main-nav {
    gap: 0;
    margin: 0 -7px;
  }

  .main-nav a {
    padding: 9px 10px 8px;
    font-size: 10px;
  }

  .page-content {
    padding: 0 13px 19px;
  }

  .site-footer {
    padding-right: 13px;
    padding-left: 13px;
  }
}

@media (max-width: 460px) {
  .account-links {
    flex-direction: column;
    align-items: flex-end;
    gap: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}

body.rathner-board-theme {
  background:
    radial-gradient(ellipse at 50% 0, rgba(113, 70, 39, 0.48), transparent 52%),
    repeating-linear-gradient(135deg, rgba(255, 255, 255, 0.012) 0, rgba(255, 255, 255, 0.012) 1px, transparent 1px, transparent 5px),
    #1b120d;
  color: #e6d5c2;
}

.rathner-board-theme a {
  color: #d6a574;
}

.rathner-board-theme a:hover,
.rathner-board-theme a:focus-visible {
  color: #f0c99c;
}

.rathner-board-theme .site-shell {
  border-color: #72563e;
  background: #2a1e16;
}

.rathner-board-theme .masthead {
  background: linear-gradient(180deg, #503a29 0%, #38291e 63%, #261b14 100%);
  border-bottom-color: #170f0a;
}

body.rathner-board-theme .masthead::before {
  background:
    radial-gradient(circle at 50% 130%, color-mix(in srgb, var(--sunburst) 28%, transparent) 0 4%, transparent 4.5%),
    repeating-conic-gradient(
      from -90deg at 50% 130%,
      color-mix(in srgb, var(--sunburst) 24%, transparent) 0deg 4deg,
      color-mix(in srgb, var(--sunburst) 3.5%, transparent) 4deg 8deg
    );
}

.rathner-board-theme .main-nav a.active {
  border-color: #765b43;
  background: #2a1e16;
}

.rathner-board-theme .page-content {
  background: #2a1e16;
}

.rathner-board-theme .side-panel,
.rathner-board-theme .forum-view {
  border-color: #6a4e37;
  background: linear-gradient(145deg, #3b2a1e, #2c2017 80%);
}

.rathner-board-theme .forum-table-wrap {
  border-color: #765b43;
  background: #38281d;
}

.rathner-board-theme .forum-table thead {
  background: linear-gradient(#604832, #493522);
}

.rathner-board-theme .forum-table thead th,
.rathner-board-theme .forum-table tbody tr:not(.category-row) > td {
  border-color: #604832;
}

.rathner-board-theme .forum-table tbody tr:not(.category-row),
.rathner-board-theme .topic-list,
.rathner-board-theme .forum-post {
  background: #35261b;
}

.rathner-board-theme .forum-table tbody tr:not(.category-row):nth-child(odd),
.rathner-board-theme .topic-list-item:nth-child(even) {
  background: #302218;
}

.rathner-board-theme .forum-table tbody tr:not(.category-row):hover {
  background: #493522;
}

.rathner-board-theme .forum-table .category-row th {
  border-color: #765b43;
  background: linear-gradient(#59412d, #44311f);
  color: #f0c99c;
}

.rathner-board-theme .topic-list-item,
.rathner-board-theme .forum-post {
  border-color: #604832;
}

.rathner-board-theme .topic-sort-select {
  border-color: #765b43;
  background: #35261b;
  color: #e6d5c2;
}

.rathner-board-theme .small-button,
.rathner-board-theme .primary-button,
.rathner-board-theme .panel-action {
  border-color: #846445;
  background: linear-gradient(#684c32, #493522);
  color: #f4e3ce;
}

.rathner-board-theme .primary-button,
.rathner-board-theme .panel-action {
  border-color: #9a7145;
  background: linear-gradient(#946b3e, #6e4b2c);
}

.rathner-board-theme .post-author {
  border-color: #604832;
  background: #302218;
}

.rathner-board-theme .post-content {
  background: #35261b;
}

.rathner-board-theme .site-footer {
  border-color: #170f0a;
  background: linear-gradient(#3a291d, #2a1e16);
}

/* Optional holiday themes. */
.theme-control {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-left: 3px;
  color: #b9c4d2;
  font-size: 10px;
}
.theme-control-label { opacity: 0.75; }
.theme-control select {
  max-width: 118px;
  height: 26px;
  border: 1px solid #64748a;
  border-radius: 2px;
  background: #172131;
  color: #f0f4f8;
  font-family: inherit;
  font-size: 11px;
}

body.holiday-christmas { background-color: #09131d; background-image: radial-gradient(circle at 20% 10%, rgba(220,235,245,.20), transparent 28%), radial-gradient(circle at 80% 20%, rgba(154,186,207,.18), transparent 30%), repeating-linear-gradient(45deg, rgba(255,255,255,.025) 0 1px, transparent 1px 12px); }
body.holiday-christmas .site-footer { border-color: #e5edf2; background: linear-gradient(180deg, #71899b, #4e6477 55%, #263746); }
body.holiday-christmas .main-nav a.active, body.holiday-christmas .side-panel { border-color: #b3c5d2; }
body.holiday-christmas .site-shell { border-color: #e5edf2; }

body.holiday-halloween { background-color: #080808; background-image: radial-gradient(circle at 80% 15%, rgba(255,116,24,.20), transparent 24%), repeating-linear-gradient(135deg, rgba(255,255,255,.018) 0 1px, transparent 1px 7px); }
body.holiday-halloween .site-footer { background: linear-gradient(180deg, #2b1b10, #17110c 60%, #080808); border-color: #ff7418; }
body.holiday-halloween .site-shell { border-color: #ff7418; }
body.holiday-halloween .main-nav a.active, body.holiday-halloween .side-panel { border-color: #a65318; }
body.holiday-halloween a { color: #ffad55; }

body.holiday-valentine { background-color: #210a14; background-image: radial-gradient(circle at 15% 20%, rgba(255,119,155,.18), transparent 25%), radial-gradient(circle at 85% 70%, rgba(170,46,96,.16), transparent 30%); }
body.holiday-valentine .site-footer { background: linear-gradient(180deg, #8c2852, #55203e 60%, #35172b); border-color: #b76886; }
body.holiday-valentine .site-shell { border-color: #d16b91; }
body.holiday-valentine .main-nav a.active, body.holiday-valentine .side-panel { border-color: #a55b76; }
body.holiday-valentine a { color: #ffabc7; }

body.holiday-st-patrick { background-color: #07150c; background-image: radial-gradient(circle at 50% 0, rgba(75,171,83,.24), transparent 35%); }
body.holiday-st-patrick .site-footer { background: linear-gradient(180deg, #20733a, #174c2b 60%, #102d1d); border-color: #5fbf70; }
body.holiday-st-patrick .site-shell { border-color: #4f9c60; }
body.holiday-st-patrick a { color: #9af0a8; }

body.holiday-easter { background-color: #171729; background-image: radial-gradient(circle at 20% 10%, rgba(255,199,225,.16), transparent 22%), radial-gradient(circle at 80% 30%, rgba(170,222,255,.14), transparent 24%), radial-gradient(circle at 40% 75%, rgba(255,238,164,.12), transparent 22%); }
body.holiday-easter .site-footer { background: linear-gradient(180deg, #68658e, #4d527d 60%, #363b62); border-color: #a8aad0; }
body.holiday-easter .site-shell { border-color: #aaa7cb; }
body.holiday-easter a { color: #c8e8ff; }

body.holiday-fourth-of-july { background-color: #09111f; background-image: linear-gradient(135deg, rgba(210,58,75,.08) 25%, transparent 25%, transparent 75%, rgba(210,58,75,.08) 75%); background-size: 32px 32px; }
body.holiday-fourth-of-july .site-footer { background: linear-gradient(180deg, #354e7d, #243a65 55%, #7d2636); border-color: #9aaed0; }
body.holiday-fourth-of-july .site-shell { border-color: #7e91b4; }
body.holiday-fourth-of-july a { color: #dcecff; }

body.holiday-thanksgiving { background-color: #1b1109; background-image: radial-gradient(circle at 50% 0, rgba(215,145,54,.16), transparent 32%); }
body.holiday-thanksgiving .site-footer { background: linear-gradient(180deg, #7a5128, #5a391e 60%, #342318); border-color: #b27b45; }
body.holiday-thanksgiving .site-shell { border-color: #a56c38; }
body.holiday-thanksgiving a { color: #eac083; }

body.holiday-new-year { background-color: #070d20; background-image: radial-gradient(circle at 20% 10%, rgba(255,213,92,.22), transparent 20%), radial-gradient(circle at 80% 15%, rgba(153,170,255,.18), transparent 22%), linear-gradient(135deg, rgba(255,255,255,.025) 25%, transparent 25%, transparent 75%, rgba(255,255,255,.025) 75%); }
body.holiday-new-year .site-footer { background: linear-gradient(180deg, #303b73, #202a58 55%, #171c40); border-color: #c0a95c; }
body.holiday-new-year .site-shell { border-color: #d0b965; }
body.holiday-new-year a { color: #fff0a6; }

@media (max-width: 460px) {
  .account-links > span {
    display: none;
  }

  .forum-table .count-column,
  .forum-table thead .count-column {
    display: none;
  }

  .forum-table .last-post-column {
    width: 112px;
  }

  .forum-name-cell {
    padding-right: 5px;
    padding-left: 5px;
  }

  .forum-name {
    font-size: 10px;
  }

  .forum-description {
    font-size: 9px;
  }

  .last-post-column {
    padding-right: 5px;
    padding-left: 5px;
    font-size: 9px;
  }

  .sidebar {
    grid-template-columns: 1fr;
  }

  .members-panel {
    grid-column: auto;
  }

  .section-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 1px;
  }

  .forum-post {
    grid-template-columns: 92px minmax(0, 1fr);
  }

  .post-author {
    padding: 9px 5px;
  }

  .post-avatar {
    width: 46px;
    height: 46px;
    flex-basis: 46px;
    font-size: 20px;
  }
}

/* Holiday themes keep the standard layout and shift its colors. */
body[class*="holiday-"] {
  --theme-page: #111b2d;
  --theme-deep: #0b111c;
  --theme-shell: #172131;
  --theme-panel: #202d40;
  --theme-panel-alt: #1c293b;
  --theme-panel-hover: #2a3a50;
  --theme-header: #34445a;
  --theme-header-dark: #29384c;
  --theme-input: #111b29;
  --theme-border: #526175;
  --theme-border-strong: #607188;
  --theme-accent: #8dd7f2;
  --theme-accent-2: #f2c36a;
  --theme-muted: #aab7c6;
  --theme-text: #d9e0e9;
  color: var(--theme-text);
}
body.holiday-christmas { --theme-page:#09131d;--theme-deep:#060c12;--theme-shell:#1a2937;--theme-panel:#263746;--theme-panel-alt:#1e303e;--theme-panel-hover:#3a5063;--theme-header:#71899b;--theme-header-dark:#4e6477;--theme-input:#101923;--theme-border:#b3c5d2;--theme-border-strong:#e5edf2;--theme-accent:#eaf6fb;--theme-accent-2:#f7fafb;--theme-muted:#c4d2dc;--theme-text:#f7fafb; }
body.holiday-halloween { --theme-page:#080808;--theme-deep:#080808;--theme-shell:#17110c;--theme-panel:#211810;--theme-panel-alt:#17110c;--theme-panel-hover:#3a2517;--theme-header:#2a1b10;--theme-header-dark:#121212;--theme-input:#0d0d0d;--theme-border:#7a471f;--theme-border-strong:#ff7418;--theme-accent:#ffad62;--theme-accent-2:#ff7418;--theme-muted:#c8b7a7;--theme-text:#f4ede6; }
body.holiday-valentine { --theme-page:#210a14;--theme-deep:#16070e;--theme-shell:#3b1728;--theme-panel:#542139;--theme-panel-alt:#451b31;--theme-panel-hover:#68304a;--theme-header:#8b405d;--theme-header-dark:#69354d;--theme-input:#26101b;--theme-border:#b66f88;--theme-border-strong:#d491a7;--theme-accent:#ffc1d3;--theme-accent-2:#ffd2a0;--theme-muted:#ecd3dc;--theme-text:#f5e6ec; }
body.holiday-st-patrick { --theme-page:#07150c;--theme-deep:#050f08;--theme-shell:#12331d;--theme-panel:#194827;--theme-panel-alt:#153d21;--theme-panel-hover:#245b32;--theme-header:#38784a;--theme-header-dark:#2a603a;--theme-input:#091b0f;--theme-border:#5f9b68;--theme-border-strong:#82b66f;--theme-accent:#b7f2c0;--theme-accent-2:#f7d774;--theme-muted:#d1e6d4;--theme-text:#edf5ee; }
body.holiday-easter { --theme-page:#171729;--theme-deep:#11111f;--theme-shell:#323252;--theme-panel:#484b72;--theme-panel-alt:#3d4165;--theme-panel-hover:#595e83;--theme-header:#7776a1;--theme-header-dark:#60668f;--theme-input:#20203b;--theme-border:#aaa7cb;--theme-border-strong:#c4c1df;--theme-accent:#d9efff;--theme-accent-2:#ffe69c;--theme-muted:#e0deef;--theme-text:#f0eef8; }
body.holiday-fourth-of-july { --theme-page:#09111f;--theme-deep:#080c14;--theme-shell:#17243a;--theme-panel:#233452;--theme-panel-alt:#6f2635;--theme-panel-hover:#304764;--theme-header:#315b99;--theme-header-dark:#183b72;--theme-input:#101827;--theme-border:#aebed3;--theme-border-strong:#f1f4f8;--theme-accent:#ffffff;--theme-accent-2:#ef9aa4;--theme-muted:#d7e3f3;--theme-text:#f7f8fb; }
body.holiday-thanksgiving { --theme-page:#19100b;--theme-deep:#110b07;--theme-shell:#3b2719;--theme-panel:#553b25;--theme-panel-alt:#452e1c;--theme-panel-hover:#76512d;--theme-header:#8a5027;--theme-header-dark:#5c351f;--theme-input:#24150d;--theme-border:#ad7947;--theme-border-strong:#cf9d62;--theme-accent:#f4c374;--theme-accent-2:#df8a3d;--theme-muted:#e8d0b0;--theme-text:#f7eddf; }
body.holiday-new-year { --theme-page:#070d20;--theme-deep:#050915;--theme-shell:#171f43;--theme-panel:#232d58;--theme-panel-alt:#1d264c;--theme-panel-hover:#303d70;--theme-header:#495b86;--theme-header-dark:#394970;--theme-input:#0c1025;--theme-border:#7688a8;--theme-border-strong:#b5a96c;--theme-accent:#fff0a6;--theme-accent-2:#e6cc72;--theme-muted:#dfe5f2;--theme-text:#eef1f8; }

body.holiday-christmas { --sunburst: #e8f3f7; }
body.holiday-halloween { --sunburst: #ff7418; }
body.holiday-valentine { --sunburst: #ff82a9; }
body.holiday-st-patrick { --sunburst: #55b86a; }
body.holiday-easter { --sunburst: #b9b0e8; }
body.holiday-fourth-of-july { --sunburst: #ffffff; }
body.holiday-thanksgiving { --sunburst: #efa13d; }
body.holiday-new-year { --sunburst: #e5d174; }

body[class*="holiday-"] { background-color: var(--theme-page); }
body[class*="holiday-"] .site-shell { border-color: var(--theme-border-strong); background: var(--theme-shell); }
body[class*="holiday-"] .page-content,
body[class*="holiday-"] .main-nav a.active { background: var(--theme-shell); }
body[class*="holiday-"] .masthead { background: linear-gradient(135deg, var(--theme-header-dark), var(--theme-header) 58%, var(--theme-accent)); border-bottom-color: var(--theme-deep); }
body.holiday-christmas .masthead { background: linear-gradient(135deg, #4e6477 0%, #71899b 38%, #b3c5d2 72%, #eef7f8 100%); }
body.holiday-halloween .masthead { background: linear-gradient(135deg, #080808 0%, #17110c 55%, #c95c12 100%); }
body.holiday-fourth-of-july .masthead { background: linear-gradient(135deg, #183b72 0%, #315b99 38%, #f1f4f8 68%, #a93445 100%); }
body.holiday-thanksgiving .masthead { background: linear-gradient(135deg, #5c351f 0%, #8a5027 48%, #b17435 78%, #d19a48 100%); }
body[class*="holiday-"] .masthead::before {
  background:
    radial-gradient(circle at 50% 130%, color-mix(in srgb, var(--sunburst) 28%, transparent) 0 4%, transparent 4.5%),
    repeating-conic-gradient(
      from -90deg at 50% 130%,
      color-mix(in srgb, var(--sunburst) 24%, transparent) 0deg 4deg,
      color-mix(in srgb, var(--sunburst) 3.5%, transparent) 4deg 8deg
    );
}
body[class*="holiday-"] .site-footer { background: linear-gradient(var(--theme-header-dark), var(--theme-deep)); border-color: var(--theme-deep); }

body[class*="holiday-"] .side-panel,
body[class*="holiday-"] .forum-view { border-color: var(--theme-border); background: linear-gradient(145deg, var(--theme-panel), var(--theme-panel-alt) 80%); }
body[class*="holiday-"] .side-panel h2 { border-bottom-color: var(--theme-border); background: linear-gradient(var(--theme-header), var(--theme-header-dark)); color: var(--theme-text); }
body[class*="holiday-"] .forum-table-wrap { border-color: var(--theme-border); background: var(--theme-panel); }
body[class*="holiday-"] .forum-table thead,
body[class*="holiday-"] .forum-table .category-row th,
body[class*="holiday-"] .post-header { background: linear-gradient(var(--theme-header), var(--theme-header-dark)); }
body[class*="holiday-"] .forum-table thead th,
body[class*="holiday-"] .forum-table tbody tr:not(.category-row)>td,
body[class*="holiday-"] .category-row th { border-color: var(--theme-border); }
body[class*="holiday-"] .forum-table tbody tr:not(.category-row) { background: var(--theme-panel); }
body[class*="holiday-"] .forum-table tbody tr:not(.category-row):nth-child(odd) { background: var(--theme-panel-alt); }
body[class*="holiday-"] .forum-table tbody tr:not(.category-row):hover { background: var(--theme-panel-hover); }

body[class*="holiday-"] .topic-list { border-color: var(--theme-border); background: var(--theme-panel-alt); }
body[class*="holiday-"] .topic-list-item,
body[class*="holiday-"] .forum-post,
body[class*="holiday-"] .notification-item { border-color: var(--theme-border); background: var(--theme-panel); }
body[class*="holiday-"] .topic-list-item:nth-child(even) { background: var(--theme-panel-alt); }
body[class*="holiday-"] .member-list-item:nth-child(even) { background: var(--theme-panel-alt); }
body[class*="holiday-"] .post-author { border-color: var(--theme-border); background: var(--theme-panel-alt); }
body[class*="holiday-"] .post-content { background: transparent; }
body[class*="holiday-"] .post-body { background: transparent; }
body[class*="holiday-"] .notification-reply-body { background: var(--theme-input); }
body[class*="holiday-"] .reply-target-notice { border-left-color: var(--theme-accent); background: color-mix(in srgb, var(--theme-header) 35%, transparent); }
body[class*="holiday-"] .daily-question-open { border-color: var(--theme-border); background: color-mix(in srgb, var(--theme-header) 18%, transparent); }
body[class*="holiday-"] .daily-question-closed { border-color: var(--theme-border-strong); background: color-mix(in srgb, var(--theme-accent-2) 12%, transparent); }

body[class*="holiday-"] .small-button,
body[class*="holiday-"] .primary-button,
body[class*="holiday-"] .panel-action,
body[class*="holiday-"] .theme-control select,
body[class*="holiday-"] .topic-sort-select,
body[class*="holiday-"] .emoji-picker-toggle { border-color: var(--theme-border-strong); background: linear-gradient(var(--theme-header), var(--theme-header-dark)); color: var(--theme-text); }
body[class*="holiday-"] .primary-button,
body[class*="holiday-"] .panel-action { border-color: var(--theme-accent-2); }
body[class*="holiday-"] .form-field input,
body[class*="holiday-"] .form-field textarea,
body[class*="holiday-"] .dialog-card input,
body[class*="holiday-"] .dialog-card textarea,
body[class*="holiday-"] input,
body[class*="holiday-"] textarea,
body[class*="holiday-"] select { border-color: var(--theme-border); background: var(--theme-input); color: var(--theme-text); }
body[class*="holiday-"] input:focus,
body[class*="holiday-"] textarea:focus,
body[class*="holiday-"] select:focus { border-color: var(--theme-accent); outline-color: var(--theme-accent); }

body[class*="holiday-"] .site-dialog,
body[class*="holiday-"] .dialog-card { border-color: var(--theme-border); background: var(--theme-panel-alt); }
body[class*="holiday-"] .dialog-heading { border-bottom-color: var(--theme-border); }
body[class*="holiday-"] h1,
body[class*="holiday-"] h2,
body[class*="holiday-"] h3,
body[class*="holiday-"] .view-title,
body[class*="holiday-"] .dialog-heading h2 { color: var(--theme-text); }
body[class*="holiday-"] .side-panel h2 { color: var(--theme-accent); }
body[class*="holiday-"] a,
body[class*="holiday-"] .forum-name,
body[class*="holiday-"] .post-author-name,
body[class*="holiday-"] .last-post-column>a { color: var(--theme-accent); }
body[class*="holiday-"] a:hover,
body[class*="holiday-"] a:focus-visible { color: var(--theme-accent-2); }
body[class*="holiday-"] .forum-description,
body[class*="holiday-"] .board-description,
body[class*="holiday-"] .latest-topic-meta,
body[class*="holiday-"] .latest-empty,
body[class*="holiday-"] .daily-question-meta,
body[class*="holiday-"] .daily-question-archive,
body[class*="holiday-"] .bulletin p,
body[class*="holiday-"] .members-panel>p,
body[class*="holiday-"] .notification-summary,
body[class*="holiday-"] .post-join-date,
body[class*="holiday-"] .post-signature,
body[class*="holiday-"] .last-post-column span,
body[class*="holiday-"] .forum-footnote,
body[class*="holiday-"] .heading-note,
body[class*="holiday-"] .form-field small { color: var(--theme-muted); }

body[class*="holiday-"] .bulletin-date,
body[class*="holiday-"] .featured-topic-badge,
body[class*="holiday-"] .topic-pinned-badge,
body[class*="holiday-"] .moderator-badge { border-color: var(--theme-border-strong); background: var(--theme-header-dark); color: var(--theme-accent-2); }

/* Rathner keeps the same structure as the standard theme, in brown. */
body.rathner-board-theme {
  --theme-page: #1b120d; --theme-deep: #170f0a; --theme-shell: #2a1e16;
  --theme-panel: #35261b; --theme-panel-alt: #302218; --theme-panel-hover: #493522;
  --theme-header: #604832; --theme-header-dark: #493522; --theme-input: #241b13;
  --theme-border: #604832; --theme-border-strong: #765b43; --theme-accent: #d6a574;
  --theme-accent-2: #f0c99c; --theme-muted: #d6c2aa; --theme-text: #e6d5c2;
  --sunburst: #b57b49;
}
body.rathner-board-theme { background-color: var(--theme-page); }
body.rathner-board-theme .site-shell { background: var(--theme-shell); border-color: var(--theme-border-strong); }
body.rathner-board-theme .page-content,
body.rathner-board-theme .main-nav a.active { background: var(--theme-shell); }
body.rathner-board-theme .masthead { background: var(--theme-header); border-color: var(--theme-deep); }
body.rathner-board-theme .site-footer { background: linear-gradient(#3a291d, var(--theme-shell)); border-color: var(--theme-deep); }
body.rathner-board-theme .side-panel,
body.rathner-board-theme .forum-view { border-color: var(--theme-border); background: linear-gradient(145deg, var(--theme-panel), var(--theme-panel-alt) 80%); }
body.rathner-board-theme .side-panel h2 { border-bottom-color: var(--theme-border); background: linear-gradient(var(--theme-header), var(--theme-header-dark)); color: var(--theme-accent-2); }
body.rathner-board-theme .forum-table-wrap { border-color: var(--theme-border-strong); background: var(--theme-panel); }
body.rathner-board-theme .forum-table thead,
body.rathner-board-theme .forum-table .category-row th,
body.rathner-board-theme .post-header { background: linear-gradient(var(--theme-header), var(--theme-header-dark)); }
body.rathner-board-theme .forum-table tbody tr:not(.category-row) { background: var(--theme-panel); }
body.rathner-board-theme .forum-table tbody tr:not(.category-row):nth-child(odd) { background: var(--theme-panel-alt); }
body.rathner-board-theme .forum-table tbody tr:not(.category-row):hover { background: var(--theme-panel-hover); }
body.rathner-board-theme .topic-list { background: var(--theme-panel-alt); border-color: var(--theme-border); }
body.rathner-board-theme .topic-list-item,
body.rathner-board-theme .forum-post,
body.rathner-board-theme .notification-item { background: var(--theme-panel); border-color: var(--theme-border); }
body.rathner-board-theme .topic-list-item:nth-child(even),
body.rathner-board-theme .post-author { background: var(--theme-panel-alt); }
body.rathner-board-theme .post-content,
body.rathner-board-theme .post-body { background: transparent; }
body.rathner-board-theme .notification-reply-body { background: var(--theme-input); }
body.rathner-board-theme .reply-target-notice { border-left-color: var(--theme-accent); background: color-mix(in srgb, var(--theme-header) 35%, transparent); }
body.rathner-board-theme .daily-question-open { border-color: var(--theme-border); background: color-mix(in srgb, var(--theme-header) 18%, transparent); }
body.rathner-board-theme h1,
body.rathner-board-theme h2,
body.rathner-board-theme h3,
body.rathner-board-theme .view-title,
body.rathner-board-theme .dialog-heading h2 { color: var(--theme-accent-2); }
body.rathner-board-theme a,
body.rathner-board-theme .forum-name,
body.rathner-board-theme .post-author-name { color: var(--theme-accent); }
body.rathner-board-theme a:hover,
body.rathner-board-theme a:focus-visible { color: #f4dfbd; }
body.rathner-board-theme .small-button,
body.rathner-board-theme .primary-button,
body.rathner-board-theme .panel-action,
body.rathner-board-theme .topic-sort-select,
body.rathner-board-theme .theme-control select { border-color: var(--theme-border-strong); background: linear-gradient(var(--theme-header), var(--theme-header-dark)); color: var(--theme-accent-2); }
body.rathner-board-theme input,
body.rathner-board-theme textarea,
body.rathner-board-theme select { border-color: var(--theme-border-strong); background: var(--theme-input); color: var(--theme-text); }
body.rathner-board-theme .site-dialog,
body.rathner-board-theme .dialog-card { background: var(--theme-panel-alt); border-color: var(--theme-border); }

/* Preserve the standard theme's transparent details and shifted menu surfaces. */
body[class*="holiday-"] .notification-reply-body,
body[class*="holiday-"] .reply-parent-context { background: color-mix(in srgb, var(--theme-deep) 35%, transparent); }
body[class*="holiday-"] .emoji-picker[open],
body[class*="holiday-"] .dialog-card,
body[class*="holiday-"] .member-list-item,
body[class*="holiday-"] .site-dialog { background: var(--theme-panel-alt); }
body[class*="holiday-"] .emoji-choice,
body[class*="holiday-"] .emoji-picker[open] .emoji-picker-toggle:hover,
body[class*="holiday-"] .emoji-picker[open] .emoji-picker-toggle:focus-visible { border-color: var(--theme-border); background: var(--theme-panel); }
body[class*="holiday-"] .emoji-choice:hover,
body[class*="holiday-"] .emoji-choice:focus-visible,
body[class*="holiday-"] .emoji-picker-toggle:hover,
body[class*="holiday-"] .emoji-picker-toggle:focus-visible { border-color: var(--theme-accent); background: var(--theme-panel-hover); }
body[class*="holiday-"] .form-heading,
body[class*="holiday-"] .dialog-heading h2,
body[class*="holiday-"] .view-title { color: var(--theme-text); }

body.rathner-board-theme .notification-reply-body,
body.rathner-board-theme .reply-parent-context { background: color-mix(in srgb, var(--theme-deep) 35%, transparent); }
body.rathner-board-theme .emoji-picker[open],
body.rathner-board-theme .dialog-card,
body.rathner-board-theme .member-list-item,
body.rathner-board-theme .site-dialog { background: var(--theme-panel-alt); }
body.rathner-board-theme .emoji-choice { border-color: var(--theme-border); background: var(--theme-panel); }
body.rathner-board-theme .form-heading { color: var(--theme-text); }

.theme-control-container {
  order: 99;
  flex-basis: 100%;
  display: flex;
  justify-content: center;
  min-height: 26px;
  margin-top: 7px;
  padding-top: 8px;
  border-top: 1px solid var(--theme-border);
}
.theme-control-container:empty { display: none; }
.theme-control-container .theme-control { margin-left: 0; }

/* Shared theme and control tokens keep the retro layout consistent across every palette. */
body {
  background-color: var(--theme-page);
  color: var(--theme-text);
}

.site-shell { border-color: var(--theme-border-strong); background: var(--theme-shell); }
.page-content { background: var(--theme-shell); }
.site-footer {
  border-top-color: var(--theme-deep);
  background: linear-gradient(var(--theme-header-dark), var(--theme-shell));
  color: var(--theme-muted);
}
.site-footer strong,
.site-footer a,
.icon-credit,
.site-footer p { color: var(--theme-muted); }
.site-footer p { border-top-color: var(--theme-border); }

.site-title,
.tagline,
.account-links,
.heading-note,
.theme-control,
.theme-control-label,
.forum-footnote,
.post-join-date,
.post-header time,
.topic-meta,
.member-list-date,
.dialog-copy,
.new-member small { color: var(--theme-muted); }

.site-title,
.tagline,
.theme-control,
.heading-note,
.member-list-date,
.post-join-date,
.topic-meta { opacity: 1; }

.section-heading h2,
.side-panel h2,
.view-title,
.dialog-heading h2,
.form-heading,
.empty-state,
.post-body,
.notification-reply-body { color: var(--theme-text); }

.forum-description,
.board-description,
.latest-topic-meta,
.latest-empty,
.latest-reply-preview,
.daily-question-meta,
.daily-question-archive,
.bulletin p,
.members-panel > p,
.panel-copy,
.notification-summary,
.post-signature,
.reply-parent-context,
.topic-preview,
.last-post-column span,
.member-list-summary { color: var(--theme-muted); }

.forum-name,
.post-author-name,
.post-header,
.last-post-column > a,
.member-list-name,
.topic-list-title,
.main-nav a.active { color: var(--theme-accent); }

.text-button { color: var(--theme-accent); }
.text-button:hover { color: var(--theme-accent-2); }

.account-links,
.forum-news-actions,
.member-pagination,
.post-vote-group,
.topic-vote-summary,
.post-header,
.forum-view .member-labels { gap: 8px; }

.small-button,
.primary-button,
.panel-action,
.reply-to-button,
.notification-read-button,
.moderation-delete,
.post-rating-choice,
.close-button,
.theme-control select,
.topic-sort-select {
  min-height: 32px;
  line-height: 1.25;
}

.small-button,
.primary-button,
.panel-action,
.reply-to-button,
.notification-read-button,
.moderation-delete,
.post-rating-choice {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  vertical-align: middle;
}

.small-button,
.primary-button,
.panel-action {
  min-width: 86px;
  padding: 7px 12px;
}

.post-rating-choice,
.reply-to-button,
.notification-read-button,
.moderation-delete {
  min-width: 0;
  padding: 4px 9px;
}

.post-rating-choice { min-width: 32px; }

.post-header {
  row-gap: 7px;
}

.post-vote-group {
  flex-wrap: wrap;
  justify-content: flex-end;
}

.forum-news-actions,
.member-pagination,
.dialog-card,
.post-form {
  row-gap: 10px;
}

.form-field,
.theme-control,
.topic-sort-control { line-height: 1.4; }

.form-field input,
.form-field textarea,
.dialog-card input,
.dialog-card textarea,
.topic-sort-select,
.theme-control select {
  min-height: 34px;
}

.form-field textarea { min-height: 112px; }

.member-list-item,
.topic-list-item,
.notification-item,
.forum-post {
  border-color: var(--theme-border);
}

.member-list-item:nth-child(even),
.topic-list-item:nth-child(even) { background: var(--theme-panel-alt); }

@media (max-width: 460px) {
  .account-links { gap: 3px; }
  .small-button,
  .primary-button,
  .panel-action { min-width: 78px; }
}
