:root {
  --bg: #0b1014;
  --panel: #111a20;
  --panel2: #16232b;
  --text: #edf7f3;
  --muted: #96aaa2;
  --gold: #e8c16a;
  --red: #159a78;
  --red2: #0e695b;
  --line: rgba(151, 180, 169, .18);
  --line-strong: rgba(232, 193, 106, .42);
  --shadow: 0 20px 55px rgba(0, 0, 0, .34);
  --accent: #28c7a2;
  --blue: #6da7ff;
  --danger: #d65f5f;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--text);
  background:
    linear-gradient(180deg, #0f171d 0%, #0b1014 42%, #090d10 100%),
    repeating-linear-gradient(90deg, rgba(255,255,255,.025) 0 1px, transparent 1px 96px);
}
a { color: inherit; text-decoration: none; }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 2px solid rgba(245, 193, 93, .72);
  outline-offset: 2px;
}
.wrap { width: min(1180px, calc(100% - 28px)); margin: 0 auto; }

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(21, 13, 16, .88);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(14px);
}
.nav { min-height: 70px; display: flex; align-items: center; justify-content: space-between; gap: 18px; }
.brand { display: inline-flex; align-items: center; gap: 12px; min-width: 260px; }
.brand-mark {
  display: grid; place-items: center;
  width: 46px; height: 46px; border-radius: 50%;
  background: linear-gradient(135deg, var(--gold), #fff0b5);
  color: #6d0914; font-weight: 900; font-size: 24px;
  box-shadow: 0 0 0 4px rgba(245, 193, 93, .13);
}
.brand strong { display: block; font-size: 18px; letter-spacing: .02em; }
.brand em { display: block; margin-top: 2px; font-style: normal; color: var(--muted); font-size: 12px; }
nav { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
nav a { padding: 8px 11px; border-radius: 6px; color: var(--muted); transition: color .16s ease, background .16s ease; }
nav a:hover { color: var(--gold); background: rgba(245, 193, 93, .08); }
nav a.active { color: var(--gold); background: rgba(245, 193, 93, .12); }

.hero { padding: 56px 0 34px; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(320px, .8fr); gap: 24px; align-items: stretch; }
.hero-copy {
  min-height: 360px;
  padding: 42px;
  border: 1px solid var(--line);
  background: linear-gradient(145deg, rgba(45, 23, 29, .88), rgba(21, 13, 16, .94));
  box-shadow: var(--shadow);
  border-radius: 8px;
}
.eyebrow { margin: 0 0 12px; color: var(--gold); font-weight: 800; letter-spacing: .08em; }
h1 { margin: 0; font-size: clamp(32px, 5vw, 58px); line-height: 1.05; letter-spacing: 0; }
.lead { max-width: 720px; margin: 20px 0 28px; color: var(--muted); font-size: 17px; line-height: 1.8; }
.actions { display: flex; gap: 12px; flex-wrap: wrap; }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 20px; border-radius: 6px; font-weight: 800; border: 0; cursor: pointer; transition: transform .16s ease, border-color .16s ease, background .16s ease; }
.btn.primary { background: linear-gradient(135deg, var(--red), #e33648); color: #fff; }
.btn.ghost { border: 1px solid var(--line); color: var(--gold); background: rgba(245, 193, 93, .06); }
.btn:hover { transform: translateY(-1px); }

.hero-panel, .thread-card, .side-card, .notice {
  border: 1px solid var(--line);
  background: rgba(33, 18, 22, .88);
  box-shadow: var(--shadow);
  border-radius: 8px;
}
.hero-panel { padding: 22px; }
.panel-head { display: flex; justify-content: space-between; align-items: center; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.panel-head strong { color: var(--gold); font-size: 20px; }
.panel-head span { color: var(--muted); font-size: 13px; }
.hot-list { list-style: none; margin: 14px 0 0; padding: 0; display: grid; gap: 10px; }
.hot-list li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 12px; border-radius: 6px; background: rgba(255,255,255,.035); }
.hot-list a { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hot-list span { color: var(--gold); font-weight: 800; }

.board-section, .content-grid, .notice { margin-top: 24px; }
.section-title { display: flex; align-items: end; justify-content: space-between; gap: 16px; margin-bottom: 16px; }
.section-title h2, .side-card h2 { margin: 0; color: var(--gold); font-size: 26px; }
.section-title p, .side-card p { margin: 0; color: var(--muted); }
.compact { margin-bottom: 12px; }
.compact h2 { font-size: 22px; }

.boards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.board {
  display: grid; grid-template-columns: 52px minmax(0, 1fr); gap: 4px 14px;
  padding: 18px; border: 1px solid var(--line); border-radius: 8px;
  background: linear-gradient(145deg, rgba(45, 23, 29, .92), rgba(33, 18, 22, .88));
}
.board:hover { border-color: rgba(245, 193, 93, .54); transform: translateY(-1px); }
.icon { grid-row: span 3; display: grid; place-items: center; width: 52px; height: 52px; border-radius: 8px; background: rgba(245, 193, 93, .12); color: var(--gold); font-size: 24px; font-weight: 900; }
.board strong { font-size: 18px; }
.board em { color: var(--muted); font-style: normal; font-size: 14px; }
.board small { color: #9f8871; }

.content-grid { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 18px; }
.thread-card, .side-card { padding: 20px; }
.threads { display: grid; gap: 8px; }
.threads a { display: grid; grid-template-columns: 50px minmax(0, 1fr) 90px; align-items: center; gap: 10px; padding: 12px; border-radius: 6px; background: rgba(255,255,255,.035); }
.threads b { color: var(--gold); }
.threads span { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.threads em { color: var(--muted); font-style: normal; text-align: right; font-size: 13px; }
.quick-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.quick-tags a { padding: 8px 10px; border: 1px solid var(--line); border-radius: 6px; color: var(--gold); background: rgba(245,193,93,.06); }

.notice { padding: 18px 20px; color: var(--muted); }
.notice strong { color: var(--gold); }
.notice p { margin: 8px 0 0; line-height: 1.8; }
.subpage { padding-top: 34px; padding-bottom: 34px; display: grid; gap: 18px; }
.subpage h1 { margin: 0; font-size: clamp(28px, 4vw, 42px); color: var(--text); }
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  color: #9f8871;
  font-size: 13px;
}
.breadcrumb a, .breadcrumb span {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 10px;
  border-radius: 6px;
  background: rgba(255,255,255,.03);
}
.breadcrumb a { color: var(--gold); }
.breadcrumb a::after {
  content: "/";
  margin-left: 8px;
  color: #806957;
}
.auth-card {
  width: min(520px, 100%);
  margin: 10px auto 0;
  padding: 26px;
  border: 1px solid var(--line);
  background: rgba(33, 18, 22, .92);
  box-shadow: var(--shadow);
  border-radius: 8px;
}
.auth-card h1 { font-size: 32px; }
.auth-card p { color: var(--muted); line-height: 1.7; }
.auth-form { display: grid; gap: 14px; margin-top: 18px; }
.auth-form label { display: grid; gap: 8px; color: var(--gold); font-weight: 800; }
.auth-form input, .auth-form select, .auth-form textarea {
  width: 100%;
  min-height: 44px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(255,255,255,.06);
  color: var(--text);
  font: inherit;
}
.auth-form textarea { min-height: 180px; padding: 12px; resize: vertical; line-height: 1.7; }
.auth-form select option { color: #1c1114; }
.wide-form { max-width: 840px; }
.auth-form input:focus, .auth-form select:focus, .auth-form textarea:focus { outline: 2px solid rgba(245, 193, 93, .32); outline-offset: 1px; }
.form-error, .form-ok {
  margin-top: 14px;
  padding: 11px 12px;
  border-radius: 6px;
  line-height: 1.6;
}
.form-error { border: 1px solid rgba(227, 54, 72, .55); color: #ffd9dd; background: rgba(183, 25, 42, .22); }
.form-ok { border: 1px solid rgba(245, 193, 93, .42); color: var(--gold); background: rgba(245, 193, 93, .09); }
.auth-note a { color: var(--gold); font-weight: 800; }
.profile-grid, .stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 12px;
  margin-top: 16px;
}
.profile-grid div, .stats-grid div {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255,255,255,.035);
}
.profile-grid strong, .stats-grid strong { display: block; color: var(--gold); font-size: 22px; }
.profile-grid span, .stats-grid span { display: block; margin-top: 6px; color: var(--muted); overflow-wrap: anywhere; }
.padded { margin-top: 18px; }
.admin-table { width: 100%; overflow-x: auto; }
.admin-table table { width: 100%; border-collapse: collapse; min-width: 760px; }
.admin-table th, .admin-table td { padding: 12px; border-bottom: 1px solid var(--line); text-align: left; }
.admin-table th { color: var(--gold); background: rgba(245,193,93,.06); }
.admin-table td { color: var(--muted); }
.inline-form { display: flex; gap: 6px; flex-wrap: wrap; margin: 0; }
.mini-btn {
  min-height: 34px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--gold);
  background: rgba(245,193,93,.06);
  cursor: pointer;
}
.mini-btn.danger { color: #ffd9dd; border-color: rgba(227,54,72,.48); background: rgba(183,25,42,.18); }
.mini-link {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--gold);
  background: rgba(245,193,93,.06);
}
.forum-hero .section-title { align-items: center; }
.portal-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 360px);
  gap: 22px;
  align-items: end;
}
.portal-copy h1 { margin-top: 0; }
.portal-stats {
  display: grid;
  gap: 10px;
}
.portal-stats div {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255,255,255,.035);
}
.portal-stats strong { display: block; color: var(--gold); font-size: 30px; }
.portal-stats span { display: block; color: var(--muted); margin-top: 4px; }
.portal-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 18px;
  align-items: start;
}
.portal-main { display: grid; gap: 18px; min-width: 0; }
.portal-boards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.compact-list { gap: 10px; }
.post-row {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 12px;
  padding: 14px;
  border: 1px solid rgba(245,193,93,.16);
  border-radius: 8px;
  background: rgba(255,255,255,.03);
}
.post-row:hover { border-color: var(--line-strong); background: rgba(245,193,93,.05); }
.post-row h3 { margin: 8px 0 6px; color: var(--gold); font-size: 20px; line-height: 1.35; }
.post-row p { margin: 0; color: var(--muted); line-height: 1.7; }
.forum-hero-stats {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.forum-hero-stats span {
  min-height: 46px;
  display: grid;
  align-content: center;
  min-width: 86px;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
  background: rgba(255,255,255,.035);
  text-align: center;
}
.forum-hero-stats strong { display: block; color: var(--gold); font-size: 20px; }
.forum-shell, .detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 18px;
  align-items: start;
}
.detail-main { display: grid; gap: 18px; min-width: 0; }
.forum-sidebar {
  display: grid;
  gap: 14px;
  position: sticky;
  top: 88px;
}
.post-list { display: grid; gap: 14px; min-width: 0; }
.post-card { transition: transform .16s ease, border-color .16s ease, background .16s ease; }
.post-card:hover { transform: translateY(-2px); border-color: var(--line-strong); background: rgba(38, 20, 25, .94); }
.post-card-head { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; }
.author-line { display: flex; align-items: center; gap: 10px; min-width: 0; }
.avatar {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 1px solid rgba(245,193,93,.38);
  border-radius: 8px;
  color: #6d0914;
  background: linear-gradient(135deg, var(--gold), #fff0b5);
  font-weight: 900;
}
.avatar.large { width: 48px; height: 48px; font-size: 20px; }
.reply-count {
  flex: 0 0 auto;
  min-height: 32px;
  display: inline-flex;
  align-items: center;
  padding: 0 10px;
  border: 1px solid rgba(227,54,72,.42);
  border-radius: 6px;
  color: #ffd9dd;
  background: rgba(183,25,42,.16);
  font-weight: 800;
  font-size: 13px;
}
.post-list h2 { margin: 10px 0; color: var(--gold); font-size: 24px; line-height: 1.35; }
.post-list h2 a:hover { color: #ffe3a3; }
.post-list p { margin: 0; color: var(--muted); line-height: 1.8; }
.post-meta { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; color: #9f8871; font-size: 13px; }
.post-meta span:not(.meta-badge) {
  min-height: 26px;
  display: inline-flex;
  align-items: center;
  padding: 0 8px;
  border-radius: 6px;
  background: rgba(255,255,255,.035);
}
.meta-badge {
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  padding: 0 10px;
  border: 1px solid rgba(245,193,93,.34);
  border-radius: 6px;
  color: var(--gold);
  background: rgba(245,193,93,.08);
  font-weight: 800;
}
.filter-form {
  display: grid;
  grid-template-columns: minmax(160px, 220px) minmax(220px, 1fr) auto auto;
  gap: 12px;
  align-items: end;
  margin-top: 16px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255,255,255,.025);
}
.filter-form label { display: grid; gap: 8px; color: var(--gold); font-weight: 800; }
.filter-form input, .filter-form select {
  width: 100%;
  min-height: 44px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(255,255,255,.06);
  color: var(--text);
  font: inherit;
}
.filter-form select option { color: #1c1114; }
.category-chips {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 14px;
}
.category-chips a {
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--gold);
  background: rgba(245,193,93,.05);
  font-weight: 800;
}
.category-chips a.active, .category-chips a:hover {
  border-color: var(--line-strong);
  background: rgba(245,193,93,.12);
}
.post-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid rgba(245,193,93,.14);
  color: #9f8871;
  font-size: 13px;
}
.read-more {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--gold);
  background: rgba(245,193,93,.06);
  font-weight: 800;
}
.read-more:hover { border-color: var(--line-strong); background: rgba(245,193,93,.1); }
.pager { display: flex; justify-content: center; align-items: center; gap: 12px; flex-wrap: wrap; }
.pager a, .pager span {
  min-height: 40px;
  padding: 9px 14px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--gold);
  background: rgba(245,193,93,.06);
}
.category-list, .activity-list, .related-list { display: grid; gap: 8px; margin-top: 12px; }
.category-list a {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid rgba(245,193,93,.14);
  border-radius: 8px;
  background: rgba(255,255,255,.03);
}
.category-list a:hover, .activity-list a:hover, .related-list a:hover { border-color: var(--line-strong); background: rgba(245,193,93,.06); }
.category-list span { color: var(--muted); }
.category-list strong { color: var(--gold); }
.activity-list a, .related-list a {
  display: grid;
  gap: 5px;
  padding: 11px 12px;
  border: 1px solid rgba(245,193,93,.14);
  border-radius: 8px;
  background: rgba(255,255,255,.03);
}
.activity-list b { color: var(--gold); }
.activity-list span, .related-list span { color: var(--muted); line-height: 1.55; }
.activity-list em, .related-list em { color: #9f8871; font-size: 12px; font-style: normal; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.empty-state { display: grid; gap: 6px; text-align: center; }
.empty-state strong { color: var(--gold); font-size: 22px; }
.post-detail h1, .post-detail h2 { margin: 12px 0; color: var(--gold); line-height: 1.25; }
.detail-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 16px 0;
}
.detail-stats div {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255,255,255,.03);
}
.detail-stats strong { display: block; color: var(--gold); overflow-wrap: anywhere; }
.detail-stats span { display: block; margin-top: 5px; color: #9f8871; font-size: 13px; }
.post-body { color: var(--muted); line-height: 1.9; white-space: normal; overflow-wrap: anywhere; }
.comment-list { display: grid; gap: 12px; }
.comment-item { padding: 14px; border: 1px solid var(--line); border-radius: 8px; background: rgba(255,255,255,.03); }
.comment-item:hover { border-color: rgba(245,193,93,.34); }
.comment-head { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; }
.floor {
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  padding: 0 10px;
  border-radius: 6px;
  color: var(--gold);
  background: rgba(245,193,93,.08);
  font-weight: 800;
}
.comment-item p { margin: 8px 0 0; color: var(--muted); line-height: 1.8; overflow-wrap: anywhere; }
.muted-line { color: var(--muted); }
footer { margin-top: 34px; border-top: 1px solid var(--line); color: var(--muted); }
.foot { min-height: 72px; display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }

@media (max-width: 860px) {
  .nav { align-items: flex-start; flex-direction: column; padding: 14px 0; }
  .brand { min-width: 0; }
  nav { justify-content: flex-start; width: 100%; }
  nav a { flex: 1 1 auto; text-align: center; background: rgba(255,255,255,.025); }
  .hero-grid, .content-grid { grid-template-columns: 1fr; }
  .forum-shell, .detail-layout, .portal-grid, .portal-hero { grid-template-columns: 1fr; }
  .portal-boards { grid-template-columns: 1fr; }
  .forum-sidebar { position: static; }
  .forum-hero .section-title { align-items: flex-start; }
  .forum-hero-stats { justify-content: stretch; width: 100%; }
  .forum-hero-stats span { flex: 1 1 30%; }
  .post-card-head { flex-direction: column; }
  .comment-head { flex-direction: column; }
  .reply-count { align-self: flex-start; }
  .hero-copy { min-height: auto; padding: 28px; }
  .boards { grid-template-columns: 1fr; }
  .profile-grid, .stats-grid { grid-template-columns: 1fr; }
  .filter-form { grid-template-columns: 1fr; }
  .detail-stats { grid-template-columns: 1fr; }
  .actions .btn, .filter-form .btn, .post-foot .read-more { width: 100%; }
  .section-title { align-items: flex-start; flex-direction: column; }
  .threads a { grid-template-columns: 44px minmax(0, 1fr); }
  .threads em { grid-column: 2; text-align: left; }
}

/* 2026 visual refresh */
.topbar {
  background: rgba(11, 16, 20, .82);
  border-bottom: 1px solid rgba(151,180,169,.16);
  box-shadow: 0 10px 28px rgba(0,0,0,.24);
}
.nav { min-height: 76px; }
.brand-mark {
  width: 44px;
  height: 44px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--accent), var(--gold));
  color: #08120f;
  box-shadow: none;
}
.brand strong { font-size: 17px; }
.brand em { color: #7f948c; }
nav a {
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  border: 1px solid transparent;
  color: #a9bbb4;
}
nav a:hover, nav a.active {
  color: var(--text);
  border-color: rgba(40,199,162,.26);
  background: rgba(40,199,162,.11);
}

.thread-card, .side-card, .notice, .hero-panel, .auth-card {
  border-color: rgba(151,180,169,.16);
  background: linear-gradient(180deg, rgba(22,35,43,.96), rgba(15,24,30,.96));
  box-shadow: 0 14px 36px rgba(0,0,0,.26);
}
.portal-hero, .forum-hero {
  position: relative;
  overflow: hidden;
  border-color: rgba(40,199,162,.24);
  background:
    linear-gradient(135deg, rgba(22,35,43,.98), rgba(13,22,27,.98) 62%, rgba(22,30,27,.98));
}
.portal-hero::before, .forum-hero::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 4px;
  background: linear-gradient(90deg, var(--accent), var(--gold), var(--blue));
}
.portal-copy, .portal-stats, .forum-hero > * { position: relative; }
.eyebrow {
  color: var(--accent);
  letter-spacing: .06em;
}
h1 {
  max-width: 860px;
  color: #f5fbf8;
}
.lead { color: #a5b8b0; }
.section-title h2, .side-card h2, .panel-head strong, .post-list h2, .post-detail h1, .post-detail h2 {
  color: #f0d184;
}
.section-title p, .side-card p { color: #95aaa2; }

.btn {
  border-radius: 8px;
  min-height: 42px;
  box-shadow: none;
}
.btn.primary {
  background: linear-gradient(135deg, #20b991, #139b81);
  color: #05110e;
}
.btn.ghost {
  border-color: rgba(151,180,169,.22);
  color: #d8e7e0;
  background: rgba(255,255,255,.035);
}
.btn.ghost:hover {
  border-color: rgba(40,199,162,.36);
  background: rgba(40,199,162,.09);
}

.portal-stats div, .forum-hero-stats span, .detail-stats div, .profile-grid div, .stats-grid div {
  border-color: rgba(151,180,169,.16);
  background: rgba(255,255,255,.035);
}
.portal-stats strong, .forum-hero-stats strong, .detail-stats strong, .profile-grid strong, .stats-grid strong {
  color: var(--accent);
}
.portal-stats span, .forum-hero-stats span, .detail-stats span { color: #91a59d; }

.board {
  border-color: rgba(151,180,169,.16);
  background: linear-gradient(180deg, rgba(22,35,43,.95), rgba(14,22,28,.95));
  transition: transform .16s ease, border-color .16s ease, background .16s ease;
}
.board:hover {
  border-color: rgba(40,199,162,.36);
  background: linear-gradient(180deg, rgba(24,42,48,.98), rgba(15,27,33,.98));
}
.icon, .avatar {
  border-radius: 8px;
  background: linear-gradient(135deg, rgba(40,199,162,.95), rgba(232,193,106,.95));
  color: #07120f;
}
.board strong { color: #f4fbf8; }
.board em, .board small { color: #8fa29b; }

.post-card, .post-row, .comment-item, .category-list a, .activity-list a, .related-list a {
  border-color: rgba(151,180,169,.14);
  background: rgba(255,255,255,.032);
}
.post-card:hover, .post-row:hover, .category-list a:hover, .activity-list a:hover, .related-list a:hover {
  transform: translateY(-1px);
  border-color: rgba(40,199,162,.32);
  background: rgba(40,199,162,.055);
}
.meta-badge {
  border-color: rgba(40,199,162,.34);
  color: #8df0d6;
  background: rgba(40,199,162,.09);
}
.post-meta span:not(.meta-badge) {
  color: #a0b3ac;
  background: rgba(255,255,255,.035);
}
.reply-count {
  border-color: rgba(232,193,106,.34);
  color: #ffe4a3;
  background: rgba(232,193,106,.08);
}
.read-more, .mini-link, .mini-btn, .category-chips a, .pager a, .pager span, .quick-tags a {
  border-color: rgba(151,180,169,.18);
  color: #d8e7e0;
  background: rgba(255,255,255,.035);
}
.read-more:hover, .mini-link:hover, .mini-btn:hover, .category-chips a:hover, .category-chips a.active {
  border-color: rgba(40,199,162,.34);
  color: #f5fffb;
  background: rgba(40,199,162,.09);
}
.mini-btn.danger {
  color: #ffc6c6;
  border-color: rgba(214,95,95,.38);
  background: rgba(214,95,95,.1);
}

.filter-form, .auth-form input, .auth-form select, .auth-form textarea, .filter-form input, .filter-form select {
  border-color: rgba(151,180,169,.18);
  background: rgba(4,9,12,.28);
}
.filter-form {
  background: rgba(255,255,255,.025);
}
.filter-form label, .auth-form label { color: #d5e5de; }
.breadcrumb a, .breadcrumb span {
  background: rgba(255,255,255,.035);
}
.breadcrumb a { color: #8df0d6; }
.breadcrumb a::after { color: #657970; }

.panel-head {
  border-bottom-color: rgba(151,180,169,.14);
}
.activity-list b, .category-list strong, .related-list span, .post-row h3, .post-list h2 {
  color: #f0d184;
}
.activity-list span, .related-list em, .category-list span, .muted-line {
  color: #94a8a0;
}
.notice {
  border-color: rgba(232,193,106,.22);
  background: linear-gradient(180deg, rgba(38,34,24,.82), rgba(20,25,23,.92));
}
.notice strong { color: #f0d184; }

@media (max-width: 860px) {
  .nav { min-height: auto; }
  nav a { justify-content: center; }
  .portal-hero, .forum-hero, .thread-card, .side-card { padding: 18px; }
  h1 { font-size: clamp(30px, 9vw, 42px); }
  .portal-stats { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .portal-stats div { padding: 12px; }
  .portal-stats strong { font-size: 24px; }
}

/* Layout upgrade: operation strip and denser portal cards */
.site-strip {
  position: sticky;
  top: 76px;
  z-index: 19;
  border-bottom: 1px solid rgba(151,180,169,.12);
  background: rgba(9, 13, 16, .74);
  backdrop-filter: blur(14px);
}
.site-strip-inner {
  min-height: 54px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(240px, 360px) auto;
  gap: 12px;
  align-items: center;
}
.strip-links {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  scrollbar-width: none;
}
.strip-links::-webkit-scrollbar { display: none; }
.strip-links a, .strip-post {
  flex: 0 0 auto;
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  padding: 0 11px;
  border: 1px solid rgba(151,180,169,.14);
  border-radius: 8px;
  color: #b8cac3;
  background: rgba(255,255,255,.026);
  font-size: 13px;
  font-weight: 800;
}
.strip-links a:hover, .strip-links a.active, .strip-post:hover {
  border-color: rgba(40,199,162,.32);
  color: #f3fffb;
  background: rgba(40,199,162,.09);
}
.strip-search {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
}
.strip-search input {
  min-height: 36px;
  width: 100%;
  padding: 0 12px;
  border: 1px solid rgba(151,180,169,.16);
  border-radius: 8px;
  color: var(--text);
  background: rgba(255,255,255,.04);
  font: inherit;
}
.strip-search button {
  min-height: 36px;
  padding: 0 13px;
  border: 0;
  border-radius: 8px;
  color: #06120f;
  background: linear-gradient(135deg, var(--accent), var(--gold));
  font-weight: 900;
  cursor: pointer;
}
.ops-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}
.ops-card {
  min-height: 108px;
  display: grid;
  align-content: center;
  gap: 8px;
  padding: 18px;
  border: 1px solid rgba(151,180,169,.16);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(22,35,43,.9), rgba(13,22,27,.94));
}
.ops-card:hover {
  border-color: rgba(40,199,162,.34);
  background: rgba(40,199,162,.06);
}
.ops-card strong { color: #f0d184; font-size: 20px; }
.ops-card span { color: #9bada6; line-height: 1.65; }

.static-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 22px;
  align-items: end;
  position: relative;
  overflow: hidden;
  border-color: rgba(40,199,162,.24);
  background:
    linear-gradient(135deg, rgba(22,35,43,.98), rgba(13,22,27,.98) 62%, rgba(22,30,27,.98));
}
.static-hero::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 4px;
  background: linear-gradient(90deg, var(--accent), var(--gold), var(--blue));
}
.static-hero > * { position: relative; }
.static-hero .lead { margin-bottom: 0; }
.hero-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.static-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}
.feature-tile {
  display: grid;
  gap: 9px;
  min-height: 150px;
  padding: 18px;
  border: 1px solid rgba(151,180,169,.16);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(22,35,43,.95), rgba(14,22,28,.95));
  transition: transform .16s ease, border-color .16s ease, background .16s ease;
}
.feature-tile:hover {
  transform: translateY(-2px);
  border-color: rgba(40,199,162,.36);
  background: linear-gradient(180deg, rgba(24,42,48,.98), rgba(15,27,33,.98));
}
.feature-tile b {
  color: #f0d184;
  font-size: 20px;
}
.feature-tile span {
  color: #95aaa2;
  line-height: 1.7;
}
.feature-tile em {
  align-self: end;
  justify-self: start;
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  padding: 0 10px;
  border: 1px solid rgba(232,193,106,.28);
  border-radius: 6px;
  color: var(--gold);
  background: rgba(232,193,106,.07);
  font-style: normal;
  font-weight: 800;
}
.static-content { margin-top: 0; }

@media (max-width: 860px) {
  .site-strip { position: static; }
  .site-strip-inner { grid-template-columns: 1fr; padding-top: 10px; padding-bottom: 10px; }
  .strip-post { justify-content: center; }
  .ops-grid { grid-template-columns: 1fr; }
  .static-hero {
    grid-template-columns: 1fr;
  }
  .hero-actions {
    justify-content: stretch;
  }
  .hero-actions .btn {
    width: 100%;
  }
  .static-grid {
    grid-template-columns: 1fr;
  }
}
