:root {
  /* sb.sb dark theme tokens */
  --bg: #0d0e14;
  --bg-elev: #14151c;
  --panel: #14151c;
  --panel-alt: #1a1b24;
  --panel-hover: #20222c;
  --navy: #1a1b24;
  --line: #2a2c38;
  --line-soft: #20222c;
  --text: #e7e8ef;
  --text-strong: #f2f3f8;
  --muted: #a8abbb;
  --text-subtle: #8b8fa1;
  --accent: #ffd02f;
  --accent-2: #ffd977;
  --sb-yellow: #ffd02f;
  --sb-yellow-hover: #ffd977;
  --sb-yellow-soft: #2e2717;
  --sb-yellow-border: #5c4b1a;
  /* 烧饼楼层隔行：偏黑炭灰，少蓝调 */
  --sb-floor-odd: #111111;
  --sb-floor-odd-side: #0a0a0a;
  --sb-floor-odd-body: #121212;
  --sb-floor-even: #1c1c1c;
  --sb-floor-even-side: #181818;
  --sb-floor-even-body: #222222;
  --sb-floor-line: rgba(255, 255, 255, 0.06);
  --mission-bar-bg: #1c1a12;
  --mission-bar-border: #3a3420;
  --avatar-fallback: #6d28d9;
  --critical: #ff9999;
  --high: #ffc94d;
  --medium: #fcb900;
  --low: #2fce93;
  --unknown: #8b8fa1;
  --success: #2fce93;
}

* { box-sizing: border-box; }

html, body {
  background: var(--bg);
  color: var(--text);
  font-family: "Source Sans 3", system-ui, sans-serif;
  min-height: 100%;
  overflow-x: clip;
  max-width: 100%;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 8px;
}
.skip-link:focus {
  left: 12px;
  z-index: 20;
  background: #fff;
  color: #000;
  padding: 6px 10px;
}

.brand-mark {
  width: 28px;
  height: 28px;
  border-radius: 6px;
  object-fit: cover;
  background: #0b1224;
  box-shadow: 0 0 0 1px rgba(148, 163, 184, 0.25);
  flex: 0 0 auto;
}
.nav-link { color: #c9d4ea !important; }
.nav-link:hover { color: #fff !important; }

.btn,
a.btn,
a.btn:hover,
a.btn:focus,
a.btn:focus-visible,
a.btn:active,
button.btn:hover {
  text-decoration: none !important;
}
.btn {
  border-radius: 10px;
  font-weight: 650;
  letter-spacing: 0.01em;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease, box-shadow 0.15s ease, transform 0.12s ease;
}
.btn:active:not(:disabled) {
  transform: translateY(1px);
}
.btn-accent {
  background: linear-gradient(180deg, #ffe06a 0%, var(--sb-yellow) 100%);
  color: #14151c;
  border: 0;
  font-weight: 750;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.28) inset, 0 6px 16px rgba(255, 208, 47, 0.18);
  padding-inline: 1.15rem;
}
.btn-accent:hover {
  background: linear-gradient(180deg, #ffe98a 0%, var(--sb-yellow-hover) 100%);
  color: #14151c;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.35) inset, 0 8px 18px rgba(255, 208, 47, 0.26);
}
.btn-accent:focus-visible {
  outline: 0;
  box-shadow: 0 0 0 0.2rem rgba(255, 208, 47, 0.35);
}
.btn-ghost {
  color: var(--muted);
  border: 1px solid var(--line);
  background: transparent;
}
.btn-ghost:hover,
.btn-ghost:focus-visible {
  color: var(--text-strong);
  border-color: var(--line-strong, #3a3d4c);
  background: var(--panel-hover);
  text-decoration: none !important;
}
.btn-outline-light {
  border: 1px solid var(--line);
  color: var(--text);
  background: rgba(255, 255, 255, 0.02);
}
.btn-outline-light:hover,
.btn-outline-light:focus-visible {
  background: var(--panel-hover);
  color: #fff;
  border-color: var(--sb-yellow-border);
  text-decoration: none !important;
}
.btn-outline-warning {
  color: var(--sb-yellow);
  border: 1px solid var(--sb-yellow-border);
  background: transparent;
}
.btn-outline-warning:hover,
.btn-outline-warning:focus-visible {
  background: var(--sb-yellow-soft);
  color: var(--sb-yellow-hover);
  border-color: var(--sb-yellow);
  text-decoration: none !important;
}
.btn-danger {
  background: linear-gradient(180deg, #ff6b6b 0%, #e11d48 100%);
  border: 0;
  color: #fff;
  font-weight: 700;
  box-shadow: 0 6px 16px rgba(225, 29, 72, 0.22);
}
.btn-danger:hover {
  background: linear-gradient(180deg, #ff8585 0%, #be123c 100%);
  color: #fff;
}
.sb-form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  align-items: center;
  margin-top: 1.15rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}
.sb-form-actions .btn-accent {
  min-width: 7.5rem;
}

.site-main {
  min-height: calc(100vh - 180px);
  overflow-x: clip;
  max-width: 100%;
}
.site-container { padding-top: 1.25rem; padding-bottom: 2rem; }
.sb-page-back {
  margin: 0 0 0.85rem;
}
.sb-page-back-btn,
.sb-page-back-btn:hover,
.sb-page-back-btn:focus,
.sb-page-back-btn:focus-visible,
.sb-page-back-btn:active {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.28rem 0.7rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.04);
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.82rem;
  text-decoration: none !important;
  line-height: 1.2;
}
.sb-page-back-btn:hover,
.sb-page-back-btn:focus-visible {
  color: #fff;
  border-color: rgba(255, 208, 47, 0.45);
  background: rgba(255, 208, 47, 0.08);
}
.sb-shell {
  width: 100%;
  max-width: 100%;
  padding-left: 1rem;
  padding-right: 1rem;
  box-sizing: border-box;
}
@media (min-width: 1200px) {
  .sb-shell {
    padding-left: 1.5rem;
    padding-right: 1.5rem;
  }
}
.page-site,
.page-forum,
.page-content,
.page-tool,
.page-auth,
.page-form,
.page-home,
.page-hub {
  background: var(--bg);
}
.page-site .site-container,
.page-forum .site-container {
  padding-top: 0.55rem;
  padding-bottom: 1.5rem;
}
.page-site .page-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.75rem 1rem;
  margin-bottom: 0.85rem;
}
.page-site .page-head h1 {
  margin: 0 0 0.25rem;
  font-size: clamp(1.25rem, 2.2vw, 1.55rem);
  font-weight: 650;
}
.page-site .page-desc,
.page-site .lead-copy {
  color: var(--muted);
  max-width: 42rem;
}
.page-site .empty {
  background: #12151c;
  border: 1px dashed rgba(255, 255, 255, 0.1);
  border-radius: 6px;
  text-align: left;
  padding: 1rem 1.1rem;
}
.page-site .disclaimer {
  border-left: 3px solid var(--sb-yellow);
  color: var(--muted);
}

.hero {
  padding: 2.2rem 0 1rem;
}
.kicker {
  color: var(--accent-2);
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.78rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
h1, h2, h3 { font-weight: 650; }
.lead-copy { color: var(--muted); max-width: 42rem; }

.panel {
  background: #12151c;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 6px;
  padding: 1rem 1.1rem;
  box-shadow: none;
}
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 0.85rem; }
.stat-card {
  background: rgba(7, 13, 24, 0.55);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.9rem;
}
.stat-card .value {
  font-family: "IBM Plex Mono", monospace;
  font-size: 1.45rem;
  color: #fff;
}
.stat-card .label { color: var(--muted); font-size: 0.8rem; }

.scan-box input {
  background: #0b1224;
  border: 1px solid #29406d;
  color: #fff;
  padding: 0.85rem 1rem;
}
.scan-box input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 0.2rem rgba(59, 130, 246, 0.2);
  background: #0b1224;
  color: #fff;
}

.table {
  --bs-table-bg: transparent;
  --bs-table-color: var(--text);
  --bs-table-border-color: var(--line);
  --bs-table-striped-bg: rgba(255,255,255,0.02);
}
.form-control, .form-select, .form-check-input {
  background: #0b1224;
  color: var(--text);
  border-color: #29406d;
  border-radius: 10px;
}
.form-control::placeholder,
.form-control::-webkit-input-placeholder,
.form-select::placeholder {
  color: #e8eaef;
  opacity: 0.72;
}
.form-control:focus, .form-select:focus {
  background: #0b1224;
  color: #fff;
  border-color: var(--accent);
  box-shadow: 0 0 0 0.2rem rgba(255, 208, 47, 0.18);
}
.form-control:focus::placeholder,
.form-control:focus::-webkit-input-placeholder {
  color: #f3f4f7;
  opacity: 0.55;
}
.form-label, .form-text, .muted { color: var(--muted); }
.form-text { color: var(--muted) !important; }

/* Number fields — drop the OS white spinner; keep typing + ↑/↓ keys. */
.form-control[type="number"] {
  appearance: textfield;
  -moz-appearance: textfield;
}
.form-control[type="number"]::-webkit-outer-spin-button,
.form-control[type="number"]::-webkit-inner-spin-button {
  appearance: none;
  -webkit-appearance: none;
  margin: 0;
  display: none;
}

/* Native file picker — match dark theme (replaces OS white “Choose File”). */
input[type="file"].form-control,
input[type="file"].form-control-sm {
  padding: 0.4rem 0.55rem;
  color: var(--muted);
  cursor: pointer;
  line-height: 1.35;
}
input[type="file"].form-control::file-selector-button,
input[type="file"].form-control-sm::file-selector-button {
  margin-right: 0.85rem;
  padding: 0.4rem 0.9rem;
  border: 1px solid var(--sb-yellow-border);
  border-radius: 8px;
  background: linear-gradient(180deg, #ffe06a 0%, var(--sb-yellow) 100%);
  color: #14151c;
  font-weight: 700;
  font-size: 0.85rem;
  cursor: pointer;
  transition: background 0.15s ease, box-shadow 0.15s ease;
}
input[type="file"].form-control::file-selector-button:hover,
input[type="file"].form-control-sm::file-selector-button:hover {
  background: linear-gradient(180deg, #ffe98a 0%, var(--sb-yellow-hover) 100%);
}
input[type="file"].form-control:hover,
input[type="file"].form-control-sm:hover {
  border-color: var(--sb-yellow-border);
}

/* Custom file row used on profile / compose when we wrap the input. */
.sb-file {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.65rem 0.85rem;
  padding: 0.7rem 0.85rem;
  border: 1px dashed rgba(255, 208, 47, 0.28);
  border-radius: 12px;
  background: rgba(255, 208, 47, 0.04);
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease;
}
.sb-file:hover,
.sb-file:focus-within {
  border-color: rgba(255, 208, 47, 0.55);
  background: rgba(255, 208, 47, 0.07);
}
.sb-file-input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}
.sb-file-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.45rem 0.95rem;
  border-radius: 8px;
  background: linear-gradient(180deg, #ffe06a 0%, var(--sb-yellow) 100%);
  color: #14151c;
  font-weight: 750;
  font-size: 0.86rem;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.25) inset;
  flex: 0 0 auto;
}
.sb-file-name {
  color: var(--muted);
  font-size: 0.86rem;
  min-width: 0;
  flex: 1 1 8rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.sb-file-name.has-file {
  color: var(--text-strong);
}

.badge-risk { font-family: "IBM Plex Mono", monospace; letter-spacing: 0.04em; }

.donate-sb {
  max-width: 44rem;
  margin: 1.5rem auto 3rem;
  padding: 0 0.75rem;
  text-align: center;
}
.donate-sb-title {
  margin: 0 0 1.5rem;
  font-size: clamp(2rem, 5vw, 2.75rem);
  font-weight: 700;
  letter-spacing: 0.04em;
  color: #f8fafc;
}
.donate-sb-card {
  background: #16171d;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 14px;
  padding: 1.75rem 1.35rem 1.5rem;
}
.donate-sb-lead {
  margin: 0 auto 1.5rem;
  max-width: 28rem;
  color: #c5cad6;
  font-size: 1rem;
  line-height: 1.65;
}
.sb-recharge-pay .donate-sb-qrs {
  grid-template-columns: minmax(0, 14rem);
  justify-items: start;
  max-width: 14rem;
  margin-left: 0;
}
.donate-sb-qrs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem 1.25rem;
  justify-items: center;
  margin: 0 auto 1.35rem;
  max-width: 48rem;
}
@media (max-width: 720px) {
  .donate-sb-qrs { grid-template-columns: 1fr; }
}
.donate-sb-qr {
  margin: 0;
  width: 100%;
  max-width: 14rem;
}
.donate-sb-qr img,
.donate-sb-qr-ph {
  display: block;
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 10px;
  background: #0c0d12;
  border: 1px solid rgba(255, 255, 255, 0.06);
}
.donate-sb-qr-ph {
  display: grid;
  place-items: center;
  color: #64748b;
  font-size: 0.85rem;
  padding: 1rem;
}
.donate-sb-qr figcaption {
  margin-top: 0.65rem;
  font-size: 0.95rem;
  color: #e2e8f0;
  font-weight: 600;
}
.donate-sb-thanks {
  margin: 0;
  color: #8b93a7;
  font-size: 0.92rem;
}
.donate-sb-more {
  margin-top: 1.25rem;
  text-align: left;
  background: #12131a;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 10px;
  padding: 0.75rem 1rem;
}
.donate-sb-more summary {
  cursor: pointer;
  color: #cbd5e1;
  font-weight: 600;
}
.donate-sb-more-body { margin-top: 0.85rem; }
.donate-presets {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.55rem;
}
.donate-preset {
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: #0e1118;
  color: var(--text);
  border-radius: 6px;
  padding: 0.75rem 0.7rem;
  font-weight: 600;
  transition: border-color 0.15s ease, background 0.15s ease, color 0.15s ease;
}
.donate-preset:hover {
  border-color: rgba(245, 197, 66, 0.45);
}
.donate-preset.is-active {
  border-color: var(--sb-yellow);
  background: var(--sb-yellow);
  color: #111;
  box-shadow: none;
}
.donate-sb-amount .input-group-text {
  background: #0e1118;
  border-color: rgba(255, 255, 255, 0.1);
  color: var(--muted);
}

.intel-source-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.intel-source-item {
  padding: 0.55rem 0;
  border-bottom: 1px solid var(--line);
}
.intel-source-item:last-child { border-bottom: 0; }
.risk-LOW { background: rgba(34, 197, 94, 0.15); color: #86efac; }
.risk-MEDIUM { background: rgba(245, 158, 11, 0.15); color: #fcd34d; }
.risk-HIGH { background: rgba(249, 115, 22, 0.16); color: #fdba74; }
.risk-CRITICAL { background: rgba(239, 68, 68, 0.16); color: #fca5a5; }
.risk-UNKNOWN { background: rgba(148, 163, 184, 0.16); color: #cbd5e1; }

.empty {
  border: 1px dashed var(--line);
  border-radius: 12px;
  padding: 1.4rem;
  color: var(--muted);
  text-align: center;
}

.site-footer {
  border-top: 1px solid var(--line-soft);
  background: #0a0b10;
  color: var(--text);
  margin-top: 2rem;
}
.site-footer a {
  color: #94a3b8;
  text-decoration: none;
}
.site-footer a:hover { color: var(--sb-yellow); }
.sb-footer-main {
  display: grid;
  gap: 1.75rem;
  padding-top: 2rem;
  padding-bottom: 1.75rem;
}
@media (min-width: 992px) {
  .sb-footer-main {
    grid-template-columns: minmax(14rem, 1.35fr) minmax(0, 3fr);
    gap: 2.5rem;
    align-items: start;
  }
}
.sb-footer-brand { min-width: 0; }
.sb-footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  text-decoration: none;
  margin-bottom: 0.75rem;
  color: #fff;
}
.sb-footer-logo:hover { color: #fff; }
.sb-footer-blurb {
  margin: 0;
  max-width: 22rem;
  color: #8b93a7;
  font-size: 0.82rem;
  line-height: 1.55;
}
.sb-footer-cols {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.25rem 1.5rem;
}
@media (min-width: 768px) {
  .sb-footer-cols {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
@media (min-width: 1100px) {
  .sb-footer-cols {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 1rem 1.75rem;
  }
}
.sb-footer-col-title {
  margin: 0 0 0.7rem;
  font-size: 0.92rem;
  font-weight: 700;
  color: #f1f5f9;
}
.sb-footer-col ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.42rem;
}
.sb-footer-col a,
.sb-footer-text-btn {
  font-size: 0.82rem;
  color: #94a3b8;
  line-height: 1.35;
}
.sb-footer-text-btn {
  appearance: none;
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
  text-align: left;
}
.sb-footer-text-btn:hover { color: var(--sb-yellow); }
.sb-footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}
.sb-footer-bottom-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.5rem 1rem;
  padding-top: 0.85rem;
  padding-bottom: 0.95rem;
  color: #64748b;
  font-size: 0.75rem;
}
.sb-footer-hash { opacity: 0.55; font-family: "IBM Plex Mono", monospace; }
.disclaimer {
  border-left: 3px solid var(--accent);
  padding-left: 0.85rem;
  color: var(--muted);
  font-size: 0.92rem;
}
.alert { border: 0; }
.sb-flash-stack {
  display: grid;
  gap: 0.55rem;
  margin-bottom: 0.85rem;
}
.sb-flash.alert {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  margin: 0;
  padding: 0.65rem 0.85rem;
  border-radius: 8px;
  border: 1px solid rgba(255, 208, 47, 0.22);
  background: linear-gradient(180deg, #242014 0%, #1a1812 100%);
  color: #f3e6b5;
  font-size: 0.9rem;
  line-height: 1.45;
  box-shadow: inset 0 1px 0 rgba(255, 208, 47, 0.06);
}
.sb-flash-dot {
  flex: 0 0 auto;
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 999px;
  background: linear-gradient(90deg, #f5c518 0%, #7af0a0 100%);
  box-shadow: 0 0 8px rgba(122, 240, 160, 0.35);
}
.sb-flash-text { flex: 1 1 auto; min-width: 0; }
.sb-flash-close {
  flex: 0 0 auto;
  width: 1.6rem;
  height: 1.6rem;
  border: 1px solid rgba(255, 208, 47, 0.28);
  border-radius: 4px;
  background: rgba(0, 0, 0, 0.28);
  color: #ffe9b8;
  font-size: 1.1rem;
  line-height: 1;
  padding: 0;
  cursor: pointer;
}
.sb-flash-close:hover {
  background: var(--sb-yellow);
  color: #14151c;
  border-color: var(--sb-yellow);
}
.alert.sb-flash-success {
  border-color: rgba(122, 240, 160, 0.28);
  background: linear-gradient(180deg, #1c2418 0%, #151a14 100%);
  color: #e8f6d8;
}
.alert.sb-flash-success .sb-flash-dot {
  background: linear-gradient(90deg, #7af0a0 0%, #f5c518 100%);
}
.alert.sb-flash-danger,
.alert.sb-flash-error {
  border-color: rgba(255, 120, 110, 0.35);
  background: linear-gradient(180deg, #2a1716 0%, #1a1212 100%);
  color: #ffd4cf;
}
.alert.sb-flash-danger .sb-flash-dot,
.alert.sb-flash-error .sb-flash-dot {
  background: linear-gradient(90deg, #ff7a6e 0%, #f5c518 100%);
  box-shadow: 0 0 8px rgba(255, 122, 110, 0.35);
}
.alert.sb-flash-warning {
  border-color: rgba(255, 208, 47, 0.4);
  background: linear-gradient(180deg, #2a2314 0%, #1a1810 100%);
  color: #fff0c2;
}
.alert.sb-flash-info {
  border-color: rgba(120, 180, 255, 0.28);
  background: linear-gradient(180deg, #161c28 0%, #12161e 100%);
  color: #dce8ff;
}
.alert.sb-flash-info .sb-flash-dot {
  background: linear-gradient(90deg, #78b4ff 0%, #f5c518 100%);
  box-shadow: 0 0 8px rgba(120, 180, 255, 0.35);
}
.sb-flash-rich {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
}
.sb-flash-chip {
  display: inline-flex;
  align-items: center;
  padding: 0.18rem 0.55rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 208, 47, 0.22);
  background: rgba(0, 0, 0, 0.28);
  color: #ffe9b8;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  white-space: nowrap;
}
.sb-flash-chip.is-title {
  border-color: rgba(122, 240, 160, 0.4);
  background: linear-gradient(90deg, rgba(122, 240, 160, 0.18), rgba(245, 197, 24, 0.14));
  color: #f6ffd8;
  font-weight: 750;
}
.sb-flash-chip.is-total {
  border-color: rgba(255, 208, 47, 0.45);
  color: var(--sb-yellow, #ffd02f);
}
.sb-flash-chip.is-streak {
  border-color: rgba(255, 180, 80, 0.35);
  color: #ffd9a0;
}
.sb-flash-chip.is-crit {
  border-color: rgba(255, 120, 110, 0.45);
  background: rgba(255, 80, 70, 0.14);
  color: #ffc4be;
}
.sb-flash-chip.is-mission {
  border-color: rgba(122, 240, 160, 0.4);
  color: #b8f5c8;
}
.sb-flash.is-checkin {
  padding-top: 0.72rem;
  padding-bottom: 0.72rem;
}
.list-group-item {
  background: transparent;
  color: var(--text);
  border-color: var(--line);
}
a {
  color: var(--sb-yellow);
  text-decoration: none;
}
a:hover {
  color: var(--sb-yellow-hover);
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

code, .mono { font-family: "IBM Plex Mono", monospace; }

.topic-board .topic-title {
  font-size: 1.05rem;
  font-weight: 600;
  text-decoration: none;
}
.topic-board .topic-title:hover { text-decoration: underline; }
.topic-row:last-child { border-bottom: 0 !important; }
details summary { cursor: pointer; }

.global-back-btn {
  white-space: nowrap;
  min-width: 4.5rem;
}

/* sb.sb-like compact forum chrome */
.sb-header {
  background: #0a0b10;
  border-bottom: 0;
  box-shadow: none;
}
.sb-topbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem 0.85rem;
  min-height: 3rem;
  padding-top: 0.4rem;
  padding-bottom: 0.4rem;
}
.sb-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  flex: 0 0 auto;
  text-decoration: none;
  color: #fff;
}
.sb-logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.85rem;
  height: 1.85rem;
  border-radius: 4px;
  background: var(--sb-yellow);
  color: #14151c;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  box-shadow: 0 0 0 1px rgba(255, 208, 47, 0.25);
}
.sb-brand-img {
  display: block;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 50%;
  object-fit: cover;
  flex: 0 0 auto;
  background: transparent;
}
.sb-footer-logo .sb-brand-img {
  width: 2.5rem;
  height: 2.5rem;
}
.sb-brand-text {
  font-weight: 700;
  letter-spacing: 0.02em;
  font-size: 0.98rem;
  color: var(--text-strong);
}
.sb-top-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
  flex: 1 1 auto;
  justify-content: flex-end;
}
.sb-cat-nav {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 0.15rem 0.55rem;
  flex: 0 1 auto;
  min-width: 0;
  max-width: 100%;
  overflow-x: auto;
  scrollbar-width: none;
}
.sb-cat-nav::-webkit-scrollbar { display: none; }
.sb-cat-nav-inline {
  margin-left: 0.15rem;
  padding-left: 0.45rem;
  border-left: 0;
}
.sb-cat-nav-link {
  flex: 0 0 auto;
  color: var(--text-subtle);
  text-decoration: none !important;
  font-size: 0.82rem;
  line-height: 1.2;
  padding: 0.28rem 0.15rem;
  border-radius: 0;
  border: 0;
  background: transparent;
  white-space: nowrap;
  transition: color 0.12s ease;
  box-shadow: none;
}
@media (max-width: 720px) {
  .sb-cat-nav-inline {
    order: 3;
    flex: 1 1 100%;
    margin-left: 0;
    padding-left: 0;
    border-left: 0;
    padding-top: 0.15rem;
  }
}
.sb-cat-nav-link:hover,
.sb-cat-nav-link:focus-visible {
  color: var(--sb-yellow);
  background: transparent;
  text-decoration: none !important;
  box-shadow: none;
}
.sb-cat-nav-link.is-active {
  color: var(--sb-yellow);
  font-weight: 700;
  background: transparent;
  box-shadow: none;
  text-decoration: none !important;
}
.sb-nav-search-field {
  position: relative;
  display: block;
  margin: 0;
}
.sb-nav-search-icon {
  position: absolute;
  left: 0.55rem;
  top: 50%;
  transform: translateY(-50%);
  color: #8b95a8;
  pointer-events: none;
}
.sb-nav-search .form-control {
  width: 9rem;
  padding-left: 1.7rem;
  background: var(--panel-alt);
  border-color: var(--line);
  color: #fff;
  font-size: 0.82rem;
  border-radius: 6px;
}
.sb-nav-search .form-control:focus {
  border-color: var(--sb-yellow);
  box-shadow: 0 0 0 3px rgb(255 208 47 / 0.12);
}
.sb-nav-search-field:focus-within .sb-nav-search-icon {
  color: var(--sb-yellow);
}
.sb-icon-link,
.sb-user-link {
  color: #c9d2e3;
  text-decoration: none !important;
  font-size: 0.82rem;
  white-space: nowrap;
}
.sb-icon-link:hover,
.sb-user-link:hover {
  color: #fff;
  text-decoration: none !important;
}
.sb-user-link {
  max-width: 7.5rem;
  overflow: hidden;
  text-overflow: ellipsis;
}
a.btn.sb-user-link {
  color: #c9d2e3;
  text-decoration: none !important;
}
.sb-icon-link.has-unread { color: var(--sb-yellow); }
.sb-nav-box {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  min-height: 1.85rem;
  border: 1px solid var(--line) !important;
  background: transparent;
  text-decoration: none !important;
}
.sb-nav-box:hover,
.sb-nav-box:focus-visible {
  text-decoration: none !important;
}
.sb-nav-box.is-admin,
.sb-nav-box.is-mod {
  color: var(--sb-yellow);
  border-color: rgba(255, 208, 47, 0.55) !important;
}
.sb-nav-box.is-admin:hover,
.sb-nav-box.is-mod:hover {
  color: var(--sb-yellow-hover);
  border-color: var(--sb-yellow) !important;
  background: var(--sb-yellow-soft);
  text-decoration: none !important;
}
.btn-ghost.sb-nav-box.has-unread {
  color: var(--sb-yellow);
  border-color: rgba(255, 208, 47, 0.55) !important;
}
.sb-top-actions a.btn,
.sb-top-actions a.btn:hover,
.sb-top-actions a.btn:focus-visible,
.lang-switch a,
.lang-switch a:hover {
  text-decoration: none !important;
}

.sb-sort-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.15rem 1rem;
  align-items: center;
  margin-bottom: 0.55rem;
  padding: 0.1rem 0 0.35rem;
  border-bottom: 0;
}
.sb-sort {
  color: var(--muted);
  text-decoration: none !important;
  font-size: 0.88rem;
  padding: 0.2rem 0;
  box-shadow: none;
}
.sb-sort:hover,
.sb-sort:focus-visible {
  color: #fff;
  text-decoration: none !important;
  box-shadow: none;
}
.sb-sort.active {
  color: var(--sb-yellow);
  font-weight: 700;
  box-shadow: none;
  text-decoration: none !important;
}

.sb-forum,
.sb-layout {
  width: 100%;
  max-width: 100%;
  min-width: 0;
}
.sb-layout {
  display: grid;
  gap: 0.85rem;
  align-items: start;
}
@media (min-width: 992px) {
  .sb-layout {
    grid-template-columns: minmax(0, 1fr) minmax(0, 18rem);
    gap: 0.85rem;
  }
}
.sb-main,
.sb-side {
  min-width: 0;
  max-width: 100%;
  overflow-wrap: anywhere;
}
.sb-panel {
  background: var(--panel);
  border: 0;
  border-radius: 10px;
  padding: 0.8rem 0.9rem;
}
.sb-topic-list {
  padding: 0;
  overflow: hidden;
  min-height: 0;
  background: rgba(255, 255, 255, 0.03);
}
.sb-empty {
  padding: 1rem 1.1rem !important;
  text-align: left !important;
  min-height: 0 !important;
}
.sb-topic-row {
  display: grid;
  grid-template-columns: 2.75rem minmax(0, 1fr);
  gap: 0.45rem 0.65rem;
  padding: 0.65rem 0.85rem;
  border-bottom: 0;
  align-items: start;
  min-width: 0;
}
.sb-topic-row + .sb-topic-row {
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}
.sb-topic-row:hover { background: rgba(255, 255, 255, 0.035); }
@media (min-width: 768px) {
  .sb-topic-row {
    grid-template-columns: 2.75rem minmax(0, 1fr) 5.5rem;
  }
}
.sb-topic-avatar {
  width: 2rem;
  height: 2rem;
  border-radius: 4px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.78rem;
  font-weight: 700;
  color: #fff;
  background: var(--avatar-fallback);
  border: 1px solid rgba(255, 255, 255, 0.1);
}
.sb-topic-avatar.is-guest {
  background: var(--panel-alt);
  color: var(--muted);
}
.sb-topic-title-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.25rem 0.35rem;
  min-width: 0;
  max-width: 100%;
}
.sb-topic-main {
  min-width: 0;
  max-width: 100%;
}
.sb-topic-title {
  color: #f3f6fb;
  font-weight: 600;
  text-decoration: none !important;
  line-height: 1.35;
  font-size: 0.94rem;
  overflow-wrap: anywhere;
  word-break: break-word;
  min-width: 0;
  max-width: 100%;
  display: inline-block;
}
.sb-badge.is-tag,
.sb-board-chip,
.sb-format-chip {
  max-width: 100%;
  overflow-wrap: anywhere;
  word-break: break-word;
}
.sb-topic-title:hover,
.sb-topic-title:focus-visible {
  color: var(--sb-yellow);
  text-decoration: none !important;
}
.sb-badge {
  display: inline-block;
  padding: 0.05rem 0.35rem;
  border-radius: 3px;
  font-size: 0.66rem;
  font-weight: 700;
  background: var(--sb-yellow);
  color: #14151c;
}
.sb-badge.is-tag { background: var(--sb-yellow-soft); color: var(--sb-yellow-hover); border: 1px solid var(--sb-yellow-border); }
.sb-badge.is-promo {
  background: rgba(255, 140, 66, 0.18);
  color: #ff9a4d;
  border: 1px solid rgba(255, 140, 66, 0.45);
  font-weight: 600;
  letter-spacing: 0.02em;
}
.sb-topic-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.15rem 0.5rem;
  margin-top: 0.12rem;
  align-items: center;
  color: var(--muted);
  font-size: 0.75rem;
}
.sb-meta-user { color: #f9a8d4; }
.sb-cat-link {
  color: #7dd3fc;
  text-decoration: none;
}
.sb-cat-link:hover { text-decoration: underline; }
.sb-meta-stat { color: var(--muted); }
.sb-meta-time { color: #64748b; }
@media (min-width: 768px) {
  .sb-topic-row {
    grid-template-columns: 2.75rem minmax(0, 1fr);
  }
}
.sb-pager { padding: 0.55rem 0.8rem; }
.sb-side {
  display: grid;
  gap: 0.7rem;
  align-content: start;
}
.sb-side-title {
  font-size: 0.84rem;
  font-weight: 650;
  margin: 0 0 0.55rem;
}
.sb-user-card-row {
  display: flex;
  gap: 0.65rem;
  align-items: center;
}
.sb-user-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.7rem;
}
/* Full-page leaderboards (/leaderboard) */
.sb-rank-page { padding: 1.1rem 1.15rem 1.25rem; }
.sb-rank-head { margin-bottom: 0.85rem; }
.sb-rank-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-bottom: 0.9rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.sb-rank-tabs a {
  display: inline-flex;
  align-items: center;
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 650;
  text-decoration: none;
}
.sb-rank-tabs a:hover {
  color: #fff;
  border-color: var(--sb-yellow-border);
  text-decoration: none;
}
.sb-rank-tabs a.is-active {
  color: #14151c;
  background: linear-gradient(180deg, #ffe06a 0%, var(--sb-yellow) 100%);
  border-color: transparent;
  font-weight: 750;
}
.sb-rank-mine {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem 0.75rem;
  margin-bottom: 0.85rem;
  padding: 0.65rem 0.8rem;
  border-radius: 10px;
  background: rgba(255, 208, 47, 0.07);
  border: 1px solid rgba(255, 208, 47, 0.22);
  font-size: 0.9rem;
}
.sb-rank-mine-label { color: var(--muted); }
.sb-rank-pos {
  color: var(--sb-yellow);
  font-family: "IBM Plex Mono", monospace;
  font-size: 1.05rem;
}
.sb-leader-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.4rem;
}
.sb-leader-row {
  display: grid;
  grid-template-columns: 2.1rem minmax(0, 1fr) auto;
  gap: 0.55rem 0.65rem;
  align-items: center;
  padding: 0.55rem 0.65rem;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.05);
}
.sb-leader-row.is-self {
  border-color: rgba(255, 208, 47, 0.35);
  background: rgba(255, 208, 47, 0.06);
}
.sb-leader-row.is-top1 { box-shadow: inset 3px 0 0 #ffd02f; }
.sb-leader-row.is-top2 { box-shadow: inset 3px 0 0 #c0c7d4; }
.sb-leader-row.is-top3 { box-shadow: inset 3px 0 0 #c47a3a; }
.sb-leader-pos {
  font-family: "IBM Plex Mono", monospace;
  font-weight: 750;
  color: var(--sb-yellow);
  text-align: center;
  font-size: 0.95rem;
}
.sb-leader-user {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  min-width: 0;
  color: inherit;
  text-decoration: none;
}
.sb-leader-user:hover { color: inherit; text-decoration: none; }
.sb-leader-user:hover .sb-name { color: var(--sb-yellow); }
.sb-leader-meta {
  display: grid;
  gap: 0.12rem;
  min-width: 0;
}
.sb-leader-sub { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sb-leader-score {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 0.35rem 0.5rem;
  text-align: right;
}
.sb-leader-num {
  font-weight: 750;
  color: var(--text-strong);
  font-size: 0.95rem;
}
.sb-leader-num.is-niu { color: var(--sb-yellow); }
.sb-leader-unit {
  color: var(--muted);
  font-size: 0.78rem;
}
.sb-leader-fiat {
  display: block;
  width: 100%;
  font-variant-numeric: tabular-nums;
  line-height: 1.25;
}
.sb-rank-mine-val .sb-leader-fiat {
  display: inline;
  margin-left: 0.35rem;
}
@media (max-width: 575px) {
  .sb-leader-row {
    grid-template-columns: 1.6rem minmax(0, 1fr);
  }
  .sb-leader-score {
    grid-column: 2;
    justify-content: flex-start;
  }
}
.sb-rank-pager {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  margin-top: 1rem;
  padding-top: 0.85rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}
.sb-rank-page-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2rem;
  height: 2rem;
  padding: 0 0.55rem;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 650;
  font-variant-numeric: tabular-nums;
  text-decoration: none;
}
.sb-rank-page-btn:hover {
  color: #fff;
  border-color: var(--sb-yellow-border);
  text-decoration: none;
}
.sb-rank-page-btn.is-current {
  color: #14151c;
  background: linear-gradient(180deg, #ffe06a 0%, var(--sb-yellow) 100%);
  border-color: transparent;
  font-weight: 750;
}
.sb-rank-page-gap {
  color: var(--muted);
  padding: 0 0.15rem;
  font-size: 0.86rem;
}

.sb-rank-list {
  list-style: none;
  padding: 0;
  margin: 0;
  counter-reset: hot;
}
.sb-rank-list li {
  display: flex;
  gap: 0.45rem;
  align-items: baseline;
  padding: 0.28rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  counter-increment: hot;
}
.sb-rank-list li::before {
  content: counter(hot);
  flex: 0 0 1rem;
  color: var(--sb-yellow);
  font-size: 0.75rem;
  font-weight: 700;
  font-family: "IBM Plex Mono", monospace;
}
.sb-rank-list li:last-child { border-bottom: 0; }
.sb-rank-list a {
  color: var(--text);
  text-decoration: none;
  flex: 1;
  min-width: 0;
  font-size: 0.84rem;
  overflow-wrap: anywhere;
  word-break: break-word;
}
.sb-rank-list a:hover { color: var(--sb-yellow); }
.sb-nav-toggle {
  display: none;
  align-items: center;
  gap: 0.4rem;
  margin-left: auto;
  min-height: 2rem;
  padding-inline: 0.55rem;
  border-color: var(--line);
}
.sb-nav-toggle-bars {
  position: relative;
  display: block;
  width: 1.05rem;
  height: 0.12rem;
  border-radius: 2px;
  background: currentColor;
  box-shadow: 0 0.28rem 0 currentColor, 0 -0.28rem 0 currentColor;
}
.sb-nav-toggle-label {
  font-size: 0.78rem;
  font-weight: 650;
}
body.sb-nav-open .sb-nav-toggle-bars {
  height: 0;
  box-shadow: none;
  background: transparent;
}
body.sb-nav-open .sb-nav-toggle-bars::before,
body.sb-nav-open .sb-nav-toggle-bars::after {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  width: 1.05rem;
  height: 0.12rem;
  border-radius: 2px;
  background: currentColor;
}
body.sb-nav-open .sb-nav-toggle-bars::before { transform: rotate(45deg); }
body.sb-nav-open .sb-nav-toggle-bars::after { transform: rotate(-45deg); }
.sb-side-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.sb-side-list li {
  padding: 0.32rem 0;
  border-bottom: 1px solid rgba(148, 163, 184, 0.08);
}
.sb-side-list li:last-child { border-bottom: 0; }
.sb-side-list a {
  color: var(--text);
  text-decoration: none;
  font-size: 0.86rem;
  overflow-wrap: anywhere;
  word-break: break-word;
}
.sb-side-list a:hover { color: #93c5fd; }
.forum-search-results {
  list-style: none;
  padding: 0;
  margin: 0;
}
.forum-search-results li {
  padding: 0.55rem 0;
  border-bottom: 1px solid var(--line);
}
.forum-search-results li:last-child { border-bottom: 0; }

.forum-compose {
  max-width: 52rem;
}
.sb-compose-layout {
  align-items: start;
}
.sb-compose-layout .sb-main {
  min-width: 0;
}
.sb-compose-panel {
  padding: 1rem 1.1rem 1.25rem;
}
.sb-compose-heading {
  margin: 0 0 1rem;
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text-strong);
}
.sb-compose-side-card .sb-topic-avatar {
  width: 2.6rem;
  height: 2.6rem;
  font-size: 0.95rem;
}
.sb-topic-avatar-img {
  object-fit: cover;
  padding: 0;
}
.sb-compose-side-level {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
  margin-top: 0.15rem;
}
.composer-tool.is-disabled,
.composer-tool:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
.sb-compose-field {
  display: grid;
  gap: 0.35rem;
  margin-bottom: 1rem;
}
.sb-compose-boards {
  border: 0;
  padding: 0;
  margin: 0 0 1rem;
  min-width: 0;
}
.sb-compose-boards legend {
  float: none;
  width: auto;
  padding: 0;
  margin-bottom: 0.15rem;
}
.sb-board-picks {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.55rem;
}
@media (max-width: 720px) {
  .sb-board-picks { grid-template-columns: 1fr; }
}
.sb-board-pick {
  display: grid;
  gap: 0.3rem;
  align-content: start;
  padding: 0.7rem 0.7rem;
  border: 1px solid var(--line-soft);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.02);
  cursor: pointer;
  min-width: 0;
  position: relative;
}
.sb-board-pick input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}
.sb-board-pick:hover {
  border-color: rgba(255, 255, 255, 0.22);
}
.sb-board-pick.is-active,
.sb-board-pick:has(input:checked) {
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}
.sb-board-pick.is-scams.is-active,
.sb-board-pick.is-scams:has(input:checked) {
  border-color: rgba(248, 113, 113, 0.65);
  background: rgba(248, 113, 113, 0.1);
}
.sb-board-pick.is-tech-sharing.is-active,
.sb-board-pick.is-tech-sharing:has(input:checked) {
  border-color: rgba(56, 189, 248, 0.65);
  background: rgba(56, 189, 248, 0.1);
}
.sb-board-pick.is-casual-sharing.is-active,
.sb-board-pick.is-casual-sharing:has(input:checked) {
  border-color: rgba(52, 211, 153, 0.65);
  background: rgba(52, 211, 153, 0.1);
}
.sb-board-pick.is-investing.is-active,
.sb-board-pick.is-investing:has(input:checked) {
  border-color: rgba(251, 191, 36, 0.7);
  background: rgba(251, 191, 36, 0.12);
}
.sb-board-pick.is-jobs.is-active,
.sb-board-pick.is-jobs:has(input:checked) {
  border-color: rgba(167, 139, 250, 0.7);
  background: rgba(167, 139, 250, 0.12);
}
.sb-board-pick.is-games.is-active,
.sb-board-pick.is-games:has(input:checked) {
  border-color: rgba(244, 114, 182, 0.7);
  background: rgba(244, 114, 182, 0.12);
}
.sb-board-pick-name {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--text-strong);
}
.sb-board-pick-desc {
  font-size: 0.74rem;
  line-height: 1.4;
  color: var(--muted);
}
.sb-compose-format-panels:empty { display: none; }
.sb-board-chip {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  padding: 0.12rem 0.42rem;
  border-radius: 3px;
  font-size: 0.72rem;
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none;
  border: 1px solid transparent;
  white-space: nowrap;
}
.sb-board-chip.is-scams {
  color: #fecaca;
  background: rgba(248, 113, 113, 0.16);
  border-color: rgba(248, 113, 113, 0.35);
}
.sb-board-chip.is-tech-sharing {
  color: #bae6fd;
  background: rgba(56, 189, 248, 0.14);
  border-color: rgba(56, 189, 248, 0.35);
}
.sb-board-chip.is-casual-sharing {
  color: #a7f3d0;
  background: rgba(52, 211, 153, 0.14);
  border-color: rgba(52, 211, 153, 0.35);
}
.sb-board-chip.is-investing {
  color: #fde68a;
  background: rgba(251, 191, 36, 0.16);
  border-color: rgba(251, 191, 36, 0.4);
}
.sb-board-chip.is-jobs {
  color: #ddd6fe;
  background: rgba(167, 139, 250, 0.16);
  border-color: rgba(167, 139, 250, 0.4);
}
.sb-board-chip.is-games {
  color: #fbcfe8;
  background: rgba(244, 114, 182, 0.16);
  border-color: rgba(244, 114, 182, 0.4);
}
.sb-board-chip:hover { filter: brightness(1.08); }
.sb-format-chip {
  display: inline-flex;
  align-items: center;
  padding: 0.1rem 0.38rem;
  border-radius: 3px;
  font-size: 0.68rem;
  font-weight: 650;
  color: #fde68a;
  background: rgba(255, 208, 47, 0.1);
  border: 1px solid rgba(255, 208, 47, 0.28);
  white-space: nowrap;
}
.sb-thread-boards {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-bottom: 0.45rem;
}
.sb-compose-label {
  font-size: 0.92rem;
  font-weight: 650;
  color: var(--text-strong);
}
.sb-compose-hint {
  font-size: 0.78rem;
  color: var(--muted);
  line-height: 1.4;
}
.sb-compose-howto-list {
  margin: 0;
  padding-left: 1.1rem;
  display: grid;
  gap: 0.2rem;
}
.sb-compose-howto-list li {
  margin: 0;
}
.sb-compose-label-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.45rem 0.75rem;
}
.composer-bar {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
}
.composer-tool,
.composer-attach-label {
  appearance: none;
  border: 1px solid var(--line-soft);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-subtle);
  font-size: 0.76rem;
  line-height: 1;
  padding: 0.38rem 0.55rem;
  border-radius: 4px;
  cursor: pointer;
  margin: 0;
}
.composer-tool:hover,
.composer-attach-label:hover {
  color: var(--sb-yellow);
  border-color: rgba(255, 208, 47, 0.35);
}
.composer-attach-label.is-accent {
  color: #14151c;
  background: var(--sb-yellow);
  border-color: var(--sb-yellow);
  font-weight: 700;
}
.composer-attach-label.is-accent:hover {
  color: #14151c;
  filter: brightness(1.05);
}
.composer-attach-wrap { margin-top: 0.55rem; }
.composer-file-input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}
.composer-attach-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem 0.65rem;
  margin-top: 0.35rem;
}
.composer-attach-clear {
  appearance: none;
  border: 0;
  background: transparent;
  color: #fca5a5;
  font-size: 0.76rem;
  padding: 0;
  cursor: pointer;
  text-decoration: underline;
}
.composer-attach-clear:hover { color: #fecaca; }
.composer-emoji-pop {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
  margin: 0.35rem 0 0.55rem;
  padding: 0.45rem;
  border: 1px solid var(--line-soft);
  border-radius: 6px;
  background: #0f1218;
}
.composer-emoji-btn {
  appearance: none;
  border: 0;
  background: transparent;
  font-size: 1.15rem;
  line-height: 1;
  padding: 0.2rem;
  cursor: pointer;
  border-radius: 4px;
}
.composer-emoji-btn:hover { background: rgba(255, 255, 255, 0.06); }
.sb-compose-type-panel {
  margin: 0 0 1rem;
  padding: 0.85rem 0.9rem;
  border: 1px solid var(--line-soft);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.02);
}
.sb-compose-check {
  display: flex;
  gap: 0.55rem;
  align-items: flex-start;
  margin-bottom: 0.85rem;
  font-size: 0.86rem;
}
.sb-compose-check input { margin-top: 0.2rem; }
.sb-prize-list { display: grid; gap: 0.55rem; }
.sb-prize-row {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) 5.5rem minmax(0, 1.6fr);
  gap: 0.45rem;
}
.sb-prize-row-niu {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto;
  align-items: end;
}
.sb-prize-cell {
  display: grid;
  gap: 0.25rem;
  margin: 0;
}
.sb-prize-remove {
  align-self: end;
  white-space: nowrap;
}
@media (max-width: 720px) {
  .sb-prize-row,
  .sb-prize-row-niu { grid-template-columns: 1fr; }
  .sb-prize-remove { justify-self: start; }
}
.sb-compose-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.35rem;
}
.forum-crumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
  margin-bottom: 0.75rem;
  font-size: 0.86rem;
  color: var(--muted);
}
.forum-crumb a { text-decoration: none; color: var(--muted); }
.forum-crumb a:hover { color: #fff; text-decoration: underline; }
.forum-crumb-sep { opacity: 0.45; }
.forum-crumb-current { color: var(--text); }

/* sb.sb-style thread floors */
.sb-thread { width: 100%; }
.sb-thread-layout {
  display: grid;
  gap: 0.85rem;
  align-items: start;
}
@media (min-width: 1100px) {
  .sb-thread-layout {
    grid-template-columns: minmax(0, 1fr) 16.5rem;
  }
}
.sb-thread-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.5rem 1rem;
  margin-bottom: 0.75rem;
}
.sb-thread-title {
  margin: 0;
  font-size: clamp(1.15rem, 2.2vw, 1.45rem);
  font-weight: 650;
  line-height: 1.35;
  max-width: 52rem;
}
.sb-thread-stats {
  display: flex;
  gap: 0.85rem;
  white-space: nowrap;
  padding-top: 0.25rem;
}
.sb-floors {
  display: grid;
  gap: 0;
  background: transparent;
  border: 1px solid var(--sb-floor-line);
  border-radius: 4px;
  overflow: hidden;
}
.sb-floor {
  display: grid;
  grid-template-columns: 1fr;
  border: 0;
  border-bottom: 1px solid var(--sb-floor-line);
  border-radius: 0;
  overflow: hidden;
  box-shadow: none;
}
.sb-floor.is-odd {
  background: var(--sb-floor-odd);
}
.sb-floor.is-even {
  background: var(--sb-floor-even);
}
.sb-floor:last-child { border-bottom: 0; }
@media (min-width: 768px) {
  .sb-floor {
    grid-template-columns: 11rem minmax(0, 1fr);
  }
}
.sb-floor-user {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.45rem;
  padding: 1.1rem 0.7rem 1.15rem;
  border-bottom: 1px solid var(--sb-floor-line);
}
.sb-floor-identity {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  min-width: 0;
  max-width: 100%;
}
.sb-floor.is-odd .sb-floor-user {
  background: var(--sb-floor-odd-side);
}
.sb-floor.is-even .sb-floor-user {
  background: var(--sb-floor-even-side);
}
@media (min-width: 768px) {
  .sb-floor-user {
    border-bottom: 0;
    border-right: 1px solid var(--sb-floor-line);
    align-self: stretch;
  }
}
.sb-floor-avatar {
  width: 4rem;
  height: 4rem;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  font-weight: 700;
  color: #e2e8f0;
  background: #1c2230;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}
.sb-floor-name-row,
.sb-name-with-noble {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.28rem;
  max-width: 100%;
  min-width: 0;
}
.sb-name-with-noble {
  justify-content: flex-start;
}
.sb-floor-name-row .sb-floor-name,
.sb-name-with-noble .sb-name {
  min-width: 0;
}
.sb-floor-name-row .sb-noble-badge,
.sb-name-with-noble .sb-noble-badge,
.sb-nested-text .sb-noble-badge {
  flex: 0 0 auto;
}
.sb-nested-text .sb-noble-badge.is-sm img {
  width: 1.05rem;
  height: 1.05rem;
  vertical-align: -0.15rem;
}
.sb-floor-name {
  color: #f9a8d4;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.92rem;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.25;
}
.sb-floor-name:hover { color: #fff; }
.sb-floor-uid {
  display: flex;
  justify-content: center;
  max-width: 100%;
  transform: scale(0.92);
  transform-origin: top center;
}
.sb-floor-level {
  margin-top: 0.15rem;
  display: flex;
  justify-content: center;
  width: 100%;
}
.sb-floor-level .sb-level-plate {
  --plate-h: 1.7rem;
}
.sb-floor-level .sb-level-plate.is-lv-only .sb-level-plate-text {
  font-size: calc(var(--plate-h) * 0.4);
  letter-spacing: 0.04em;
}
.sb-floor-avatar-wrap {
  display: flex;
  justify-content: center;
}
.sb-floor-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.25rem;
  width: 100%;
  margin-top: 0.2rem;
  padding: 0.4rem 0.2rem 0.15rem;
  border-top: 1px dashed rgba(255, 255, 255, 0.1);
  font-size: 0.68rem;
  color: #94a3b8;
}
.sb-floor-stats > div {
  padding: 0.25rem 0.15rem;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.03);
}
.sb-floor-stats strong {
  display: block;
  color: #e2e8f0;
  font-size: 0.74rem;
  font-weight: 700;
  line-height: 1.15;
}
.sb-floor-stats span {
  display: block;
  font-size: 0.58rem;
  color: #64748b;
}
.sb-floor-role {
  display: inline-block;
  margin-top: 0.1rem;
  padding: 0.12rem 0.45rem;
  border-radius: 3px;
  font-size: 0.68rem;
  font-weight: 700;
  color: #111;
  background: var(--sb-yellow);
}
.sb-level-badge {
  display: inline-block;
  margin-top: 0.1rem;
  padding: 0.12rem 0.4rem;
  border-radius: 3px;
  font-size: 0.68rem;
  font-weight: 700;
  color: #14151c;
  background: var(--sb-yellow);
  border: 1px solid var(--sb-yellow);
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.sb-level-bar {
  height: 0.35rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
  margin-top: 0.55rem;
}
.sb-level-bar > span {
  display: block;
  height: 100%;
  background: var(--sb-yellow);
  border-radius: 999px;
}
.sb-level-note strong { color: var(--sb-yellow); }

/* Newcomer missions (sb.sb-style) */
.sb-mission-bar-wrap {
  border: 0;
  background: linear-gradient(180deg, #242014 0%, var(--mission-bar-bg) 100%);
}
.sb-mission-bar {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  width: 100%;
  margin: 0;
  padding: 0.55rem 1rem;
  color: #f3e6b5;
  text-decoration: none !important;
  font-size: 0.84rem;
}
.sb-mission-bar:hover,
.sb-mission-bar:focus-visible {
  color: #fff6d8;
  text-decoration: none !important;
}
.sb-mission-bar-label { flex: 1 1 auto; min-width: 0; }
.sb-mission-bar-track {
  flex: 0 0 8rem;
  height: 0.4rem;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.35);
  overflow: hidden;
  border: 0;
}
.sb-mission-bar-track > span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #f5c518 0%, #7af0a0 100%);
}
.sb-mission-bar-pct {
  flex: 0 0 auto;
  color: var(--sb-yellow);
  font-weight: 700;
  font-size: 0.78rem;
}
.sb-mission-bar-go {
  flex: 0 0 auto;
  padding: 0.22rem 0.65rem;
  border-radius: 6px;
  border: 0;
  background: rgba(0, 0, 0, 0.28);
  color: #ffe9b8;
  font-size: 0.78rem;
  font-weight: 650;
}
.sb-mission-bar:hover .sb-mission-bar-go {
  background: var(--sb-yellow);
  color: #14151c;
}
.sb-mission-modal .modal-content {
  background: var(--panel);
  color: var(--text);
  border: 1px solid var(--line);
}
.sb-mission-preview {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.45rem;
}
.sb-mission-preview li {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.55rem 0.65rem;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
}
.sb-mission-preview strong { color: var(--sb-yellow); }
.sb-mission-track {
  height: 0.4rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}
.sb-mission-track > span {
  display: block;
  height: 100%;
  background: var(--sb-yellow);
}
.sb-mission-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.55rem;
}
.sb-mission-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.65rem 1rem;
  padding: 0.75rem 0.85rem;
  border-radius: 5px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.02);
}
.sb-mission-row.is-done {
  opacity: 0.72;
  border-color: rgba(245, 197, 66, 0.22);
}
.sb-mission-main { min-width: 0; flex: 1 1 14rem; }
.sb-mission-meta {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  flex: 0 0 auto;
}
.sb-mission-xp {
  color: var(--sb-yellow);
  font-weight: 700;
  font-size: 0.86rem;
}
.sb-mission-status {
  font-size: 0.78rem;
  color: #86efac;
}
.sb-user-links {
  list-style: none;
  margin: 0.65rem 0 0;
  padding: 0.55rem 0 0;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  display: grid;
  gap: 0.35rem;
}
.sb-user-links a,
.sb-text-btn {
  color: #93c5fd;
  font-size: 0.82rem;
  text-decoration: none;
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
  text-align: left;
}
.sb-user-links a:hover,
.sb-text-btn:hover { color: #fff; text-decoration: underline; }
.sb-inline-form { display: inline; margin: 0; }

/* User hub (sb.sb-style home) */
.sb-hub {
  display: grid;
  gap: 0.85rem;
}
@media (min-width: 992px) {
  .sb-hub {
    grid-template-columns: minmax(0, 1fr) 17.5rem;
    align-items: start;
  }
}
.sb-hub-main,
.sb-hub-side {
  display: grid;
  gap: 0.75rem;
  min-width: 0;
}
.sb-hub-banner { padding: 1rem; }
.sb-hub-identity {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  margin-bottom: 0.9rem;
}
.sb-hub-avatar-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  flex: 0 0 auto;
}
.sb-hub-avatar {
  width: 3.4rem;
  height: 3.4rem;
  border-radius: 6px;
  object-fit: cover;
  border: 1px solid rgba(255, 255, 255, 0.1);
  flex: 0 0 auto;
}
.sb-avatar-pets {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.15rem;
  max-width: 7.5rem;
}
.sb-avatar-pets .pet-stage {
  margin: 0;
}
.sb-hub-avatar.is-fallback {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--avatar-fallback);
  font-weight: 700;
  color: #fff;
}
.sb-stat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.55rem;
}
@media (max-width: 700px) {
  .sb-stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.sb-stat-grid > div,
.sb-stat-grid > a.sb-stat-link {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 5px;
  padding: 0.55rem 0.6rem;
  text-align: center;
  text-decoration: none !important;
  color: inherit;
  display: block;
}
.sb-stat-grid > a.sb-stat-link:hover {
  border-color: rgba(255, 208, 47, 0.35);
  background: rgba(255, 208, 47, 0.06);
}
.sb-stat-grid strong {
  display: block;
  font-size: 1.05rem;
  color: #f8fafc;
  line-height: 1.2;
}
.sb-stat-grid span {
  display: block;
  margin-top: 0.15rem;
  font-size: 0.72rem;
  color: var(--muted);
}
.sb-follows-panel {
  padding: 1rem 1.05rem 0.85rem;
}
.sb-follows-head {
  margin-bottom: 0.35rem;
}
.sb-follows-title-row {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.45rem 0.85rem;
  margin-bottom: 0.65rem;
}
.sb-follows-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-strong);
}
.sb-follows-back {
  color: #94a3b8;
  font-size: 0.82rem;
  text-decoration: none;
}
.sb-follows-back:hover { color: var(--sb-yellow); }
.sb-follows-tabs {
  margin-bottom: 0.25rem;
  padding-bottom: 0.55rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.sb-follow-list {
  list-style: none;
  margin: 0.35rem 0 0;
  padding: 0;
  display: grid;
}
.sb-follow-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.7rem 0.35rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 8px;
  transition: background 0.12s ease;
}
.sb-follow-row:first-child { border-top: 0; }
.sb-follow-row:hover {
  background: rgba(255, 255, 255, 0.03);
}
.sb-follow-avatar {
  flex: 0 0 auto;
  text-decoration: none;
  line-height: 0;
}
.sb-follow-meta { flex: 1 1 auto; }
.sb-follow-name-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 0.45rem;
}
.sb-follow-name-row .sb-name {
  font-weight: 650;
  font-size: 0.98rem;
  text-decoration: none;
}
.sb-follow-sub {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 0.65rem;
  margin-top: 0.2rem;
}
.sb-follow-lv { color: #94a3b8; }
.sb-follow-action {
  flex: 0 0 auto;
  margin-left: auto;
}
.sb-follows-empty {
  margin: 1.1rem 0 0.35rem;
  padding: 0.85rem 0.25rem;
}
.sb-follows-pager {
  margin-top: 0.35rem;
  padding-top: 0.35rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}
.sb-stat-grid-compact {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-bottom: 0.35rem;
}
.sb-hub-level { margin-top: 0.85rem; }
.sb-hub-level-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem 0.75rem;
  align-items: center;
  margin-bottom: 0.45rem;
  font-size: 0.86rem;
  font-weight: 650;
}
.sb-level-plate {
  /* Emblem is ~square; text lives only in the right capsule bar. */
  --plate-h: 2.5rem;
  --plate-text-inset: calc(var(--plate-h) * 1.08);
  position: relative;
  display: inline-flex;
  align-items: center;
  height: var(--plate-h);
  flex: 0 0 auto;
  max-width: 100%;
  isolation: isolate;
}
.sb-level-plate.is-sm { --plate-h: 1.85rem; }
.sb-level-plate.is-md { --plate-h: 2.5rem; }
.sb-level-plate.is-lg { --plate-h: 3.15rem; }
.sb-level-plate-art {
  display: block;
  height: 100%;
  width: auto;
  max-width: min(22rem, 100%);
  object-fit: contain;
  object-position: left center;
  /* Drop the solid black artboard so it blends with the panel */
  mix-blend-mode: lighten;
}
.sb-level-plate-text {
  position: absolute;
  left: var(--plate-text-inset);
  right: calc(var(--plate-h) * 0.28);
  top: 50%;
  transform: translateY(-50%);
  z-index: 1;
  margin: 0;
  padding: 0 0.15rem;
  color: #fff;
  font-weight: 800;
  font-size: calc(var(--plate-h) * 0.32);
  line-height: 1.1;
  letter-spacing: 0.02em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-align: center;
  text-shadow:
    0 1px 0 rgba(0, 0, 0, 0.75),
    0 0 6px rgba(0, 0, 0, 0.45);
  pointer-events: none;
}
.sb-level-plate.is-lg .sb-level-plate-text {
  font-size: calc(var(--plate-h) * 0.3);
}
.sb-level-plate.is-sm .sb-level-plate-text {
  font-size: calc(var(--plate-h) * 0.34);
  right: calc(var(--plate-h) * 0.22);
}
.sb-level-plate.is-lv-only .sb-level-plate-text {
  font-size: calc(var(--plate-h) * 0.42);
  letter-spacing: 0.04em;
}
.sb-level-plate.is-plain {
  min-width: 6.5rem;
  padding: 0 0.75rem 0 0.55rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 208, 47, 0.35);
  background: linear-gradient(90deg, #2a1a12 0%, #1a1410 100%);
}
.sb-level-plate.is-plain .sb-level-plate-text {
  position: static;
  transform: none;
  left: auto;
  right: auto;
}
.sb-medal-wall {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(6.8rem, 1fr));
  gap: 0.75rem 0.55rem;
}
.sb-medal {
  text-align: center;
  padding: 0.25rem 0.15rem;
}
.sb-medal.is-locked { opacity: 0.42; filter: grayscale(0.85); }
.sb-medal.is-earned { opacity: 1; filter: none; }
.sb-medal-art {
  width: 4.5rem;
  height: 4.5rem;
  margin: 0 auto 0.35rem;
  display: flex;
  align-items: center;
  justify-content: center;
}
.sb-medal-art img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}
.sb-medal-title {
  font-size: 0.72rem;
  line-height: 1.25;
  color: #e2e8f0;
}
.sb-medal-progress { font-size: 0.66rem; margin-top: 0.15rem; }
.sb-medal-hall {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(15.5rem, 1fr));
  gap: 0.85rem;
}
.sb-medal-card {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  padding: 0.75rem 0.7rem;
  border: 1px solid var(--line-soft);
  background: rgba(255, 255, 255, 0.02);
  border-radius: 6px;
}
.sb-medal-card.is-locked {
  opacity: 0.55;
  filter: grayscale(0.55);
}
.sb-medal-card.is-earned {
  opacity: 1;
  filter: none;
  border-color: rgba(255, 208, 47, 0.28);
}
.sb-medal-card-art {
  width: 4.4rem;
  height: 4.4rem;
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
}
.sb-medal-card-art img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}
.sb-medal-card-title {
  font-size: 0.92rem;
  font-weight: 650;
  margin: 0 0 0.2rem;
  color: var(--text-strong);
}
.sb-medal-card-blurb { line-height: 1.35; }
.sb-medal-card-meta { color: var(--sb-yellow); }
.sb-level-icon {
  width: 1.55rem;
  height: 1.55rem;
  object-fit: contain;
  flex: 0 0 auto;
}

.sb-hub-menu {
  list-style: none;
  margin: 0.7rem 0 0;
  padding: 0.65rem 0 0;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  display: grid;
  /* Row-major fill keeps rows level; 2 cols → even pairs (no leftover 3rd column). */
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-auto-flow: row;
  gap: 0.15rem 0.85rem;
  align-items: stretch;
}
.sb-hub-menu li {
  margin: 0;
  padding: 0;
  min-width: 0;
  display: flex;
}
.sb-hub-menu a,
.sb-hub-menu .sb-text-btn {
  color: #e2e8f0;
  font-size: 0.8rem;
  text-decoration: none;
  line-height: 1.25;
  background: none;
  border: 0;
  padding: 0.35rem 0;
  /* Reserve two lines so wrapped ZH/MS labels share one row height with short EN ones. */
  min-height: 2.7em;
  width: 100%;
  display: flex;
  align-items: center;
  text-align: left;
  cursor: pointer;
  overflow-wrap: anywhere;
  hyphens: auto;
}
.sb-hub-menu a:hover,
.sb-hub-menu .sb-text-btn:hover { color: var(--sb-yellow); }
.sb-hub-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem 0.9rem;
  margin-bottom: 0.75rem;
  padding-bottom: 0.55rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  font-size: 0.86rem;
}
.sb-hub-tabs .is-active { color: var(--sb-yellow); font-weight: 650; }
.sb-hub-tabs a { color: #94a3b8; text-decoration: none; }
.sb-hub-tabs a:hover { color: #fff; }

/* Profile bottom activity (topics / replies) — sb.sb-like */
.sb-profile-activity {
  padding-top: 0.35rem;
}
.sb-profile-tabs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.15rem 1.15rem;
  margin: 0 0 0.35rem;
  padding: 0.15rem 0 0.7rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  font-size: 0.92rem;
}
.sb-profile-tabs a {
  position: relative;
  color: #c9d2e3;
  text-decoration: none !important;
  padding: 0.1rem 0;
  font-weight: 500;
}
.sb-profile-tabs a:hover {
  color: #fff;
  text-decoration: none !important;
}
.sb-profile-tabs a.is-active {
  color: #fff;
  font-weight: 650;
  padding-left: 0.55rem;
}
.sb-profile-tabs a.is-active::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.2rem;
  bottom: 0.2rem;
  width: 2px;
  border-radius: 1px;
  background: var(--sb-yellow);
}
.sb-profile-list {
  margin: 0 -0.15rem;
}
.sb-profile-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.65rem 1rem;
  align-items: center;
  padding: 0.85rem 0.35rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}
.sb-profile-row:last-child { border-bottom: 0; }
.sb-profile-row:hover { background: rgba(255, 255, 255, 0.03); }
.sb-profile-row-main { min-width: 0; }
.sb-profile-row-title {
  display: block;
  color: #f1f5f9;
  font-size: 0.98rem;
  font-weight: 650;
  line-height: 1.35;
  text-decoration: none !important;
  overflow-wrap: anywhere;
  margin-bottom: 0.35rem;
}
.sb-profile-row-title:hover {
  color: #fff;
  text-decoration: none !important;
}
.sb-profile-row-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.2rem 0.75rem;
  color: #8b95a8;
  font-size: 0.78rem;
  line-height: 1.4;
}
.sb-profile-row-meta span {
  max-width: 14rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.sb-profile-row-cat {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 3.2rem;
  padding: 0.28rem 0.55rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 4px;
  color: #c9d2e3;
  font-size: 0.75rem;
  text-decoration: none !important;
  white-space: nowrap;
}
.sb-profile-row-cat:hover {
  color: #fff;
  border-color: rgba(255, 208, 47, 0.45);
  text-decoration: none !important;
}
.sb-profile-empty { padding: 0.85rem 0.15rem 0.35rem; }
@media (max-width: 640px) {
  .sb-profile-row {
    grid-template-columns: minmax(0, 1fr);
    gap: 0.45rem;
  }
  .sb-profile-row-cat { justify-self: start; }
}
.sb-ledger {
  list-style: none;
  margin: 0;
  padding: 0;
}
.sb-ledger li {
  display: grid;
  grid-template-columns: 4.5rem minmax(0, 1fr) auto;
  gap: 0.55rem;
  padding: 0.45rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  font-size: 0.86rem;
}
.sb-ledger .is-plus { color: #86efac; font-weight: 700; }
.sb-ledger .is-minus { color: #fca5a5; font-weight: 700; }
.sb-points-ledger {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.86rem;
}
.sb-points-ledger th,
.sb-points-ledger td {
  padding: 0.48rem 0.55rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  text-align: left;
  vertical-align: top;
}
.sb-points-ledger th {
  color: #94a3b8;
  font-weight: 650;
  font-size: 0.78rem;
  white-space: nowrap;
}
.sb-points-ledger td.num,
.sb-points-ledger th.num {
  text-align: right;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.sb-points-ledger .is-minus { color: #fca5a5; font-weight: 700; }
.sb-points-ledger .points-when {
  color: #94a3b8;
  white-space: nowrap;
}
.sb-points-ledger a {
  color: #e2e8f0;
  text-decoration: none;
}
.sb-points-ledger a:hover { color: var(--sb-yellow); }
.sb-mall-spend .muted a { color: #cbd5e1; }
.sb-mall-spend .muted a:hover { color: var(--sb-yellow); }
.btn-light {
  background: #f8fafc;
  color: #0f172a;
  border: 0;
  font-weight: 650;
}
.btn-light:hover { background: #fff; color: #0f172a; }
.sb-floor-body {
  padding: 1rem 1.1rem 1.15rem;
  min-width: 0;
}
.sb-floor.is-odd .sb-floor-body {
  background: var(--sb-floor-odd-body);
}
.sb-floor.is-even .sb-floor-body {
  background: var(--sb-floor-even-body);
}
.sb-floor-meta {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.75rem;
  margin-bottom: 0.85rem;
}
.sb-floor-num {
  color: #888;
  padding: 0;
  border-radius: 0;
  background: transparent;
}
.sb-floor-tools,
.sb-nested-tools {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 0.28rem;
  flex-shrink: 0;
}
.sb-tool-btn,
a.sb-tool-btn {
  appearance: none;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: transparent;
  color: #cfcfcf;
  font-size: 0.75rem;
  padding: 0.2rem 0.5rem;
  border-radius: 2px;
  cursor: pointer;
  line-height: 1.3;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}
.sb-tool-btn:hover,
a.sb-tool-btn:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.35);
}
.forum-disclose.is-tool {
  position: relative;
}
.forum-disclose.is-tool > summary {
  list-style: none;
  cursor: pointer;
  color: #cfcfcf;
  font-size: 0.75rem;
  padding: 0.2rem 0.5rem;
  border-radius: 2px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: transparent;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}
.forum-disclose.is-tool > summary::-webkit-details-marker { display: none; }
.forum-disclose.is-tool > summary::before { content: none; }
.forum-disclose.is-tool > summary:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.35);
}
.sb-tool-form {
  position: absolute;
  right: 0;
  top: calc(100% + 0.35rem);
  z-index: 5;
  width: min(18rem, 70vw);
  padding: 0.75rem;
  border-radius: 10px;
  background: #171c26;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.5);
}
.sb-floor-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: center;
  margin-top: 1rem;
  padding-top: 0.85rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}
.sb-replies-bar {
  display: flex;
  align-items: baseline;
  gap: 0.4rem;
  margin: 0;
  padding: 0.55rem 1rem;
  background: #0a0a0a;
  border: 0;
  border-bottom: 1px solid var(--sb-floor-line);
  border-radius: 0;
  font-size: 0.9rem;
  width: auto;
}
.sb-nested {
  margin-top: 1rem;
  padding: 0.45rem 0.55rem;
  border-radius: 2px;
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.05);
}
.sb-nested-items {
  display: grid;
  gap: 0.35rem;
}
.sb-nested-item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 0.45rem 0.55rem;
  align-items: start;
  padding: 0.5rem 0.45rem;
  border: 0;
  border-radius: 0;
  background: transparent;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  transition: background 0.15s ease;
}
.sb-nested-item:hover {
  background: rgba(255, 255, 255, 0.03);
}
.sb-nested-items .sb-nested-item:last-child {
  border-bottom: 0;
}
.sb-nested-avatar {
  display: inline-flex;
  text-decoration: none;
  margin-top: 0.1rem;
}
.sb-mini-avatar,
.sb-mini-avatar-img {
  width: 1.45rem;
  height: 1.45rem;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.68rem;
  font-weight: 700;
  color: #e2e8f0;
  background: #1c2230;
  border: 1px solid rgba(255, 255, 255, 0.1);
  object-fit: cover;
}
.avatar-framed.is-mini {
  width: 1.65rem;
  height: 1.65rem;
}
.sb-nested-text {
  min-width: 0;
  color: #e2e8f0;
  font-size: 0.9rem;
  line-height: 1.5;
}
.sb-nested-name {
  color: #e2e8f0;
  font-weight: 700;
  text-decoration: none;
}
.sb-nested-name:hover { color: #fff; }
.sb-nested-op {
  display: inline-block;
  margin: 0 0.15rem;
  padding: 0.05rem 0.3rem;
  border-radius: 4px;
  font-size: 0.68rem;
  font-weight: 700;
  line-height: 1.2;
  color: #111;
  background: var(--sb-yellow);
  vertical-align: middle;
}
.sb-nested-sep { color: #94a3b8; }
.sb-nested-body {
  display: inline;
  margin: 0;
  color: #cbd5e1;
}
.sb-nested-body p {
  display: inline;
  margin: 0;
}
.sb-nested-body p + p { display: block; margin-top: 0.35rem; }
.sb-nested-tools {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 0.25rem;
  font-size: 0.78rem;
  color: #64748b;
}
.sb-nested-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-top: 0.35rem;
  padding: 0.45rem 0.55rem 0.2rem;
  border-top: 0;
  font-size: 0.8rem;
}
.sb-nested-count { color: #94a3b8; }
.sb-floor-sign {
  margin-top: 0.95rem;
  padding: 0.65rem 0.75rem;
  border-top: 0;
  border-radius: 8px;
  background: rgba(245, 197, 66, 0.06);
  border: 1px solid rgba(245, 197, 66, 0.12);
}
.sb-floor-sign-label {
  display: block;
  margin-bottom: 0.25rem;
  font-size: 0.72rem;
  color: #94a3b8;
}
.sb-floor-sign-body {
  margin: 0;
  font-size: 0.86rem;
  color: #f5c542;
  white-space: pre-wrap;
  word-break: break-word;
}
@media (max-width: 640px) {
  .sb-nested-item {
    grid-template-columns: auto minmax(0, 1fr);
  }
  .sb-nested-tools {
    grid-column: 1 / -1;
    justify-content: flex-start;
  }
}
.sb-composer {
  margin-top: 0.75rem;
  padding: 1rem 1.05rem;
  background: var(--sb-floor-odd-body);
  border: 1px solid var(--sb-floor-line);
  border-radius: 4px;
  box-shadow: none;
}
.sb-composer .forum-composer-input,
.sb-composer textarea {
  border-radius: 2px;
  border-color: rgba(255, 255, 255, 0.1);
  background: #0a0a0a;
}
.sb-composer .forum-composer-input:focus,
.sb-composer textarea:focus {
  border-color: rgba(255, 208, 47, 0.45);
  box-shadow: 0 0 0 2px rgba(255, 208, 47, 0.12);
}
.sb-thread-side { display: grid; gap: 0.7rem; }
.sb-thread-side .sb-panel,
.sb-thread-side .sb-user-card {
  border-radius: 4px;
  border-color: var(--sb-floor-line);
  box-shadow: none;
  background: var(--sb-floor-odd-body);
  padding: 1rem;
}
.forum-avatar {
  flex: 0 0 auto;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #1c2230;
  color: #fff;
  font-weight: 700;
  font-size: 0.95rem;
}

.md-body,
.forum-body {
  font-size: 1.05rem;
  line-height: 1.7;
  color: #dce5f5;
  overflow-wrap: anywhere;
}
.md-body p,
.forum-body p { margin-bottom: 0.9rem; }
.md-body p:last-child,
.forum-body p:last-child { margin-bottom: 0; }
.md-body ul,
.md-body ol {
  padding-left: 1.25rem;
  margin-bottom: 0.9rem;
}
.md-body code,
.forum-body code {
  font-family: "IBM Plex Mono", ui-monospace, monospace;
  font-size: 0.9em;
  background: rgba(7, 13, 24, 0.55);
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 0.05rem 0.35rem;
}
.md-body pre,
.forum-body pre {
  background: #0b1220;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 8px;
  padding: 0.9rem 1rem;
  overflow-x: auto;
  margin: 0.85rem 0 1rem;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
}
.md-body pre code,
.forum-body pre code {
  display: block;
  border: 0;
  background: transparent;
  padding: 0;
  color: #e2e8f0;
  font-size: 0.86rem;
  line-height: 1.55;
  white-space: pre;
}
.md-body img,
.forum-body img,
.sb-post-shot-img {
  display: block;
  max-width: 100%;
  height: auto;
  max-height: 520px;
  object-fit: contain;
  margin: 0.85rem 0;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 8px;
  background: #0b1220;
}
.sb-poll,
.sb-lotto,
.sb-rp {
  margin: 1rem 0 0.35rem;
  padding: 0.9rem 1rem;
  border-radius: 10px;
}
.sb-rp {
  border: 1px solid rgba(234, 179, 8, 0.35);
  background: linear-gradient(160deg, rgba(120, 53, 15, 0.35), rgba(7, 13, 24, 0.55));
}
.sb-poll {
  border: 1px solid rgba(56, 189, 248, 0.35);
  background: linear-gradient(160deg, rgba(12, 74, 110, 0.35), rgba(7, 13, 24, 0.55));
}
.sb-lotto {
  border: 1px solid rgba(167, 139, 250, 0.35);
  background: linear-gradient(160deg, rgba(76, 29, 149, 0.28), rgba(7, 13, 24, 0.55));
}
.sb-poll-title { color: #7dd3fc; }
.sb-lotto-title { color: #ddd6fe; }
.sb-poll-option-list {
  display: grid;
  gap: 0.55rem;
}
.sb-poll-option-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 0.4rem;
  align-items: center;
}
.sb-poll-option-preview {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.sb-poll-compose-thumb,
.sb-poll-option-img {
  display: block;
  max-width: 160px;
  max-height: 120px;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 6px;
  border: 1px solid rgba(148, 163, 184, 0.28);
  background: #0b1220;
}
.sb-poll-form {
  display: grid;
  gap: 0.55rem;
}
.sb-poll-option {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  margin: 0;
  cursor: pointer;
}
.sb-poll-option-body {
  display: grid;
  gap: 0.35rem;
  min-width: 0;
}
.sb-poll-option.has-image .sb-poll-option-img {
  max-width: 220px;
  max-height: 160px;
}
.sb-poll-results .sb-poll-option-img {
  margin-bottom: 0.35rem;
}
.sb-poll-results {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.55rem;
}
.sb-poll-row {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  font-size: 0.9rem;
}
.sb-poll-bar {
  margin-top: 0.25rem;
  height: 6px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.2);
  overflow: hidden;
}
.sb-poll-bar::after {
  content: "";
  display: block;
  width: var(--pct, 0%);
  height: 100%;
  background: #38bdf8;
}
.sb-poll-results .is-mine .sb-poll-bar::after { background: #fbbf24; }
.sb-lotto-check,
.sb-lotto-prizes {
  margin: 0 0 0.55rem;
  padding-left: 1.1rem;
  font-size: 0.88rem;
}
.sb-lotto-mine {
  margin: 0 0 0.55rem;
  color: #ddd6fe;
  font-weight: 600;
}
.sb-lotto-mine p { margin: 0 0 0.25rem; }
.sb-rp-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.35rem;
}
.sb-rp-title { color: #fde68a; }
.sb-rp-status {
  font-size: 0.75rem;
  padding: 0.15rem 0.45rem;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.35);
}
.sb-rp-status.is-open { color: #86efac; border-color: rgba(134, 239, 172, 0.4); }
.sb-rp-status.is-closed { color: var(--muted); }
.sb-rp-mine {
  margin: 0 0 0.55rem;
  color: #fde68a;
  font-weight: 600;
}
.sb-rp-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem;
  margin-bottom: 0.55rem;
}
.sb-rp-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.25rem;
  font-size: 0.88rem;
}
.sb-rp-list li {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.2rem 0;
  border-top: 1px solid rgba(148, 163, 184, 0.15);
}
.sb-post-shot {
  margin: 1rem 0 0.35rem;
  padding: 0;
}
.sb-post-shot-link {
  display: block;
}
.sb-post-shot-cap {
  margin-top: 0.35rem;
}
.md-body blockquote {
  margin: 0 0 0.9rem;
  padding: 0.35rem 0 0.35rem 0.9rem;
  border-left: 3px solid var(--accent);
  color: var(--muted);
}

.forum-indicators {
  margin-top: 1.1rem;
  padding-top: 0.9rem;
  border-top: 1px solid var(--line);
  display: grid;
  gap: 0.35rem;
  font-size: 0.9rem;
}
.forum-tags { display: flex; flex-wrap: wrap; gap: 0.35rem; margin-top: 0.25rem; }

.forum-disclose {
  color: var(--muted);
  font-size: 0.88rem;
}
.forum-disclose summary {
  cursor: pointer;
  list-style: none;
  color: var(--muted);
}
.forum-disclose summary::-webkit-details-marker { display: none; }
.forum-disclose summary::before {
  content: "▸ ";
  color: var(--sb-yellow);
}
.forum-disclose[open] summary::before { content: "▾ "; }
.forum-disclose summary:hover { color: #fff; }
.sb-floor-actions .forum-disclose summary {
  padding: 0.28rem 0.55rem;
  border: 1px solid var(--line);
  border-radius: 0.375rem;
}
.forum-composer-input {
  min-height: 7.5rem;
  line-height: 1.55;
  font-size: 1rem;
  resize: vertical;
}
.page-forum .pagination .page-link,
.page-hub .pagination .page-link {
  background: rgba(7, 13, 24, 0.45);
  border-color: var(--line);
  color: var(--text);
}
.page-forum .pagination .page-item.active .page-link,
.page-hub .pagination .page-item.active .page-link {
  background: var(--accent);
  border-color: var(--accent);
  color: #14151c;
}
.page-forum .pagination .page-link:hover,
.page-hub .pagination .page-link:hover {
  background: rgba(255, 208, 47, 0.16);
  color: #fff;
}

@media (max-width: 767px) {
  .forum-op,
  .forum-comment { padding: 1.05rem 1rem; }
  .forum-search { width: 100%; }
  .forum-search .form-control { flex: 1; min-width: 0; }
  .forum-composer { bottom: 0.35rem; }
}

/* Shared comfort for tool / content pages */
.page-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.85rem 1rem;
  margin-bottom: 1.15rem;
}
.page-head h1 {
  margin: 0 0 0.3rem;
  font-size: clamp(1.35rem, 2.2vw, 1.7rem);
  font-weight: 650;
  letter-spacing: -0.02em;
}
.page-head .lead-copy,
.page-desc {
  margin: 0;
  color: var(--muted);
  max-width: 40rem;
  line-height: 1.55;
}
.page-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  align-items: center;
}
.tool-narrow {
  max-width: 44rem;
}
.scan-box .form-control,
.tool-lookup .form-control {
  padding: 0.9rem 1rem;
  font-size: 1.02rem;
}
.result-block h2,
.result-block h3 {
  margin-top: 1.25rem;
}
.result-block h2:first-child,
.result-block > h2:first-of-type {
  margin-top: 0;
}
.result-dl {
  margin: 0;
}
.result-dl dt {
  color: var(--muted);
  font-weight: 500;
  font-size: 0.9rem;
  padding-top: 0.45rem;
}
.result-dl dd {
  margin-bottom: 0.45rem;
  padding-top: 0.35rem;
  line-height: 1.5;
}
.finding-list {
  list-style: none;
  padding: 0;
  margin: 0.75rem 0 0;
}
.finding-list li {
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--line);
}
.finding-list li:last-child { border-bottom: 0; }
.finding-list .muted { margin-top: 0.25rem; line-height: 1.45; }
.soft-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.soft-list li {
  padding: 0.7rem 0;
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
}
.soft-list li:last-child { border-bottom: 0; }
.range-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  align-items: end;
  margin-bottom: 1.25rem;
}
.page-auth .panel,
.page-form .panel {
  padding: 1.45rem 1.5rem;
}
.page-auth .form-control,
.page-form .form-control,
.page-form .form-select {
  padding: 0.7rem 0.85rem;
}
.reports-table-wrap {
  background: #12151c;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 6px;
  overflow: hidden;
  box-shadow: none;
}
.reports-table-wrap .table {
  margin-bottom: 0;
}
.reports-table-wrap .table > :not(caption) > * > * {
  padding: 0.85rem 1rem;
}
.status-pill {
  display: inline-block;
  padding: 0.15rem 0.55rem;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  background: rgba(148, 163, 184, 0.16);
  color: #cbd5e1;
}
.status-pill.is-pending { background: rgba(245, 158, 11, 0.16); color: #fcd34d; }
.status-pill.is-verified { background: rgba(34, 197, 94, 0.16); color: #86efac; }
.status-pill.is-rejected { background: rgba(239, 68, 68, 0.16); color: #fca5a5; }
.hero {
  padding: 2.4rem 0 1.35rem;
}
.hero .display-5 {
  max-width: 18ch;
  line-height: 1.15;
  letter-spacing: -0.03em;
}
@media (min-width: 768px) {
  .hero .display-5 { max-width: 22ch; }
}

.site-nav.sticky-top {
  z-index: 1030;
  backdrop-filter: blur(14px);
}
.page-content .content-article {
  max-width: none;
  margin: 0;
  padding: 1.15rem 1.25rem;
}
.page-content .content-article h1 {
  margin-bottom: 0.85rem;
  font-size: clamp(1.25rem, 2.2vw, 1.55rem);
  letter-spacing: -0.02em;
}
.page-content .content-article p,
.content-bullets {
  line-height: 1.65;
  color: #dce3f0;
}
.content-bullets {
  padding-left: 1.15rem;
  margin: 0;
}
.content-bullets li { margin-bottom: 0.7rem; }

.about-guide .lead-copy { color: #e8eef8; }
.about-toc {
  margin: 1.1rem 0 1.4rem;
  padding: 0.85rem 1rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #0f1218;
}
.about-toc strong {
  display: block;
  margin-bottom: 0.45rem;
  font-size: 0.92rem;
}
.about-toc ol {
  margin: 0;
  padding-left: 1.2rem;
  columns: 2;
  column-gap: 1.5rem;
}
.about-toc li {
  break-inside: avoid;
  margin: 0.22rem 0;
  font-size: 0.88rem;
}
.about-toc a { color: #9ec1ff; text-decoration: none; }
.about-toc a:hover { text-decoration: underline; }
@media (max-width: 640px) {
  .about-toc ol { columns: 1; }
}
.about-sec {
  margin-top: 1.55rem;
  padding-top: 0.35rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  scroll-margin-top: 4.5rem;
}
.about-sec h2 { margin-bottom: 0.55rem; }
.about-links {
  margin: 0.65rem 0 0;
  font-size: 0.9rem;
}
.about-links a { color: #9ec1ff; }
.about-noble-tiers {
  margin-top: 0.75rem;
}
.about-noble-tiers .sb-noble-tier {
  opacity: 1;
  filter: none;
}
.feed-table-panel .feed-table {
  --bs-table-bg: transparent;
  --bs-table-color: var(--text);
  --bs-table-border-color: var(--line);
}
.feed-table-panel .feed-table tbody tr:hover {
  background: rgba(255, 255, 255, 0.03);
}
.notify-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.65rem;
}
.notify-item { margin: 0; }
.notify-item.is-unread {
  border-color: rgba(96, 165, 250, 0.45);
  box-shadow: inset 3px 0 0 var(--accent);
}
.profile-avatar,
.profile-avatar-fallback {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  object-fit: cover;
  flex: 0 0 auto;
}
.profile-avatar-fallback {
  font-size: 1.35rem;
}
.profile-bio {
  max-width: 40rem;
  line-height: 1.6;
  color: #d7e0f1;
  margin: -0.25rem 0 1.25rem;
}

/* Let's chat / customer support launcher */
.support-launcher {
  position: fixed;
  right: 1.1rem;
  bottom: 1.1rem;
  z-index: 1040;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.65rem;
}
.support-fab {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  border: 0;
  border-radius: 999px;
  padding: 0.75rem 1.15rem;
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  color: #fff;
  font-weight: 650;
  box-shadow: 0 12px 28px rgba(37, 99, 235, 0.35);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.support-fab:hover {
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 16px 32px rgba(37, 99, 235, 0.42);
}
.support-fab-dot {
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 50%;
  background: #86efac;
  box-shadow: 0 0 0 3px rgba(134, 239, 172, 0.25);
}
.support-panel {
  width: min(22rem, calc(100vw - 1.5rem));
  background: linear-gradient(180deg, rgba(16, 32, 68, 0.98), rgba(10, 18, 38, 0.98));
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: 0 22px 48px rgba(0, 0, 0, 0.4);
  overflow: hidden;
}
.support-panel[hidden] { display: none !important; }
.support-panel-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.9rem 1rem;
  border-bottom: 1px solid var(--line);
  background: rgba(7, 13, 24, 0.35);
}
.support-panel-body { padding: 1rem; }
.support-panel-channels {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}
.support-channels {
  display: grid;
  gap: 0.55rem;
}
.support-channel {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--line);
  border-radius: 12px;
  text-decoration: none;
  color: var(--text);
  background: rgba(7, 13, 24, 0.35);
}
.support-channel:hover {
  border-color: rgba(96, 165, 250, 0.55);
  color: #fff;
}
.support-channel-compact {
  flex-direction: row;
  align-items: center;
  padding: 0.4rem 0.7rem;
  font-size: 0.86rem;
}
.support-ticket {
  width: 100%;
  max-width: 52rem;
}
.support-thread {
  display: grid;
  gap: 0.75rem;
  width: 100%;
}
.support-bubble {
  width: 100%;
  min-width: 0;
  padding: 0.95rem 1.05rem;
  box-sizing: border-box;
}
.support-bubble.is-staff {
  border-color: rgba(96, 165, 250, 0.35);
  background: linear-gradient(180deg, rgba(37, 99, 235, 0.16), rgba(10, 18, 38, 0.9));
}
.support-bubble.is-user {
  border-color: rgba(255, 208, 47, 0.18);
}
.support-bubble-meta {
  margin-bottom: 0.35rem;
}
.support-bubble-body {
  white-space: pre-wrap;
  line-height: 1.55;
  overflow-wrap: anywhere;
}
.support-ticket .panel {
  width: 100%;
}
@media (max-width: 575px) {
  .support-launcher {
    right: 0.75rem;
    bottom: 0.75rem;
  }
  .support-fab {
    padding: 0.7rem 1rem;
    font-size: 0.92rem;
  }
}

/* Mobile polish + trust UI */
.lang-switch {
  display: inline-flex;
  gap: 0.35rem;
  align-items: center;
  font-size: 0.78rem;
}
.lang-switch a {
  color: var(--text-subtle) !important;
  text-decoration: none !important;
  padding: 0.15rem 0.35rem;
  border-radius: 4px;
}
.lang-switch a.is-active,
.lang-switch a:hover {
  color: var(--sb-yellow) !important;
  background: var(--sb-yellow-soft);
  text-decoration: none !important;
}
.nav-alerts.has-unread {
  border-color: rgba(255, 208, 47, 0.65) !important;
  box-shadow: 0 0 0 1px rgba(255, 208, 47, 0.2);
}
.alert-count {
  display: inline-flex;
  min-width: 1.25rem;
  justify-content: center;
  padding: 0 0.35rem;
  border-radius: 999px;
  background: #ef4444;
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
}
.alert-unread {
  border: 1px solid rgba(96, 165, 250, 0.35);
  background: rgba(37, 99, 235, 0.16);
  color: #dbe7ff;
}
.how-to-panel .how-to-list {
  padding-left: 1.15rem;
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}
.how-to-list li { margin-bottom: 0.45rem; }
.footer-official a {
  white-space: nowrap;
}
.range-date { max-width: 11rem; }

@media (max-width: 767px) {
  .global-back-btn { min-width: auto; padding-left: 0.55rem; padding-right: 0.55rem; }
  .navbar-brand strong { font-size: 0.95rem; }
  .brand-mark { width: 32px; height: 32px; }
  .hero { padding-top: 1.4rem; }
  .hero .display-5 { font-size: 1.7rem; max-width: none; }
  .scan-box .row > [class*="col-"] { width: 100%; }
  .reports-table-wrap,
  .feed-table-panel .table-responsive,
  .table-responsive {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  .forum-composer {
    position: static;
    box-shadow: none;
  }
  .forum-thread,
  .forum-compose {
    max-width: none;
  }
  .support-launcher { bottom: 0.85rem; }
  .nav-actions {
    width: 100%;
    padding-top: 0.5rem;
  }
  .range-date { max-width: none; width: 100%; }
}

/* WordPress-inspired admin shell */
.admin-body {
  margin: 0;
  min-height: 100vh;
  background: #f0f0f1;
  color: #1d2327;
  font-family: "Source Sans 3", system-ui, sans-serif;
}
.admin-body .alert { border-radius: 4px; }
.admin-topbar {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  gap: 0.65rem;
  min-height: 32px;
  padding: 0 0.75rem;
  background: #1d2327;
  color: #f0f0f1;
  border-bottom: 1px solid #2c3338;
}
.admin-topbar a,
.admin-topbar-logout {
  color: #c3c4c7;
  text-decoration: none;
  font-size: 0.86rem;
  background: transparent;
  border: 0;
  padding: 0;
}
.admin-topbar a:hover,
.admin-topbar-logout:hover { color: #fff; }
.admin-topbar-brand {
  font-weight: 700;
  color: #fff !important;
}
.admin-topbar-site {
  padding: 0 0.4rem;
  border-left: 1px solid #3c434a;
}
.admin-jump {
  margin-left: 0.35rem;
  max-width: 11rem;
  height: 1.55rem;
  padding: 0 0.35rem;
  border: 1px solid #3c434a;
  border-radius: 2px;
  background: #2c3338;
  color: #f0f0f1;
  font-size: 0.78rem;
}
.admin-topbar-links {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 0.85rem;
  flex-wrap: wrap;
}
.admin-topbar-user { color: #a7aaad; font-size: 0.82rem; }
.admin-topbar-user strong { color: #fff; font-weight: 600; }
.admin-menu-toggle {
  display: none;
  border: 1px solid #3c434a;
  background: #2c3338;
  color: #fff;
  border-radius: 3px;
  width: 2rem;
  height: 1.75rem;
  line-height: 1;
}
.admin-shell {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  min-height: calc(100vh - 32px);
  transition: grid-template-columns 0.18s ease;
}
.admin-shell.is-folded {
  grid-template-columns: 48px minmax(0, 1fr);
}
.admin-sidebar {
  position: sticky;
  top: 32px;
  align-self: start;
  height: calc(100vh - 32px);
  overflow-y: auto;
  background: #1d2327;
  color: #f0f0f1;
  padding: 0.4rem 0 1.5rem;
  border-right: 1px solid #2c3338;
}
.admin-sidebar-fold {
  display: flex;
  align-items: center;
  justify-content: center;
  width: calc(100% - 0.8rem);
  margin: 0.35rem 0.4rem 0.55rem;
  height: 1.6rem;
  border: 1px solid #3c434a;
  border-radius: 2px;
  background: #2c3338;
  color: #c3c4c7;
  font-size: 1rem;
  line-height: 1;
  cursor: pointer;
}
.admin-sidebar-fold:hover { color: #fff; background: #3c434a; }
.admin-menu-group { margin-bottom: 0.15rem; }
.admin-menu-section {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  margin: 0;
  padding: 0.55rem 0.75rem 0.25rem;
  border: 0;
  background: transparent;
  font-size: 0.68rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #a7aaad;
  font-weight: 600;
  cursor: pointer;
  text-align: left;
}
.admin-menu-section:hover { color: #fff; }
.admin-menu-caret::before {
  content: "▾";
  font-size: 0.65rem;
  opacity: 0.7;
}
.admin-menu-group.is-collapsed .admin-menu-caret::before { content: "▸"; }
.admin-menu-group.is-collapsed .admin-menu { display: none; }
.admin-menu {
  list-style: none;
  margin: 0;
  padding: 0;
}
.admin-menu a {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.42rem 0.65rem 0.42rem 0.55rem;
  color: #f0f0f1;
  text-decoration: none;
  font-size: 0.88rem;
  border-left: 4px solid transparent;
}
.admin-menu-ico {
  flex: 0 0 1.1rem;
  width: 1.1rem;
  text-align: center;
  opacity: 0.85;
  font-size: 0.78rem;
}
.admin-menu-label { flex: 1; min-width: 0; }
.admin-menu a:hover { background: #2c3338; color: #fff; }
.admin-menu a.is-active {
  background: #2271b1;
  border-left-color: #72aee6;
  color: #fff;
  font-weight: 600;
}
.admin-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.25rem;
  margin-left: auto;
  padding: 0 0.35rem;
  border-radius: 10px;
  background: #d63638;
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  line-height: 1.35;
}
.admin-sidebar-hint {
  margin: 1.1rem 0.75rem 0;
  padding-top: 0.75rem;
  border-top: 1px solid #2c3338;
  color: #8c8f94;
  font-size: 0.72rem;
  line-height: 1.35;
}
.admin-shell.is-folded .admin-menu-section span:first-child,
.admin-shell.is-folded .admin-menu-label,
.admin-shell.is-folded .admin-badge,
.admin-shell.is-folded .admin-sidebar-hint,
.admin-shell.is-folded .admin-menu-caret { display: none; }
.admin-shell.is-folded .admin-menu a {
  justify-content: center;
  padding-left: 0.35rem;
  padding-right: 0.35rem;
}
.admin-shell.is-folded .admin-menu-ico { flex-basis: auto; font-size: 0.95rem; }
.admin-shell.is-folded .admin-sidebar-fold { transform: scaleX(-1); }

.admin-workspace { min-width: 0; background: #f0f0f1; }
.admin-breadcrumbs {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.35rem;
  padding: 0.55rem 1.5rem 0;
  font-size: 0.82rem;
  color: #646970;
}
.admin-breadcrumbs a { color: #2271b1; text-decoration: none; }
.admin-breadcrumbs a:hover { color: #135e96; text-decoration: underline; }
.admin-bc-sep { color: #a7aaad; }
.admin-bc-current { color: #1d2327; font-weight: 600; }
.admin-main {
  padding: 0.75rem 1.35rem 2rem;
  max-width: 1080px;
}
.admin-page-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.5rem 1rem;
  margin-bottom: 0.9rem;
}
.admin-page-head h1 {
  margin: 0;
  font-size: 1.28rem;
  font-weight: 600;
  color: #1d2327;
  letter-spacing: -0.01em;
}
.admin-page-desc {
  margin: 0.2rem 0 0;
  color: #646970;
  font-size: 0.86rem;
  max-width: 40rem;
  line-height: 1.4;
}
.admin-page-actions { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.admin-panel,
.admin-card {
  background: #fff;
  border: 1px solid #dcdcde;
  border-radius: 6px;
  box-shadow: none;
  padding: 0.95rem 1rem;
  margin-bottom: 0.85rem;
}
.admin-panel h2,
.admin-card h2,
.admin-card .h5 {
  font-size: 0.9rem;
  font-weight: 600;
  margin: 0 0 0.75rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid #f0f0f1;
  color: #1d2327;
}
.admin-table {
  margin: 0;
  font-size: 0.86rem;
}
.admin-table thead th {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #646970;
  border-bottom-width: 1px;
  white-space: nowrap;
}
.admin-table td,
.admin-table th {
  padding: 0.55rem 0.6rem;
  vertical-align: middle;
}
.admin-table tbody tr:last-child td { border-bottom: 0; }
.admin-status {
  display: inline-flex;
  align-items: center;
  padding: 0.12rem 0.45rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 600;
  line-height: 1.3;
  background: #f0f0f1;
  color: #50575e;
}
.admin-status.is-pending { background: #fcf0e3; color: #9a6700; }
.admin-status.is-paid_pending { background: #e5f5fa; color: #0a4b78; }
.admin-status.is-completed { background: #edfaef; color: #007017; }
.admin-status.is-rejected { background: #fcf0f1; color: #b32d2e; }
.admin-status.is-cancelled { background: #f0f0f1; color: #646970; }
.admin-empty {
  margin: 0;
  padding: 0.85rem 0.2rem;
  color: #8c8f94;
  font-size: 0.86rem;
}
.admin-actions {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}
.admin-actions .btn { min-width: 4.5rem; }
.admin-at-a-glance {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}
@media (min-width: 900px) {
  .admin-at-a-glance { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
.admin-glance-card {
  display: block;
  background: #fff;
  border: 1px solid #dcdcde;
  border-left: 3px solid #2271b1;
  border-radius: 6px;
  padding: 0.85rem 0.95rem;
  text-decoration: none;
  color: inherit;
  transition: border-color 0.15s ease, background 0.15s ease;
}
.admin-glance-card:hover {
  border-color: #2271b1;
  background: #f6f7f7;
  color: inherit;
}
.admin-glance-card.is-urgent { border-left-color: #d63638; }
.admin-glance-value {
  display: block;
  font-family: "IBM Plex Mono", monospace;
  font-size: 1.45rem;
  font-weight: 600;
  color: #1d2327;
  line-height: 1.15;
}
.admin-glance-label {
  display: block;
  margin-top: 0.25rem;
  color: #646970;
  font-size: 0.8rem;
}
.admin-dash-grid {
  display: grid;
  gap: 0.85rem;
}
@media (min-width: 960px) {
  .admin-dash-grid { grid-template-columns: 1.35fr 1fr; align-items: start; }
}
.admin-shortcut-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.45rem;
}
.admin-shortcut-list li {
  display: grid;
  gap: 0.12rem;
  padding: 0.7rem 0.8rem;
  border: 1px solid #dcdcde;
  border-radius: 6px;
  background: #fff;
}
.admin-shortcut-list a {
  color: #1d2327;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
}
.admin-shortcut-list a:hover { color: #2271b1; }
.admin-shortcut-list span { color: #646970; font-size: 0.8rem; line-height: 1.35; }
.admin-topbar-user {
  color: #a7aaad;
  font-size: 0.82rem;
}
.admin-body .table {
  --bs-table-bg: #fff;
  --bs-table-color: #1d2327;
  --bs-table-border-color: #dcdcde;
  --bs-table-striped-bg: #f6f7f7;
}
.admin-body .panel {
  background: #fff;
  border: 1px solid #c3c4c7;
  border-radius: 4px;
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.04);
  color: #1d2327;
}
.admin-body .muted,
.admin-body .form-label,
.admin-body .form-text,
.admin-body .disclaimer { color: #646970; }
.admin-body .disclaimer { border-left-color: #2271b1; }
.admin-body .empty {
  background: #f6f7f7;
  border-color: #dcdcde;
  color: #646970;
}
.admin-body .form-control,
.admin-body .form-select {
  background: #fff;
  color: #1d2327;
  border-color: #8c8f94;
}
.admin-body .btn-outline-light {
  color: #1d2327;
  border-color: #8c8f94;
}
.admin-body .btn-outline-light:hover {
  background: #f0f0f1;
  color: #1d2327;
  border-color: #8c8f94;
}
.admin-body .btn-ghost {
  color: #1d2327;
  border-color: #8c8f94;
}
.admin-body .btn-accent {
  background: #2271b1;
}
.admin-body .btn-accent:hover { background: #135e96; }
.admin-body .mono { color: #1d2327; }
.admin-body a { color: #2271b1; }
.admin-body .skip-link {
  position: absolute;
  left: -9999px;
}
.admin-body .skip-link:focus {
  left: 0.5rem;
  top: 0.5rem;
  z-index: 100;
  background: #fff;
  color: #1d2327;
  padding: 0.4rem 0.6rem;
}

@media (max-width: 900px) {
  .admin-menu-toggle { display: inline-flex; align-items: center; justify-content: center; }
  .admin-jump { max-width: 8.5rem; }
  .admin-shell,
  .admin-shell.is-folded { grid-template-columns: 1fr; }
  .admin-sidebar-fold { display: none; }
  .admin-sidebar {
    display: none;
    position: absolute;
    z-index: 30;
    top: 32px;
    width: min(280px, 88vw);
    height: calc(100vh - 32px);
    box-shadow: 4px 0 16px rgba(0, 0, 0, 0.2);
  }
  .admin-shell.is-nav-open .admin-sidebar { display: block; }
  .admin-breadcrumbs { padding: 0.55rem 1rem 0; }
  .admin-main { padding: 0.75rem 1rem 2rem; }
}

/* Mall / pets / vanity */
.sb-mall-cats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
}
@media (max-width: 575px) {
  .sb-mall-cats { grid-template-columns: 1fr; }
}
.sb-mall-cat {
  display: block;
  text-decoration: none;
  color: inherit;
  transition: background 0.15s ease, transform 0.15s ease;
}
.sb-mall-cat:hover,
.sb-mall-cat:focus-visible {
  color: inherit;
  text-decoration: none;
  background: rgba(255, 208, 47, 0.06);
  transform: translateY(-1px);
}
.sb-pet-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 0.75rem;
}
.sb-pet-buy .form-select {
  background: #0f1218;
  color: #e2e8f0;
  border-color: rgba(255, 255, 255, 0.12);
}
.sb-pet-img {
  width: 100%;
  max-width: 140px;
  height: auto;
  display: block;
  margin: 0 auto 0.5rem;
  image-rendering: auto;
}
.pet-stage {
  display: inline-flex;
  align-items: flex-end;
  justify-content: center;
  margin: 0 auto 0.5rem;
  cursor: pointer;
  user-select: none;
}
.pet-sprite {
  overflow: hidden;
  position: relative;
  flex: none;
  pointer-events: none;
}
.pet-sheet {
  display: block;
  max-width: none !important;
  height: auto;
  pointer-events: none;
  user-select: none;
  will-change: transform;
}
.sb-vanity-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 0.65rem;
}
.sb-vanity-item {
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  padding: 0.65rem;
  text-align: center;
  background: #0f1218;
}
.sb-vanity-num {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--sb-yellow);
}
.sb-vanity-item.is-sold {
  opacity: 0.55;
}
.sb-vanity-item.is-sold .sb-vanity-num {
  color: rgba(255, 255, 255, 0.45);
}
.sb-corner-pet,
.pet-float {
  position: fixed;
  right: 1rem;
  bottom: 1rem;
  z-index: 40;
  cursor: grab;
  touch-action: none;
  filter: drop-shadow(0 6px 12px rgba(0, 0, 0, 0.45));
}
.sb-corner-pet.is-dragging,
.pet-float.is-dragging {
  cursor: grabbing;
}
.pet-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.15rem;
}
.pet-plate {
  max-width: 5.5rem;
  padding: 0.12rem 0.45rem;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 650;
  line-height: 1.2;
  color: #1a1a1a;
  background: linear-gradient(180deg, #ffe56a 0%, #ffd02f 55%, #e6b800 100%);
  border: 1px solid rgba(0, 0, 0, 0.18);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.35) inset, 0 2px 4px rgba(0, 0, 0, 0.25);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.sb-floor-pet {
  margin: 0.45rem auto 0;
}
.sb-floor-pet .pet-stage {
  margin-bottom: 0;
}
.sb-profile-pets {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}
.sb-profile-pet {
  margin: 0;
  text-align: center;
  width: auto;
  min-width: 4.5rem;
}
.sb-profile-pet .pet-stage {
  margin-bottom: 0.25rem;
}

.admin-perm-form { max-width: 46rem; }
.admin-perm-group {
  margin-bottom: 1.25rem;
  padding: 0.85rem 1rem;
  border: 1px solid var(--line-soft, rgba(255,255,255,0.08));
  border-radius: 8px;
  background: rgba(255,255,255,0.02);
}
.admin-perm-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.35rem;
}
.admin-perm-item {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem 0.65rem;
  margin: 0;
  font-size: 0.9rem;
  cursor: pointer;
}
.admin-perm-item.is-default { opacity: 0.85; cursor: default; }
.admin-perm-key {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.78rem;
  color: #94a3b8;
  min-width: 9.5rem;
}
.admin-perm-label { color: #e2e8f0; }
.admin-perm-tag {
  font-size: 0.68rem;
  padding: 0.1rem 0.4rem;
  border-radius: 4px;
  background: rgba(148, 163, 184, 0.15);
  color: #94a3b8;
}
.admin-perm-tag.is-extra {
  background: rgba(255, 208, 47, 0.15);
  color: var(--sb-yellow, #ffd02f);
}
.admin-subnav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin: 0 0 0.9rem;
}
.admin-subnav a {
  display: inline-flex;
  align-items: center;
  padding: 0.28rem 0.65rem;
  border: 1px solid #dcdcde;
  border-radius: 999px;
  background: #fff;
  color: #1d2327 !important;
  text-decoration: none;
  font-size: 0.8rem;
  font-weight: 600;
}
.admin-subnav a:hover {
  border-color: #2271b1;
  color: #2271b1 !important;
}
.admin-mall-cat {
  margin: 1rem 0 0.55rem;
  font-size: 0.84rem;
  font-weight: 600;
  color: #50575e;
}
.admin-create-box {
  padding: 0.75rem 0.85rem;
  border: 1px dashed #2271b1;
  border-radius: 6px;
  background: #f0f6fc;
}
.admin-inline-edit {
  padding: 0.55rem 0.7rem;
  border: 1px solid #dcdcde;
  border-radius: 6px;
  background: #f6f7f7;
}
.admin-inline-edit-row {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  gap: 0.55rem 0.75rem;
}
.admin-inline-edit-meta {
  min-width: 10rem;
  flex: 1 1 10rem;
}
.admin-inline-edit-row .form-control,
.admin-inline-edit-row .form-select {
  width: 7rem;
  min-width: 5rem;
}
.admin-body .admin-inline-edit .btn-outline-light {
  color: #1d2327;
  border-color: #8c8f94;
}

.admin-vanity-tools {
  display: grid;
  gap: 0.85rem;
  margin-bottom: 1.25rem;
}
@media (min-width: 1100px) {
  .admin-vanity-tools {
    grid-template-columns: 1fr 1fr;
    align-items: start;
  }
}
.admin-vanity-tier {
  margin: 0 0 1.35rem;
  padding: 0;
  border: 1px solid #dcdcde;
  border-radius: 10px;
  background: #fff;
  overflow: hidden;
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.03);
}
.admin-vanity-tier + .admin-vanity-tier {
  margin-top: 1.5rem;
}
.admin-vanity-tier-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.85rem 1.25rem;
  align-items: end;
  padding: 0.9rem 1rem;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}
.admin-vanity-tier-title {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
  color: #1d2327;
}
.admin-vanity-tier-meta {
  margin: 0.2rem 0 0;
  font-size: 0.78rem;
  color: #646970;
}
.admin-vanity-tier-note {
  margin: 0;
  padding: 0.55rem 1rem;
  font-size: 0.78rem;
  color: #50575e;
  background: rgba(255, 255, 255, 0.55);
  border-bottom: 1px dashed rgba(0, 0, 0, 0.06);
}
.admin-vanity-tier-price input {
  width: 9rem;
}
.admin-vanity-tier.is-tier1 .admin-vanity-tier-head {
  background: linear-gradient(90deg, #fff8e5 0%, #fffdf7 100%);
  border-left: 4px solid #dba617;
}
.admin-vanity-tier.is-tier2 .admin-vanity-tier-head {
  background: linear-gradient(90deg, #eef6ff 0%, #f7fbff 100%);
  border-left: 4px solid #2271b1;
}
.admin-vanity-tier.is-tier3 .admin-vanity-tier-head {
  background: linear-gradient(90deg, #f3eefc 0%, #faf8ff 100%);
  border-left: 4px solid #8e44ad;
}
.admin-vanity-tier.is-other .admin-vanity-tier-head {
  background: #f6f7f7;
  border-left: 4px solid #8c8f94;
}
.admin-vanity-rows {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  padding: 0.85rem 1rem 1rem;
}
.admin-vanity-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  align-items: stretch;
  padding: 0.65rem 0.75rem;
  border: 1px solid #dcdcde;
  border-radius: 8px;
  background: #f6f7f7;
}
.admin-vanity-row.is-sold {
  opacity: 0.72;
  background: #f0f0f1;
}
.admin-vanity-row-form {
  flex: 1 1 18rem;
  min-width: 0;
}
.admin-vanity-row-del {
  display: flex;
  align-items: end;
}
.admin-vanity-num {
  display: block;
  font-size: 1.05rem;
  letter-spacing: 0.02em;
}
.admin-vanity-status {
  display: inline-block;
  margin-top: 0.2rem;
  padding: 0.05rem 0.4rem;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  background: #dcdcde;
  color: #2c3338;
}
.admin-vanity-status.is-on_sale {
  background: #dff0d8;
  color: #1e4620;
}
.admin-vanity-status.is-held {
  background: #fff3cd;
  color: #664d03;
}
.admin-vanity-status.is-sold {
  background: #f1d1d1;
  color: #6b1d1d;
}

.checkin-page { width: 100%; max-width: none; }
.checkin-hero-grid {
  display: grid;
  gap: 1.25rem;
  align-items: center;
}
@media (min-width: 720px) {
  .checkin-hero-grid { grid-template-columns: 9rem minmax(0, 1fr); gap: 1.5rem; }
}
.checkin-streak-box { text-align: center; }
.checkin-streak-num {
  font-size: clamp(2.4rem, 5vw, 3rem);
  font-weight: 800;
  line-height: 1;
  color: var(--sb-yellow, #ffd02f);
}
.checkin-streak-label { color: #94a3b8; font-size: 0.9rem; margin-top: 0.35rem; }
.checkin-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
  margin-top: 1.25rem;
}
@media (min-width: 720px) {
  .checkin-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
.checkin-stats > div {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 8px;
  padding: 0.7rem 0.75rem;
  text-align: center;
}
.checkin-stat-val { display: block; font-weight: 700; font-size: 1.15rem; }
.checkin-stat-lbl { display: block; color: #94a3b8; font-size: 0.75rem; margin-top: 0.2rem; }
.checkin-split {
  display: grid;
  gap: 1rem;
  margin-top: 1rem;
  align-items: start;
}
@media (min-width: 900px) {
  .checkin-split { grid-template-columns: minmax(17rem, 0.85fr) minmax(0, 1.35fr); }
}
.checkin-cal-wrap {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 0.35rem;
}
.checkin-cal-head {
  color: #94a3b8;
  font-size: 0.75rem;
  text-align: center;
  line-height: 1.2;
  padding: 0.15rem 0;
}
.checkin-cal-day {
  aspect-ratio: 1;
  max-height: 2.75rem;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: rgba(255,255,255,0.03);
  font-size: 0.85rem;
  color: #cbd5e1;
}
.checkin-cal-day.is-pad { background: transparent; visibility: hidden; }
.checkin-cal-day.is-checked {
  background: rgba(255, 208, 47, 0.18);
  color: var(--sb-yellow, #ffd02f);
  font-weight: 700;
}
.checkin-cal-day.is-today { outline: 1px solid rgba(255, 208, 47, 0.55); }
.checkin-board { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.55rem; }
.checkin-board-row {
  padding: 0.55rem 0.65rem;
  border-radius: 8px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.05);
}
.checkin-board-main {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.5rem;
  align-items: center;
  font-size: 0.9rem;
}
.checkin-board-main a {
  text-decoration: none;
  font-weight: 650;
}
.checkin-board-main a:hover {
  text-decoration: underline;
  text-underline-offset: 0.15em;
}
.checkin-board-msg { margin-top: 0.3rem; color: #94a3b8; font-size: 0.85rem; }
.checkin-chip {
  font-size: 0.72rem;
  padding: 0.1rem 0.4rem;
  border-radius: 999px;
  background: rgba(148,163,184,0.15);
  color: #cbd5e1;
}
.checkin-chip.is-crit {
  background: rgba(255, 208, 47, 0.18);
  color: var(--sb-yellow, #ffd02f);
}
.sb-prop-cats { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.55rem; }
.sb-prop-cat {
  display: grid;
  gap: 0.2rem;
  padding: 0.75rem 0.85rem;
  border-radius: 10px;
  border: 0;
  text-decoration: none !important;
  color: inherit;
  background: rgba(255, 255, 255, 0.035);
  transition: background 0.15s ease, box-shadow 0.15s ease;
}
.sb-prop-cat:hover,
.sb-prop-cat:focus-visible {
  color: inherit;
  text-decoration: none !important;
  background: rgba(255, 208, 47, 0.08);
}
.sb-prop-cat.is-active {
  background: rgba(255, 208, 47, 0.12);
  box-shadow: inset 3px 0 0 var(--sb-yellow);
}
.sb-prop-cat strong,
.sb-prop-cat:hover strong,
.sb-prop-cat.is-active strong {
  text-decoration: none !important;
}
.sb-prop-grid {
  display: grid;
  gap: 0.75rem;
  grid-template-columns: repeat(auto-fill, minmax(14rem, 1fr));
}
.sb-prop-art {
  margin: 0;
  line-height: 0;
}
.sb-prop-art img {
  display: block;
  object-fit: contain;
  background: #0f1218;
  border-radius: 6px;
}
.sb-backpack-prop-art {
  display: inline-block;
  vertical-align: middle;
  margin-right: 0.35rem;
  object-fit: contain;
  border-radius: 4px;
  background: #0f1218;
}
.sb-prop-card {
  padding: 0.85rem;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.08);
  background: rgba(255,255,255,0.02);
}
.sb-prop-inv { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.45rem; }
.sb-prop-inv li,
.sb-prop-inv-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.65rem;
  align-items: center;
  justify-content: space-between;
  padding: 0.55rem 0;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}
.sb-prop-inv-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.65rem;
  align-items: baseline;
  min-width: 12rem;
  flex: 1;
}
.sb-prop-use {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: center;
}
.sb-prop-use .form-select { width: auto; min-width: 7rem; max-width: 14rem; }

/* Name colors — solid */
.sb-name.is-red { color: #f0384b !important; }
.sb-name.is-orange { color: #ff7a2e !important; }
.sb-name.is-yellow { color: #d4af37 !important; }
.sb-name.is-green { color: #51cf66 !important; }
.sb-name.is-cyan { color: #3bc9db !important; }
.sb-name.is-blue { color: #4dabf7 !important; }
.sb-name.is-purple { color: #b197fc !important; }
.sb-name.is-gold { color: #ffd02f !important; }

/* Name colors — animated / FX */
.sb-name.is-rainbow {
  background: linear-gradient(
    90deg,
    #ff4d4d,
    #ff9f1c,
    #ffd43b,
    #40c057,
    #339af0,
    #845ef7,
    #f06595,
    #ff4d4d
  );
  background-size: 200% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent !important;
  font-weight: 600;
  animation: sb-name-rainbow 3s linear infinite;
}
@keyframes sb-name-rainbow {
  0% { background-position: 0% center; }
  100% { background-position: -200% center; }
}
.sb-name.is-neon {
  color: #f3e8ff !important;
  font-weight: 600;
  text-shadow: 0 0 2px #c084fc, 0 0 6px #a855f7, 0 0 12px #9333ea;
  animation: sb-name-neon 2.4s ease-in-out infinite;
}
@keyframes sb-name-neon {
  50% { text-shadow: 0 0 1px rgba(192, 132, 252, 0.55), 0 0 4px rgba(168, 85, 247, 0.4); }
}
.sb-name.is-toon {
  color: #ffd1e8 !important;
  font-weight: 700;
  text-shadow:
    -1px -1px 0 #e64980,
     1px -1px 0 #e64980,
    -1px  1px 0 #e64980,
     1px  1px 0 #e64980,
     0  2px 0 #e64980;
}
.sb-name.is-pop {
  color: #bbf7d0 !important;
  font-weight: 700;
  text-shadow: 1.5px 1.5px 0 #16a34a;
}
.sb-prop-name-preview {
  margin: 0 0 0.75rem;
  font-size: 1.05rem;
}
.sb-prop-name-preview .sb-name { font-size: 1.15rem; }

/* UID badges / vanity capsules */
.sb-uid-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  font-variant-numeric: tabular-nums;
  vertical-align: middle;
  line-height: 1.2;
}
.sb-uid-badge .uid-vanity-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1em;
  font-size: 0.85em;
  font-weight: 800;
}
.sb-uid-badge.is-own,
.sb-uid-badge.is-orange,
.sb-uid-badge.is-gold,
.sb-uid-badge.is-red,
.sb-uid-badge.is-yellow,
.sb-uid-badge.is-green,
.sb-uid-badge.is-cyan,
.sb-uid-badge.is-blue,
.sb-uid-badge.is-purple,
.sb-uid-badge.is-pink,
.sb-uid-badge.is-silver,
.sb-uid-badge.is-rainbow,
.sb-uid-badge.is-neon,
.sb-uid-badge.is-toon {
  padding: 0.12rem 0.45rem 0.12rem 0.28rem;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.78em;
  color: #111;
}
.sb-uid-badge.is-own { background: #ffd02f; color: #111; }
.sb-uid-badge.is-orange { background: linear-gradient(110deg, #ffb347, #e67e22); }
.sb-uid-badge.is-gold { background: linear-gradient(110deg, #ffe7a1, #fcb900); }
.sb-uid-badge.is-red { background: linear-gradient(110deg, #ff6b6b, #c92a2a); color: #fff; }
.sb-uid-badge.is-yellow { background: linear-gradient(110deg, #ffe066, #fab005); color: #5c4800; }
.sb-uid-badge.is-green { background: linear-gradient(110deg, #8ce99a, #2f9e44); color: #052e12; }
.sb-uid-badge.is-cyan { background: linear-gradient(110deg, #66d9e8, #0c8599); color: #043844; }
.sb-uid-badge.is-blue { background: linear-gradient(110deg, #74c0fc, #1c7ed6); color: #062a4a; }
.sb-uid-badge.is-purple { background: linear-gradient(110deg, #b197fc, #7048e8); color: #1b0b45; }
.sb-uid-badge.is-pink { background: linear-gradient(110deg, #ffa8cc, #e64980); color: #4a0b28; }
.sb-uid-badge.is-silver { background: linear-gradient(110deg, #f1f3f5, #adb5bd); color: #212529; }
.sb-uid-badge.is-rainbow {
  color: #111;
  background: linear-gradient(90deg, #ff4d4d, #ff9f1c, #ffd43b, #40c057, #339af0, #845ef7, #f06595, #ff4d4d);
  background-size: 200% 100%;
  animation: sb-uid-rainbow 3s linear infinite;
}
@keyframes sb-uid-rainbow {
  0% { background-position: 0% center; }
  100% { background-position: -200% center; }
}
.sb-uid-badge.is-neon {
  background: #2b1654;
  color: #f3e8ff;
  box-shadow: 0 0 0 1px #a855f7, 0 0 10px rgba(168, 85, 247, 0.65);
  animation: sb-uid-neon 2.4s ease-in-out infinite;
}
@keyframes sb-uid-neon {
  50% { box-shadow: 0 0 0 1px rgba(168, 85, 247, 0.45), 0 0 4px rgba(168, 85, 247, 0.35); }
}
.sb-uid-badge.is-toon {
  background: #ff8ec8;
  color: #fff;
  text-shadow:
    -1px -1px 0 #9d174d,
     1px -1px 0 #9d174d,
    -1px  1px 0 #9d174d,
     1px  1px 0 #9d174d;
}
.sb-uid-badge.is-pop {
  background: #4ade80;
  color: #fff;
  box-shadow: 2px 2px #14532d, inset 0 0 0 1.5px #14532d;
  text-shadow: 1.5px 1.5px 0 #14532d;
}
.sb-prop-uid-preview {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem;
  margin: 0 0 0.75rem;
}
.sb-uid-need {
  color: #ffb4a8;
  padding: 0.4rem 0.55rem;
  border-radius: 6px;
  background: rgba(231, 76, 60, 0.12);
  border: 1px solid rgba(231, 76, 60, 0.28);
}
.sb-uid-terms {
  display: grid;
  gap: 0.35rem;
  margin-bottom: 0.55rem;
}
.sb-uid-term {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.1rem 0.5rem;
  align-items: center;
  padding: 0.5rem 0.65rem;
  border-radius: 10px;
  border: 0;
  background: rgba(255, 255, 255, 0.035);
  cursor: pointer;
  font-size: 0.86rem;
  transition: background 0.15s ease, box-shadow 0.15s ease;
}
.sb-uid-term input { grid-row: span 2; }
/* Follow the checked radio — don't rely on JS .is-active alone. */
.sb-uid-term.is-active,
.sb-uid-term:has(input:checked) {
  background: rgba(255, 208, 47, 0.1);
  box-shadow: inset 3px 0 0 var(--sb-yellow);
}
.sb-uid-term:not(:has(input:checked)) {
  background: rgba(255, 255, 255, 0.035);
  box-shadow: none;
}
.sb-uid-term.is-short { opacity: 0.72; }
.sb-uid-term .mono { color: var(--muted); font-size: 0.8rem; }
.sb-uid-term .mono small { display: block; }
.sb-uid-short { grid-column: 2; color: #ff8e8e; font-size: 0.78rem; }

/* Duo-tone vanity badges */
.sb-uid-duo {
  --t1: #3a3a3a;
  --t2: #0b0b0b;
  --t3: #000;
  --rim1: rgba(255, 255, 255, 0.45);
  --rim2: #888;
  --g1: #fff;
  --g2: #ddd;
  --g3: #999;
  --p1: #1b1f27;
  --p2: #0b0d12;
  --spark: #ffe066;
  display: inline-flex;
  align-items: center;
  height: 18px;
  vertical-align: middle;
  line-height: 1;
}
.sb-uid-duo .uid-duo-tile {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 18px;
  margin-right: -4px;
  border-radius: 4px;
  background: linear-gradient(150deg, var(--t1) 0%, var(--t2) 55%, var(--t3) 100%);
  box-shadow:
    0 0 0 1px var(--rim2),
    inset 0 0 0 1px var(--rim1),
    inset 0 1px 1px rgba(255, 255, 255, 0.35),
    0 1px 2px rgba(0, 0, 0, 0.35);
  font-size: 11.5px;
  font-weight: 800;
}
.sb-uid-duo .uid-duo-tile b {
  background: linear-gradient(180deg, var(--g1), var(--g2) 45%, var(--g3));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-weight: 800;
  filter: drop-shadow(0 1px 0 rgba(0, 0, 0, 0.6));
}
.sb-uid-duo .uid-duo-tile::after {
  content: "";
  position: absolute;
  top: -1px;
  right: -1px;
  width: 7px;
  height: 7px;
  pointer-events: none;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 0C12.8 7.4 16.6 11.2 24 12 16.6 12.8 12.8 16.6 12 24 11.2 16.6 7.4 12.8 0 12 7.4 11.2 11.2 7.4 12 0z' fill='%23fff6ec'/%3E%3C/svg%3E") 50% center / contain no-repeat;
  filter: drop-shadow(0 0 1.5px var(--spark));
}
.sb-uid-duo .uid-duo-plate {
  display: inline-flex;
  align-items: center;
  height: 15px;
  padding: 0 8px;
  border-radius: 0 3px 3px 0;
  background: linear-gradient(180deg, var(--p1), var(--p2));
  clip-path: polygon(0 0, 100% 0, calc(100% - 4px) 100%, 0 100%);
  box-shadow:
    inset 0 1px rgba(255, 255, 255, 0.1),
    inset 0 0 0 1px color-mix(in srgb, var(--g2) 38%, transparent);
}
.sb-uid-duo .uid-duo-plate span {
  background: linear-gradient(180deg, var(--g1), var(--g2) 50%, var(--g3));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.04em;
  font-variant-numeric: tabular-nums;
}
.uid-d-rose { --t1:#3a3a3a; --t2:#0b0b0b; --rim1:rgba(255,214,196,.55); --rim2:#c98a72; --g1:#ffeee4; --g2:#f0b89f; --g3:#c47e64; --p1:#1d2033; --p2:#0c0e1a; --spark:#ffb999; }
.uid-d-champ { --t1:#3a3529; --t2:#0d0b07; --rim1:rgba(255,236,180,.55); --rim2:#c9a25a; --g1:#fff6d8; --g2:#f1cf7a; --g3:#b88a32; --p1:#1f1c14; --p2:#0d0b07; --spark:#ffd27a; }
.uid-d-silver { --t1:#3b3f46; --t2:#101216; --rim1:rgba(235,240,248,.6); --rim2:#a7b0bd; --g1:#fff; --g2:#d5dbe4; --g3:#8d97a5; --p1:#1b1f27; --p2:#0b0d12; --spark:#d9e6ff; }
.uid-d-jade { --t1:#173a2c; --t2:#06140e; --rim1:rgba(197,255,222,.5); --rim2:#4fb184; --g1:#e8fff2; --g2:#8fe3b6; --g3:#3d9a6d; --p1:#0f2a20; --p2:#06140e; --spark:#9dffcf; }
.uid-d-ruby { --t1:#45121b; --t2:#170307; --rim1:rgba(255,200,205,.55); --rim2:#d0596a; --g1:#fff0f1; --g2:#ff9aa6; --g3:#c2394c; --p1:#2a0b11; --p2:#140306; --spark:#ff9aa6; }
.uid-d-sapph { --t1:#14244a; --t2:#050b1b; --rim1:rgba(200,220,255,.55); --rim2:#5b84d6; --g1:#eef4ff; --g2:#9cbcff; --g3:#4a6fc2; --p1:#0f1a38; --p2:#060b1a; --spark:#a9c4ff; }
.uid-d-amethyst { --t1:#2e1648; --t2:#10061c; --rim1:rgba(228,205,255,.55); --rim2:#9a6ad6; --g1:#f8f0ff; --g2:#cfa8ff; --g3:#8a55c9; --p1:#1f0f33; --p2:#0d0517; --spark:#d8b8ff; }
.uid-d-rainbow .uid-duo-tile b,
.uid-d-rainbow .uid-duo-plate span {
  background: linear-gradient(90deg, #ff4d4d, #ff9f1c, #ffd43b, #40c057, #339af0, #845ef7, #f06595, #ff4d4d);
  background-size: 200% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: sb-uid-duo-flow 2.6s linear infinite;
}
.uid-d-rainbow .uid-duo-tile {
  border: 1px solid transparent;
  background:
    linear-gradient(150deg, #2b2b33, #000) padding-box,
    linear-gradient(90deg, #ff4d4d, #ffd43b, #40c057, #339af0, #845ef7, #ff4d4d) border-box;
  background-size: 100% 100%, 200% 100%;
  animation: sb-uid-duo-flow 2.6s linear infinite;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.35), 0 1px 2px rgba(0,0,0,.35);
}
.uid-d-neon { --t1:#2a0f3d; --t2:#12051d; --rim1:rgba(255,170,240,.6); --rim2:#ff4fd8; --g1:#ffe3fb; --g2:#ff8ff0; --g3:#c45cff; --p1:#1c0a2b; --p2:#0c0414; --spark:#ff7ae6; }
.uid-d-neon .uid-duo-tile { animation: sb-uid-neon-tile 2.2s ease-in-out infinite; }
.uid-d-neon .uid-duo-plate span {
  filter: drop-shadow(0 0 3px rgba(255, 79, 216, 0.9));
  animation: sb-uid-neon-text 2.2s ease-in-out infinite;
}
.uid-d-aurora { --t1:#0b2a2e; --t2:#05121a; --rim1:rgba(170,255,230,.55); --rim2:#3fe0c5; --g1:#d9fff6; --g2:#7af0d0; --g3:#8b7bff; --p1:#0a1d24; --p2:#040b10; --spark:#7af0d0; }
.uid-d-aurora .uid-duo-tile b,
.uid-d-aurora .uid-duo-plate span {
  background: linear-gradient(90deg, #7af0d0, #4dabf7, #b197fc, #f783ac, #7af0d0);
  background-size: 300% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: sb-uid-aurora 5s ease-in-out infinite alternate;
}
.uid-d-cyber { --t1:#0a1f2b; --t2:#050c14; --rim1:rgba(0,240,255,.6); --rim2:#ff2bd6; --g1:#e6fdff; --g2:#00f0ff; --g3:#00a8c6; --p1:#0c1220; --p2:#05070e; --spark:#00f0ff; }
.uid-d-cyber .uid-duo-plate {
  box-shadow: inset 0 1px rgba(255,255,255,.08), inset 0 0 0 1px rgba(255,43,214,.55), 0 0 6px rgba(0,240,255,.35);
}
.uid-d-cyber .uid-duo-plate span { animation: sb-uid-glitch 3.2s steps(1) infinite; }
@keyframes sb-uid-duo-flow {
  0% { background-position: 0% center; }
  100% { background-position: -200% center; }
}
@keyframes sb-uid-neon-tile {
  50% { box-shadow: 0 0 0 1px rgba(255,79,216,.45), inset 0 0 0 1px rgba(255,170,240,.35); }
}
@keyframes sb-uid-neon-text {
  50% { filter: drop-shadow(0 0 1px rgba(255,79,216,.5)); }
}
@keyframes sb-uid-aurora {
  0% { background-position: 0% center; }
  100% { background-position: 100% center; }
}
@keyframes sb-uid-glitch {
  0%, 90%, 100% { opacity: 1; filter: none; }
  92% { opacity: .85; filter: hue-rotate(40deg); }
  94% { opacity: 1; transform: translateX(0.5px); }
  96% { opacity: .7; filter: hue-rotate(-30deg); }
}

/* Animated avatar */
.sb-floor-avatar.is-animated,
.sb-topic-avatar.is-animated {
  box-shadow: 0 0 0 2px rgba(255, 208, 47, 0.55), 0 0 12px rgba(125, 255, 179, 0.35);
  animation: sb-avatar-pulse 2.4s ease-in-out infinite;
}
@keyframes sb-avatar-pulse {
  0%, 100% { box-shadow: 0 0 0 2px rgba(255, 208, 47, 0.45), 0 0 8px rgba(125, 255, 179, 0.25); }
  50% { box-shadow: 0 0 0 3px rgba(255, 208, 47, 0.75), 0 0 16px rgba(125, 255, 179, 0.45); }
}

/* Avatar frames (shop preview + equipped) */
.avatar-framed {
  --frame-hole: 0.55;
  position: relative;
  display: inline-grid;
  place-items: center;
  flex-shrink: 0;
  width: 2.75rem;
  height: 2.75rem;
  max-width: 100%;
  box-sizing: border-box;
}
.avatar-framed.is-topic {
  width: 2.75rem;
  height: 2.75rem;
  justify-self: center;
}
.avatar-framed.is-floor {
  width: 5.2rem;
  height: 5.2rem;
}
.avatar-framed.is-hub {
  width: 4.8rem;
  height: 4.8rem;
}
.avatar-framed.is-shop {
  width: 5.5rem;
  height: 5.5rem;
}
.avatar-framed .sb-topic-avatar,
.avatar-framed .sb-floor-avatar,
.avatar-framed .sb-hub-avatar,
.avatar-framed .sb-topic-avatar-img,
.avatar-framed .sb-floor-avatar-img,
.avatar-framed .sb-hub-avatar-img,
.avatar-framed .sb-prop-preview-face {
  width: calc(100% * var(--frame-hole));
  height: calc(100% * var(--frame-hole));
  border-radius: 50%;
  z-index: 1;
  border: 0;
  object-fit: cover;
}
.avatar-framed .sb-hub-avatar.is-fallback {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--avatar-fallback);
  font-weight: 700;
  color: #fff;
  font-size: 1.25rem;
}
.avatar-framed .sb-prop-preview-face {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.1rem;
  color: #fff;
  background: var(--avatar-fallback);
}
.avatar-framed .avatar-frame {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  pointer-events: none;
  z-index: 2;
}
.sb-prop-preview {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  margin: 0 0 0.75rem;
}
.sb-prop-preview-label {
  font-size: 0.72rem;
  color: var(--muted);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.sb-prop-card.has-preview {
  display: flex;
  flex-direction: column;
}
@media (min-width: 768px) {
  .sb-topic-row {
    grid-template-columns: 2.75rem minmax(0, 1fr) 5.5rem;
  }
}

/* Title highlight */
.sb-topic-title.is-hl,
.sb-thread-title.is-hl {
  font-weight: 700;
}
.sb-topic-title.is-hl.is-red,
.sb-thread-title.is-hl.is-red { color: #ff6b6b; }
.sb-topic-title.is-hl.is-orange,
.sb-thread-title.is-hl.is-orange { color: #ff9f43; }
.sb-topic-title.is-hl.is-yellow,
.sb-thread-title.is-hl.is-yellow { color: #ffd02f; }
.sb-topic-title.is-hl.is-green,
.sb-thread-title.is-hl.is-green { color: #7dffb3; }
.sb-topic-title.is-hl.is-cyan,
.sb-thread-title.is-hl.is-cyan { color: #5ee7ff; }
.sb-topic-title.is-hl.is-blue,
.sb-thread-title.is-hl.is-blue { color: #6ec1ff; }
.sb-topic-title.is-hl.is-purple,
.sb-thread-title.is-hl.is-purple { color: #c4a1ff; }
.sb-topic-title.is-hl.is-pink,
.sb-thread-title.is-hl.is-pink { color: #ff8ec8; }
.sb-topic-title.is-hl.is-white,
.sb-thread-title.is-hl.is-white { color: #f8fafc; text-shadow: 0 0 6px rgba(255,255,255,0.35); }
.sb-topic-title.is-hl.is-rainbow,
.sb-thread-title.is-hl.is-rainbow {
  background: linear-gradient(
    90deg,
    #ff4d4d,
    #ff9f1c,
    #ffd43b,
    #40c057,
    #339af0,
    #845ef7,
    #f06595,
    #ff4d4d
  );
  background-size: 200% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: sb-title-rainbow 3s linear infinite;
}
.sb-topic-title.is-hl.is-neon,
.sb-thread-title.is-hl.is-neon {
  color: #f3e8ff;
  text-shadow: 0 0 2px #c084fc, 0 0 8px #a855f7, 0 0 14px #9333ea;
  animation: sb-title-neon 2.4s ease-in-out infinite;
}
@keyframes sb-title-rainbow {
  0% { background-position: 0% center; }
  100% { background-position: -200% center; }
}
@keyframes sb-title-neon {
  50% { text-shadow: 0 0 1px rgba(192,132,252,.55), 0 0 4px rgba(168,85,247,.4); }
}

/* Title highlight shop */
.sb-title-shop {
  padding: 0.85rem 0 0.25rem;
  display: grid;
  gap: 0.85rem;
}
.sb-title-preview {
  display: grid;
  gap: 0.45rem;
  padding: 0.85rem;
  border-radius: 10px;
  border: 0;
  background: rgba(255, 255, 255, 0.035);
}
.sb-title-preview-samples {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.35rem 0.55rem;
}
.sb-title-preview-samples .sb-topic-title {
  font-size: 1.05rem;
}
.sb-title-swatches {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}
.sb-title-swatch {
  width: 1.35rem;
  height: 1.35rem;
  border-radius: 999px;
  border: 2px solid transparent;
  cursor: pointer;
  padding: 0;
}
.sb-title-swatch.is-active {
  border-color: #fff;
  box-shadow: 0 0 0 2px rgba(255,208,47,0.55);
}
.sb-title-swatch.is-red { background: #ff6b6b; }
.sb-title-swatch.is-orange { background: #ff9f43; }
.sb-title-swatch.is-yellow { background: #ffd02f; }
.sb-title-swatch.is-green { background: #7dffb3; }
.sb-title-swatch.is-cyan { background: #5ee7ff; }
.sb-title-swatch.is-blue { background: #6ec1ff; }
.sb-title-swatch.is-purple { background: #c4a1ff; }
.sb-title-swatch.is-pink { background: #ff8ec8; }
.sb-title-swatch.is-white { background: #f8fafc; }
.sb-title-swatch.is-rainbow {
  background: linear-gradient(90deg, #ff4d4d, #ffd43b, #40c057, #339af0, #845ef7, #f06595);
}
.sb-title-swatch.is-neon {
  background: #9333ea;
  box-shadow: 0 0 8px rgba(168,85,247,0.8);
}
.sb-title-terms {
  display: grid;
  gap: 0.45rem;
}
.sb-title-term {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.2rem 0.65rem;
  align-items: center;
  padding: 0.65rem 0.8rem;
  border-radius: 10px;
  border: 0;
  background: rgba(255, 255, 255, 0.035);
  cursor: pointer;
  transition: background 0.15s ease, box-shadow 0.15s ease;
}
.sb-title-term input { grid-row: span 2; }
.sb-title-term.is-active,
.sb-title-term:has(input:checked) {
  background: rgba(255, 208, 47, 0.1);
  box-shadow: inset 3px 0 0 var(--sb-yellow);
}
.sb-title-term:not(:has(input:checked)) {
  background: rgba(255, 255, 255, 0.035);
  box-shadow: none;
}
.sb-title-term.is-short { opacity: 0.72; }
.sb-title-term-label { font-weight: 600; }
.sb-title-term-price { color: var(--muted); font-size: 0.85rem; }
.sb-title-term-price small { display: block; }
.sb-title-term-short {
  grid-column: 2;
  color: #ff8e8e;
  font-size: 0.8rem;
}
.sb-title-buy-row {
  display: flex;
  gap: 0.55rem;
  align-items: center;
  margin-top: 0.45rem;
}
.sb-title-buy-row .form-control {
  width: 3.5rem;
  height: 2.5rem;
  text-align: center;
  background: rgba(255, 255, 255, 0.05);
  border: 0;
  border-radius: 10px;
  color: #fff;
}
.sb-title-buy-row .btn {
  height: 2.5rem;
  border-radius: 10px;
}

/* 牛币总量看板 + 水位池 */
.sb-niu-pool {
  max-width: 56rem;
  margin: 0 auto;
  padding: 1.25rem 0 2.5rem;
  text-align: center;
}
.sb-niu-pool-eyebrow {
  margin: 0 0 0.35rem;
  color: var(--sb-yellow);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.sb-niu-pool-title {
  margin: 0 0 0.45rem;
  font-size: clamp(1.35rem, 3vw, 1.85rem);
  font-weight: 700;
}
.sb-niu-pool-total-line {
  margin: 0 auto 1.25rem;
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}
.sb-niu-pool-blurb {
  margin: 0 auto 1.35rem;
  max-width: 36rem;
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.5;
}
.sb-niu-tank-wrap {
  display: grid;
  grid-template-columns: minmax(10rem, 14rem) minmax(0, 1fr);
  gap: 1rem;
  align-items: stretch;
}
.sb-niu-tank {
  --niu-level: 100%;
  position: relative;
  display: flex;
  gap: 0.45rem;
  align-items: stretch;
  min-height: 18rem;
}
.sb-niu-tank-glass {
  position: relative;
  flex: 1;
  overflow: hidden;
  border-radius: 1.1rem 1.1rem 0.55rem 0.55rem;
  border: 2px solid rgba(180, 200, 220, 0.35);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.06), transparent 28%),
    #0a0c10;
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.05),
    0 12px 28px rgba(0, 0, 0, 0.35);
}
.sb-niu-water {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: var(--niu-level);
  min-height: 0.35rem;
  max-height: 100%;
  background:
    linear-gradient(180deg, rgba(255, 224, 102, 0.95) 0%, #e6b422 38%, #b8860b 100%);
  transition: height 1.1s cubic-bezier(0.22, 0.61, 0.36, 1);
  overflow: hidden;
}
.sb-niu-tank.is-low .sb-niu-water {
  background: linear-gradient(180deg, #ffc14d 0%, #d97706 45%, #92400e 100%);
}
.sb-niu-tank.is-critical .sb-niu-water {
  background: linear-gradient(180deg, #fb7185 0%, #e11d48 50%, #7f1d1d 100%);
}
.sb-niu-wave {
  position: absolute;
  left: -20%;
  width: 140%;
  height: 1.4rem;
  top: -0.7rem;
  border-radius: 40%;
  opacity: 0.55;
  background: rgba(255, 255, 255, 0.28);
  animation: sb-niu-wave 4.5s linear infinite;
}
.sb-niu-wave-b {
  opacity: 0.28;
  top: -0.45rem;
  animation-duration: 6.5s;
  animation-direction: reverse;
}
@keyframes sb-niu-wave {
  from { transform: translateX(0) rotate(0deg); }
  to { transform: translateX(-12%) rotate(6deg); }
}
.sb-niu-bubbles span {
  position: absolute;
  bottom: 8%;
  width: 0.35rem;
  height: 0.35rem;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.45);
  animation: sb-niu-bubble 4s ease-in infinite;
}
.sb-niu-bubbles span:nth-child(1) { left: 18%; animation-delay: 0s; }
.sb-niu-bubbles span:nth-child(2) { left: 36%; width: 0.25rem; height: 0.25rem; animation-delay: 0.8s; }
.sb-niu-bubbles span:nth-child(3) { left: 52%; animation-delay: 1.4s; }
.sb-niu-bubbles span:nth-child(4) { left: 68%; width: 0.28rem; height: 0.28rem; animation-delay: 2.1s; }
.sb-niu-bubbles span:nth-child(5) { left: 82%; animation-delay: 2.8s; }
@keyframes sb-niu-bubble {
  0% { transform: translateY(0) scale(1); opacity: 0; }
  15% { opacity: 0.7; }
  100% { transform: translateY(-9rem) scale(0.5); opacity: 0; }
}
.sb-niu-tank-shine {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(105deg, rgba(255, 255, 255, 0.14) 0%, transparent 28%, transparent 72%, rgba(255, 255, 255, 0.05) 100%);
}
.sb-niu-tank-marks {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 0.35rem 0;
  color: #6b7280;
  font-size: 0.68rem;
  text-align: left;
  min-width: 2.2rem;
}
.sb-niu-board {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 1.35rem 1rem 1.15rem;
  border-radius: 4px;
  border: 1px solid rgba(255, 208, 47, 0.22);
  background:
    linear-gradient(180deg, #1a160c 0%, #0e0e0e 55%, #0a0a0a 100%);
  box-shadow: inset 0 1px 0 rgba(255, 208, 47, 0.08);
}
.sb-niu-board-label {
  margin-bottom: 0.75rem;
  color: #c9b87a;
  font-size: 0.85rem;
  letter-spacing: 0.06em;
}
.sb-niu-digits {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 0.28rem;
  font-variant-numeric: tabular-nums;
}
.sb-niu-digit {
  display: inline-flex;
  width: 1.85rem;
  height: 2.55rem;
  align-items: center;
  justify-content: center;
  border-radius: 3px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: linear-gradient(180deg, #2a2a2a 0%, #111 48%, #1a1a1a 100%);
  box-shadow: inset 0 -2px 0 rgba(0, 0, 0, 0.45);
}
.sb-niu-digit-face {
  color: var(--sb-yellow);
  font-size: 1.55rem;
  font-weight: 700;
  line-height: 1;
  font-family: "Cascadia Mono", "Consolas", "Source Sans 3", monospace;
}
.sb-niu-sep {
  color: #8a7a45;
  font-size: 1.35rem;
  font-weight: 700;
  padding: 0 0.05rem;
}
.sb-niu-board-unit {
  margin: 0.85rem 0 0;
  color: #9a9a9a;
  font-size: 0.85rem;
}
.sb-niu-level-readout {
  margin: 0.55rem 0 0;
  color: #a8abbb;
  font-size: 0.8rem;
}
.sb-niu-meta {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.65rem;
  margin-top: 1rem;
}
.sb-niu-meta > div {
  padding: 0.75rem 0.55rem;
  border-radius: 4px;
  border: 1px solid var(--sb-floor-line, rgba(255, 255, 255, 0.06));
  background: #121212;
}
.sb-niu-meta strong {
  display: block;
  color: #f2f2f2;
  font-size: 1rem;
  font-variant-numeric: tabular-nums;
}
.sb-niu-meta span {
  display: block;
  margin-top: 0.2rem;
  color: #888;
  font-size: 0.75rem;
}
.sb-niu-pool-note {
  margin: 1rem 0 0;
  font-size: 0.82rem;
}
@media (max-width: 800px) {
  .sb-niu-tank-wrap {
    grid-template-columns: 1fr;
    justify-items: center;
  }
  .sb-niu-tank {
    width: min(16rem, 100%);
    min-height: 14rem;
    max-width: 16rem;
    margin: 0;
    box-sizing: border-box;
  }
  .sb-niu-tank-glass {
    flex: 1 1 auto;
    min-width: 9rem;
    width: auto;
  }
  .sb-niu-board {
    width: 100%;
    max-width: 36rem;
    justify-self: stretch;
  }
}
@media (max-width: 640px) {
  .sb-niu-digit {
    width: 1.2rem;
    height: 1.85rem;
  }
  .sb-niu-digit-face { font-size: 0.98rem; }
  .sb-niu-sep { font-size: 0.9rem; padding: 0; }
  .sb-niu-meta {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .sb-niu-digits {
    gap: 0.16rem;
  }
  .sb-niu-board {
    padding: 1rem 0.7rem 0.9rem;
  }
}

.sb-noble-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 0;
  flex: 0 0 auto;
}
.sb-noble-badge img {
  display: block;
  object-fit: contain;
  background: transparent;
}
.sb-noble-badge.is-sm img { width: 1.35rem; height: 1.35rem; }
.sb-noble-badge.is-md img { width: 1.75rem; height: 1.75rem; }
.sb-noble-badge.is-lg img { width: 2.15rem; height: 2.15rem; }

.sb-noble-tiers {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.55rem;
}
@media (max-width: 720px) {
  .sb-noble-tiers { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.sb-noble-tier {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  padding: 0.55rem 0.4rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #0f1218;
  text-align: center;
  opacity: 0.45;
  filter: grayscale(0.7);
}
.sb-noble-tier.is-on {
  opacity: 1;
  filter: none;
}
.sb-noble-tier.is-current {
  border-color: rgba(255, 208, 47, 0.55);
  box-shadow: inset 0 0 0 1px rgba(255, 208, 47, 0.12);
}
.sb-noble-tier img {
  width: 2.4rem;
  height: 2.4rem;
  object-fit: contain;
  background: transparent;
}
.sb-noble-tier > strong {
  font-size: 0.82rem;
}
.sb-noble-tier-needs {
  list-style: none;
  margin: 0.15rem 0 0;
  padding: 0;
  width: 100%;
  display: grid;
  gap: 0.08rem;
}
.sb-noble-tier-needs li {
  display: flex;
  justify-content: space-between;
  gap: 0.35rem;
  font-size: 0.66rem;
  color: var(--muted);
  line-height: 1.2;
}
.sb-noble-tier-needs strong {
  color: var(--text);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.sb-noble-progress {
  margin-top: 0.15rem;
}
.sb-noble-next {
  margin: 0;
}
.sb-recharge-site-earn {
  position: relative;
  overflow: hidden;
  padding: 1rem 1.05rem 1.05rem;
  border-radius: 12px;
  border: 1px solid var(--sb-yellow-border);
  background:
    radial-gradient(120% 90% at 100% 0%, rgba(255, 208, 47, 0.18), transparent 55%),
    linear-gradient(165deg, #1a160c 0%, #12151c 48%, #0f1218 100%);
  box-shadow: inset 0 1px 0 rgba(255, 224, 106, 0.12);
}
.sb-recharge-site-earn::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 3px;
  background: linear-gradient(180deg, #ffe06a 0%, var(--sb-yellow) 55%, transparent 100%);
}
.sb-recharge-site-earn-top {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 0.65rem 1rem;
  margin-bottom: 0.85rem;
  padding-left: 0.35rem;
}
.sb-recharge-site-earn-label {
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 224, 106, 0.72);
  margin-bottom: 0.2rem;
}
.sb-recharge-site-earn-figure {
  display: flex;
  align-items: baseline;
  gap: 0.45rem;
  line-height: 1;
}
.sb-recharge-site-earn-cur {
  font-size: 0.85rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.55);
}
.sb-recharge-site-earn-figure strong {
  font-size: clamp(1.75rem, 4vw, 2.15rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--sb-yellow);
  font-variant-numeric: tabular-nums;
  text-shadow: 0 0 24px rgba(255, 208, 47, 0.22);
}
.sb-recharge-site-earn-orders {
  padding: 0.28rem 0.65rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 208, 47, 0.28);
  background: rgba(0, 0, 0, 0.28);
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.75rem;
  white-space: nowrap;
}
.sb-recharge-site-earn-fx {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.55rem;
  padding-left: 0.35rem;
}
.sb-recharge-site-earn-fx-item {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  padding: 0.55rem 0.65rem;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(0, 0, 0, 0.28);
}
.sb-recharge-site-earn-fx-item span {
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.48);
}
.sb-recharge-site-earn-fx-item strong {
  font-size: 1.05rem;
  font-variant-numeric: tabular-nums;
  color: #fff;
}
.sb-recharge-site-earn-fx-item.is-myr {
  border-color: rgba(255, 208, 47, 0.28);
  background: rgba(255, 208, 47, 0.08);
}
.sb-recharge-site-earn-fx-item.is-myr strong {
  color: var(--sb-yellow);
}
.sb-recharge-site-earn-donate {
  margin: 0.75rem 0 0;
  padding: 0.55rem 0.65rem 0.15rem 0.35rem;
  border-top: 1px solid rgba(255, 208, 47, 0.16);
  font-size: 0.78rem;
  line-height: 1.45;
  color: rgba(255, 224, 106, 0.72);
}
@media (max-width: 520px) {
  .sb-recharge-site-earn-fx {
    grid-template-columns: 1fr;
  }
}
.sb-recharge-mine {
  margin-top: 1.65rem;
  padding-top: 1.25rem;
  border-top: 1px dashed rgba(255, 255, 255, 0.12);
}
.sb-recharge-mine-head {
  margin-bottom: 0.85rem;
}
.sb-recharge-mine-title {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 700;
  color: #e8eaed;
}
.sb-recharge-mine .sb-stat-grid {
  border-color: rgba(125, 211, 252, 0.18);
}
.sb-recharge-mine .sb-recharge-spent-equiv {
  border-color: rgba(125, 211, 252, 0.16);
  background: rgba(14, 28, 40, 0.55);
}
.sb-recharge-spent-equiv {
  list-style: none;
  margin: 0;
  padding: 0.45rem 0.65rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.1rem;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #0f1218;
}
.sb-recharge-spent-equiv li {
  display: flex;
  gap: 0.35rem;
  align-items: baseline;
}
.sb-recharge-spent-equiv strong {
  color: var(--text);
  font-variant-numeric: tabular-nums;
}

.sb-recharge-packs {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(9.5rem, 1fr));
  gap: 0.75rem;
}
.sb-recharge-pack {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  margin: 0;
  padding: 0.9rem 0.85rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #0f1218;
}
.sb-recharge-pack.is-bonus {
  border-color: rgba(255, 208, 47, 0.45);
  box-shadow: inset 0 0 0 1px rgba(255, 208, 47, 0.12);
}
.sb-recharge-pack-niu strong {
  display: block;
  font-size: 1.25rem;
  line-height: 1.1;
}
.sb-recharge-pack-niu span {
  color: var(--muted);
  font-size: 0.78rem;
}
.sb-recharge-pack-bonus {
  color: var(--sb-yellow);
  font-size: 0.75rem;
  font-weight: 700;
}
.sb-recharge-pack-prices {
  list-style: none;
  margin: 0 0 0.2rem;
  padding: 0;
  display: grid;
  gap: 0.12rem;
}
.sb-recharge-pack-prices li {
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
  color: var(--muted);
  font-size: 0.75rem;
  line-height: 1.2;
}
.sb-recharge-pack-prices strong {
  color: var(--text);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.sb-recharge-currency {
  display: block;
  margin-bottom: 0.15rem;
}
.sb-recharge-currency select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #0f1218;
  color: var(--text);
  font-size: 0.78rem;
  padding: 0.28rem 0.4rem;
}
.sb-recharge-ref-hint {
  padding: 0.7rem 0.85rem;
  border-radius: 6px;
  border: 1px dashed rgba(255, 208, 47, 0.45);
  background: rgba(255, 208, 47, 0.08);
  font-weight: 600;
}
.sb-recharge-steps {
  margin: 0 0 1rem;
  padding-left: 1.25rem;
  line-height: 1.55;
}
.sb-recharge-steps li { margin: 0.2rem 0; }
.sb-recharge-proof-img {
  display: block;
  max-width: min(100%, 22rem);
  max-height: 16rem;
  object-fit: contain;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: #0c0d12;
}
.sb-recharge-paid-form .form-control[type="file"] {
  max-width: 28rem;
}
.sb-recharge-status.is-pending { color: #fbbf24; }
.sb-recharge-status.is-paid_pending { color: #38bdf8; }
.sb-recharge-status.is-completed { color: #34d399; }
.sb-recharge-status.is-rejected { color: #f87171; }
.sb-recharge-status.is-cancelled { color: #94a3b8; }
.admin-recharge-proof {
  display: block;
  width: 3.25rem;
  height: 3.25rem;
  object-fit: cover;
  border-radius: 4px;
  border: 1px solid #dcdcde;
  background: #f0f0f1;
}

.sb-danger-box {
  display: inline-block;
  width: fit-content;
  max-width: 100%;
  border: 1px solid #c0392b;
  background: rgba(192, 57, 43, 0.08);
  border-radius: 6px;
  padding: 0.45rem 0.85rem;
}
.sb-danger-box-panel {
  display: block;
  width: auto;
  border-width: 2px;
  background: rgba(192, 57, 43, 0.06);
  padding: 0.75rem 1rem;
}
.sb-danger-box-link {
  display: inline;
  color: #e74c3c;
  font-weight: 600;
  font-size: 0.9rem;
  text-decoration: none;
  white-space: nowrap;
}
.sb-danger-box-link:hover {
  color: #ff6b5e;
  text-decoration: underline;
}

.sb-bank-quote {
  display: grid;
  gap: 0.85rem 1.25rem;
  padding: 1rem 1.1rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(16, 185, 129, 0.08), transparent 55%),
    #0f1218;
}
.sb-bank-quote.is-flat {
  background:
    linear-gradient(180deg, rgba(148, 163, 184, 0.08), transparent 55%),
    #0f1218;
}
.sb-bank-quote.is-empty {
  background: #0f1218;
}
.sb-bank-quote-label {
  display: block;
  color: var(--muted);
  font-size: 0.78rem;
  margin-bottom: 0.2rem;
}
.sb-bank-quote-price {
  font-size: clamp(1.8rem, 4vw, 2.4rem);
  line-height: 1.05;
  font-weight: 800;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}
.sb-bank-quote-unit {
  margin-left: 0.35rem;
  color: var(--muted);
  font-size: 0.9rem;
}
.sb-bank-quote-change {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.35rem 0.65rem;
}
.sb-bank-meter {
  height: 0.28rem;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.06);
  overflow: hidden;
}
.sb-bank-meter span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #34d399, #6ee7b7);
  width: 0;
  transition: width 0.25s linear;
}
.sb-bank-chg {
  font-size: 1.15rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}
.sb-bank-chg-pct {
  font-size: 0.95rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.sb-bank-chg.is-up,
.sb-bank-chg-pct.is-up { color: #34d399; }
.sb-bank-chg.is-flat,
.sb-bank-chg-pct.is-flat { color: #94a3b8; }
.sb-bank-chg-label {
  color: var(--muted);
  font-size: 0.78rem;
}
.sb-bank-quote-meta {
  list-style: none;
  margin: 0;
  padding: 0.55rem 0 0;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.55rem 0.85rem;
}
@media (min-width: 768px) {
  .sb-bank-quote-meta { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
.sb-bank-quote-meta li {
  display: flex;
  flex-direction: column;
  gap: 0.12rem;
  min-width: 0;
}
.sb-bank-quote-meta span {
  color: var(--muted);
  font-size: 0.72rem;
}
.sb-bank-quote-meta strong {
  font-size: 0.9rem;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}
.sb-ledger[data-bank-log] li {
  grid-template-columns: auto minmax(0, 1fr);
  align-items: baseline;
}
.sb-ledger[data-bank-log] li .mono {
  grid-column: 1 / -1;
  font-size: 0.78rem;
}
.sb-ledger[data-bank-log] li .small {
  grid-column: 1 / -1;
}

/* —— Phone + iPad responsive shell —— */
@media (max-width: 991px) {
  .sb-nav-toggle {
    display: inline-flex;
    order: 2;
  }
  .sb-brand { order: 1; }
  .sb-topbar {
    position: relative;
    align-items: center;
    gap: 0.45rem 0.65rem;
    padding-top: max(0.4rem, env(safe-area-inset-top, 0px));
  }
  .sb-top-actions {
    display: none;
    order: 4;
    position: absolute;
    top: calc(100% + 0.2rem);
    left: 0;
    right: 0;
    z-index: 1040;
    flex-direction: column;
    align-items: stretch;
    gap: 0.45rem;
    padding: 0.75rem;
    margin: 0;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 10px;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
  }
  body.sb-nav-open .sb-top-actions {
    display: flex;
  }
  body.sb-nav-open::after {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 1010;
    background: rgba(0, 0, 0, 0.45);
  }
  .sb-header.sticky-top { z-index: 1030; }
  .sb-top-actions .sb-nav-search,
  .sb-top-actions .sb-nav-search-field,
  .sb-top-actions .sb-nav-search .form-control,
  .sb-top-actions .lang-switch,
  .sb-top-actions .sb-nav-logout,
  .sb-top-actions > a.btn,
  .sb-top-actions > form,
  .sb-top-actions .sb-user-link,
  .sb-top-actions .sb-nav-logout .btn {
    width: 100% !important;
    max-width: none !important;
  }
  .sb-nav-search .form-control {
    width: 100%;
    font-size: 16px; /* iOS: avoid zoom on focus */
  }
  .sb-top-actions > a.btn,
  .sb-top-actions .sb-nav-logout .btn {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    min-height: 2.35rem;
  }
  .lang-switch {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.35rem;
  }
  .sb-cat-nav-inline {
    order: 3;
    flex: 1 1 100%;
    width: 100%;
    margin-left: 0;
    padding-left: 0;
    padding-top: 0.25rem;
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    mask-image: linear-gradient(90deg, #000 85%, transparent);
  }
  .sb-topic-row {
    grid-template-columns: 2.75rem minmax(0, 1fr);
    align-items: start;
  }
  .sb-topic-main,
  .sb-topic-title-row,
  .sb-topic-title {
    min-width: 0;
    max-width: 100%;
  }
  .sb-topic-title {
    flex: 1 1 100%;
    word-break: break-word;
    overflow-wrap: anywhere;
  }
  .sb-topic-list {
    overflow: hidden;
  }
  .sb-shell {
    padding-left: max(0.75rem, env(safe-area-inset-left, 0px));
    padding-right: max(0.75rem, env(safe-area-inset-right, 0px));
  }
  .sb-layout {
    gap: 0.7rem;
  }
  .sb-hub-menu {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.35rem 0.55rem;
  }
  .sb-hub-menu li { border-bottom: 0; padding: 0; }
  .sb-hub-tabs {
    overflow-x: auto;
    flex-wrap: nowrap;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .sb-hub-tabs::-webkit-scrollbar { display: none; }
  .sb-recharge-packs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .table-responsive,
  .sb-points-ledger-wrap,
  .reports-table-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  input.form-control,
  select.form-control,
  textarea.form-control,
  .form-control-sm,
  .form-select,
  .form-select-sm {
    font-size: 16px !important;
  }
  .sb-mission-bar {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    align-items: center;
    gap: 0.35rem 0.55rem;
    padding: 0.55rem max(0.75rem, env(safe-area-inset-right, 0px)) 0.55rem max(0.75rem, env(safe-area-inset-left, 0px));
  }
  .sb-mission-bar-label {
    grid-column: 1 / -1;
    font-size: 0.78rem;
    line-height: 1.35;
  }
  .sb-mission-bar-track {
    grid-column: 1 / 2;
    flex: none;
    width: auto;
    min-width: 0;
    max-width: none;
  }
  .sb-mission-bar-pct { grid-column: 2; }
  .sb-mission-bar-go { grid-column: 3; margin-left: 0; }
  .sb-board-picks { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sb-poll-option-row {
    grid-template-columns: minmax(0, 1fr);
  }
  .sb-tool-form {
    position: fixed;
    left: 0.75rem;
    right: 0.75rem;
    top: auto;
    bottom: max(0.75rem, env(safe-area-inset-bottom, 0px));
    width: auto;
    max-height: min(70vh, 28rem);
    overflow: auto;
  }
  .sb-corner-pet,
  .pet-float {
    right: max(0.65rem, env(safe-area-inset-right, 0px));
    bottom: max(0.65rem, env(safe-area-inset-bottom, 0px));
  }
}

@media (max-width: 767px) {
  .sb-brand-text { font-size: 0.9rem; }
  .sb-brand-img { width: 2rem; height: 2rem; }
  .sb-floor-user {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-start;
    text-align: left;
    gap: 0.45rem 0.65rem;
    padding: 0.7rem 0.75rem;
  }
  .sb-floor-avatar-wrap { flex: 0 0 auto; }
  .sb-floor-avatar {
    width: 2.55rem;
    height: 2.55rem;
    font-size: 0.9rem;
    border-radius: 8px;
  }
  .sb-floor-identity {
    align-items: flex-start;
    flex: 1 1 auto;
    min-width: 0;
    gap: 0.2rem;
  }
  .sb-floor-name-row {
    justify-content: flex-start;
    flex: 0 1 auto;
    min-width: 0;
  }
  .sb-floor-uid,
  .sb-floor-level,
  .sb-floor-role {
    flex: 0 0 auto;
  }
  .sb-floor-stats,
  .sb-floor-pet {
    display: none;
  }
  .sb-floor-body {
    padding: 0.75rem;
  }
  .sb-floor-meta {
    flex-wrap: wrap;
    gap: 0.35rem 0.65rem;
  }
  .sb-floor-actions {
    flex-wrap: wrap;
    gap: 0.35rem;
  }
  .sb-tool-btn,
  a.sb-tool-btn,
  .forum-disclose.is-tool > summary {
    min-height: 2rem;
    padding: 0.35rem 0.65rem;
  }
  .sb-hub-identity {
    flex-wrap: wrap;
  }
  .sb-hub-avatar {
    width: 3rem;
    height: 3rem;
  }
  .sb-recharge-packs {
    grid-template-columns: 1fr 1fr;
    gap: 0.55rem;
  }
  .sb-recharge-pack { padding: 0.75rem 0.65rem; }
  .sb-panel { padding: 0.7rem 0.75rem; }
  .page-auth .panel,
  .page-form .panel {
    padding: 1.05rem 0.95rem;
  }
  .sb-bank-quote {
    padding: 0.85rem 0.9rem;
    gap: 0.65rem;
  }
  .sb-bank-quote-price {
    font-size: clamp(1.35rem, 7vw, 1.85rem);
    word-break: break-all;
  }
  .sb-bank-chg { font-size: 1rem; }
  .sb-compose-actions .btn,
  .sb-compose-actions button {
    flex: 1 1 auto;
    min-height: 2.4rem;
  }
  .sb-stat-grid-compact {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .sb-ledger li {
    grid-template-columns: auto minmax(0, 1fr);
    gap: 0.25rem 0.55rem;
  }
  .sb-medal-hall {
    grid-template-columns: 1fr;
  }
  .sb-medal-wall {
    grid-template-columns: repeat(auto-fill, minmax(5.2rem, 1fr));
  }
  .sb-sort-bar {
    gap: 0.35rem 0.85rem;
    overflow-x: auto;
    flex-wrap: nowrap;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .sb-sort-bar::-webkit-scrollbar { display: none; }
  .sb-sort { white-space: nowrap; }
  .page-site .site-container,
  .page-forum .site-container {
    padding-bottom: max(1.25rem, env(safe-area-inset-bottom, 0px));
  }
}

@media (max-width: 480px) {
  .sb-nav-toggle-label { display: none; }
  .sb-recharge-packs {
    grid-template-columns: 1fr;
  }
  .sb-hub-menu {
    grid-template-columns: 1fr;
  }
  .sb-board-picks { grid-template-columns: 1fr; }
  .sb-topic-row {
    padding: 0.55rem 0.7rem;
    gap: 0.4rem 0.55rem;
  }
  .sb-topic-title { font-size: 0.9rem; }
  .sb-bank-quote-meta { grid-template-columns: 1fr; }
  .donate-presets { grid-template-columns: 1fr; }
}

/* iPad portrait / small tablet: keep floors side-by-side, tighten chrome */
@media (min-width: 768px) and (max-width: 991px) {
  .sb-shell {
    padding-left: max(1rem, env(safe-area-inset-left, 0px));
    padding-right: max(1rem, env(safe-area-inset-right, 0px));
  }
  .sb-floor {
    grid-template-columns: 9.5rem minmax(0, 1fr);
  }
  .sb-floor-user {
    padding: 0.85rem 0.55rem;
  }
  .sb-floor-avatar {
    width: 3.25rem;
    height: 3.25rem;
  }
  .sb-recharge-packs {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .sb-mall-cats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .sb-pet-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .sb-vanity-grid {
    grid-template-columns: repeat(auto-fill, minmax(7.5rem, 1fr));
  }
  .sb-stat-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .sb-niu-tank-wrap {
    grid-template-columns: minmax(8rem, 11rem) minmax(0, 1fr);
  }
  .checkin-split {
    grid-template-columns: 1fr;
  }
  .sb-compose-layout .sb-side {
    order: 2;
  }
}

/* —— Site-wide: every page on phone + iPad —— */
img,
svg,
video,
canvas,
iframe {
  max-width: 100%;
}
pre,
.code-block,
.hljs {
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.sb-panel,
.panel,
.sb-hub-main,
.sb-hub-side,
.sb-main,
.sb-side,
.site-main,
.site-container {
  min-width: 0;
  max-width: 100%;
}

@media (max-width: 991px) {
  /* Hub / profile / wallet / bank / mall / recharge */
  .sb-hub,
  .sb-compose-layout,
  .sb-thread-layout {
    gap: 0.75rem;
  }
  .sb-hub-level-row {
    gap: 0.35rem 0.55rem;
  }
  .sb-hub-level-row .ms-auto {
    margin-left: 0 !important;
    width: 100%;
  }
  .sb-level-plate.is-lg { --plate-h: 2.55rem; }
  .sb-profile-tabs,
  .sb-rank-tabs,
  .sb-hub-tabs {
    display: flex;
    flex-wrap: nowrap;
    gap: 0.55rem 0.85rem;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 0.15rem;
  }
  .sb-profile-tabs::-webkit-scrollbar,
  .sb-rank-tabs::-webkit-scrollbar,
  .sb-hub-tabs::-webkit-scrollbar { display: none; }
  .sb-profile-tabs a,
  .sb-rank-tabs a,
  .sb-hub-tabs a {
    flex: 0 0 auto;
    white-space: nowrap;
  }
  .sb-rank-mine {
    flex-wrap: wrap;
    gap: 0.35rem 0.65rem;
  }
  .sb-rank-mine-val {
    flex: 1 1 100%;
    min-width: 0;
    overflow-wrap: anywhere;
  }
  .sb-leader-fiat { overflow-wrap: anywhere; }

  /* Economy grids */
  .sb-mall-cats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .sb-pet-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .sb-vanity-grid {
    grid-template-columns: repeat(auto-fill, minmax(6.5rem, 1fr));
  }
  .sb-noble-tiers {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .sb-recharge-spent-equiv {
    flex-wrap: wrap;
  }
  .sb-prop-inv-meta { min-width: 0; width: 100%; }
  .sb-prop-use {
    width: 100%;
    justify-content: flex-start;
  }
  .sb-prop-use .form-select,
  .sb-prop-use .form-control {
    flex: 1 1 auto;
    min-width: 0;
    max-width: none;
    width: auto;
  }
  .sb-niu-tank-wrap {
    grid-template-columns: 1fr;
    justify-items: center;
    gap: 0.85rem;
  }
  .sb-niu-tank {
    width: min(16rem, 92vw);
    min-height: 14rem;
    max-width: 18rem;
    margin: 0;
    box-sizing: border-box;
  }
  .sb-niu-tank-glass {
    flex: 1 1 auto;
    min-width: 9rem;
    width: auto;
  }
  .sb-niu-board {
    width: 100%;
    max-width: 36rem;
    justify-self: stretch;
  }

  /* Missions / check-in */
  .sb-mission-row {
    flex-direction: column;
    align-items: stretch;
  }
  .sb-mission-meta {
    justify-content: space-between;
    width: 100%;
  }
  .checkin-cal-day {
    max-height: 2.35rem;
    font-size: 0.78rem;
    border-radius: 6px;
  }
  .checkin-cal-wrap { gap: 0.25rem; }

  /* Compose / thread */
  .sb-prize-row {
    grid-template-columns: 1fr;
  }
  .composer-bar {
    width: 100%;
  }
  .composer-tool,
  .composer-attach-label {
    min-height: 2.1rem;
    padding: 0.45rem 0.65rem;
  }
  .sb-compose-actions {
    width: 100%;
  }
  .sb-compose-actions .btn {
    flex: 1 1 calc(50% - 0.35rem);
  }
  .sb-nested-item {
    grid-template-columns: auto minmax(0, 1fr);
  }
  .sb-nested-tools {
    grid-column: 1 / -1;
  }

  /* Auth / forms / content */
  .page-auth .btn,
  .page-form .btn,
  .page-auth .w-100,
  .page-form form .btn[type="submit"] {
    min-height: 2.55rem;
  }
  .page-content .content-article,
  .about-guide,
  .about-sec {
    overflow-wrap: anywhere;
  }
  .donate-sb-amount .input-group {
    flex-wrap: wrap;
  }
  .donate-sb-amount .form-control {
    min-width: 0;
    flex: 1 1 8rem;
  }

  /* Tables everywhere */
  .table-responsive,
  .sb-points-ledger-wrap,
  .reports-table-wrap,
  .feed-table-panel .table-responsive,
  .admin-body .table-responsive {
    display: block;
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  .sb-points-ledger,
  .reports-table-wrap .table,
  table.table {
    min-width: 32rem;
  }

  /* Footer */
  .sb-footer-cols {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .sb-footer-main {
    padding-top: 1.35rem;
    padding-bottom: 1.25rem;
    gap: 1.25rem;
  }

  /* Scanner / tools / reports */
  .scan-box .btn,
  .tool-lookup .btn,
  .page-tool .btn {
    min-height: 2.4rem;
  }
  .page-head {
    flex-direction: column;
    align-items: stretch;
  }
  .page-actions {
    width: 100%;
  }
  .page-actions .btn {
    flex: 1 1 auto;
    justify-content: center;
  }

  /* Floating pet: keep clear of home indicator */
  .sb-corner-pet,
  .pet-float {
    transform: scale(0.92);
    transform-origin: bottom right;
  }
}

@media (max-width: 767px) {
  .sb-mall-cats {
    grid-template-columns: 1fr;
  }
  .sb-pet-grid,
  .sb-noble-tiers,
  .sb-prop-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .sb-vanity-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .sb-vanity-num { font-size: 1.1rem; }
  .sb-stat-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .sb-hub-identity {
    gap: 0.65rem;
  }
  .sb-hub-avatar-col {
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    gap: 0.55rem;
  }
  .sb-avatar-pets {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 0.35rem;
    max-width: none;
  }
  .sb-rank-page { padding: 0.85rem 0.8rem 1rem; }
  .sb-leader-score {
    width: 100%;
  }
  .sb-footer-cols {
    grid-template-columns: 1fr 1fr;
    gap: 1rem 1.1rem;
  }
  .sb-footer-blurb { max-width: none; }
  .about-noble-tiers {
    grid-template-columns: 1fr !important;
  }
  .sb-uid-term {
    grid-template-columns: auto minmax(0, 1fr);
  }
  .checkin-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .sb-thread-title {
    font-size: 1.05rem;
  }
  .sb-thread-stats {
    width: 100%;
    justify-content: flex-start;
  }
  .forum-crumb {
    font-size: 0.82rem;
  }
  .sb-page-back-btn {
    min-height: 2rem;
  }
  /* Bootstrap utility rows used on economy forms */
  .sb-hub .row > [class*="col-"] {
    width: 100%;
    max-width: 100%;
  }
  .sb-hub .d-flex.flex-wrap.gap-2 .btn,
  .sb-hub .d-flex.flex-wrap.gap-2 > a.btn {
    flex: 1 1 auto;
    text-align: center;
    justify-content: center;
  }
}

@media (max-width: 480px) {
  .sb-vanity-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .sb-footer-cols {
    grid-template-columns: 1fr;
  }
  .sb-stat-grid > div,
  .sb-stat-grid > a.sb-stat-link {
    padding: 0.45rem 0.35rem;
  }
  .sb-points-ledger,
  .reports-table-wrap .table,
  table.table {
    min-width: 28rem;
    font-size: 0.8rem;
  }
  .sb-pet-card .btn,
  .sb-vanity-item .btn {
    width: 100%;
  }
  .sb-pet-grid,
  .sb-prop-grid {
    grid-template-columns: 1fr;
  }
  .sb-noble-tiers {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* —— Extra polish: mall / niu pool / wallet / recharge / hub —— */
@media (max-width: 991px) {
  .sb-prop-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .sb-prop-cats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    display: grid;
  }
  .sb-prop-cat { min-height: 100%; }
  .sb-niu-pool {
    padding: 0.75rem 0 max(1.5rem, env(safe-area-inset-bottom, 0px));
  }
  .sb-niu-pool-total-line {
    font-size: 0.95rem;
    overflow-wrap: anywhere;
  }
  .sb-niu-meta {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .sb-niu-meta strong {
    font-size: 0.92rem;
    overflow-wrap: anywhere;
  }
  .sb-title-buy-row {
    flex-wrap: wrap;
  }
  .sb-title-buy-row .btn {
    flex: 1 1 auto;
    min-width: 0;
  }
  .sb-title-preview-samples .sb-topic-title {
    display: block;
    overflow-wrap: anywhere;
  }
  .sb-uid-terms {
    display: grid;
    gap: 0.4rem;
  }
  .sb-recharge-site-earn {
    padding: 0.85rem 0.85rem 0.95rem;
  }
  .sb-recharge-site-earn-figure strong {
    font-size: clamp(1.45rem, 6vw, 1.95rem);
  }
  .sb-recharge-packs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .sb-hub .row.g-3 > [class*="col-"] {
    flex: 0 0 100%;
    max-width: 100%;
  }
  .sb-hub form.d-flex.flex-wrap .form-control,
  .sb-hub form.d-flex.flex-wrap .form-control-sm {
    width: 100%;
    min-width: 0;
  }
  .sb-hub form.d-flex.flex-wrap .btn {
    width: 100%;
  }
  .sb-prop-inv-row {
    align-items: stretch;
  }
  .sb-prop-use {
    width: 100%;
  }
  .sb-prop-use .btn {
    flex: 1 1 auto;
  }
  .sb-vanity-item {
    min-width: 0;
  }
  .sb-vanity-item form .btn {
    width: 100%;
  }
  .sb-pet-card {
    min-width: 0;
  }
  .sb-pet-buy .form-select {
    width: 100%;
  }
  .sb-mall-spend .sb-points-ledger {
    font-size: 0.8rem;
  }
  .page-notifications .list-group-item,
  .sb-notif-list li {
    overflow-wrap: anywhere;
  }
  .support-form .btn,
  .page-support .btn[type="submit"] {
    width: 100%;
    min-height: 2.5rem;
  }
}

@media (max-width: 767px) {
  .sb-prop-cats {
    grid-template-columns: 1fr;
  }
  .sb-niu-tank {
    width: min(14rem, 88vw);
    max-width: 14rem;
    min-height: 12.5rem;
  }
  .sb-niu-tank-glass {
    min-width: 8.5rem;
  }
  .sb-niu-tank-marks {
    font-size: 0.62rem;
    min-width: 1.85rem;
    flex: 0 0 auto;
  }
  .sb-niu-digits {
    gap: 0.12rem;
    max-width: 100%;
  }
  .sb-niu-digit {
    width: clamp(0.95rem, 6.2vw, 1.2rem);
    height: clamp(1.55rem, 9vw, 1.85rem);
  }
  .sb-niu-digit-face {
    font-size: clamp(0.85rem, 4.8vw, 0.98rem);
  }
  .sb-recharge-site-earn-fx {
    grid-template-columns: 1fr;
  }
  .sb-recharge-pack-niu strong {
    font-size: 1.1rem;
  }
  .sb-bank-quote-meta {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .sb-ledger li > .muted.small {
    grid-column: 1 / -1;
  }
  .sb-title-term {
    grid-template-columns: auto minmax(0, 1fr);
  }
  .donate-sb-qrs {
    grid-template-columns: 1fr;
  }
  .donate-sb-qr img {
    max-width: 14rem;
    margin-inline: auto;
  }
}

@media (max-width: 480px) {
  .sb-niu-meta {
    gap: 0.45rem;
  }
  .sb-niu-meta > div {
    padding: 0.55rem 0.4rem;
  }
  .sb-recharge-packs {
    grid-template-columns: 1fr;
  }
  .sb-mall-cat h2 {
    font-size: 1.05rem;
  }
}

