:root {
  --ink: #18221d;
  --ink-soft: #3d4942;
  --muted: #778079;
  --muted-2: #9ba29d;
  --paper: #f5f4ee;
  --surface: #ffffff;
  --surface-soft: #fafaf6;
  --line: #e7e7df;
  --line-strong: #d9dbd1;
  --green: #216b4d;
  --green-deep: #164b37;
  --green-dark: #0e3d2b;
  --green-soft: #e9f3ed;
  --green-pale: #f3f8f4;
  --orange: #e86e4c;
  --orange-soft: #fff0e9;
  --yellow: #f1c75b;
  --blue: #5d86a8;
  --blue-soft: #eaf2f9;
  --violet: #8372a7;
  --red: #d95555;
  --shadow-sm: 0 2px 8px rgba(30, 45, 36, 0.04);
  --shadow-md: 0 12px 34px rgba(33, 54, 42, 0.09);
  --shadow-lg: 0 24px 80px rgba(16, 42, 29, 0.18);
  --serif: "Songti SC", "STSong", "Noto Serif CJK SC", "Source Han Serif SC", serif;
  --sans: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

html[data-theme="dark"],
html.dark,
body.dark {
  --ink: #edf5ef;
  --ink-soft: #c7d4ca;
  --muted: #9eada2;
  --muted-2: #7f8f84;
  --paper: #101713;
  --surface: #19241d;
  --surface-soft: #141d18;
  --line: rgba(216, 235, 221, 0.12);
  --line-strong: rgba(216, 235, 221, 0.2);
  --green: #78c89d;
  --green-deep: #9edbb9;
  --green-dark: #d5f2e1;
  --green-soft: rgba(102, 190, 143, 0.15);
  --green-pale: rgba(102, 190, 143, 0.1);
  --orange-soft: rgba(232, 110, 76, 0.14);
  --blue-soft: rgba(93, 134, 168, 0.14);
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.22);
  --shadow-md: 0 12px 34px rgba(0, 0, 0, 0.28);
  --shadow-lg: 0 24px 80px rgba(0, 0, 0, 0.42);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at 8% 8%, rgba(224, 235, 225, 0.42), transparent 25rem),
    radial-gradient(circle at 93% 24%, rgba(246, 226, 189, 0.3), transparent 25rem),
    var(--paper);
  font-family: var(--sans);
  font-size: 14px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

/* 无障碍：跳转到主内容链接 */
.skip-link {
  position: absolute;
  top: -100%;
  left: 16px;
  z-index: 10000;
  padding: 8px 16px;
  background: var(--green);
  color: #fff;
  text-decoration: none;
  border-radius: 0 0 6px 6px;
  font-size: 13px;
  font-weight: 600;
  transition: top 0.15s ease;
}
.skip-link:focus {
  top: 0;
}

/* 无障碍：仅屏幕阅读器可见 */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

button,
input,
textarea,
select {
  color: inherit;
  font: inherit;
}

button {
  border: 0;
  cursor: pointer;
}

button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid rgba(33, 107, 77, 0.23);
  outline-offset: 2px;
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.56;
}

input,
textarea,
select {
  border: 0;
  outline: 0;
  background: transparent;
}

textarea {
  resize: vertical;
}

h1,
h2,
h3,
p {
  margin: 0;
}

.is-hidden {
  display: none !important;
}

.boot-progress {
  position: fixed;
  z-index: 500;
  top: 0;
  right: 0;
  left: 0;
  height: 3px;
  overflow: hidden;
  background: rgba(33, 107, 77, 0.12);
}

.boot-progress i {
  display: block;
  width: 38%;
  height: 100%;
  border-radius: 3px;
  background: linear-gradient(90deg, transparent, var(--green), transparent);
  animation: boot-loading 1.15s ease-in-out infinite;
}

@keyframes boot-loading {
  from {
    transform: translateX(-110%);
  }
  to {
    transform: translateX(310%);
  }
}

.icon-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.icon {
  width: 20px;
  height: 20px;
  flex: 0 0 auto;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.icon-sprite symbol {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--green);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.14em;
  line-height: 1.3;
  text-transform: uppercase;
}

.eyebrow.light {
  color: rgba(255, 255, 255, 0.7);
}

.live-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #82d7a8;
  box-shadow: 0 0 0 4px rgba(130, 215, 168, 0.13);
  animation: pulse 2.4s infinite;
}

@keyframes pulse {
  50% {
    box-shadow: 0 0 0 7px rgba(130, 215, 168, 0);
  }
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: var(--ink);
  font-family: var(--serif);
  font-size: 19px;
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: 0.03em;
  white-space: nowrap;
}

.brand small {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-family: var(--sans);
  font-size: 7px;
  font-weight: 700;
  letter-spacing: 0.2em;
}

.brand-light {
  position: relative;
  z-index: 2;
  color: #fff;
}

.brand-light small {
  color: rgba(255, 255, 255, 0.48);
}

.brand-mark {
  position: relative;
  display: grid;
  width: 39px;
  height: 39px;
  place-items: center;
  overflow: hidden;
  border-radius: 13px 13px 13px 4px;
  color: #fff;
  background: var(--green);
  box-shadow: 0 7px 16px rgba(33, 107, 77, 0.22);
}

.brand-mark i {
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.16);
}

.brand-mark i:first-child {
  top: -10px;
  right: -7px;
  width: 28px;
  height: 28px;
}

.brand-mark i:nth-child(2) {
  bottom: -12px;
  left: -7px;
  width: 25px;
  height: 25px;
  background: rgba(241, 199, 91, 0.38);
}

.brand-mark b {
  position: relative;
  font-family: Georgia, serif;
  font-size: 27px;
  font-weight: 400;
  font-style: italic;
}

.brand.compact {
  gap: 9px;
  font-size: 17px;
}

.brand.compact .brand-mark {
  width: 32px;
  height: 32px;
  border-radius: 10px 10px 10px 3px;
}

.brand.compact .brand-mark b {
  font-size: 22px;
}

.avatar {
  display: inline-flex;
  width: 38px;
  height: 38px;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  overflow: hidden;
  border: 2px solid rgba(255, 255, 255, 0.9);
  border-radius: 50%;
  color: #24513c;
  background:
    radial-gradient(circle at 68% 20%, rgba(255, 255, 255, 0.75) 0 10%, transparent 11%),
    linear-gradient(140deg, #d8e9da, #a8d4ba);
  font-family: var(--serif);
  font-size: 15px;
  font-weight: 800;
  box-shadow: 0 3px 10px rgba(24, 34, 29, 0.08);
}

.avatar.mint {
  color: #24513c;
  background: linear-gradient(140deg, #d6eadc, #9dccb0);
}

.avatar.peach {
  color: #7a3d2c;
  background: linear-gradient(140deg, #ffe2d6, #f2b196);
}

.avatar.blue {
  color: #34566e;
  background: linear-gradient(140deg, #dbeaf5, #a7c9df);
}

.avatar.violet {
  color: #54456c;
  background: linear-gradient(140deg, #e9e1f3, #c3b3d8);
}

.avatar.yellow {
  color: #735b18;
  background: linear-gradient(140deg, #fff5d6, #efd27a);
}

.avatar-md {
  width: 44px;
  height: 44px;
  font-size: 17px;
}

.avatar-sm {
  width: 34px;
  height: 34px;
  font-size: 13px;
}

.avatar-xs {
  width: 25px;
  height: 25px;
  border-width: 1.5px;
  font-size: 10px;
}

.icon-button {
  display: inline-flex;
  width: 40px;
  height: 40px;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  border-radius: 12px;
  color: var(--ink-soft);
  background: transparent;
  transition: color 0.2s, background 0.2s, transform 0.2s;
}

.icon-button:hover {
  color: var(--green);
  background: var(--green-soft);
}

.icon-button:active {
  transform: scale(0.94);
}

.icon-button.small {
  width: 30px;
  height: 30px;
  border-radius: 9px;
}

.primary-button,
.secondary-button {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 18px;
  border-radius: 11px;
  font-weight: 700;
  transition: transform 0.2s, box-shadow 0.2s, background 0.2s;
}

.primary-button {
  color: #fff;
  background: var(--green);
  box-shadow: 0 8px 20px rgba(33, 107, 77, 0.18);
}

.primary-button:hover {
  background: var(--green-deep);
  box-shadow: 0 10px 24px rgba(33, 107, 77, 0.24);
}

.primary-button:active,
.secondary-button:active {
  transform: translateY(1px);
}

.primary-button .icon {
  width: 17px;
  height: 17px;
}

.primary-button.full {
  width: 100%;
  min-height: 48px;
  justify-content: center;
}

.secondary-button {
  border: 1px solid var(--line-strong);
  color: var(--ink-soft);
  background: var(--surface);
}

.secondary-button:hover {
  border-color: #b9c9bd;
  color: var(--green);
  background: var(--green-pale);
}

.secondary-button .icon {
  width: 17px;
  height: 17px;
}

.text-button,
.inline-link {
  padding: 0;
  color: var(--green);
  background: transparent;
  font-size: inherit;
  font-weight: 700;
}

.text-button:hover,
.inline-link:hover {
  text-decoration: underline;
}

/* Authentication */

.auth-screen {
  display: grid;
  min-height: 100vh;
  grid-template-columns: minmax(0, 1.16fr) minmax(460px, 0.84fr);
  background: var(--paper);
}

.auth-visual {
  position: relative;
  display: flex;
  min-height: 100vh;
  flex-direction: column;
  overflow: hidden;
  padding: 42px clamp(42px, 6vw, 92px);
  color: #fff;
  background:
    radial-gradient(circle at 82% 22%, rgba(91, 146, 112, 0.38), transparent 26%),
    radial-gradient(circle at 14% 88%, rgba(238, 192, 83, 0.12), transparent 26%),
    linear-gradient(145deg, #174c37 0%, #103d2c 58%, #0b3023 100%);
}

.auth-visual::before {
  position: absolute;
  right: -140px;
  bottom: -280px;
  width: 590px;
  height: 590px;
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 50%;
  content: "";
}

.auth-visual::after {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0.25;
  background-image: radial-gradient(rgba(255, 255, 255, 0.25) 0.6px, transparent 0.6px);
  background-size: 17px 17px;
  content: "";
  -webkit-mask-image: linear-gradient(120deg, #000, transparent 55%);
  mask-image: linear-gradient(120deg, #000, transparent 55%);
}

.auth-copy {
  position: relative;
  z-index: 2;
  width: min(560px, 88%);
  margin: auto 0;
  padding: 36px 0 76px;
}

.auth-copy h1 {
  margin: 20px 0 24px;
  font-family: var(--serif);
  font-size: clamp(42px, 5vw, 68px);
  font-weight: 800;
  line-height: 1.22;
  letter-spacing: -0.035em;
}

.auth-copy h1 span {
  position: relative;
  display: inline-block;
  color: #f5d477;
}

.auth-copy h1 span::after {
  position: absolute;
  right: -4px;
  bottom: -5px;
  left: 2px;
  height: 7px;
  border-radius: 50%;
  background: rgba(245, 212, 119, 0.34);
  content: "";
  transform: rotate(-1deg);
}

.auth-copy > p {
  max-width: 460px;
  color: rgba(255, 255, 255, 0.64);
  font-size: 15px;
  line-height: 1.9;
}

.auth-stats {
  display: flex;
  gap: 0;
  margin-top: 40px;
}

.auth-stats div {
  display: flex;
  min-width: 105px;
  flex-direction: column;
  padding: 0 25px;
  border-left: 1px solid rgba(255, 255, 255, 0.14);
}

.auth-stats div:first-child {
  padding-left: 0;
  border-left: 0;
}

.auth-stats strong {
  font-family: Georgia, serif;
  font-size: 21px;
  font-weight: 500;
}

.auth-stats span {
  margin-top: 4px;
  color: rgba(255, 255, 255, 0.45);
  font-size: 10px;
}

.visual-note {
  position: absolute;
  z-index: 3;
  display: flex;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.1);
  box-shadow: 0 18px 50px rgba(4, 24, 15, 0.17);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
}

.visual-note.note-one {
  right: clamp(36px, 5vw, 78px);
  bottom: 20%;
  align-items: center;
  gap: 11px;
  width: 258px;
  padding: 13px 14px;
  transform: rotate(2.5deg);
  animation: float-one 7s ease-in-out infinite;
}

.visual-note.note-one div {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.visual-note.note-one strong {
  overflow: hidden;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.visual-note.note-one small {
  margin-top: 3px;
  color: rgba(255, 255, 255, 0.48);
  font-size: 9px;
}

.mini-avatar {
  display: grid;
  width: 32px;
  height: 32px;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 50%;
  color: #21523b;
  background: linear-gradient(140deg, #d8eddd, #8ec5a4);
  font-family: var(--serif);
  font-size: 12px;
  font-weight: 800;
}

.note-heart {
  margin-left: auto;
  color: #f4c75f;
  font-size: 9px;
}

.visual-note.note-two {
  top: 20%;
  right: clamp(26px, 3vw, 52px);
  width: 205px;
  flex-direction: column;
  padding: 17px 18px;
  transform: rotate(-2deg);
  animation: float-two 8s ease-in-out infinite;
}

.quote-mark {
  height: 20px;
  color: #f0cc72;
  font-family: Georgia, serif;
  font-size: 35px;
  line-height: 1;
}

.visual-note.note-two p {
  margin: 5px 0 9px;
  font-family: var(--serif);
  font-size: 12px;
  line-height: 1.6;
}

.visual-note.note-two small {
  color: rgba(255, 255, 255, 0.44);
  font-size: 8px;
}

@keyframes float-one {
  50% {
    transform: translateY(-8px) rotate(1.5deg);
  }
}

@keyframes float-two {
  50% {
    transform: translateY(7px) rotate(-1deg);
  }
}

.visual-orbit {
  position: absolute;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 50%;
}

.orbit-one {
  right: -30px;
  bottom: -110px;
  width: 430px;
  height: 430px;
}

.orbit-two {
  right: 35px;
  bottom: -32px;
  width: 260px;
  height: 260px;
}

.auth-visual-foot {
  position: relative;
  z-index: 2;
  color: rgba(255, 255, 255, 0.28);
  font-size: 9px;
  letter-spacing: 0.12em;
}

.auth-panel {
  display: grid;
  min-height: 100vh;
  place-items: center;
  padding: 38px clamp(28px, 5vw, 78px);
  background:
    radial-gradient(circle at 90% 10%, rgba(231, 235, 222, 0.7), transparent 18rem),
    var(--paper);
}

.auth-card {
  width: min(100%, 410px);
}

.auth-mobile-brand {
  display: none;
}

.auth-heading {
  margin-bottom: 22px;
}

.auth-heading h2 {
  margin: 10px 0 7px;
  font-family: var(--serif);
  font-size: 30px;
  font-weight: 800;
  line-height: 1.3;
  letter-spacing: -0.025em;
}

.auth-heading p {
  color: var(--muted);
  font-size: 12px;
}

.auth-tabs {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  margin-bottom: 20px;
  border-bottom: 1px solid var(--line-strong);
}

.auth-tab {
  position: relative;
  padding: 10px 8px 13px;
  color: var(--muted);
  background: transparent;
  font-weight: 700;
}

.auth-tab::after {
  position: absolute;
  right: 19%;
  bottom: -1px;
  left: 19%;
  height: 2px;
  border-radius: 2px;
  background: transparent;
  content: "";
  transition: background 0.2s;
}

.auth-tab.active {
  color: var(--ink);
}

.auth-tab.active::after {
  background: var(--green);
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 7px;
  color: var(--ink-soft);
  font-size: 11px;
  font-weight: 700;
}

.field > span {
  padding-left: 1px;
}

.input-wrap {
  display: flex;
  height: 46px;
  align-items: center;
  gap: 10px;
  padding: 0 13px;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.76);
  transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}

.input-wrap:focus-within {
  border-color: rgba(33, 107, 77, 0.65);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(33, 107, 77, 0.08);
}

.input-wrap .icon {
  width: 17px;
  height: 17px;
  color: var(--muted-2);
}

.input-wrap input,
.input-wrap select {
  width: 100%;
  height: 100%;
  font-size: 12px;
}

.input-wrap input::placeholder,
.field textarea::placeholder,
.post-title-input::placeholder,
.post-body-input::placeholder {
  color: #a9aea9;
}

.select-wrap {
  position: relative;
}

.select-wrap::after {
  position: absolute;
  right: 12px;
  color: var(--muted);
  content: "";
  pointer-events: none;
}

.select-wrap select {
  appearance: none;
  -webkit-appearance: none;
}

.password-toggle {
  padding: 4px 2px;
  color: var(--muted);
  background: transparent;
  font-size: 10px;
  font-weight: 700;
}

.form-options {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: -2px;
  color: var(--muted);
  font-size: 10px;
}

.check-row {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 500;
}

.check-row input {
  width: 14px;
  height: 14px;
  margin: 0;
  accent-color: var(--green);
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.agreement {
  align-items: flex-start;
  line-height: 1.5;
}

.agreement input {
  margin-top: 1px;
}

.inline-link {
  font-size: inherit;
}

.form-error {
  min-height: 0;
  margin: -3px 0 -2px;
  color: var(--red);
  font-size: 10px;
  line-height: 1.4;
}

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

/* 密码强度指示器 */
.password-strength {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 4px;
  padding: 0 2px;
}
.password-strength:empty {
  display: none;
}
.strength-bars {
  display: flex;
  gap: 3px;
  flex-shrink: 0;
}
.strength-bar {
  width: 28px;
  height: 3px;
  border-radius: 2px;
  background: #e5e7eb;
  transition: background 0.2s ease;
}
.strength-text {
  font-size: 10px;
  line-height: 1.3;
  color: var(--muted-2);
}

.demo-login {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  margin-top: 19px;
  padding-top: 17px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 10px;
}

.demo-login button {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 0;
  color: var(--green);
  background: transparent;
  font-size: 10px;
  font-weight: 700;
}

.demo-login .icon {
  width: 13px;
  height: 13px;
}

.local-note {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  margin-top: 15px;
  color: #a0a49f;
  font-size: 8px;
}

.local-note .icon {
  width: 12px;
  height: 12px;
}

/* App shell */

.app {
  display: grid;
  width: 100%;
  max-width: 1420px;
  min-height: 100vh;
  grid-template-columns: 224px minmax(520px, 1fr) 290px;
  gap: 26px;
  margin: 0 auto;
  padding: 22px 26px 42px;
}

.sidebar {
  position: sticky;
  top: 20px;
  display: flex;
  height: calc(100vh - 44px);
  min-height: 640px;
  flex-direction: column;
  padding: 12px 4px 8px 0;
}

.sidebar-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 5px;
}

.sidebar-menu {
  display: none;
}

.main-nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-top: 30px;
}

.nav-item {
  position: relative;
  display: flex;
  width: 100%;
  height: 45px;
  align-items: center;
  gap: 13px;
  padding: 0 14px;
  border-radius: 12px;
  color: #5f6963;
  background: transparent;
  font-size: 12px;
  font-weight: 600;
  text-align: left;
  transition: background 0.2s, color 0.2s;
}

.nav-item:hover {
  color: var(--green);
  background: rgba(255, 255, 255, 0.6);
}

.nav-item.active {
  color: var(--green-deep);
  background: #fff;
  box-shadow: var(--shadow-sm);
}

.nav-item.active::before {
  position: absolute;
  left: 0;
  width: 3px;
  height: 17px;
  border-radius: 0 3px 3px 0;
  background: var(--green);
  content: "";
}

.nav-item .icon {
  width: 19px;
  height: 19px;
}

.admin-data-nav {
  margin-top: 7px;
  border: 1px solid rgba(179, 204, 189, 0.72);
  color: var(--green-deep);
  background: rgba(236, 247, 240, 0.72);
}

.refresh-control.refreshing .icon {
  animation: refresh-spin 0.8s linear infinite;
}

.refresh-control:disabled {
  cursor: wait;
  opacity: 0.72;
}

@keyframes refresh-spin {
  to {
    transform: rotate(360deg);
  }
}

.pull-refresh-indicator {
  position: fixed;
  z-index: 38;
  top: calc(64px + env(safe-area-inset-top));
  left: 50%;
  display: none;
  align-items: center;
  gap: 6px;
  padding: 7px 11px;
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 999px;
  color: var(--green-deep);
  background: rgba(255, 255, 255, 0.84);
  box-shadow: var(--shadow-sm);
  font-size: 8px;
  opacity: 0.92;
  transform: translate(-50%, 0);
  transition: transform 0.15s ease;
  backdrop-filter: blur(14px);
}

.pull-refresh-indicator .icon {
  width: 13px;
  height: 13px;
}

.pull-refresh-indicator.ready {
  color: #fff;
  background: var(--green);
}

.mention-menu {
  position: fixed;
  z-index: 260;
  width: min(220px, calc(100vw - 20px));
  overflow: hidden;
  padding: 5px;
  border: 1px solid rgba(255, 255, 255, 0.78);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 16px 40px rgba(26, 54, 37, 0.2);
  backdrop-filter: blur(18px) saturate(140%);
}

.mention-menu button {
  display: flex;
  width: 100%;
  align-items: center;
  gap: 8px;
  padding: 7px;
  border-radius: 8px;
  background: transparent;
  text-align: left;
}

.mention-menu button:hover {
  background: var(--green-pale);
}

.mention-menu button > span:last-child {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.mention-menu strong {
  font-size: 9px;
}

.mention-menu small {
  color: var(--muted);
  font-size: 7px;
}

.nav-badge {
  display: grid;
  min-width: 19px;
  height: 19px;
  place-items: center;
  margin-left: auto;
  padding: 0 5px;
  border-radius: 10px;
  color: #fff;
  background: var(--orange);
  font-size: 8px;
}

.sidebar-section {
  margin-top: 27px;
}

.sidebar-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 11px 10px;
  color: #9a9f9a;
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.sidebar-label button {
  display: grid;
  place-items: center;
  padding: 0;
  color: inherit;
  background: transparent;
}

.sidebar-label .icon {
  width: 15px;
  height: 15px;
}

.board-link {
  display: flex;
  width: 100%;
  height: 39px;
  align-items: center;
  gap: 11px;
  padding: 0 10px;
  border-radius: 9px;
  color: var(--ink-soft);
  background: transparent;
  font-size: 11px;
  font-weight: 600;
  text-align: left;
  transition: background 0.2s;
}

.board-link:hover {
  background: rgba(255, 255, 255, 0.68);
}

.board-link small {
  margin-left: auto;
  color: #a1a6a1;
  font-size: 8px;
  font-weight: 400;
}

.board-dot {
  display: grid;
  width: 22px;
  height: 22px;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 7px 7px 7px 3px;
  font-family: Georgia, serif;
  font-size: 9px;
  font-weight: 700;
}

.grade-one {
  color: #276248 !important;
  background: #dfeee3;
}

.grade-two {
  color: #a25138 !important;
  background: #fae6de;
}

.grade-three {
  color: #496e8c !important;
  background: #e4edf4;
}

.general {
  color: #846a23 !important;
  background: #f7edcb;
}

.sidebar-compose {
  display: flex;
  width: 100%;
  min-height: 43px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 21px;
  border-radius: 11px;
  color: #fff;
  background: var(--green);
  font-size: 11px;
  font-weight: 700;
  box-shadow: 0 8px 20px rgba(33, 107, 77, 0.15);
}

.sidebar-compose:hover {
  background: var(--green-deep);
}

.sidebar-compose .icon {
  width: 17px;
  height: 17px;
}

.sidebar-footer {
  margin-top: auto;
}

.sidebar-profile {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 13px 8px;
  border-top: 1px solid var(--line);
}

.avatar-wrap {
  padding: 0;
  border-radius: 50%;
  background: transparent;
}

.sidebar-user-copy {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
  align-items: flex-start;
  padding: 0;
  background: transparent;
}

.sidebar-user-copy strong {
  max-width: 100%;
  overflow: hidden;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sidebar-user-copy span {
  margin-top: 2px;
  color: var(--muted);
  font-size: 8px;
}

.community-rule {
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 3px 4px 0;
  padding: 11px 12px;
  border: 1px solid #e3e6db;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.45);
}

.community-rule .icon {
  width: 16px;
  height: 16px;
  color: var(--green);
}

.community-rule div {
  display: flex;
  flex-direction: column;
}

.community-rule strong {
  font-size: 9px;
}

.community-rule span {
  margin-top: 2px;
  color: var(--muted);
  font-size: 7px;
}

.main-content {
  min-width: 0;
  padding-top: 8px;
}

.view {
  animation: view-in 0.28s ease both;
}

@keyframes view-in {
  from {
    opacity: 0;
    transform: translateY(4px);
  }
}

.page-toolbar {
  display: flex;
  min-height: 55px;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 14px;
}

.page-toolbar h1 {
  margin-top: 4px;
  font-family: var(--serif);
  font-size: 27px;
  font-weight: 800;
  line-height: 1.25;
  letter-spacing: -0.02em;
}

.toolbar-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.search-trigger {
  display: flex;
  width: 244px;
  height: 39px;
  align-items: center;
  gap: 8px;
  padding: 0 10px 0 13px;
  border: 1px solid var(--line);
  border-radius: 11px;
  color: #949b96;
  background: rgba(255, 255, 255, 0.68);
  text-align: left;
  transition: border-color 0.2s, background 0.2s;
}

.search-trigger:hover {
  border-color: #c7d0c8;
  background: #fff;
}

.search-trigger .icon {
  width: 16px;
  height: 16px;
}

.search-trigger span {
  flex: 1;
  overflow: hidden;
  font-size: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.search-trigger kbd {
  padding: 2px 5px;
  border: 1px solid var(--line);
  border-radius: 4px;
  color: #a0a6a1;
  background: #f8f8f4;
  font-family: var(--sans);
  font-size: 7px;
}

.notification-button {
  position: relative;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.68);
}

.notification-dot {
  position: absolute;
  top: 8px;
  right: 8px;
  display: none;
  width: 6px;
  height: 6px;
  border: 1.5px solid #fff;
  border-radius: 50%;
  background: var(--orange);
}

.notification-dot.visible {
  display: block;
}

.category-tabs {
  display: flex;
  gap: 4px;
  margin-bottom: 15px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.58);
  overflow-x: auto;
  scrollbar-width: none;
}

.mailbox-notice {
  position: relative;
  display: flex;
  min-height: 86px;
  align-items: center;
  gap: 15px;
  margin: 0 0 14px;
  overflow: hidden;
  padding: 15px 18px;
  border: 1px solid rgba(126, 183, 148, 0.46);
  border-radius: 16px;
  background:
    radial-gradient(circle at 91% 18%, rgba(166, 219, 187, 0.42), transparent 30%),
    radial-gradient(circle at 5% 120%, rgba(172, 211, 231, 0.24), transparent 36%),
    linear-gradient(125deg, rgba(248, 253, 249, 0.92), rgba(233, 244, 239, 0.78));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.96),
    0 10px 30px rgba(31, 91, 56, 0.1);
  backdrop-filter: blur(22px) saturate(145%);
  -webkit-backdrop-filter: blur(22px) saturate(145%);
}

.mailbox-notice-copy {
  position: relative;
  z-index: 1;
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
}

.mailbox-notice-copy strong {
  margin-top: 4px;
  color: #326048;
  font-family: var(--serif);
  font-size: 24px;
  line-height: 1.25;
  letter-spacing: 0.02em;
}

.mailbox-notice-copy p {
  margin-top: 3px;
  color: #697c6f;
  font-size: 9px;
}

.mailbox-notice-icon {
  position: relative;
  z-index: 1;
  display: grid;
  width: 52px;
  height: 52px;
  flex: 0 0 auto;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.84);
  border-radius: 18px 18px 18px 6px;
  background: rgba(255, 255, 255, 0.56);
  box-shadow: 0 8px 22px rgba(31, 91, 56, 0.12);
  color: var(--green);
}

.mailbox-notice-icon .icon {
  width: 25px;
  height: 25px;
}

.mailbox-notice-action {
  position: relative;
  z-index: 1;
  flex: 0 0 auto;
  min-height: 34px;
  padding: 0 13px;
  border: 1px solid rgba(255, 255, 255, 0.76);
  border-radius: 10px;
  color: #fff;
  background: linear-gradient(135deg, #4a9d71, #236b4b);
  box-shadow: 0 7px 18px rgba(34, 107, 74, 0.2);
  font-size: 9px;
  font-weight: 700;
}

.mailbox-notice-mark {
  position: absolute;
  right: 18px;
  bottom: -4px;
  color: rgba(43, 97, 67, 0.055);
  font-family: Georgia, serif;
  font-size: 28px;
  font-weight: 700;
  line-height: 0.82;
  text-align: right;
  letter-spacing: -0.03em;
  pointer-events: none;
}

.category-tabs::-webkit-scrollbar {
  display: none;
}

.category-tab {
  min-width: 65px;
  height: 33px;
  flex: 1;
  padding: 0 12px;
  border-radius: 8px;
  color: var(--muted);
  background: transparent;
  font-size: 10px;
  font-weight: 600;
  white-space: nowrap;
  transition: background 0.2s, color 0.2s, box-shadow 0.2s;
}

.category-tab:hover {
  color: var(--ink);
}

.category-tab.active {
  color: var(--green-deep);
  background: #fff;
  box-shadow: 0 2px 8px rgba(26, 48, 35, 0.07);
  font-weight: 700;
}

.board-intro {
  position: relative;
  display: flex;
  min-height: 171px;
  overflow: hidden;
  border-radius: 16px;
  color: #fff;
  background:
    radial-gradient(circle at 84% 24%, rgba(107, 158, 125, 0.4), transparent 28%),
    linear-gradient(125deg, #1a573e, #123f2d);
  box-shadow: 0 12px 28px rgba(26, 70, 49, 0.12);
  transition: background 0.3s;
}

.board-intro::after {
  position: absolute;
  right: -31px;
  bottom: -95px;
  width: 260px;
  height: 260px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 50%;
  content: "";
}

.board-intro[data-category="高一"] {
  background:
    radial-gradient(circle at 84% 24%, rgba(132, 181, 145, 0.35), transparent 28%),
    linear-gradient(125deg, #2f6b4d, #1c4936);
}

.board-intro[data-category="高二"] {
  background:
    radial-gradient(circle at 84% 24%, rgba(238, 161, 117, 0.3), transparent 28%),
    linear-gradient(125deg, #894f39, #603426);
}

.board-intro[data-category="高三"] {
  background:
    radial-gradient(circle at 84% 24%, rgba(116, 159, 192, 0.36), transparent 28%),
    linear-gradient(125deg, #345d79, #213e54);
}

.board-intro[data-category="通用"] {
  background:
    radial-gradient(circle at 84% 24%, rgba(236, 199, 92, 0.35), transparent 28%),
    linear-gradient(125deg, #6c5925, #4c3d15);
}

.board-intro-copy {
  position: relative;
  z-index: 2;
  width: 70%;
  padding: 22px 0 20px 25px;
}

.board-intro h2 {
  max-width: 470px;
  margin: 7px 0 7px;
  font-family: var(--serif);
  font-size: clamp(18px, 2.1vw, 23px);
  font-weight: 700;
  line-height: 1.42;
  letter-spacing: 0.005em;
}

.board-intro p {
  color: rgba(255, 255, 255, 0.6);
  font-size: 9px;
  line-height: 1.65;
}

.board-topics {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 12px;
}

.board-topics span {
  padding: 3px 8px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 20px;
  color: rgba(255, 255, 255, 0.68);
  background: rgba(255, 255, 255, 0.06);
  font-size: 8px;
}

.board-art {
  position: absolute;
  top: 0;
  right: 0;
  width: 29%;
  height: 100%;
}

.orbit-copy {
  position: absolute;
  top: 31px;
  right: 25px;
  color: rgba(255, 255, 255, 0.07);
  font-family: Georgia, serif;
  font-size: 27px;
  font-style: italic;
  font-weight: 700;
  line-height: 0.9;
  text-align: right;
}

.art-bubble {
  position: absolute;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.08);
  box-shadow: 0 9px 30px rgba(0, 0, 0, 0.1);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.bubble-a {
  top: 29px;
  left: 28px;
  width: 57px;
  height: 57px;
  border-radius: 20px 20px 20px 6px;
  transform: rotate(-7deg);
}

.bubble-b {
  right: 37px;
  bottom: 25px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  color: #f6cf72;
  transform: rotate(8deg);
}

.bubble-c {
  right: 30px;
  bottom: 73px;
  width: 42px;
  height: 34px;
  border-radius: 11px 11px 11px 4px;
  color: #fff;
  font-family: Georgia, serif;
  font-size: 12px;
  font-style: italic;
}

.quick-compose {
  display: flex;
  min-height: 63px;
  align-items: center;
  gap: 12px;
  margin-top: 14px;
  padding: 9px 11px 9px 14px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.76);
  box-shadow: var(--shadow-sm);
  cursor: text;
  transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}

.quick-compose:hover {
  border-color: #c8d1c9;
  background: #fff;
  box-shadow: 0 7px 20px rgba(26, 48, 35, 0.07);
}

.compose-placeholder {
  flex: 1;
  color: #9ea39f;
  font-size: 11px;
}

.compose-tools {
  display: flex;
  align-items: center;
  gap: 8px;
}

.mini-tool {
  display: inline-flex;
  width: 32px;
  height: 32px;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  color: var(--muted);
  background: transparent;
}

.mini-tool:hover {
  color: var(--green);
  background: var(--green-soft);
}

.mini-tool .icon {
  width: 17px;
  height: 17px;
}

.publish-button {
  height: 34px;
  padding: 0 15px;
  border-radius: 8px;
  color: #fff;
  background: var(--green);
  font-size: 10px;
  font-weight: 700;
}

.feed-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 20px 1px 10px;
}

.feed-filters {
  display: flex;
  gap: 5px;
}

.feed-filter {
  display: inline-flex;
  height: 29px;
  align-items: center;
  gap: 4px;
  padding: 0 10px;
  border-radius: 7px;
  color: var(--muted);
  background: transparent;
  font-size: 9px;
  font-weight: 600;
}

.feed-filter:hover {
  color: var(--ink);
}

.feed-filter.active {
  color: var(--green-deep);
  background: #e8eee8;
}

.feed-filter .icon {
  width: 12px;
  height: 12px;
}

.feed-result {
  color: #a0a59f;
  font-size: 8px;
}

.post-feed {
  display: flex;
  flex-direction: column;
  gap: 11px;
}

.post-card {
  position: relative;
  padding: 18px 19px 13px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-sm);
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
}

.post-card:hover {
  border-color: #d5dbd3;
  box-shadow: 0 8px 26px rgba(26, 48, 35, 0.07);
  transform: translateY(-1px);
}

.post-card.pinned {
  border-top: 2px solid #dfc46f;
}

.post-card.promoted {
  border-color: rgba(224, 166, 64, 0.54);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.96),
    0 14px 34px rgba(164, 108, 24, 0.12);
}

.post-card-head {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.post-author {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 9px;
}

.post-author-copy {
  display: flex;
  min-width: 0;
  flex-direction: column;
  align-items: flex-start;
}

.post-author-line {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 10px;
  font-weight: 700;
}

.author-badge {
  padding: 1px 5px;
  border-radius: 4px;
  color: var(--green);
  background: var(--green-soft);
  font-size: 7px;
  font-weight: 700;
}

.post-author-copy > span {
  margin-top: 2px;
  color: var(--muted);
  font-size: 8px;
}

.post-meta-right {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-left: auto;
}

.category-badge {
  padding: 3px 7px;
  border-radius: 5px;
  font-size: 8px;
  font-weight: 700;
}

.pinned-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 3px 6px;
  border-radius: 5px;
  color: #8f711c;
  background: #faf1d4;
  font-size: 7px;
  font-weight: 700;
}

.pinned-badge .icon {
  width: 9px;
  height: 9px;
}

.post-more {
  width: 25px;
  height: 25px;
  border-radius: 7px;
  color: #9ba09c;
  background: transparent;
}

.post-card h3 {
  margin: 13px 0 6px;
  font-family: var(--serif);
  font-size: 16px;
  font-weight: 800;
  line-height: 1.45;
  letter-spacing: 0.005em;
  cursor: pointer;
}

.post-card h3:hover {
  color: var(--green);
}

.post-excerpt {
  display: -webkit-box;
  overflow: hidden;
  color: #68716b;
  font-size: 10px;
  line-height: 1.75;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  cursor: pointer;
}

.post-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 9px;
}

.post-tags span {
  color: #7f9185;
  font-size: 8px;
}

.post-actions {
  display: flex;
  align-items: center;
  gap: 3px;
  margin-top: 13px;
  padding-top: 10px;
  border-top: 1px solid #f0f0eb;
}

.action-button {
  display: inline-flex;
  min-width: 48px;
  height: 28px;
  align-items: center;
  gap: 5px;
  padding: 0 7px;
  border-radius: 7px;
  color: #8b928d;
  background: transparent;
  font-size: 8px;
  transition: color 0.18s, background 0.18s;
}

.action-button:hover {
  color: var(--green);
  background: var(--green-pale);
}

.action-button .icon {
  width: 15px;
  height: 15px;
}

.action-button.liked {
  color: var(--orange);
  background: var(--orange-soft);
}

.action-button.liked .icon {
  fill: currentColor;
}

.action-button.disliked {
  color: #52617a;
  background: #edf1f5;
}

.action-button.disliked .icon {
  fill: currentColor;
}

.action-button.favorited {
  color: #9a761c;
  background: #fbf4dc;
}

.action-button.favorited .icon {
  fill: currentColor;
}

.post-actions .action-spacer {
  flex: 1;
}

.action-button.comments {
  margin-left: auto;
}

.post-actions .read-count {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 0 6px;
  color: #a1a6a1;
  font-size: 8px;
}

.post-actions .read-count .icon {
  width: 13px;
  height: 13px;
}

.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 50px 20px;
  border: 1px dashed var(--line-strong);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.45);
  text-align: center;
}

.empty-illustration {
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  margin-bottom: 12px;
  border-radius: 20px 20px 20px 6px;
  color: var(--green);
  background: var(--green-soft);
}

.empty-illustration .icon {
  width: 26px;
  height: 26px;
}

.empty-state h3 {
  font-family: var(--serif);
  font-size: 17px;
}

.empty-state p {
  margin: 5px 0 15px;
  color: var(--muted);
  font-size: 10px;
}

.load-more {
  display: block;
  margin: 16px auto 0;
  padding: 7px 15px;
  border-radius: 15px;
  color: #a0a59f;
  background: transparent;
  font-size: 8px;
}

/* Right rail */

.right-rail {
  position: sticky;
  top: 20px;
  display: flex;
  height: calc(100vh - 42px);
  min-height: 690px;
  flex-direction: column;
  gap: 12px;
  padding-top: 5px;
}

.rail-top-actions {
  display: flex;
  height: 35px;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.mini-profile-card,
.rail-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.76);
  box-shadow: var(--shadow-sm);
}

.mini-profile-card {
  flex: 0 0 auto;
}

.mini-profile-cover {
  height: 50px;
  background:
    radial-gradient(circle at 80% 20%, rgba(250, 223, 146, 0.45), transparent 27%),
    linear-gradient(120deg, #dbe9df, #b4d2bd 55%, #e9ddbd);
}

.mini-profile-cover::after {
  display: block;
  width: 100%;
  height: 100%;
  opacity: 0.35;
  background-image: radial-gradient(#6f8b77 0.7px, transparent 0.7px);
  background-size: 10px 10px;
  content: "";
}

.mini-profile-body {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-top: -21px;
  padding: 0 13px 12px;
}

.mini-avatar-wrap .avatar {
  width: 46px;
  height: 46px;
  border-width: 3px;
  font-size: 17px;
}

.mini-profile-body > strong {
  margin-top: 6px;
  font-family: var(--serif);
  font-size: 12px;
}

.mini-profile-body > span {
  margin-top: 1px;
  color: var(--muted);
  font-size: 8px;
}

.mini-profile-stats {
  display: flex;
  width: 100%;
  margin: 10px 0 9px;
}

.mini-profile-stats div {
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: center;
  border-left: 1px solid var(--line);
}

.mini-profile-stats div:first-child {
  border-left: 0;
}

.mini-profile-stats strong {
  font-family: Georgia, serif;
  font-size: 12px;
}

.mini-profile-stats span {
  color: var(--muted);
  font-size: 7px;
}

.text-profile-button {
  display: flex;
  width: 100%;
  height: 30px;
  align-items: center;
  justify-content: center;
  gap: 3px;
  border-radius: 7px;
  color: var(--green);
  background: var(--green-pale);
  font-size: 8px;
  font-weight: 700;
}

.text-profile-button .icon {
  width: 12px;
  height: 12px;
}

.rail-card {
  padding: 14px;
}

.rail-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}

.rail-card-head h2 {
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: var(--serif);
  font-size: 13px;
  font-weight: 800;
}

.rail-card-head h2 .icon {
  width: 15px;
  height: 15px;
  color: var(--orange);
}

.rail-card-head > span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--muted);
  font-size: 7px;
}

.rail-card-head > span::before {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--orange);
  content: "";
}

.trend-row {
  display: flex;
  width: 100%;
  align-items: flex-start;
  gap: 9px;
  padding: 8px 2px;
  border-top: 1px solid #f0f0eb;
  background: transparent;
  text-align: left;
}

.trend-row b {
  padding-top: 1px;
  color: #b7bbb7;
  font-family: Georgia, serif;
  font-size: 11px;
  font-style: italic;
  font-weight: 500;
}

.trend-row b.top {
  color: var(--orange);
}

.trend-row span {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.trend-row strong {
  overflow: hidden;
  font-size: 9px;
  line-height: 1.5;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.trend-row:hover strong {
  color: var(--green);
}

.trend-row small {
  margin-top: 2px;
  color: var(--muted-2);
  font-size: 7px;
}

.event-card {
  position: relative;
  padding: 16px;
  background:
    radial-gradient(circle at 100% 0%, rgba(242, 211, 126, 0.16), transparent 44%),
    #fff;
}

.event-date {
  position: absolute;
  top: 37px;
  right: 15px;
  display: flex;
  align-items: center;
  gap: 4px;
  color: #b49b57;
}

.event-date strong {
  font-family: Georgia, serif;
  font-size: 25px;
  font-weight: 500;
  line-height: 1;
}

.event-date span {
  font-size: 6px;
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1.25;
}

.event-copy h3 {
  margin: 9px 0 4px;
  font-family: var(--serif);
  font-size: 15px;
}

.event-copy p {
  width: 72%;
  color: var(--muted);
  font-size: 8px;
}

.event-copy > span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 9px;
  color: #8b928d;
  font-size: 7px;
}

.event-copy .icon {
  width: 11px;
  height: 11px;
}

.event-participants {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 13px;
  padding-top: 10px;
  border-top: 1px solid #f0f0eb;
}

.avatar-stack {
  display: flex;
  align-items: center;
}

.avatar-stack .avatar {
  margin-left: -6px;
}

.avatar-stack .avatar:first-child {
  margin-left: 0;
}

.avatar-stack .more {
  margin-left: 4px;
  color: var(--muted);
  font-size: 7px;
}

.event-participants .text-button {
  font-size: 8px;
}

.rail-footer {
  margin-top: auto;
  color: #a4a9a4;
  font-size: 7px;
  line-height: 1.8;
  text-align: center;
}

.rail-footer button {
  padding: 0;
  color: inherit;
  background: transparent;
  font-size: inherit;
}

.rail-footer button:hover {
  color: var(--green);
}

.mobile-header,
.mobile-nav {
  display: none;
}

/* Messages */

.messages-toolbar,
.profile-toolbar {
  margin-bottom: 20px;
}

.messages-layout {
  display: grid;
  height: calc(100vh - 135px);
  min-height: 560px;
  grid-template-columns: 247px minmax(0, 1fr);
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.75);
  box-shadow: var(--shadow-sm);
}

.conversation-panel {
  display: flex;
  min-width: 0;
  flex-direction: column;
  border-right: 1px solid var(--line);
  background: rgba(250, 250, 246, 0.68);
}

.conversation-head {
  display: flex;
  height: 59px;
  align-items: center;
  justify-content: space-between;
  padding: 0 13px 0 18px;
}

.conversation-head h2 {
  font-family: var(--serif);
  font-size: 16px;
}

.conversation-head h2 span {
  display: inline-grid;
  min-width: 18px;
  height: 18px;
  place-items: center;
  margin-left: 3px;
  padding: 0 5px;
  border-radius: 9px;
  color: var(--green);
  background: var(--green-soft);
  font-family: var(--sans);
  font-size: 8px;
}

.conversation-head .icon-button {
  width: 31px;
  height: 31px;
}

.messages-search {
  display: flex;
  height: 34px;
  align-items: center;
  gap: 7px;
  margin: 0 13px 10px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.messages-search .icon {
  width: 14px;
  height: 14px;
  color: var(--muted-2);
}

.messages-search input {
  width: 100%;
  font-size: 9px;
}

.conversation-list {
  flex: 1;
  overflow-y: auto;
  padding: 0 7px 12px;
}

.conversation-item {
  position: relative;
  display: flex;
  width: 100%;
  align-items: center;
  gap: 9px;
  padding: 11px 10px;
  border-radius: 10px;
  background: transparent;
  text-align: left;
  transition: background 0.18s;
}

.conversation-item:hover {
  background: rgba(255, 255, 255, 0.7);
}

.conversation-item.active {
  background: #fff;
  box-shadow: 0 2px 8px rgba(24, 43, 32, 0.05);
}

.conversation-copy {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
}

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

.conversation-top strong {
  overflow: hidden;
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.conversation-top span {
  flex: 0 0 auto;
  color: #a2a7a2;
  font-size: 7px;
}

.conversation-preview {
  display: block;
  max-width: 100%;
  overflow: hidden;
  margin-top: 2px;
  color: var(--muted);
  font-size: 8px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.unread-count {
  position: absolute;
  right: 9px;
  bottom: 9px;
  display: grid;
  min-width: 16px;
  height: 16px;
  place-items: center;
  padding: 0 4px;
  border-radius: 8px;
  color: #fff;
  background: var(--orange);
  font-size: 7px;
}

.chat-panel {
  position: relative;
  min-width: 0;
  background:
    radial-gradient(circle at 100% 0%, rgba(224, 235, 226, 0.35), transparent 14rem),
    #fdfdfb;
}

.chat-empty {
  display: flex;
  height: 100%;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 30px;
  text-align: center;
}

.chat-empty-art {
  position: relative;
  display: grid;
  width: 74px;
  height: 74px;
  place-items: center;
  margin-bottom: 16px;
  border-radius: 24px 24px 24px 7px;
  color: var(--green);
  background: var(--green-soft);
  transform: rotate(-3deg);
}

.chat-empty-art .icon {
  width: 31px;
  height: 31px;
}

.chat-empty-art span {
  position: absolute;
  right: -20px;
  top: 4px;
  padding: 5px 8px;
  border-radius: 9px 9px 9px 3px;
  color: #fff;
  background: var(--orange);
  font-family: Georgia, serif;
  font-size: 9px;
  font-style: italic;
  transform: rotate(7deg);
}

.chat-empty h2 {
  font-family: var(--serif);
  font-size: 18px;
}

.chat-empty p {
  width: min(260px, 100%);
  margin-top: 6px;
  color: var(--muted);
  font-size: 9px;
  line-height: 1.7;
}

.chat-active {
  display: flex;
  height: 100%;
  flex-direction: column;
}

.chat-header {
  display: flex;
  min-height: 59px;
  align-items: center;
  gap: 9px;
  padding: 8px 16px;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(10px);
}

.chat-back {
  display: none;
}

.chat-contact {
  display: flex;
  flex: 1;
  flex-direction: column;
}

.chat-contact strong {
  font-size: 10px;
}

.chat-contact > span {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-top: 1px;
  color: var(--muted);
  font-size: 7px;
}

.online-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #60b581;
}

.chat-messages {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 11px;
  overflow-y: auto;
  padding: 20px 18px;
}

.chat-date-divider {
  align-self: center;
  margin-bottom: 4px;
  padding: 3px 8px;
  border-radius: 10px;
  color: #a5aaa5;
  background: #f0f1ec;
  font-size: 7px;
}

.message-row {
  display: flex;
  max-width: 83%;
  align-items: flex-end;
  gap: 7px;
}

.message-row.mine {
  align-self: flex-end;
  flex-direction: row-reverse;
}

.message-bubble {
  padding: 9px 12px;
  border-radius: 12px 12px 12px 4px;
  color: var(--ink-soft);
  background: #fff;
  box-shadow: 0 2px 8px rgba(25, 44, 33, 0.05);
  font-size: 10px;
  line-height: 1.65;
}

.message-row.mine .message-bubble {
  border-radius: 12px 12px 4px 12px;
  color: #fff;
  background: var(--green);
}

.message-time {
  align-self: flex-end;
  color: #acb0ac;
  font-size: 6px;
}

.message-row.mine .message-time {
  order: -1;
}

.chat-composer {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 11px 14px;
  border-top: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.92);
}

.chat-composer .icon-button {
  width: 32px;
  height: 32px;
  color: var(--muted);
}

.chat-input-wrap {
  display: flex;
  height: 38px;
  flex: 1;
  align-items: center;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #f8f8f4;
}

.chat-input-wrap:focus-within {
  border-color: #adc2b4;
  background: #fff;
}

.chat-input-wrap input {
  width: 100%;
  font-size: 9px;
}

.send-button {
  display: grid;
  width: 37px;
  height: 37px;
  place-items: center;
  border-radius: 10px;
  color: #fff;
  background: var(--green);
}

.send-button .icon {
  width: 17px;
  height: 17px;
}

.points-gift-trigger {
  color: #a77a1b;
}

.points-gift-trigger:hover {
  color: #8f6816;
  background: rgba(250, 226, 157, 0.45);
}

.message-row.mine .points-message-bubble {
  padding: 0;
  background: transparent;
  box-shadow: none;
}

.points-gift-card {
  display: flex;
  min-width: 220px;
  align-items: center;
  gap: 10px;
  padding: 11px 12px;
  border: 1px solid rgba(255, 225, 175, 0.55);
  border-radius: 14px 14px 4px 14px;
  color: #fff8ea;
  background:
    radial-gradient(circle at 100% 0%, rgba(255, 231, 169, 0.3), transparent 38%),
    linear-gradient(135deg, rgba(181, 84, 57, 0.96), rgba(214, 115, 69, 0.93));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.25),
    0 8px 22px rgba(139, 61, 35, 0.18);
}

.message-row:not(.mine) .points-gift-card {
  border-radius: 14px 14px 14px 4px;
}

.points-gift-symbol {
  display: grid;
  width: 35px;
  height: 35px;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 11px;
  color: #c86c45;
  background: #fff3d8;
}

.points-gift-symbol .icon {
  width: 19px;
  height: 19px;
}

.points-gift-copy {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
}

.points-gift-copy > span {
  color: rgba(255, 255, 255, 0.6);
  font-size: 7px;
}

.points-gift-copy > strong {
  font-family: Georgia, serif;
  font-size: 16px;
  line-height: 1.35;
}

.points-gift-copy > strong small {
  font-family: var(--sans);
  font-size: 7px;
}

.points-gift-copy p {
  overflow: hidden;
  max-width: 150px;
  margin-top: 1px;
  color: rgba(255, 255, 255, 0.67);
  font-size: 7px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.points-gift-card > button {
  height: 28px;
  padding: 0 9px;
  flex: 0 0 auto;
  border-radius: 8px;
  color: #9f4a32;
  background: #fff3d8;
  font-size: 8px;
  font-weight: 800;
}

.points-gift-card > button:hover {
  background: #fff;
}

.points-gift-card .gift-state {
  color: rgba(255, 255, 255, 0.58);
  font-size: 7px;
}

.points-gift-card.claimed {
  filter: saturate(0.72);
  opacity: 0.82;
}

.points-gift-modal {
  width: min(100%, 440px);
}

.points-gift-modal form {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 0 22px 23px;
}

.gift-recipient {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border-radius: 10px;
  background: rgba(255, 249, 236, 0.7);
}

.gift-recipient > div {
  display: flex;
  flex-direction: column;
}

.gift-recipient span,
.gift-recipient small {
  color: var(--muted);
  font-size: 7px;
}

.gift-recipient strong {
  margin: 1px 0;
  font-size: 10px;
}

.points-gift-modal textarea {
  padding: 10px 12px;
  border: 1px solid var(--line-strong);
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.6);
  font-size: 9px;
}

.gift-balance-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 9px 11px;
  border-radius: 9px;
  color: var(--muted);
  background: rgba(238, 243, 236, 0.76);
  font-size: 8px;
}

.gift-balance-line strong {
  color: var(--green);
  font-family: Georgia, serif;
  font-size: 13px;
}

.gift-submit {
  min-height: 44px;
  background:
    linear-gradient(135deg, #ca7650, #b6543b);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.27),
    0 9px 24px rgba(159, 72, 44, 0.21);
}

/* Profile */

.profile-hero {
  position: relative;
  overflow: hidden;
  padding: 26px 27px 0;
  border-radius: 17px;
  color: #fff;
  background:
    radial-gradient(circle at 93% 8%, rgba(242, 210, 123, 0.22), transparent 28%),
    linear-gradient(120deg, #235f46, #183f2f 67%, #153727);
  box-shadow: 0 14px 30px rgba(30, 67, 46, 0.13);
}

.profile-pattern {
  position: absolute;
  inset: 0;
  opacity: 0.12;
  background-image: radial-gradient(rgba(255, 255, 255, 0.8) 0.6px, transparent 0.6px);
  background-size: 13px 13px;
  -webkit-mask-image: linear-gradient(90deg, transparent 25%, #000);
  mask-image: linear-gradient(90deg, transparent 25%, #000);
}

.profile-hero::after {
  position: absolute;
  top: -88px;
  right: -60px;
  width: 260px;
  height: 260px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 50%;
  content: "";
}

.profile-main {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 17px;
}

.profile-avatar {
  display: grid;
  width: 78px;
  height: 78px;
  place-items: center;
  flex: 0 0 auto;
  border: 3px solid rgba(255, 255, 255, 0.88);
  border-radius: 50%;
  color: #24513c;
  background:
    radial-gradient(circle at 67% 24%, rgba(255, 255, 255, 0.85) 0 8%, transparent 9%),
    linear-gradient(145deg, #d9ebdc, #99c7ab);
  box-shadow: 0 10px 24px rgba(8, 30, 18, 0.18);
  font-family: var(--serif);
  font-size: 28px;
  font-weight: 800;
}

.profile-avatar.peach {
  color: #7a3d2c;
  background:
    radial-gradient(circle at 67% 24%, rgba(255, 255, 255, 0.85) 0 8%, transparent 9%),
    linear-gradient(145deg, #ffe2d6, #f2b196);
}

.profile-avatar.blue {
  color: #34566e;
  background:
    radial-gradient(circle at 67% 24%, rgba(255, 255, 255, 0.85) 0 8%, transparent 9%),
    linear-gradient(145deg, #dbeaf5, #a7c9df);
}

.profile-avatar.violet {
  color: #54456c;
  background:
    radial-gradient(circle at 67% 24%, rgba(255, 255, 255, 0.85) 0 8%, transparent 9%),
    linear-gradient(145deg, #e9e1f3, #c3b3d8);
}

.profile-copy {
  min-width: 0;
}

.profile-name-line {
  display: flex;
  align-items: center;
  gap: 8px;
}

.profile-name-line h2 {
  font-family: var(--serif);
  font-size: 23px;
  font-weight: 800;
}

.level-badge {
  display: inline-flex;
  height: 20px;
  align-items: center;
  gap: 3px;
  padding: 0 7px;
  border: 1px solid rgba(246, 212, 126, 0.28);
  border-radius: 10px;
  color: #f6d679;
  background: rgba(246, 212, 126, 0.1);
  font-size: 7px;
}

.level-badge .icon {
  width: 9px;
  height: 9px;
  fill: currentColor;
}

.profile-meta {
  margin-top: 3px;
  color: rgba(255, 255, 255, 0.55);
  font-size: 9px;
}

.profile-bio {
  margin-top: 7px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 10px;
}

.profile-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 8px;
}

.profile-tags span {
  padding: 2px 7px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  color: rgba(255, 255, 255, 0.58);
  background: rgba(255, 255, 255, 0.06);
  font-size: 7px;
}

.profile-stats {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  margin-top: 26px;
  border-top: 1px solid rgba(255, 255, 255, 0.11);
}

.profile-stats div {
  display: flex;
  align-items: baseline;
  gap: 5px;
  padding: 13px 0 15px;
  border-left: 1px solid rgba(255, 255, 255, 0.09);
}

.profile-stats div:first-child {
  border-left: 0;
}

.profile-stats strong {
  padding-left: 16px;
  font-family: Georgia, serif;
  font-size: 17px;
  font-weight: 500;
}

.profile-stats span {
  color: rgba(255, 255, 255, 0.46);
  font-size: 7px;
}

.profile-content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 270px;
  gap: 15px;
  margin-top: 15px;
}

.profile-activity-card,
.achievement-card,
.account-card {
  border: 1px solid var(--line);
  border-radius: 15px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: var(--shadow-sm);
}

.profile-activity-card {
  min-width: 0;
  padding: 18px;
}

.section-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 15px;
  margin-bottom: 15px;
}

.section-heading h2 {
  margin-top: 3px;
  font-family: var(--serif);
  font-size: 18px;
}

.section-heading.compact {
  align-items: center;
  margin-bottom: 12px;
}

.section-heading.compact h2 {
  font-size: 15px;
}

.profile-tabs {
  display: flex;
  gap: 2px;
  padding: 3px;
  border-radius: 8px;
  background: #f3f3ee;
}

.profile-tab {
  height: 27px;
  padding: 0 10px;
  border-radius: 6px;
  color: var(--muted);
  background: transparent;
  font-size: 8px;
}

.profile-tab.active {
  color: var(--ink);
  background: #fff;
  box-shadow: 0 1px 4px rgba(24, 40, 30, 0.07);
  font-weight: 700;
}

.profile-posts {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.profile-post-row {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 11px 10px;
  border-radius: 10px;
  background: #fbfbf8;
  cursor: pointer;
  transition: background 0.2s;
}

.profile-post-row:hover {
  background: var(--green-pale);
}

.profile-post-icon {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 10px;
  color: var(--green);
  background: var(--green-soft);
  font-family: Georgia, serif;
  font-size: 10px;
  font-weight: 700;
}

.profile-post-copy {
  min-width: 0;
  flex: 1;
}

.profile-post-copy strong {
  display: block;
  overflow: hidden;
  font-family: var(--serif);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.profile-post-copy span {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 3px;
  color: var(--muted);
  font-size: 7px;
}

.profile-post-copy em {
  padding: 1px 5px;
  border-radius: 4px;
  font-style: normal;
}

.profile-post-stats {
  display: flex;
  gap: 8px;
  color: var(--muted);
  font-size: 7px;
}

.profile-post-stats span {
  display: inline-flex;
  align-items: center;
  gap: 2px;
}

.profile-post-stats .icon {
  width: 10px;
  height: 10px;
}

.profile-aside {
  display: flex;
  flex-direction: column;
  gap: 13px;
}

.achievement-card,
.account-card {
  padding: 16px;
}

.growth-level {
  display: flex;
  align-items: center;
  gap: 11px;
  padding-bottom: 13px;
  border-bottom: 1px solid var(--line);
}

.growth-ring {
  display: grid;
  width: 52px;
  height: 52px;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 50%;
  background: conic-gradient(var(--green) 0 68%, #e3eae4 68%);
}

.growth-ring::before {
  grid-area: 1 / 1;
  width: 43px;
  height: 43px;
  border-radius: 50%;
  background: #fff;
  content: "";
}

.growth-ring span {
  position: relative;
  grid-area: 1 / 1;
  font-family: Georgia, serif;
  font-size: 11px;
  font-weight: 700;
}

.growth-level > div:last-child {
  min-width: 0;
  flex: 1;
}

.growth-level strong {
  font-size: 9px;
}

.growth-level p {
  margin-top: 3px;
  color: var(--muted);
  font-size: 7px;
}

.growth-level p b {
  color: var(--orange);
}

.progress {
  height: 4px;
  margin-top: 6px;
  overflow: hidden;
  border-radius: 2px;
  background: #e9ece8;
}

.progress i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--green);
}

.badge-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 5px;
  margin-top: 12px;
}

.achievement-badge {
  display: flex;
  min-width: 0;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding: 7px 2px;
  border-radius: 7px;
  opacity: 0.35;
  filter: grayscale(1);
  background: #f6f6f1;
}

.achievement-badge.active {
  opacity: 1;
  filter: none;
  background: #fdf9ea;
}

.achievement-badge span {
  font-size: 16px;
}

.achievement-badge small {
  overflow: hidden;
  width: 100%;
  font-size: 6px;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.account-card .section-heading {
  margin-bottom: 5px;
}

.setting-row {
  display: flex;
  width: 100%;
  height: 35px;
  align-items: center;
  justify-content: space-between;
  padding: 0;
  border-top: 1px solid #f0f0eb;
  color: var(--ink-soft);
  background: transparent;
  font-size: 8px;
}

.setting-row > span:first-child {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.setting-row .icon {
  width: 14px;
  height: 14px;
  color: var(--muted);
}

.setting-row:hover {
  color: var(--green);
}

.toggle {
  position: relative;
  width: 26px;
  height: 15px;
  border-radius: 8px;
  background: #d9dcd8;
}

.toggle::after {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: #fff;
  content: "";
}

.toggle.on {
  background: var(--green);
}

.toggle.on::after {
  left: 13px;
}

/* Modals */

.modal-backdrop {
  position: fixed;
  z-index: 100;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 26px;
  background: rgba(12, 24, 17, 0.45);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  animation: backdrop-in 0.2s ease both;
}

@keyframes backdrop-in {
  from {
    opacity: 0;
  }
}

.modal {
  width: min(100%, 650px);
  max-height: min(90vh, 860px);
  overflow: hidden;
  border-radius: 18px;
  background: var(--surface);
  box-shadow: var(--shadow-lg);
  animation: modal-in 0.25s cubic-bezier(0.2, 0.85, 0.25, 1) both;
}

@keyframes modal-in {
  from {
    opacity: 0;
    transform: translateY(10px) scale(0.98);
  }
}

.modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 22px 24px 14px;
}

.modal-header h2 {
  margin-top: 4px;
  font-family: var(--serif);
  font-size: 21px;
}

.modal-header .modal-close {
  width: 34px;
  height: 34px;
  margin-top: -4px;
  color: var(--muted);
  background: #f5f5f0;
}

.create-post-modal form {
  padding: 0 24px 20px;
}

.composer-author {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 8px 0;
}

.composer-author div {
  display: flex;
  flex-direction: column;
}

.composer-author strong {
  font-size: 10px;
}

.composer-author span {
  color: var(--muted);
  font-size: 8px;
}

.category-picker {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 5px;
  margin: 11px 0;
}

.category-picker > span {
  margin-right: 3px;
  color: var(--muted);
  font-size: 8px;
}

.category-picker label {
  cursor: pointer;
}

.category-picker input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.category-picker label span {
  display: inline-flex;
  height: 25px;
  align-items: center;
  padding: 0 9px;
  border: 1px solid transparent;
  border-radius: 7px;
  font-size: 8px;
  font-weight: 600;
}

.category-picker input:checked + span {
  border-color: currentColor;
  box-shadow: 0 0 0 1px #fff inset;
}

.post-title-input {
  display: block;
  width: 100%;
  padding: 14px 0 10px;
  border-top: 1px solid var(--line);
  font-family: var(--serif);
  font-size: 18px;
  font-weight: 700;
}

.post-body-input {
  display: block;
  width: 100%;
  min-height: 180px;
  padding: 12px 0;
  border-top: 1px solid var(--line);
  font-size: 11px;
  line-height: 1.8;
}

.composer-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.composer-tools {
  display: flex;
  gap: 4px;
}

.mini-tool.labeled {
  width: auto;
  gap: 5px;
  padding: 0 9px;
  background: #f7f7f2;
  font-size: 8px;
}

.composer-submit {
  display: flex;
  align-items: center;
  gap: 12px;
}

.composer-submit > span {
  color: var(--muted);
  font-size: 7px;
}

.composer-submit .primary-button {
  min-height: 36px;
  padding: 0 14px;
  font-size: 9px;
}

.create-post-modal .form-error {
  margin-top: 8px;
}

.detail-modal {
  width: min(100%, 760px);
  max-height: 92vh;
  background: #fbfbf8;
}

.detail-topbar {
  display: flex;
  height: 56px;
  align-items: center;
  justify-content: space-between;
  padding: 0 13px;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.89);
}

.detail-topbar > span {
  font-family: var(--serif);
  font-size: 13px;
  font-weight: 700;
}

.detail-scroll {
  max-height: calc(92vh - 56px);
  overflow-y: auto;
}

.detail-post {
  padding: 24px 27px 20px;
  background: #fff;
}

.detail-author {
  display: flex;
  align-items: center;
  gap: 10px;
}

.detail-author-copy {
  display: flex;
  flex: 1;
  flex-direction: column;
}

.detail-author-copy strong {
  font-size: 11px;
}

.detail-author-copy span {
  color: var(--muted);
  font-size: 8px;
}

.follow-button {
  height: 27px;
  padding: 0 10px;
  border: 1px solid var(--line-strong);
  border-radius: 7px;
  color: var(--green);
  background: transparent;
  font-size: 8px;
  font-weight: 700;
}

.follow-button.following {
  color: var(--muted);
  background: #f5f5f0;
}

.detail-post h1 {
  margin: 17px 0 11px;
  font-family: var(--serif);
  font-size: 25px;
  line-height: 1.45;
}

.detail-body {
  color: #47524b;
  font-size: 11px;
  line-height: 2;
  white-space: pre-wrap;
}

.detail-tags {
  display: flex;
  gap: 6px;
  margin-top: 14px;
}

.detail-tags span {
  color: #6c8c79;
  font-size: 8px;
}

.detail-actions {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-top: 19px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.detail-actions .action-button {
  height: 32px;
  border: 1px solid var(--line);
  padding: 0 10px;
  font-size: 8px;
}

.detail-actions .action-button:last-child {
  margin-left: auto;
}

.comments-section {
  margin-top: 9px;
  padding: 20px 27px 24px;
  background: #fbfbf8;
}

.comments-section > h2 {
  font-family: var(--serif);
  font-size: 16px;
}

.comment-form {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  margin: 13px 0 18px;
}

.comment-form-input {
  display: flex;
  flex: 1;
  align-items: flex-end;
  gap: 8px;
  padding: 7px 8px 7px 12px;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  background: #fff;
}

.comment-form-input:focus-within {
  border-color: #aac0b1;
  box-shadow: 0 0 0 3px rgba(33, 107, 77, 0.06);
}

.comment-form-input textarea {
  width: 100%;
  min-height: 28px;
  max-height: 100px;
  padding: 4px 0;
  font-size: 10px;
  line-height: 1.5;
}

.comment-form-input button {
  height: 27px;
  padding: 0 9px;
  border-radius: 7px;
  color: #fff;
  background: var(--green);
  font-size: 8px;
}

.comment-list {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.comment {
  display: flex;
  gap: 9px;
}

.comment-content {
  min-width: 0;
  flex: 1;
}

.comment-head {
  display: flex;
  align-items: center;
  gap: 6px;
}

.comment-head strong {
  font-size: 9px;
}

.comment-head .author-op {
  padding: 1px 4px;
  border-radius: 3px;
  color: var(--green);
  background: var(--green-soft);
  font-size: 6px;
  font-weight: 700;
}

.comment-head time {
  margin-left: auto;
  color: var(--muted-2);
  font-size: 7px;
}

.comment-text {
  margin-top: 4px;
  color: #566159;
  font-size: 9px;
  line-height: 1.7;
}

.comment-actions {
  display: flex;
  gap: 10px;
  margin-top: 5px;
}

.comment-actions button {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 0;
  color: var(--muted);
  background: transparent;
  font-size: 7px;
}

.comment-actions .icon {
  width: 11px;
  height: 11px;
}

.comment-actions button.active {
  color: var(--orange);
}

.no-comments {
  padding: 20px;
  color: var(--muted);
  font-size: 9px;
  text-align: center;
}

.search-modal {
  align-self: flex-start;
  width: min(100%, 620px);
  margin-top: max(7vh, 40px);
}

.search-modal-head {
  display: flex;
  height: 59px;
  align-items: center;
  gap: 10px;
  padding: 0 16px;
  border-bottom: 1px solid var(--line);
}

.search-modal-head > .icon {
  color: var(--muted);
}

.search-modal-head input {
  flex: 1;
  font-size: 13px;
}

.search-cancel {
  padding: 4px;
  color: var(--green);
  background: transparent;
  font-size: 9px;
  font-weight: 700;
}

.search-tabs {
  display: flex;
  gap: 4px;
  padding: 7px 16px;
  border-bottom: 1px solid var(--line);
  background: rgba(248, 249, 245, 0.7);
}

.search-tabs button {
  height: 28px;
  padding: 0 12px;
  border-radius: 7px;
  color: var(--muted);
  background: transparent;
  font-size: 8px;
  font-weight: 700;
}

.search-tabs button.active {
  color: var(--green-deep);
  background: #fff;
  box-shadow: var(--shadow-sm);
}

.search-body {
  min-height: 250px;
  max-height: 60vh;
  overflow-y: auto;
  padding: 20px;
}

.search-suggestions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px;
}

.search-suggestions .eyebrow {
  width: 100%;
  margin-bottom: 4px;
}

.search-suggestions button {
  padding: 6px 9px;
  border-radius: 8px;
  color: var(--ink-soft);
  background: #f5f5f0;
  font-size: 8px;
}

.search-suggestions button:hover {
  color: var(--green);
  background: var(--green-soft);
}

.search-key-hint {
  display: flex;
  justify-content: space-between;
  margin-top: 30px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  color: var(--muted-2);
  font-size: 7px;
}

.search-result-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
  color: var(--muted);
  font-size: 8px;
}

.search-result {
  display: block;
  width: 100%;
  padding: 11px 12px;
  border-radius: 9px;
  background: transparent;
  text-align: left;
}

.search-result:hover {
  background: var(--green-pale);
}

.search-result strong {
  display: block;
  font-family: var(--serif);
  font-size: 11px;
}

.search-result span {
  display: block;
  overflow: hidden;
  margin-top: 3px;
  color: var(--muted);
  font-size: 8px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.search-result.user-result {
  display: flex;
  align-items: center;
  gap: 9px;
}

.search-user-copy {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
}

.search-user-copy > span {
  display: block;
}

.topic-result strong {
  color: var(--green);
}

.new-message-modal {
  width: min(100%, 430px);
}

.new-message-search {
  margin: 0 20px 10px;
}

.people-list {
  max-height: 400px;
  overflow-y: auto;
  padding: 0 12px 16px;
}

.person-row {
  display: flex;
  width: 100%;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border-radius: 9px;
  background: transparent;
  text-align: left;
}

.person-row:hover {
  background: var(--green-pale);
}

.person-copy {
  display: flex;
  flex: 1;
  flex-direction: column;
}

.person-copy strong {
  font-size: 9px;
}

.person-copy span {
  color: var(--muted);
  font-size: 7px;
}

.person-row > .icon {
  width: 14px;
  height: 14px;
  color: var(--muted-2);
}

.edit-profile-modal {
  width: min(100%, 500px);
}

.edit-profile-modal form {
  display: flex;
  flex-direction: column;
  gap: 13px;
  padding: 0 23px 22px;
}

.edit-avatar-row {
  display: flex;
  align-items: center;
  gap: 11px;
  padding-bottom: 13px;
  border-bottom: 1px solid var(--line);
}

.small-avatar {
  width: 48px;
  height: 48px;
  border-color: #fff;
  font-size: 17px;
}

.edit-avatar-row > div:nth-child(2) {
  display: flex;
  flex: 1;
  flex-direction: column;
}

.edit-avatar-row strong {
  font-size: 9px;
}

.edit-avatar-row span {
  color: var(--muted);
  font-size: 7px;
}

.avatar-styles {
  display: flex;
  gap: 6px;
}

.avatar-style {
  width: 21px;
  height: 21px;
  border: 2px solid transparent;
  border-radius: 50%;
}

.avatar-style.active {
  border-color: #fff;
  box-shadow: 0 0 0 2px var(--green);
}

.avatar-style.mint {
  background: #9dccb0;
}

.avatar-style.peach {
  background: #f2b196;
}

.avatar-style.blue {
  background: #a7c9df;
}

.avatar-style.violet {
  background: #c3b3d8;
}

.edit-profile-modal textarea {
  padding: 11px 13px;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.76);
  font-size: 11px;
  line-height: 1.6;
}

.edit-profile-modal textarea:focus {
  border-color: rgba(33, 107, 77, 0.65);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(33, 107, 77, 0.08);
}

.modal-form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 2px;
}

.rules-modal {
  width: min(100%, 540px);
}

.rules-body {
  max-height: 70vh;
  overflow-y: auto;
  padding: 3px 24px 24px;
}

.rule-intro {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 17px;
  padding: 12px;
  border-radius: 9px;
  color: var(--green);
  background: var(--green-soft);
}

.rule-intro .icon {
  width: 19px;
  height: 19px;
}

.rule-intro p {
  font-size: 9px;
}

.rules-body article {
  display: flex;
  gap: 12px;
  padding: 13px 0;
  border-top: 1px solid var(--line);
}

.rules-body article > b {
  color: #c3c8c3;
  font-family: Georgia, serif;
  font-size: 15px;
  font-style: italic;
  font-weight: 500;
}

.rules-body h3 {
  font-family: var(--serif);
  font-size: 13px;
}

.rules-body article p {
  margin-top: 4px;
  color: var(--muted);
  font-size: 9px;
  line-height: 1.75;
}

.rules-body .primary-button {
  margin-top: 10px;
}

.toast {
  position: fixed;
  z-index: 300;
  right: 50%;
  bottom: 30px;
  display: flex;
  min-height: 38px;
  align-items: center;
  gap: 7px;
  padding: 9px 15px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  color: #fff;
  background: rgba(22, 49, 34, 0.94);
  box-shadow: 0 9px 30px rgba(9, 28, 17, 0.24);
  font-size: 9px;
  opacity: 0;
  pointer-events: none;
  transform: translate(50%, 12px);
  transition: opacity 0.2s, transform 0.2s;
}

.toast.show {
  opacity: 1;
  transform: translate(50%, 0);
}

.toast .icon {
  width: 14px;
  height: 14px;
  color: #9ddbb5;
}

/* Friends, identity and daily ranking */

.messages-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.add-friend-button {
  position: relative;
}

.request-badge {
  display: grid;
  min-width: 18px;
  height: 18px;
  place-items: center;
  padding: 0 5px;
  border-radius: 9px;
  color: #fff;
  background: var(--orange);
  font-size: 7px;
}

.profile-id-line {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 7px;
  color: rgba(255, 255, 255, 0.5);
  font-size: 7px;
}

.profile-id-line strong {
  color: #f5d477;
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 9px;
  letter-spacing: 0.04em;
}

.profile-id-line button {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  padding: 2px 5px;
  border-radius: 5px;
  color: rgba(255, 255, 255, 0.57);
  background: rgba(255, 255, 255, 0.08);
  font-size: 7px;
}

.profile-id-line button:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.14);
}

.profile-id-line .icon {
  width: 10px;
  height: 10px;
}

.admin-setting-row {
  color: #6b725f;
}

.account-status {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 7px 0 2px;
  padding: 9px 10px;
  border: 1px solid #f0d8cb;
  border-radius: 8px;
  color: #9c523b;
  background: #fff7f2;
}

.account-status .icon {
  width: 15px;
  height: 15px;
  color: var(--orange);
}

.account-status div {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.account-status strong {
  font-size: 8px;
}

.account-status span {
  margin-top: 1px;
  font-size: 6px;
}

.hot-update-note {
  display: flex;
  align-items: center;
  gap: 4px;
  margin: 5px 1px 0;
  padding-top: 8px;
  border-top: 1px solid #f0f0eb;
  color: #a2a7a2;
  font-size: 6px;
}

.hot-update-note .icon {
  width: 10px;
  height: 10px;
}

.hot-empty {
  padding: 18px 6px 10px;
  color: var(--muted);
  font-size: 8px;
  line-height: 1.7;
  text-align: center;
}

.follow-button.friend {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  border-color: rgba(33, 107, 77, 0.2);
  background: var(--green-pale);
}

.follow-button.friend .icon {
  width: 11px;
  height: 11px;
}

.modal-header-note {
  margin-top: 3px;
  color: var(--muted);
  font-size: 8px;
}

.friend-modal {
  width: min(100%, 570px);
}

.friend-id-form {
  padding: 0 22px 13px;
}

.friend-input-wrap {
  height: 49px;
  padding-right: 6px;
}

.friend-input-wrap .primary-button {
  min-height: 36px;
  flex: 0 0 auto;
  padding: 0 15px;
  font-size: 9px;
}

.friend-search-result {
  min-height: 70px;
  margin: 0 22px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: #fbfbf8;
}

.friend-tip {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 14px;
  color: var(--muted);
}

.friend-tip .icon {
  width: 18px;
  height: 18px;
  color: var(--green);
}

.friend-tip p {
  font-size: 8px;
  line-height: 1.65;
}

.friend-profile-result {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 13px;
  background: #fff;
}

.friend-profile-copy {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
}

.friend-profile-copy strong {
  font-family: var(--serif);
  font-size: 11px;
}

.friend-profile-copy span {
  margin-top: 2px;
  color: var(--muted);
  font-size: 7px;
}

.friend-profile-copy small {
  margin-top: 4px;
  color: var(--green);
  font-size: 7px;
}

.friend-result-actions {
  display: flex;
  align-items: center;
  gap: 5px;
}

.friend-result-actions .primary-button,
.friend-result-actions .secondary-button {
  min-height: 31px;
  padding: 0 10px;
  font-size: 8px;
}

.friend-result-actions .icon {
  width: 12px;
  height: 12px;
}

.friend-not-found {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 15px;
}

.friend-not-found .icon {
  color: var(--muted);
}

.friend-not-found div {
  display: flex;
  flex-direction: column;
}

.friend-not-found strong {
  font-size: 9px;
}

.friend-not-found span {
  margin-top: 2px;
  color: var(--muted);
  font-size: 7px;
}

.friend-requests-section {
  max-height: 300px;
  overflow-y: auto;
  margin-top: 14px;
  padding: 14px 22px calc(20px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
}

.friend-section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}

.friend-section-heading h3 {
  font-family: var(--serif);
  font-size: 13px;
}

.friend-section-heading h3 span {
  display: inline-grid;
  min-width: 17px;
  height: 17px;
  place-items: center;
  margin-left: 3px;
  padding: 0 4px;
  border-radius: 9px;
  color: var(--orange);
  background: var(--orange-soft);
  font-family: var(--sans);
  font-size: 7px;
}

.friend-section-heading > span {
  color: var(--muted);
  font-size: 7px;
}

.request-group-label {
  margin: 10px 0 4px;
  color: #9aa09b;
  font-size: 7px;
  font-weight: 700;
  letter-spacing: 0.06em;
}

.request-group-label.outgoing {
  margin-top: 14px;
}

.friend-request-row {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 10px 7px;
  border-radius: 9px;
}

.friend-request-row:hover {
  background: #fafaf6;
}

.friend-request-row.outgoing {
  padding-top: 7px;
  padding-bottom: 7px;
}

.friend-request-copy {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
}

.friend-request-copy strong {
  font-size: 9px;
}

.friend-request-copy span {
  margin-top: 1px;
  color: var(--muted);
  font-size: 7px;
}

.friend-request-copy p {
  overflow: hidden;
  margin-top: 3px;
  color: #657269;
  font-size: 7px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.friend-request-actions {
  display: flex;
  align-items: center;
  gap: 7px;
}

.small-primary {
  height: 29px;
  padding: 0 11px;
  border-radius: 7px;
  color: #fff;
  background: var(--green);
  font-size: 8px;
  font-weight: 700;
}

.text-button.muted {
  color: var(--muted);
  font-size: 8px;
  font-weight: 500;
}

.friend-requests-empty {
  padding: 20px 0;
  color: var(--muted);
  font-size: 8px;
  text-align: center;
}

.friend-message-empty {
  border: 0;
  background: transparent;
}

/* Admin */

.admin-gate-modal {
  width: min(100%, 420px);
}

.admin-gate-modal form {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 3px 24px 25px;
}

.admin-gate-icon {
  display: grid;
  width: 54px;
  height: 54px;
  place-items: center;
  align-self: center;
  margin: 1px 0 2px;
  border-radius: 18px 18px 18px 6px;
  color: var(--green);
  background: var(--green-soft);
}

.admin-gate-icon .icon {
  width: 23px;
  height: 23px;
}

.admin-gate-modal form > p {
  color: var(--muted);
  font-size: 9px;
  line-height: 1.7;
  text-align: center;
}

.admin-gate-note {
  color: var(--muted-2);
  font-size: 7px;
  text-align: center;
}

.admin-modal {
  display: flex;
  width: min(100%, 760px);
  max-height: 88vh;
  flex-direction: column;
  background: #fbfbf8;
}

.admin-modal-header {
  align-items: center;
  padding-bottom: 12px;
  background: #fff;
}

.admin-header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.admin-mode-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 8px;
  border-radius: 10px;
  color: var(--green);
  background: var(--green-soft);
  font-size: 7px;
  font-weight: 700;
}

.admin-mode-badge i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #4caa70;
  box-shadow: 0 0 0 3px rgba(76, 170, 112, 0.12);
}

.admin-summary {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  margin: 0 20px 12px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: #fff;
}

.admin-summary div {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
  padding: 11px 5px;
  border-left: 1px solid var(--line);
}

.admin-summary div:first-child {
  border-left: 0;
}

.admin-summary strong {
  font-family: Georgia, serif;
  font-size: 16px;
  font-weight: 500;
}

.admin-summary strong.danger-value {
  color: var(--red);
}

.admin-summary strong.warning-value {
  color: var(--orange);
}

.admin-summary span {
  color: var(--muted);
  font-size: 7px;
}

.admin-search {
  margin: 0 20px 8px;
  background: #fff;
}

.admin-user-list {
  flex: 1;
  min-height: 180px;
  overflow-y: auto;
  padding: 0 14px 10px;
}

.admin-user-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 7px;
  padding: 11px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: #fff;
}

.admin-user-copy {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
}

.admin-user-name {
  display: flex;
  align-items: center;
  gap: 6px;
}

.admin-user-name strong {
  font-size: 10px;
}

.status-chip {
  padding: 1px 5px;
  border-radius: 5px;
  font-size: 6px;
  font-weight: 700;
}

.status-chip.normal {
  color: var(--green);
  background: var(--green-soft);
}

.status-chip.muted {
  color: #9a741d;
  background: #fbf1cf;
}

.status-chip.banned {
  color: #aa4e42;
  background: #fde9e6;
}

.admin-user-copy > span,
.admin-user-copy > small {
  margin-top: 1px;
  color: var(--muted);
  font-size: 7px;
}

.admin-user-copy > small {
  font-family: "SFMono-Regular", Consolas, monospace;
  color: #7d9486;
}

.restriction-detail {
  margin-top: 3px;
  color: #b0604e;
  font-size: 7px;
}

.admin-row-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 4px;
  max-width: 150px;
}

.admin-action-button {
  height: 27px;
  padding: 0 8px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  font-size: 7px;
  font-weight: 600;
}

.admin-action-button:hover {
  background: #f7f7f2;
}

.admin-action-button.mute {
  color: #98731d;
}

.admin-action-button.ban {
  color: #b45346;
}

.admin-action-button.lift {
  color: var(--green);
  border-color: #c8ddcf;
  background: var(--green-pale);
}

.admin-list-empty {
  padding: 45px 10px;
  color: var(--muted);
  font-size: 9px;
  text-align: center;
}

.admin-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 20px calc(12px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
  background: #fff;
  color: var(--muted);
  font-size: 7px;
}

.admin-footer .text-button {
  font-size: 8px;
}

.moderation-modal {
  width: min(100%, 480px);
}

.moderation-modal form {
  display: flex;
  flex-direction: column;
  gap: 13px;
  padding: 0 23px 22px;
}

.moderation-target {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 10px;
  border-radius: 10px;
  background: #f8f8f3;
}

.moderation-target > div {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
}

.moderation-target strong {
  font-size: 10px;
}

.moderation-target span:not(.category-badge):not(.avatar) {
  margin-top: 2px;
  color: var(--muted);
  font-size: 7px;
}

.duration-row {
  display: grid;
  grid-template-columns: 1fr 105px;
  gap: 8px;
}

.duration-row .input-wrap {
  height: 44px;
}

.input-suffix {
  flex: 0 0 auto;
  color: var(--muted);
  font-size: 8px;
}

.moderation-warning {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 10px 11px;
  border-radius: 9px;
  color: #825f2b;
  background: #fff8e7;
}

.moderation-warning .icon {
  width: 15px;
  height: 15px;
  margin-top: 1px;
  color: #b2873d;
}

.moderation-warning p {
  font-size: 8px;
  line-height: 1.6;
}

.danger-button {
  min-height: 41px;
  padding: 0 17px;
  border-radius: 9px;
  color: #fff;
  background: #b75143;
  font-size: 9px;
  font-weight: 700;
}

.danger-button:hover {
  background: #9e4135;
}

/* Identity, social profile and points */

.profile-link,
.comment-avatar-button,
.comment-author-button {
  padding: 0;
  border: 0;
  color: inherit;
  background: transparent;
  text-align: left;
}

.post-author.profile-link {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 9px;
}

.post-author.profile-link:hover .post-author-line,
.detail-author-copy.profile-link:hover strong,
.comment-author-button:hover {
  color: var(--green);
}

.detail-author-copy.profile-link {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
  align-items: flex-start;
}

.comment-avatar-button {
  flex: 0 0 auto;
  border-radius: 50%;
}

.comment-author-button {
  font-size: 9px;
  font-weight: 700;
}

.comment-delete {
  margin-left: auto;
  color: #b55a4d !important;
}

.admin-user-badge {
  display: inline-flex;
  height: 19px;
  align-items: center;
  gap: 3px;
  padding: 0 7px;
  border: 1px solid rgba(206, 158, 54, 0.22);
  border-radius: 9px;
  color: #8a671a;
  background:
    linear-gradient(135deg, rgba(255, 248, 215, 0.92), rgba(247, 221, 139, 0.66));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.75);
  font-size: 7px;
  font-weight: 800;
  white-space: nowrap;
}

.admin-user-badge .icon {
  width: 10px;
  height: 10px;
}

.admin-user-badge.compact {
  height: 16px;
  padding: 0 5px;
  font-size: 6px;
}

.admin-user-badge.compact .icon {
  width: 8px;
  height: 8px;
}

.avatar.avatar-admin {
  box-shadow:
    0 0 0 2px rgba(243, 205, 103, 0.78),
    0 0 15px rgba(243, 205, 103, 0.32);
}

.mobile-avatar.avatar-admin {
  box-shadow:
    0 0 0 2px rgba(243, 205, 103, 0.82),
    0 0 14px rgba(243, 205, 103, 0.36);
}

.admin-reaction-mark {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  color: #a77d19;
  font-size: 7px;
  white-space: nowrap;
}

.admin-reaction-mark .icon,
.admin-comment-reaction .icon {
  width: 10px;
  height: 10px;
}

.admin-comment-reaction {
  display: inline-flex;
  color: #b28a2b;
}

.avatar-frame-aurora {
  position: relative;
  isolation: isolate;
  box-shadow:
    0 0 0 2px rgba(255, 255, 255, 0.86),
    0 0 0 4px rgba(82, 213, 185, 0.65),
    0 0 18px rgba(87, 218, 198, 0.42),
    inset 0 1px 1px rgba(255, 255, 255, 0.6) !important;
  animation: aurora-frame 4.8s ease-in-out infinite;
}

.avatar-frame-aurora::after {
  position: absolute;
  z-index: -1;
  inset: -4px;
  border-radius: inherit;
  background: conic-gradient(
    from 0deg,
    rgba(116, 231, 211, 0.8),
    rgba(128, 172, 255, 0.2),
    rgba(246, 217, 123, 0.72),
    rgba(116, 231, 211, 0.8)
  );
  content: "";
  animation: aurora-spin 6s linear infinite;
}

.avatar-frame-starlight {
  box-shadow:
    0 0 0 2px rgba(255, 255, 255, 0.9),
    0 0 0 4px rgba(232, 193, 94, 0.78),
    0 0 20px rgba(235, 193, 87, 0.45),
    inset 0 1px 1px rgba(255, 255, 255, 0.7) !important;
}

.avatar-frame-starlight::after {
  position: absolute;
  z-index: -1;
  inset: -6px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 15% 24%, #fff 0 1px, transparent 1.4px),
    radial-gradient(circle at 84% 70%, #fff5c4 0 1.2px, transparent 1.7px),
    radial-gradient(circle at 55% 4%, #fff 0 1px, transparent 1.4px),
    transparent;
  content: "";
}

.avatar-frame-blossom {
  box-shadow:
    0 0 0 2px rgba(255, 255, 255, 0.9),
    0 0 0 4px rgba(244, 164, 145, 0.62),
    0 0 18px rgba(242, 166, 148, 0.38),
    inset 0 1px 1px rgba(255, 255, 255, 0.7) !important;
}

.avatar-frame-blossom::after {
  position: absolute;
  z-index: -1;
  inset: -4px;
  border-radius: 50%;
  background: conic-gradient(
    from 30deg,
    rgba(255, 178, 152, 0.9),
    rgba(133, 214, 169, 0.25),
    rgba(247, 211, 117, 0.8),
    rgba(255, 178, 152, 0.9)
  );
  content: "";
}

.avatar-frame-prism {
  box-shadow:
    0 0 0 2px rgba(255, 255, 255, 0.92),
    0 0 0 4px rgba(105, 165, 230, 0.68),
    3px 0 15px rgba(104, 176, 232, 0.35),
    -3px 0 15px rgba(159, 127, 218, 0.35),
    inset 0 1px 1px rgba(255, 255, 255, 0.7) !important;
}

.avatar-frame-prism::after {
  position: absolute;
  z-index: -1;
  inset: -4px;
  border-radius: 50%;
  background: conic-gradient(
    from 190deg,
    rgba(92, 179, 232, 0.86),
    rgba(255, 255, 255, 0.15),
    rgba(159, 127, 218, 0.8),
    rgba(92, 179, 232, 0.86)
  );
  content: "";
}

@keyframes aurora-frame {
  50% {
    box-shadow:
      0 0 0 2px rgba(255, 255, 255, 0.86),
      0 0 0 4px rgba(109, 171, 255, 0.62),
      0 0 23px rgba(87, 218, 198, 0.55),
      inset 0 1px 1px rgba(255, 255, 255, 0.6) !important;
  }
}

@keyframes aurora-spin {
  to {
    transform: rotate(360deg);
  }
}

.post-frame-ember,
.forum-bubble-ember {
  position: relative;
  border-color: rgba(214, 167, 65, 0.56) !important;
  box-shadow:
    0 0 0 1px rgba(255, 234, 177, 0.48),
    0 14px 36px rgba(118, 83, 23, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.9) !important;
}

.post-frame-ember::after,
.forum-bubble-ember::after {
  position: absolute;
  z-index: 2;
  inset: -1px;
  padding: 1px;
  border-radius: inherit;
  background: conic-gradient(
    from 90deg,
    rgba(247, 205, 104, 0.85),
    rgba(255, 255, 255, 0.12),
    rgba(232, 110, 76, 0.5),
    rgba(247, 205, 104, 0.85)
  );
  content: "";
  pointer-events: none;
  -webkit-mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
}

.post-frame-frost,
.forum-bubble-frost {
  position: relative;
  border-color: rgba(111, 171, 212, 0.52) !important;
  box-shadow:
    0 0 0 1px rgba(205, 238, 255, 0.55),
    0 14px 36px rgba(63, 114, 148, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.94) !important;
}

.post-frame-frost::after,
.forum-bubble-frost::after {
  position: absolute;
  z-index: 2;
  inset: -1px;
  padding: 1px;
  border-radius: inherit;
  background: conic-gradient(
    from 220deg,
    rgba(126, 195, 236, 0.8),
    rgba(255, 255, 255, 0.12),
    rgba(180, 161, 230, 0.55),
    rgba(126, 195, 236, 0.8)
  );
  content: "";
  pointer-events: none;
  -webkit-mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
}

.profile-like-count {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 7px;
  color: rgba(255, 255, 255, 0.62);
  font-size: 7px;
}

.profile-like-count .icon {
  width: 11px;
  height: 11px;
  color: #f1c55f;
  fill: rgba(241, 197, 95, 0.3);
}

.shop-entry {
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 12px;
  padding: 10px;
  border: 1px solid rgba(210, 222, 211, 0.9);
  border-radius: 9px;
  color: var(--ink);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.72), rgba(230, 243, 235, 0.5));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.92);
  text-align: left;
}

.shop-entry:hover {
  border-color: rgba(33, 107, 77, 0.3);
  transform: translateY(-1px);
}

.shop-entry > span:first-child {
  display: grid;
  min-width: 0;
  grid-template-columns: 17px 1fr;
  align-items: center;
  gap: 1px 6px;
}

.shop-entry > span:first-child .icon {
  grid-row: 1 / 3;
  width: 16px;
  height: 16px;
  color: #a77c1d;
  fill: #f3ce69;
}

.shop-entry b {
  font-size: 8px;
}

.shop-entry small {
  color: var(--muted);
  font-size: 6px;
}

.shop-entry-balance {
  display: flex;
  align-items: center;
  gap: 3px;
  color: var(--green);
  font-size: 7px;
  white-space: nowrap;
}

.shop-entry-balance b {
  font-family: Georgia, serif;
  font-size: 11px;
}

.shop-entry-balance .icon {
  width: 11px;
  height: 11px;
}

.setting-row > small {
  color: var(--muted);
  font-size: 7px;
}

.user-profile-modal {
  width: min(100%, 570px);
}

.public-profile-cover {
  position: relative;
  min-height: 156px;
  overflow: hidden;
  padding: 28px 24px 22px;
  color: #fff;
  background:
    radial-gradient(circle at 82% 20%, rgba(245, 210, 110, 0.26), transparent 26%),
    linear-gradient(130deg, rgba(27, 91, 64, 0.94), rgba(15, 47, 34, 0.96));
}

.public-profile-orbs {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 12% 80%, rgba(115, 198, 154, 0.22), transparent 20%),
    radial-gradient(circle at 92% 95%, rgba(255, 255, 255, 0.1), transparent 22%);
}

.public-profile-close {
  position: absolute;
  z-index: 2;
  top: 12px;
  right: 12px;
  color: rgba(255, 255, 255, 0.75);
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(12px);
}

.public-profile-identity {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 42px;
}

.public-profile-identity .profile-avatar {
  width: 72px;
  height: 72px;
  font-size: 25px;
}

.public-profile-identity > div {
  min-width: 0;
}

.public-profile-name {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px;
}

.public-profile-name h2 {
  font-family: var(--serif);
  font-size: 22px;
}

.public-profile-identity p {
  margin-top: 3px;
  color: rgba(255, 255, 255, 0.56);
  font-size: 8px;
}

.public-level {
  display: inline-block;
  margin-top: 6px;
  padding: 2px 7px;
  border: 1px solid rgba(245, 212, 119, 0.2);
  border-radius: 8px;
  color: #f4d477;
  background: rgba(245, 212, 119, 0.08);
  font-size: 7px;
}

.public-profile-body {
  padding: 18px 22px 22px;
}

.public-profile-bio {
  color: #5f6a63;
  font-size: 9px;
  line-height: 1.75;
}

.public-tags {
  margin-top: 8px;
}

.public-tags span {
  padding: 2px 7px;
  border: 1px solid var(--line);
  color: var(--muted);
  background: rgba(255, 255, 255, 0.55);
}

.public-profile-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  margin: 16px 0;
  padding: 11px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.public-profile-stats div {
  display: flex;
  flex-direction: column;
  align-items: center;
  border-left: 1px solid var(--line);
}

.public-profile-stats div:first-child {
  border-left: 0;
}

.public-profile-stats strong {
  font-family: Georgia, serif;
  font-size: 14px;
}

.public-profile-stats span {
  margin-top: 1px;
  color: var(--muted);
  font-size: 6px;
}

.public-profile-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 7px;
}

.profile-like-button {
  display: inline-flex;
  min-height: 36px;
  align-items: center;
  gap: 5px;
  padding: 0 10px;
  border: 1px solid rgba(216, 82, 80, 0.16);
  border-radius: 9px;
  color: #bd5a54;
  background: rgba(255, 241, 237, 0.72);
  font-size: 8px;
  font-weight: 700;
}

.profile-like-button .icon {
  width: 14px;
  height: 14px;
  fill: rgba(216, 82, 80, 0.15);
}

.profile-like-button:hover {
  background: #fff0eb;
}

.profile-like-button small {
  color: #b47f78;
  font-size: 6px;
}

.profile-like-button.limit {
  color: var(--muted);
  background: #f3f3ee;
}

.public-profile-actions .primary-button,
.public-profile-actions .secondary-button {
  min-height: 36px;
  font-size: 8px;
}

.admin-public-edit {
  margin-left: auto;
  border: 1px solid var(--line);
}

.public-recent-posts {
  margin-top: 17px;
}

.public-section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 7px;
  font-family: var(--serif);
  font-size: 12px;
  font-weight: 700;
}

.public-section-title small {
  color: var(--muted);
  font-family: var(--sans);
  font-size: 7px;
  font-weight: 500;
}

.public-post-row {
  display: flex;
  width: 100%;
  align-items: center;
  gap: 8px;
  padding: 9px 8px;
  border-radius: 8px;
  background: transparent;
  text-align: left;
}

.public-post-row:hover {
  background: rgba(233, 243, 237, 0.76);
}

.public-post-row strong {
  min-width: 0;
  flex: 1;
  overflow: hidden;
  font-family: var(--serif);
  font-size: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.public-post-row small {
  color: var(--muted);
  font-size: 7px;
}

.public-posts-empty {
  padding: 14px 0;
  color: var(--muted);
  font-size: 8px;
  text-align: center;
}

.points-shop-modal {
  width: min(100%, 650px);
}

.shop-balance {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  margin: 0 22px 14px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.78);
  border-radius: 13px;
  background:
    radial-gradient(circle at 100% 0%, rgba(245, 210, 113, 0.22), transparent 45%),
    linear-gradient(135deg, rgba(26, 87, 62, 0.93), rgba(22, 58, 42, 0.92));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.22),
    0 10px 26px rgba(29, 69, 48, 0.16);
}

.shop-balance div {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding: 14px 8px;
  border-left: 1px solid rgba(255, 255, 255, 0.11);
  color: #fff;
}

.shop-balance div:first-child {
  border-left: 0;
}

.shop-balance span {
  color: rgba(255, 255, 255, 0.52);
  font-size: 7px;
}

.shop-balance strong {
  font-family: Georgia, serif;
  font-size: 22px;
  font-weight: 500;
}

.shop-balance strong b {
  font-weight: 500;
}

.shop-balance strong small {
  margin-left: 2px;
  color: rgba(255, 255, 255, 0.45);
  font-family: var(--sans);
  font-size: 8px;
}

.shop-balance .shop-level {
  color: #f4d577;
  font-size: 18px;
}

.shop-products {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 11px;
  padding: 0 22px;
}

.shop-product {
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.56);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.88),
    0 7px 20px rgba(35, 66, 47, 0.07);
  backdrop-filter: blur(18px);
}

.shop-product.equipped {
  border-color: rgba(199, 160, 68, 0.42);
}

.shop-product-preview {
  display: grid;
  height: 112px;
  place-items: center;
  background:
    radial-gradient(circle at 30% 20%, rgba(137, 214, 177, 0.28), transparent 40%),
    radial-gradient(circle at 72% 78%, rgba(246, 208, 112, 0.22), transparent 38%),
    rgba(236, 244, 238, 0.66);
}

.avatar-xl {
  width: 62px;
  height: 62px;
  font-size: 22px;
}

.shop-post-preview {
  position: relative;
  display: flex;
  width: 145px;
  height: 72px;
  flex-direction: column;
  gap: 7px;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.68);
  box-shadow: 0 8px 20px rgba(44, 68, 50, 0.08);
}

.shop-post-preview span {
  height: 6px;
  border-radius: 4px;
  background: rgba(55, 87, 67, 0.16);
}

.shop-post-preview span:first-child {
  width: 67%;
  height: 8px;
  background: rgba(42, 82, 58, 0.26);
}

.shop-post-preview span:last-child {
  width: 82%;
}

.shop-product-copy {
  padding: 12px;
}

.shop-product-title {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 5px;
}

.shop-product-title h3 {
  font-family: var(--serif);
  font-size: 13px;
}

.shop-product-title span {
  color: #9b741b;
  font-family: Georgia, serif;
  font-size: 10px;
  white-space: nowrap;
}

.shop-product-copy p {
  min-height: 34px;
  margin: 5px 0 10px;
  color: var(--muted);
  font-size: 7px;
  line-height: 1.65;
}

.shop-product-copy .primary-button,
.shop-product-copy .secondary-button {
  min-height: 34px;
  font-size: 8px;
}

.shop-note {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 13px 20px calc(18px + env(safe-area-inset-bottom));
  color: var(--muted);
  font-size: 7px;
}

.shop-note .icon {
  width: 13px;
  height: 13px;
  color: #ad831e;
}

.mall-hero {
  position: relative;
  display: grid;
  min-height: 184px;
  grid-template-columns: 1fr 220px;
  align-items: center;
  gap: 24px;
  overflow: hidden;
  padding: 26px 29px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 20px;
  color: #fff;
  background:
    radial-gradient(circle at 83% 18%, rgba(245, 210, 111, 0.24), transparent 24%),
    radial-gradient(circle at 9% 100%, rgba(107, 206, 163, 0.26), transparent 31%),
    linear-gradient(128deg, rgba(25, 98, 66, 0.94), rgba(14, 53, 36, 0.96));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.25),
    0 20px 48px rgba(19, 71, 43, 0.2);
  backdrop-filter: blur(28px) saturate(135%);
}

.mall-hero::before {
  position: absolute;
  inset: 0;
  opacity: 0.15;
  background-image: radial-gradient(rgba(255, 255, 255, 0.85) 0.6px, transparent 0.7px);
  background-size: 13px 13px;
  content: "";
  -webkit-mask-image: linear-gradient(90deg, transparent 25%, #000);
  mask-image: linear-gradient(90deg, transparent 25%, #000);
}

.mall-hero-copy {
  position: relative;
  z-index: 2;
}

.mall-hero h2 {
  max-width: 470px;
  margin: 8px 0 8px;
  font-family: var(--serif);
  font-size: clamp(20px, 2.2vw, 26px);
  line-height: 1.45;
}

.mall-hero p {
  max-width: 450px;
  color: rgba(255, 255, 255, 0.58);
  font-size: 8px;
  line-height: 1.75;
}

.mall-balance-card {
  position: relative;
  z-index: 2;
  min-width: 190px;
  padding: 16px 17px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 16px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.17), rgba(255, 255, 255, 0.07));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.28),
    0 12px 28px rgba(7, 31, 18, 0.12);
  backdrop-filter: blur(18px);
}

.mall-balance-card > span {
  color: rgba(255, 255, 255, 0.54);
  font-size: 8px;
}

.mall-balance-card > strong {
  display: block;
  margin: 1px 0 8px;
  font-family: Georgia, serif;
  font-size: 34px;
  font-weight: 500;
  line-height: 1;
}

.mall-balance-card > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding-top: 8px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.mall-balance-card small {
  color: rgba(255, 255, 255, 0.46);
  font-size: 7px;
}

.mall-balance-card small b {
  color: #f4d477;
  font-weight: 700;
}

.mall-glints i {
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.62);
  box-shadow: 0 0 15px rgba(255, 255, 255, 0.7);
}

.mall-glints i:first-child {
  top: 24px;
  right: 260px;
  width: 4px;
  height: 4px;
}

.mall-glints i:nth-child(2) {
  right: 43px;
  bottom: 25px;
  width: 3px;
  height: 3px;
}

.mall-glints i:nth-child(3) {
  top: 38px;
  right: 55px;
  width: 2px;
  height: 2px;
}

.mall-section-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin: 21px 2px 11px;
}

.mall-section-heading h2 {
  margin-top: 3px;
  font-family: var(--serif);
  font-size: 19px;
}

.mall-section-heading > span {
  color: var(--muted);
  font-size: 7px;
}

.mall-products {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.mall-products .shop-product {
  overflow: hidden;
}

.mall-products .shop-product-preview {
  height: 122px;
}

.mall-footnote {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  margin-top: 15px;
  padding: 10px;
  color: var(--muted);
  font-size: 7px;
  text-align: center;
}

.mall-footnote .icon {
  width: 12px;
  height: 12px;
  color: #a57b1c;
}

.message-receipt {
  display: block;
  margin-top: 1px;
  color: #9aa39c;
  font-size: 6px;
  font-weight: 500;
}

.message-row.mine .message-receipt {
  color: var(--green);
}

.admin-tabs {
  display: flex;
  gap: 4px;
  margin: 0 20px 10px;
  padding: 3px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.5);
  backdrop-filter: blur(16px);
}

.admin-tabs button {
  height: 31px;
  flex: 1;
  border-radius: 7px;
  color: var(--muted);
  background: transparent;
  font-size: 8px;
  font-weight: 600;
}

.admin-tabs button.active {
  color: var(--green-deep);
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 2px 9px rgba(39, 72, 51, 0.08);
}

.admin-user-row.protected-admin,
.admin-content-row.protected-admin {
  border-color: rgba(219, 189, 106, 0.36);
  background:
    linear-gradient(135deg, rgba(255, 252, 239, 0.74), rgba(255, 255, 255, 0.55));
}

.status-chip.admin {
  color: #8c6917;
  background: rgba(247, 224, 151, 0.6);
}

.admin-protected-label {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 3px 6px;
  border-radius: 6px;
  color: #9b7b34;
  background: rgba(247, 232, 184, 0.56);
  font-size: 6px;
  white-space: nowrap;
}

.admin-action-button.edit {
  color: var(--green);
}

.admin-action-button .icon {
  width: 10px;
  height: 10px;
}

.admin-content-row {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 7px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: rgba(255, 255, 255, 0.67);
  backdrop-filter: blur(14px);
}

.admin-content-copy {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
}

.admin-content-copy > strong {
  overflow: hidden;
  font-family: var(--serif);
  font-size: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-content-copy > span {
  overflow: hidden;
  margin-top: 2px;
  color: #657069;
  font-size: 7px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-content-copy > small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 6px;
}

.admin-content-actions {
  display: flex;
  align-items: center;
  gap: 4px;
}

.comment-content-row .admin-content-copy > strong {
  font-family: var(--sans);
}

.admin-user-edit-modal {
  display: flex;
  width: min(100%, 560px);
  max-height: min(90dvh, 900px);
  flex-direction: column;
  overflow: hidden;
}

.admin-user-edit-modal form {
  display: flex;
  min-height: 0;
  flex: 1;
  flex-direction: column;
  gap: 12px;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 0 23px 22px;
  -webkit-overflow-scrolling: touch;
}

.admin-user-edit-modal textarea {
  padding: 10px 12px;
  border: 1px solid var(--line-strong);
  border-radius: 9px;
  font-size: 10px;
}

.admin-promoter-summary {
  margin-top: 4px !important;
  color: #7b5a16 !important;
  font-weight: 700;
}

.admin-edit-section {
  display: flex;
  flex-direction: column;
  gap: 9px;
  padding: 12px;
  border: 1px solid var(--ui-border);
  border-radius: 13px;
  background: var(--ui-surface-soft);
}

.admin-edit-section-head {
  display: flex;
  align-items: center;
  gap: 9px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--ui-border);
}

.admin-edit-section-head > span {
  display: grid;
  width: 24px;
  height: 24px;
  flex: 0 0 24px;
  place-items: center;
  border-radius: 8px;
  color: #805e18;
  background: rgba(232, 195, 101, 0.24);
  font-family: Georgia, serif;
  font-size: 9px;
}

.admin-edit-section-head > div {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.admin-edit-section-head strong {
  color: var(--ui-text);
  font-size: 11px;
}

.admin-edit-section-head small,
.admin-custom-title-editor > small {
  color: var(--ui-text-muted);
  font-size: 8px;
  line-height: 1.5;
}

.admin-user-edit-modal .modal-form-actions {
  position: sticky;
  z-index: 3;
  bottom: 0;
  align-items: center;
  margin: 2px -23px -22px;
  padding: 12px 23px max(14px, env(safe-area-inset-bottom));
  border-top: 1px solid var(--ui-border);
  background: color-mix(in srgb, var(--ui-surface) 92%, transparent);
  backdrop-filter: blur(18px);
}

.admin-edit-save-note {
  margin-right: auto;
  color: var(--ui-text-muted);
  font-size: 8px;
}

.admin-promoter-editor {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 13px;
  border: 1px solid rgba(197, 155, 56, 0.24);
  border-radius: 13px;
  background:
    radial-gradient(circle at 92% 0%, rgba(232, 194, 98, 0.16), transparent 42%),
    var(--ui-surface-soft);
}

.admin-promoter-editor-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.admin-promoter-editor-head h3 {
  margin-top: 2px;
  color: var(--ui-text);
  font-family: var(--serif);
  font-size: 15px;
}

.admin-promoter-editor-head > span {
  padding: 4px 8px;
  border: 1px solid var(--ui-border);
  border-radius: 999px;
  color: var(--ui-text-muted);
  background: var(--ui-surface);
  font-size: 8px;
  font-weight: 800;
  white-space: nowrap;
}

.admin-promoter-editor-head > span.active {
  color: #765714;
  border-color: rgba(197, 155, 56, 0.28);
  background: #fff3ca;
}

.admin-promoter-editor > small {
  color: var(--ui-text-muted);
  font-size: 8px;
  line-height: 1.55;
}

html[data-theme="dark"] .admin-promoter-editor {
  border-color: rgba(226, 191, 95, 0.22);
  background:
    radial-gradient(circle at 92% 0%, rgba(169, 126, 34, 0.17), transparent 44%),
    #141c18;
}

html[data-theme="dark"] .admin-promoter-editor-head > span.active {
  color: #efd98f;
  border-color: rgba(226, 191, 95, 0.24);
  background: rgba(103, 79, 25, 0.48);
}

html[data-theme="dark"] .admin-promoter-summary {
  color: #e6c973 !important;
}

html[data-theme="dark"] .admin-edit-section {
  border-color: var(--ui-border);
  background: #141c18;
}

html[data-theme="dark"] .admin-edit-section-head > span {
  color: #efd88c;
  background: rgba(115, 87, 27, 0.46);
}

html[data-theme="dark"] .admin-user-edit-modal .modal-form-actions {
  background: rgba(25, 36, 29, 0.94);
}

/* Liquid glass visual system */

body {
  position: relative;
  isolation: isolate;
  background:
    radial-gradient(circle at 8% 8%, rgba(250, 255, 250, 0.98), transparent 30rem),
    radial-gradient(circle at 88% 11%, rgba(223, 212, 252, 0.72), transparent 28rem),
    radial-gradient(circle at 80% 76%, rgba(249, 222, 158, 0.53), transparent 30rem),
    radial-gradient(circle at 17% 83%, rgba(173, 230, 204, 0.7), transparent 27rem),
    linear-gradient(145deg, #e4eee7 0%, #edf2ea 45%, #e7edf6 100%);
  background-attachment: fixed;
}

body::before {
  position: fixed;
  z-index: -1;
  inset: 0;
  opacity: 0.28;
  background-image:
    radial-gradient(rgba(255, 255, 255, 0.9) 0.7px, transparent 0.8px),
    linear-gradient(120deg, transparent 20%, rgba(255, 255, 255, 0.33), transparent 80%);
  background-size: 15px 15px, 100% 100%;
  content: "";
  pointer-events: none;
}

.app {
  position: relative;
}

.app::before,
.app::after {
  position: fixed;
  z-index: -1;
  border-radius: 50%;
  content: "";
  filter: blur(3px);
  pointer-events: none;
}

.app::before {
  top: 14%;
  left: 15%;
  width: 210px;
  height: 210px;
  background: rgba(255, 255, 255, 0.35);
  box-shadow: 0 0 120px 50px rgba(255, 255, 255, 0.26);
}

.app::after {
  right: 6%;
  bottom: 10%;
  width: 260px;
  height: 260px;
  background: rgba(161, 219, 198, 0.2);
  box-shadow: 0 0 130px 55px rgba(161, 219, 198, 0.2);
}

.category-tabs,
.quick-compose,
.post-card,
.mini-profile-card,
.rail-card,
.profile-activity-card,
.achievement-card,
.account-card,
.messages-layout,
.modal,
.community-rule,
.nav-item.active,
.search-trigger,
.notification-button {
  border: 1px solid rgba(255, 255, 255, 0.74);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.79), rgba(255, 255, 255, 0.5));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.92),
    inset 0 -1px 0 rgba(255, 255, 255, 0.25),
    0 12px 34px rgba(31, 61, 42, 0.08);
  backdrop-filter: blur(24px) saturate(145%);
  -webkit-backdrop-filter: blur(24px) saturate(145%);
}

.post-card,
.mini-profile-card,
.rail-card,
.profile-activity-card,
.achievement-card,
.account-card,
.messages-layout,
.modal {
  border-radius: 18px;
}

.post-card:hover {
  border-color: rgba(255, 255, 255, 0.96);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.95),
    0 18px 44px rgba(32, 72, 48, 0.13);
  transform: translateY(-2px);
}

.sidebar .brand {
  padding-left: 5px;
}

.nav-item {
  border: 1px solid transparent;
}

.nav-item.active {
  border-color: rgba(255, 255, 255, 0.8);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.86), rgba(244, 255, 248, 0.56));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.96),
    0 8px 24px rgba(33, 76, 49, 0.08);
}

.board-intro {
  border: 1px solid rgba(255, 255, 255, 0.19);
  background:
    radial-gradient(circle at 82% 18%, rgba(153, 227, 189, 0.32), transparent 27%),
    radial-gradient(circle at 12% 110%, rgba(237, 203, 111, 0.17), transparent 35%),
    linear-gradient(125deg, rgba(29, 100, 69, 0.88), rgba(15, 55, 38, 0.91));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.24),
    0 18px 42px rgba(21, 67, 44, 0.18);
  backdrop-filter: blur(22px) saturate(125%);
}

.board-intro[data-category] {
  background:
    radial-gradient(circle at 84% 24%, rgba(255, 255, 255, 0.19), transparent 28%),
    linear-gradient(125deg, rgba(35, 103, 74, 0.9), rgba(16, 54, 39, 0.92));
}

.quick-compose {
  border-radius: 17px;
}

.quick-compose:focus-within,
.quick-compose:hover {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.91), rgba(245, 255, 248, 0.63));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.99),
    0 17px 40px rgba(30, 77, 49, 0.12);
}

.primary-button {
  border: 1px solid rgba(255, 255, 255, 0.22);
  background:
    linear-gradient(135deg, rgba(58, 145, 103, 0.98), rgba(20, 94, 64, 0.98));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.32),
    0 8px 23px rgba(33, 107, 77, 0.25);
}

.primary-button:hover {
  background:
    linear-gradient(135deg, rgba(66, 155, 113, 1), rgba(18, 82, 55, 1));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.38),
    0 11px 27px rgba(33, 107, 77, 0.3);
}

.secondary-button {
  border-color: rgba(255, 255, 255, 0.78);
  background: rgba(255, 255, 255, 0.46);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.86);
  backdrop-filter: blur(12px);
}

.post-actions {
  border-top-color: rgba(161, 177, 166, 0.18);
}

.profile-hero {
  border: 1px solid rgba(255, 255, 255, 0.22);
  background:
    radial-gradient(circle at 88% 10%, rgba(249, 217, 126, 0.22), transparent 27%),
    radial-gradient(circle at 4% 100%, rgba(123, 199, 158, 0.22), transparent 34%),
    linear-gradient(130deg, rgba(36, 105, 75, 0.91), rgba(15, 56, 39, 0.94));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.24),
    0 18px 44px rgba(24, 76, 47, 0.18);
  backdrop-filter: blur(25px) saturate(130%);
}

.growth-ring {
  background: conic-gradient(var(--green) 0 0%, rgba(255, 255, 255, 0.24) 0);
}

.growth-ring::before {
  background: rgba(255, 255, 255, 0.82);
  box-shadow: inset 0 1px 4px rgba(40, 81, 54, 0.08);
}

.messages-layout {
  overflow: hidden;
}

.conversation-panel {
  border-right-color: rgba(164, 177, 168, 0.2);
  background: rgba(250, 253, 249, 0.36);
}

.chat-panel {
  background:
    radial-gradient(circle at 100% 0%, rgba(218, 238, 225, 0.55), transparent 15rem);
}

.conversation-item.active {
  border: 1px solid rgba(255, 255, 255, 0.8);
  background: rgba(255, 255, 255, 0.72);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.93),
    0 4px 14px rgba(34, 75, 48, 0.07);
}

.message-bubble {
  border: 1px solid rgba(255, 255, 255, 0.7);
  background: rgba(255, 255, 255, 0.73);
  backdrop-filter: blur(13px);
}

.message-row.mine .message-bubble {
  border-color: rgba(255, 255, 255, 0.18);
  background:
    linear-gradient(135deg, rgba(49, 135, 95, 0.94), rgba(24, 100, 69, 0.95));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.24),
    0 5px 16px rgba(29, 101, 66, 0.15);
}

.chat-header,
.chat-composer {
  background: rgba(255, 255, 255, 0.52);
  backdrop-filter: blur(18px);
}

.modal-backdrop {
  background:
    radial-gradient(circle at 25% 16%, rgba(177, 225, 204, 0.2), transparent 27rem),
    rgba(13, 31, 21, 0.46);
  backdrop-filter: blur(14px) saturate(115%);
  -webkit-backdrop-filter: blur(14px) saturate(115%);
}

.modal {
  border: 1px solid rgba(255, 255, 255, 0.85);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.93), rgba(247, 251, 247, 0.8));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.97),
    0 30px 90px rgba(11, 41, 24, 0.24);
  backdrop-filter: blur(32px) saturate(145%);
}

.input-wrap,
.messages-search,
.admin-search,
.friend-search-result,
.moderation-target,
.public-tags span {
  border-color: rgba(255, 255, 255, 0.76);
  background: rgba(255, 255, 255, 0.46);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(13px);
}

.input-wrap:focus-within,
.messages-search:focus-within {
  border-color: rgba(91, 159, 121, 0.54);
  background: rgba(255, 255, 255, 0.72);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.92),
    0 0 0 3px rgba(52, 131, 91, 0.08);
}

.admin-modal,
.detail-modal {
  background:
    linear-gradient(145deg, rgba(250, 253, 250, 0.94), rgba(239, 246, 241, 0.87));
}

.admin-summary {
  border-color: rgba(255, 255, 255, 0.75);
  background: rgba(255, 255, 255, 0.48);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(16px);
}

.admin-user-row,
.admin-content-row,
.friend-request-row {
  border-color: rgba(255, 255, 255, 0.74);
  background: rgba(255, 255, 255, 0.52);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.86);
  backdrop-filter: blur(15px);
}

.admin-user-row.protected-admin,
.admin-content-row.protected-admin {
  border-color: rgba(223, 193, 110, 0.34);
  background:
    linear-gradient(135deg, rgba(255, 252, 238, 0.73), rgba(255, 255, 255, 0.48));
}

.admin-footer,
.detail-topbar {
  background: rgba(255, 255, 255, 0.53);
  backdrop-filter: blur(18px);
}

.shop-product {
  border-color: rgba(255, 255, 255, 0.86);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.74), rgba(255, 255, 255, 0.4));
}

.auth-panel {
  background:
    radial-gradient(circle at 88% 11%, rgba(221, 211, 249, 0.46), transparent 20rem),
    radial-gradient(circle at 10% 88%, rgba(174, 226, 198, 0.44), transparent 20rem),
    rgba(242, 247, 241, 0.66);
  backdrop-filter: blur(28px);
}

.auth-card {
  padding: 25px;
  border: 1px solid rgba(255, 255, 255, 0.64);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.34);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.86),
    0 24px 65px rgba(32, 76, 48, 0.1);
  backdrop-filter: blur(24px) saturate(135%);
}

.mobile-header,
.mobile-nav {
  border-color: rgba(255, 255, 255, 0.68);
  background: rgba(244, 250, 245, 0.72);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.88),
    0 -8px 28px rgba(29, 65, 43, 0.07);
  backdrop-filter: blur(24px) saturate(140%);
}

.promotion-choice {
  display: flex;
  align-items: center;
  gap: 11px;
  margin: 11px 0;
  padding: 12px 13px;
  border: 1px solid rgba(228, 168, 77, 0.42);
  border-radius: 13px;
  background:
    radial-gradient(circle at 90% 0%, rgba(255, 225, 155, 0.5), transparent 42%),
    linear-gradient(135deg, rgba(255, 250, 232, 0.92), rgba(255, 244, 219, 0.68));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.9),
    0 8px 22px rgba(157, 102, 28, 0.09);
  cursor: pointer;
}

.promotion-choice > input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.promotion-choice-icon {
  display: grid;
  width: 36px;
  height: 36px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 11px;
  color: #925810;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 5px 15px rgba(164, 104, 26, 0.12);
}

.promotion-choice-icon .icon {
  width: 19px;
  height: 19px;
}

.promotion-choice-copy {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
  gap: 2px;
}

.promotion-choice-copy strong {
  color: #74440f;
  font-size: 10px;
}

.promotion-choice-copy strong b {
  margin-left: 5px;
  color: #a96918;
  font-size: 8px;
}

.promotion-choice-copy small {
  color: #98734a;
  font-size: 7px;
  line-height: 1.5;
}

.promotion-choice-price {
  flex: 0 0 auto;
  padding: 5px 8px;
  border-radius: 999px;
  color: #8a4d08;
  background: #fff1c8;
  font-size: 8px;
  font-weight: 800;
}

.promotion-choice:has(input:checked) {
  border-color: #d78c28;
  background:
    radial-gradient(circle at 90% 0%, rgba(255, 213, 114, 0.72), transparent 44%),
    linear-gradient(135deg, #fff7da, #ffe9b6);
  box-shadow:
    inset 0 1px 0 #fff,
    0 0 0 3px rgba(215, 140, 40, 0.12),
    0 10px 28px rgba(157, 102, 28, 0.13);
}

.post-promote-row {
  display: flex;
  width: 100%;
  align-items: center;
  gap: 9px;
  margin: 4px 0 9px;
  padding: 9px 11px;
  border: 1px solid rgba(218, 169, 82, 0.34);
  border-radius: 10px;
  color: #86551b;
  background: rgba(255, 247, 221, 0.68);
  text-align: left;
}

.post-promote-row > .icon {
  width: 17px;
  height: 17px;
  color: #b16e1e;
}

.post-promote-row span {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
}

.post-promote-row strong {
  font-size: 9px;
}

.post-promote-row small {
  color: #a17b4c;
  font-size: 7px;
}

.post-promote-row b {
  font-size: 8px;
  white-space: nowrap;
}

.pinned-badge.promoted {
  color: #8e5511;
  background: #fff0c8;
}

.membership-market {
  margin: 18px 0;
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: 18px;
  background:
    radial-gradient(circle at 0% 0%, rgba(237, 205, 116, 0.16), transparent 24rem),
    linear-gradient(145deg, rgba(255, 255, 255, 0.72), rgba(249, 245, 232, 0.48));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.92),
    0 14px 36px rgba(38, 63, 46, 0.08);
  backdrop-filter: blur(22px) saturate(140%);
}

.membership-market-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 15px;
}

.membership-market-head h2 {
  margin-top: 3px;
  font-family: var(--serif);
  font-size: 21px;
}

.membership-current {
  color: #78633d;
  font-size: 8px;
  text-align: right;
}

.membership-market-note {
  margin: 7px 0 13px;
  color: var(--muted);
  font-size: 8px;
  line-height: 1.6;
}

.membership-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.membership-card {
  position: relative;
  overflow: hidden;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.86);
  border-radius: 15px;
  background: rgba(255, 255, 255, 0.58);
  box-shadow: inset 0 1px 0 #fff, 0 8px 22px rgba(36, 62, 45, 0.07);
}

.membership-card::before {
  position: absolute;
  top: -38px;
  right: -28px;
  width: 105px;
  height: 105px;
  border-radius: 50%;
  background: var(--member-glow, rgba(218, 175, 77, 0.22));
  content: "";
  filter: blur(4px);
  pointer-events: none;
}

.membership-card.member-gold {
  --member-accent: #9d6914;
  --member-glow: rgba(245, 196, 76, 0.34);
  border-color: rgba(218, 171, 66, 0.5);
  background: linear-gradient(145deg, rgba(255, 251, 228, 0.88), rgba(255, 239, 190, 0.6));
}

.membership-card.member-platinum {
  --member-accent: #5b6f7c;
  --member-glow: rgba(164, 207, 229, 0.35);
  border-color: rgba(152, 190, 211, 0.54);
  background: linear-gradient(145deg, rgba(247, 252, 255, 0.9), rgba(222, 238, 247, 0.64));
}

.membership-card.member-plus {
  --member-accent: #744b9d;
  --member-glow: rgba(194, 144, 243, 0.34);
  border-color: rgba(174, 133, 214, 0.48);
  background: linear-gradient(145deg, rgba(251, 247, 255, 0.9), rgba(235, 220, 250, 0.64));
}

.membership-card.member-u {
  --member-accent: #8b5710;
  --member-glow: rgba(244, 194, 91, 0.5);
  border-color: rgba(208, 151, 45, 0.58);
  background:
    radial-gradient(circle at 100% 0%, rgba(255, 214, 105, 0.45), transparent 42%),
    linear-gradient(145deg, rgba(31, 56, 42, 0.94), rgba(17, 38, 28, 0.96));
  color: #fff6dc;
}

.membership-card.active {
  box-shadow:
    inset 0 1px 0 #fff,
    0 0 0 2px color-mix(in srgb, var(--member-accent) 36%, transparent),
    0 12px 30px rgba(44, 69, 51, 0.12);
}

.membership-card.unavailable {
  opacity: 0.72;
}

.membership-card.included {
  border-style: dashed;
  opacity: 0.78;
}

.membership-card.included button:disabled {
  color: var(--green-deep);
  background: var(--green-soft);
}

.membership-card-top {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.membership-token {
  display: grid;
  width: 33px;
  height: 33px;
  place-items: center;
  border-radius: 11px 11px 11px 4px;
  color: #fff;
  background: var(--member-accent, var(--green));
  font-family: Georgia, serif;
  font-size: 10px;
  font-weight: 700;
  box-shadow: 0 7px 16px color-mix(in srgb, var(--member-accent) 26%, transparent);
}

.membership-price {
  color: var(--member-accent, var(--muted));
  font-size: 7px;
  font-weight: 700;
}

.membership-card.member-u .membership-price {
  color: #f4cf78;
}

.membership-card h3 {
  position: relative;
  margin: 10px 0 4px;
  font-family: var(--serif);
  font-size: 15px;
}

.membership-card > p {
  position: relative;
  min-height: 34px;
  color: var(--muted);
  font-size: 7px;
  line-height: 1.6;
}

.membership-card.member-u > p {
  color: rgba(255, 246, 220, 0.65);
}

.membership-perks {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 5px;
  margin: 10px 0 12px;
}

.membership-perks span {
  display: flex;
  align-items: center;
  gap: 5px;
  color: var(--ink-soft);
  font-size: 7px;
}

.membership-card.member-u .membership-perks span {
  color: rgba(255, 246, 220, 0.8);
}

.membership-perks .icon {
  width: 11px;
  height: 11px;
  color: var(--member-accent);
}

.membership-card .primary-button,
.membership-card .secondary-button {
  position: relative;
  min-height: 32px;
  font-size: 8px;
}

.membership-card .primary-button {
  background: linear-gradient(135deg, var(--member-accent), color-mix(in srgb, var(--member-accent) 76%, #163d29));
}

.membership-card button:disabled {
  color: #8d938e;
  background: rgba(237, 239, 235, 0.76);
  box-shadow: none;
}

.membership-badge {
  display: inline-flex;
  height: 19px;
  align-items: center;
  padding: 0 7px;
  border-radius: 8px;
  font-size: 7px;
  font-weight: 800;
  white-space: nowrap;
}

.membership-badge.compact {
  height: 16px;
  padding: 0 5px;
  font-size: 6px;
}

.membership-badge.member-gold {
  color: #83560d;
  background: #fff0bf;
}

.membership-badge.member-platinum {
  color: #4e6573;
  background: #e1f1f8;
}

.membership-badge.member-plus {
  color: #694694;
  background: #efe1fb;
}

.membership-badge.member-u {
  color: #ffe19a;
  background: #273f2f;
  box-shadow: inset 0 0 0 1px rgba(255, 220, 136, 0.3);
}

.avatar.member-avatar-gold,
.profile-avatar.member-avatar-gold,
.mobile-avatar.member-avatar-gold {
  box-shadow: 0 0 0 3px #fff2bd, 0 0 0 5px rgba(203, 147, 36, 0.62), 0 8px 20px rgba(160, 108, 18, 0.22);
}

.avatar.member-avatar-platinum,
.profile-avatar.member-avatar-platinum,
.mobile-avatar.member-avatar-platinum {
  box-shadow: 0 0 0 3px #effbff, 0 0 0 5px rgba(151, 198, 222, 0.82), 0 8px 20px rgba(79, 123, 145, 0.2);
}

.avatar.member-avatar-plus,
.profile-avatar.member-avatar-plus,
.mobile-avatar.member-avatar-plus {
  box-shadow: 0 0 0 3px #f7edff, 0 0 0 5px rgba(170, 120, 220, 0.72), 0 8px 20px rgba(102, 63, 145, 0.22);
}

.avatar.member-avatar-u,
.profile-avatar.member-avatar-u,
.mobile-avatar.member-avatar-u {
  box-shadow: 0 0 0 3px #fff1b9, 0 0 0 5px #2b4937, 0 0 23px rgba(247, 199, 92, 0.5);
}

.message-row .message-bubble.member-bubble-gold {
  border-color: rgba(214, 165, 58, 0.5);
  color: #563a0b;
  background: linear-gradient(135deg, rgba(255, 250, 225, 0.96), rgba(255, 233, 173, 0.9));
}

.message-row .message-bubble.member-bubble-platinum {
  border-color: rgba(154, 196, 218, 0.54);
  color: #334d5b;
  background: linear-gradient(135deg, rgba(249, 254, 255, 0.97), rgba(221, 240, 248, 0.92));
}

.message-row .message-bubble.member-bubble-plus {
  border-color: rgba(174, 132, 216, 0.5);
  color: #50346c;
  background: linear-gradient(135deg, rgba(253, 249, 255, 0.97), rgba(234, 218, 249, 0.92));
}

.message-row .message-bubble.member-bubble-u {
  border-color: rgba(230, 186, 81, 0.58);
  color: #fff5d9;
  background: linear-gradient(135deg, rgba(42, 72, 53, 0.97), rgba(22, 47, 33, 0.98));
}

.message-bubble.chat-cosmetic-mint {
  border-color: rgba(107, 190, 145, 0.55);
  background: linear-gradient(135deg, rgba(234, 250, 241, 0.96), rgba(205, 238, 219, 0.9));
  color: #24513c;
}

.message-bubble.chat-cosmetic-peach {
  border-color: rgba(236, 159, 125, 0.55);
  background: linear-gradient(135deg, rgba(255, 245, 239, 0.97), rgba(255, 220, 204, 0.92));
  color: #713c2b;
}

.message-bubble.chat-cosmetic-violet {
  border-color: rgba(173, 135, 209, 0.52);
  background: linear-gradient(135deg, rgba(252, 247, 255, 0.97), rgba(234, 218, 249, 0.92));
  color: #50346c;
}

.shop-chat-preview {
  position: relative;
  width: 148px;
  padding: 13px 15px;
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: 16px 16px 16px 5px;
  box-shadow: 0 8px 20px rgba(44, 68, 50, 0.08);
  font-size: 9px;
}

.shop-chat-preview::after {
  position: absolute;
  bottom: -6px;
  left: 13px;
  width: 12px;
  height: 12px;
  border-right: 1px solid inherit;
  border-bottom: 1px solid inherit;
  background: inherit;
  content: "";
  transform: rotate(45deg);
}

.cosmetic-expiry {
  display: block;
  margin: -3px 0 9px;
  color: var(--muted);
  font-size: 7px;
}

.recommend-friend-trigger {
  color: var(--green);
  background: var(--green-soft);
}

.recommend-friend-modal form {
  display: flex;
  flex-direction: column;
  gap: 13px;
  padding: 0 23px 23px;
}

.friend-request-compose-modal form {
  display: flex;
  flex-direction: column;
  gap: 13px;
  padding: 0 23px 23px;
}

.recommend-friend-modal textarea,
.friend-request-compose-modal textarea {
  padding: 11px 13px;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.76);
  font-size: 11px;
  line-height: 1.6;
}

.friend-recommendations-section {
  border-top: 1px solid rgba(164, 184, 171, 0.18);
}

.recommendation-row {
  border-color: rgba(197, 173, 113, 0.25);
  background: rgba(255, 250, 233, 0.54);
}

.post-management-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 2px 0 9px;
}

.post-management-links button {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 0;
  color: var(--muted);
  background: transparent;
  font-size: 7px;
}

.post-management-links button:hover {
  color: var(--green);
}

.post-management-links .danger-text,
.action-button.danger-text {
  color: var(--red);
}

.post-management-links .icon {
  width: 11px;
  height: 11px;
}

.edit-post-modal form,
.report-modal form {
  display: flex;
  flex-direction: column;
  gap: 13px;
  padding: 0 23px 23px;
}

.edit-post-modal textarea,
.report-modal textarea {
  min-height: 130px;
  padding: 11px 13px;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.76);
  font-size: 11px;
  line-height: 1.65;
}

.report-reasons {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin: 0;
  padding: 0;
  border: 0;
}

.report-reasons legend {
  grid-column: 1 / -1;
  margin-bottom: 2px;
  color: var(--ink-soft);
  font-size: 10px;
  font-weight: 700;
}

.report-reasons label {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.56);
  font-size: 9px;
  cursor: pointer;
}

.report-reasons input {
  accent-color: var(--green);
}

.report-row.resolved {
  opacity: 0.72;
}

.report-review-panel {
  margin: 0 17px 17px;
  padding: 15px;
  border: 1px solid rgba(221, 158, 73, 0.42);
  border-radius: 13px;
  background:
    radial-gradient(circle at 100% 0%, rgba(255, 217, 139, 0.35), transparent 40%),
    rgba(255, 248, 228, 0.74);
}

.report-review-panel.resolved {
  border-color: rgba(119, 168, 136, 0.36);
  background: rgba(237, 248, 241, 0.72);
}

.report-review-head {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.report-review-head > .icon {
  width: 21px;
  height: 21px;
  color: #b06b16;
}

.report-review-head > div {
  flex: 1;
}

.report-review-head h3 {
  margin-top: 3px;
  font-family: var(--serif);
  font-size: 15px;
}

.report-review-head p {
  margin-top: 5px;
  color: var(--muted);
  font-size: 8px;
}

.report-review-actions,
.report-punish-actions {
  display: flex;
  justify-content: flex-end;
  gap: 7px;
  margin-top: 12px;
}

.report-review-actions button,
.report-punish-actions button {
  min-height: 32px;
  padding: 0 12px;
  border-radius: 8px;
  font-size: 8px;
  font-weight: 700;
}

.report-punish-actions {
  align-items: center;
}

.report-punish-actions > span {
  margin-right: auto;
  color: var(--muted);
  font-size: 8px;
}

.report-mail-action {
  margin-top: 18px;
  width: fit-content;
}

.notifications-modal {
  width: min(100%, 520px);
}

.notifications-list {
  max-height: min(68vh, 560px);
  overflow-y: auto;
  padding: 0 14px 18px;
}

.notification-row {
  display: flex;
  width: 100%;
  align-items: center;
  gap: 10px;
  padding: 12px 10px;
  border-top: 1px solid var(--line);
  background: transparent;
  text-align: left;
}

.notification-row:first-child {
  border-top: 0;
}

.notification-row:hover {
  background: var(--green-pale);
}

.notification-icon {
  display: grid;
  width: 32px;
  height: 32px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 10px;
  color: var(--green);
  background: var(--green-soft);
}

.notification-icon .icon {
  width: 16px;
  height: 16px;
}

.notification-row > span:nth-child(2) {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
}

.notification-row strong {
  font-size: 9px;
}

.notification-row small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 7px;
}

.notification-row > .icon {
  width: 13px;
  height: 13px;
  color: var(--muted-2);
}

.mailbox-modal {
  width: min(100%, 760px);
}

.mailbox-layout {
  display: grid;
  min-height: 360px;
  max-height: min(72vh, 620px);
  grid-template-columns: 245px minmax(0, 1fr);
  border-top: 1px solid var(--line);
}

.mailbox-list {
  overflow-y: auto;
  padding: 10px;
  border-right: 1px solid var(--line);
  background: rgba(246, 248, 244, 0.44);
}

.mail-row {
  display: flex;
  width: 100%;
  flex-direction: column;
  gap: 3px;
  margin-bottom: 5px;
  padding: 11px;
  border: 1px solid transparent;
  border-radius: 10px;
  background: transparent;
  text-align: left;
}

.mail-row:hover,
.mail-row.active {
  border-color: var(--line);
  background: rgba(255, 255, 255, 0.72);
  box-shadow: var(--shadow-sm);
}

.mail-row.unread strong {
  color: var(--green-deep);
}

.mail-row .mail-status {
  align-self: flex-start;
  color: var(--muted);
  font-size: 6px;
}

.mail-row.unread .mail-status {
  color: var(--orange);
  font-weight: 700;
}

.mail-row strong {
  overflow: hidden;
  font-size: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mail-row small {
  color: var(--muted);
  font-size: 7px;
}

.mailbox-detail {
  overflow-y: auto;
  padding: 24px;
}

.mail-detail-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 13px;
  color: var(--muted);
  font-size: 7px;
}

.mailbox-detail h3 {
  margin-bottom: 12px;
  font-family: var(--serif);
  font-size: 20px;
}

.mailbox-detail > p {
  color: var(--ink-soft);
  font-size: 10px;
  line-height: 1.9;
}

.mail-points {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 18px;
  padding: 10px 12px;
  border-radius: 10px;
  color: #8c6418;
  background: #fff4cf;
  font-size: 8px;
  font-weight: 700;
}

.mail-points .icon {
  width: 15px;
  height: 15px;
}

.mailbox-empty {
  display: grid;
  min-height: 140px;
  place-items: center;
  padding: 20px;
  color: var(--muted);
  font-size: 9px;
  text-align: center;
}

html[data-theme="dark"] body {
  background:
    radial-gradient(circle at 8% 8%, rgba(61, 119, 83, 0.18), transparent 25rem),
    radial-gradient(circle at 93% 24%, rgba(128, 97, 43, 0.12), transparent 25rem),
    var(--paper);
}

html[data-theme="dark"] .sidebar,
html[data-theme="dark"] .mobile-header,
html[data-theme="dark"] .mobile-nav {
  background: rgba(17, 27, 21, 0.88);
  border-color: rgba(220, 238, 225, 0.1);
}

html[data-theme="dark"] .category-tabs,
html[data-theme="dark"] .quick-compose,
html[data-theme="dark"] .post-card,
html[data-theme="dark"] .mini-profile-card,
html[data-theme="dark"] .rail-card,
html[data-theme="dark"] .profile-activity-card,
html[data-theme="dark"] .achievement-card,
html[data-theme="dark"] .account-card,
html[data-theme="dark"] .messages-layout,
html[data-theme="dark"] .modal,
html[data-theme="dark"] .community-rule,
html[data-theme="dark"] .shop-product,
html[data-theme="dark"] .membership-market,
html[data-theme="dark"] .auth-card {
  border-color: rgba(232, 246, 236, 0.14);
  background:
    linear-gradient(145deg, rgba(29, 43, 34, 0.9), rgba(18, 29, 23, 0.82));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 12px 34px rgba(0, 0, 0, 0.25);
}

html[data-theme="dark"] .nav-item:hover,
html[data-theme="dark"] .conversation-panel,
html[data-theme="dark"] .messages-search,
html[data-theme="dark"] .admin-search,
html[data-theme="dark"] .input-wrap,
html[data-theme="dark"] .friend-search-result,
html[data-theme="dark"] .admin-user-row,
html[data-theme="dark"] .admin-content-row,
html[data-theme="dark"] .friend-request-row,
html[data-theme="dark"] .search-tabs,
html[data-theme="dark"] .admin-footer,
html[data-theme="dark"] .detail-topbar,
html[data-theme="dark"] .chat-header,
html[data-theme="dark"] .chat-composer {
  border-color: rgba(220, 238, 225, 0.1);
  background: rgba(25, 38, 30, 0.74);
}

html[data-theme="dark"] .nav-item.active,
html[data-theme="dark"] .conversation-item.active,
html[data-theme="dark"] .admin-tabs button.active,
html[data-theme="dark"] .search-tabs button.active,
html[data-theme="dark"] .modal-header .modal-close {
  color: var(--green-deep);
  background: rgba(224, 242, 230, 0.1);
}

html[data-theme="dark"] .search-suggestions button,
html[data-theme="dark"] .mini-tool.labeled,
html[data-theme="dark"] .admin-action-button,
html[data-theme="dark"] .comment-form-input,
html[data-theme="dark"] .report-reasons label {
  color: var(--ink-soft);
  background: rgba(255, 255, 255, 0.07);
}

html[data-theme="dark"] .message-bubble {
  color: var(--ink);
  background: rgba(35, 52, 41, 0.9);
}

html[data-theme="dark"] .mailbox-list {
  background: rgba(15, 24, 18, 0.42);
}

html[data-theme="dark"] .mail-row:hover,
html[data-theme="dark"] .mail-row.active {
  background: rgba(224, 242, 230, 0.08);
}

html[data-theme="dark"] .mail-points {
  color: #f1cf7f;
  background: rgba(126, 91, 27, 0.28);
}

html[data-theme="dark"] .report-review-panel {
  border-color: rgba(213, 162, 75, 0.36);
  background: rgba(77, 57, 24, 0.34);
}

html[data-theme="dark"] .report-review-panel.resolved {
  border-color: rgba(104, 162, 124, 0.3);
  background: rgba(39, 70, 51, 0.34);
}

html[data-theme="dark"] .mailbox-notice {
  border-color: rgba(105, 183, 138, 0.3);
  background:
    radial-gradient(circle at 91% 18%, rgba(98, 177, 132, 0.18), transparent 30%),
    radial-gradient(circle at 5% 120%, rgba(82, 139, 169, 0.14), transparent 36%),
    linear-gradient(125deg, rgba(31, 48, 36, 0.92), rgba(22, 38, 30, 0.86));
}

html[data-theme="dark"] .mailbox-notice-copy strong {
  color: #bce5cc;
}

html[data-theme="dark"] .mailbox-notice-copy p {
  color: rgba(231, 239, 232, 0.62);
}

html[data-theme="dark"] .mailbox-notice-icon {
  border-color: rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.08);
}

html[data-theme="dark"] .mailbox-notice-mark {
  color: rgba(173, 224, 193, 0.07);
}

html[data-theme="dark"] .modal-backdrop {
  background: rgba(3, 8, 5, 0.72);
}

html[data-theme="dark"] .profile-hero,
html[data-theme="dark"] .board-intro,
html[data-theme="dark"] .mall-hero {
  filter: saturate(0.9) brightness(0.9);
}

.field-hint {
  display: block;
  margin-top: 6px;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.55;
}

.setting-row-value {
  margin-left: auto;
  color: var(--green);
  font-size: 10px;
  font-weight: 700;
}

.promoter-modal {
  width: min(100%, 860px);
  overflow: hidden;
}

.promoter-content {
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-height: min(72vh, 720px);
  overflow-y: auto;
  padding: 0 24px 24px;
}

.promoter-page-toolbar {
  align-items: flex-start;
}

.promoter-page-toolbar h1 {
  margin-top: 3px;
}

.promoter-page-toolbar > div:first-child > p {
  margin-top: 7px;
  color: var(--muted);
  font-size: 11px;
}

.promoter-page-actions {
  display: flex;
  align-items: center;
  gap: 9px;
}

.promoter-page-level {
  display: inline-flex;
  min-height: 34px;
  align-items: center;
  padding: 0 12px;
  border: 1px solid rgba(255, 255, 255, 0.78);
  border-radius: 999px;
  color: var(--green);
  background: rgba(255, 255, 255, 0.48);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
  font-size: 10px;
  font-weight: 800;
  backdrop-filter: blur(13px);
}

.promoter-page-content {
  max-height: none;
  overflow: visible;
  padding: 0 0 28px;
}

.promoter-hero {
  position: relative;
  display: flex;
  min-height: 180px;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  overflow: hidden;
  padding: 28px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 22px;
  color: #f6fff9;
  background:
    radial-gradient(circle at 76% 18%, rgba(255, 220, 129, 0.22), transparent 28%),
    radial-gradient(circle at 12% 115%, rgba(135, 230, 178, 0.24), transparent 38%),
    linear-gradient(130deg, rgba(24, 92, 63, 0.96), rgba(17, 47, 35, 0.96));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.24),
    0 18px 44px rgba(20, 67, 44, 0.18);
  backdrop-filter: blur(25px) saturate(135%);
}

.promoter-hero h3 {
  max-width: 560px;
  margin-top: 8px;
  font-family: var(--serif);
  font-size: clamp(22px, 3.4vw, 33px);
  line-height: 1.3;
}

.promoter-hero p {
  max-width: 600px;
  margin-top: 9px;
  color: rgba(239, 255, 245, 0.7);
  font-size: 12px;
  line-height: 1.75;
}

.promoter-seal {
  position: relative;
  z-index: 1;
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 7px;
  padding: 9px 13px;
  border: 1px solid rgba(255, 230, 166, 0.35);
  border-radius: 999px;
  color: #ffe8a8;
  background: rgba(255, 255, 255, 0.09);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
  backdrop-filter: blur(12px);
}

.promoter-orbit {
  position: absolute;
  right: 8%;
  bottom: -115px;
  width: 260px;
  height: 260px;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 50%;
  box-shadow:
    0 0 0 34px rgba(255, 255, 255, 0.035),
    0 0 0 76px rgba(255, 255, 255, 0.025);
}

.promoter-level-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.promoter-level-card,
.promoter-activation-card,
.promoter-progress-card,
.promoter-rules,
.promoter-db-warning {
  border: 1px solid rgba(255, 255, 255, 0.78);
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.76), rgba(246, 251, 247, 0.54));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.92),
    0 10px 30px rgba(31, 67, 44, 0.07);
  backdrop-filter: blur(20px) saturate(135%);
}

.promoter-level-card {
  position: relative;
  display: flex;
  min-height: 154px;
  flex-direction: column;
  overflow: hidden;
  padding: 17px;
  border-radius: 17px;
}

.promoter-level-card > span {
  color: var(--muted-2);
  font-family: Georgia, serif;
  font-size: 11px;
  font-weight: 700;
}

.promoter-level-card strong {
  margin-top: 9px;
  font-family: var(--serif);
  font-size: 17px;
}

.promoter-level-card p {
  margin-top: 6px;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.65;
}

.promoter-level-card b {
  margin-top: auto;
  padding-top: 10px;
  color: var(--green);
  font-size: 10px;
}

.promoter-level-card.intermediate {
  background:
    radial-gradient(circle at 100% 0%, rgba(172, 139, 227, 0.2), transparent 46%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.8), rgba(247, 244, 255, 0.56));
}

.promoter-level-card.senior {
  background:
    radial-gradient(circle at 100% 0%, rgba(236, 185, 82, 0.24), transparent 47%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.82), rgba(255, 250, 234, 0.58));
}

.promoter-activation-card {
  padding: 20px;
  border-radius: 18px;
}

.promoter-section-heading,
.promoter-progress-top,
.promoter-progress-foot,
.promoter-identity-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.promoter-section-heading h3 {
  margin-top: 4px;
  font-family: var(--serif);
  font-size: 20px;
}

.promoter-lock,
.promoter-live {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--muted);
  font-size: 10px;
}

.promoter-lock .icon,
.promoter-live .icon {
  width: 14px;
  height: 14px;
}

.promoter-activation-form {
  margin-top: 16px;
}

.promoter-submit {
  margin-top: 12px;
}

.promoter-identity-card {
  position: relative;
  overflow: hidden;
  padding: 25px;
  border: 1px solid rgba(255, 255, 255, 0.26);
  border-radius: 22px;
  color: #f8fffb;
  background:
    radial-gradient(circle at 88% 8%, rgba(255, 255, 255, 0.19), transparent 26%),
    linear-gradient(135deg, rgba(36, 110, 79, 0.97), rgba(16, 56, 39, 0.97));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.25),
    0 20px 50px rgba(18, 69, 43, 0.2);
}

.promoter-identity-card.intermediate {
  background:
    radial-gradient(circle at 88% 8%, rgba(245, 220, 255, 0.22), transparent 28%),
    linear-gradient(135deg, rgba(87, 60, 130, 0.97), rgba(41, 31, 69, 0.97));
}

.promoter-identity-card.senior {
  color: #2b2413;
  background:
    radial-gradient(circle at 86% 10%, rgba(255, 255, 255, 0.55), transparent 28%),
    linear-gradient(135deg, rgba(245, 205, 106, 0.97), rgba(172, 117, 38, 0.97));
}

.promoter-level-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 11px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  font-size: 10px;
  font-weight: 800;
  backdrop-filter: blur(12px);
}

.promoter-live {
  color: rgba(255, 255, 255, 0.68);
}

.promoter-identity-card.senior .promoter-live {
  color: rgba(43, 36, 19, 0.67);
}

.promoter-card-label {
  display: block;
  margin-top: 26px;
  color: rgba(255, 255, 255, 0.58);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.2em;
}

.promoter-identity-card.senior .promoter-card-label {
  color: rgba(43, 36, 19, 0.56);
}

.promoter-code {
  display: block;
  margin-top: 4px;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: clamp(38px, 7vw, 64px);
  font-weight: 800;
  letter-spacing: 0.08em;
  line-height: 1.15;
  text-shadow: 0 8px 28px rgba(0, 0, 0, 0.13);
}

.promoter-copy-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 18px;
}

.promoter-copy-actions .primary-button {
  background: rgba(255, 255, 255, 0.16);
}

.promoter-copy-actions .secondary-button {
  color: inherit;
  background: rgba(255, 255, 255, 0.1);
}

.promoter-identity-card.senior .promoter-copy-actions .primary-button,
.promoter-identity-card.senior .promoter-copy-actions .secondary-button {
  color: #2b2413;
  border-color: rgba(80, 58, 18, 0.2);
  background: rgba(255, 255, 255, 0.37);
}

.promoter-link-preview {
  overflow: hidden;
  margin-top: 11px;
  color: rgba(255, 255, 255, 0.5);
  font-size: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.promoter-identity-card.senior .promoter-link-preview {
  color: rgba(43, 36, 19, 0.52);
}

.promoter-progress-card {
  padding: 20px;
  border-radius: 18px;
}

.promoter-progress-top > div {
  display: flex;
  align-items: baseline;
  gap: 9px;
}

.promoter-progress-top span {
  color: var(--muted);
  font-size: 10px;
}

.promoter-progress-top strong {
  color: var(--green);
  font-family: var(--serif);
  font-size: 28px;
}

.promoter-progress-track {
  height: 11px;
  overflow: hidden;
  margin-top: 12px;
  border: 1px solid rgba(255, 255, 255, 0.82);
  border-radius: 999px;
  background: rgba(43, 88, 61, 0.08);
  box-shadow: inset 0 1px 3px rgba(39, 76, 51, 0.1);
}

.promoter-progress-track i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #5fac80, #2c7b58 60%, #edc66c);
  box-shadow: 0 0 16px rgba(69, 159, 112, 0.36);
  transition: width 0.45s ease;
}

.promoter-progress-card > p {
  margin-top: 9px;
  color: var(--ink-soft);
  font-size: 11px;
}

.promoter-progress-foot {
  margin-top: 14px;
  padding-top: 13px;
  border-top: 1px solid rgba(151, 170, 158, 0.18);
}

.promoter-progress-foot > span {
  color: var(--muted);
  font-size: 9px;
}

.promoter-progress-foot .secondary-button {
  padding: 8px 11px;
}

.promoter-rules {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  padding: 15px;
  border-radius: 16px;
}

.promoter-rules > div {
  display: flex;
  align-items: flex-start;
  gap: 9px;
}

.promoter-rules .icon {
  width: 17px;
  height: 17px;
  margin-top: 1px;
  color: var(--green);
}

.promoter-rules p {
  color: var(--muted);
  font-size: 9px;
  line-height: 1.65;
}

.promoter-db-warning {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 18px;
  border-radius: 16px;
  color: #7a4b22;
  background: linear-gradient(145deg, rgba(255, 248, 228, 0.9), rgba(255, 255, 255, 0.68));
}

.promoter-db-warning > .icon {
  color: #c88337;
}

.promoter-db-warning p {
  margin-top: 4px;
  font-size: 10px;
  line-height: 1.65;
}

.promoter-actions {
  display: flex;
  justify-content: flex-end;
}

html[data-theme="dark"] .promoter-level-card,
html[data-theme="dark"] .promoter-activation-card,
html[data-theme="dark"] .promoter-progress-card,
html[data-theme="dark"] .promoter-rules {
  border-color: rgba(224, 242, 230, 0.15);
  background: linear-gradient(145deg, rgba(35, 51, 41, 0.9), rgba(25, 38, 30, 0.76));
}

html[data-theme="dark"] .promoter-progress-track {
  background: rgba(255, 255, 255, 0.08);
}

html[data-theme="dark"] .promoter-db-warning {
  color: #efd4a8;
  background: rgba(82, 58, 25, 0.74);
}

/* Responsive */

@media (max-width: 1240px) {
  .app {
    grid-template-columns: 210px minmax(480px, 1fr) 268px;
    gap: 20px;
    padding-right: 20px;
    padding-left: 20px;
  }

  .sidebar-lab small,
  .board-link small {
    display: none;
  }

  .right-rail {
    font-size: 13px;
  }

  .profile-content-grid {
    grid-template-columns: minmax(0, 1fr) 250px;
  }

  .messages-layout {
    grid-template-columns: 225px minmax(0, 1fr);
  }
}

@media (max-width: 1060px) {
  .app {
    max-width: 880px;
    grid-template-columns: 205px minmax(0, 1fr);
  }

  .right-rail {
    display: none;
  }

  .search-trigger {
    width: 205px;
  }

  .profile-content-grid {
    grid-template-columns: 1fr;
  }

  .profile-aside {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 800px) {
  body {
    padding-bottom: env(safe-area-inset-bottom);
    font-size: 14px;
    background: var(--paper);
  }

  .pull-refresh-indicator {
    display: flex;
  }

  .app {
    display: block;
    max-width: none;
    min-height: 100vh;
    padding: 70px 14px 90px;
  }

  .sidebar,
  .right-rail {
    display: none;
  }

  .mobile-header {
    position: fixed;
    z-index: 40;
    top: 0;
    right: 0;
    left: 0;
    display: flex;
    height: calc(58px + env(safe-area-inset-top));
    align-items: center;
    justify-content: space-between;
    padding: env(safe-area-inset-top) 15px 0;
    border-bottom: 1px solid rgba(225, 226, 217, 0.84);
    background: rgba(245, 244, 238, 0.9);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
  }

  .mobile-header-actions {
    display: flex;
    align-items: center;
    gap: 5px;
  }

  .mobile-header .icon-button {
    width: 35px;
    height: 35px;
  }

  .mobile-avatar {
    display: grid;
    width: 32px;
    height: 32px;
    place-items: center;
    border: 2px solid #fff;
    border-radius: 50%;
    color: #24513c;
    background: linear-gradient(140deg, #d6eadc, #9dccb0);
    font-family: var(--serif);
    font-size: 12px;
    font-weight: 700;
    box-shadow: 0 3px 8px rgba(24, 45, 33, 0.08);
  }

  .mobile-avatar.peach {
    color: #7a3d2c;
    background: linear-gradient(140deg, #ffe2d6, #f2b196);
  }

  .mobile-avatar.blue {
    color: #34566e;
    background: linear-gradient(140deg, #dbeaf5, #a7c9df);
  }

  .mobile-avatar.violet {
    color: #54456c;
    background: linear-gradient(140deg, #e9e1f3, #c3b3d8);
  }

  .main-content {
    padding-top: 0;
  }

  .page-toolbar {
    min-height: 43px;
    margin-bottom: 11px;
  }

  .page-toolbar h1 {
    margin-top: 2px;
    font-size: 23px;
  }

  .page-toolbar .eyebrow {
    font-size: 8px;
  }

  .mailbox-notice {
    min-height: 78px;
    gap: 11px;
    padding: 13px 14px;
    border-radius: 14px;
  }

  .mailbox-notice-icon {
    width: 45px;
    height: 45px;
  }

  .mailbox-notice-copy strong {
    font-size: 20px;
  }

  .mailbox-notice-copy p {
    max-width: 195px;
    font-size: 8px;
  }

  .mailbox-notice-action {
    min-height: 31px;
    padding: 0 9px;
    font-size: 8px;
  }

  .mailbox-notice-mark {
    right: 10px;
    font-size: 24px;
  }

  .toolbar-actions,
  .profile-toolbar .secondary-button {
    display: none;
  }

  .category-tabs {
    margin-right: -14px;
    margin-left: -14px;
    padding: 5px 14px;
    border-right: 0;
    border-left: 0;
    border-radius: 0;
    background: rgba(255, 255, 255, 0.52);
  }

  .category-tab {
    min-width: auto;
    flex: 0 0 auto;
    height: 31px;
    padding: 0 13px;
    border-radius: 7px;
    font-size: 10px;
  }

  .board-intro {
    min-height: 160px;
    border-radius: 15px;
  }

  .board-intro-copy {
    width: 82%;
    padding: 20px 0 18px 19px;
  }

  .board-intro h2 {
    max-width: 310px;
    margin-top: 6px;
    font-size: 18px;
    line-height: 1.5;
  }

  .board-intro p {
    display: -webkit-box;
    max-width: 270px;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
  }

  .board-topics span:nth-child(3) {
    display: none;
  }

  .board-art {
    right: -33px;
    width: 40%;
    opacity: 0.7;
  }

  .orbit-copy {
    display: none;
  }

  .bubble-a {
    top: 19px;
    left: 30px;
  }

  .bubble-b {
    right: 23px;
    bottom: 20px;
  }

  .bubble-c {
    display: none;
  }

  .quick-compose {
    min-height: 58px;
    margin-top: 11px;
    padding: 8px 9px 8px 12px;
  }

  .quick-compose .avatar {
    width: 36px;
    height: 36px;
  }

  .compose-tools .mini-tool {
    display: none;
  }

  .publish-button {
    height: 31px;
    padding: 0 12px;
  }

  .feed-heading {
    margin-top: 15px;
  }

  .post-card {
    padding: 15px 14px 10px;
    border-radius: 13px;
  }

  .post-card h3 {
    margin-top: 12px;
    font-size: 15px;
  }

  .post-excerpt {
    font-size: 10px;
    line-height: 1.8;
    -webkit-line-clamp: 3;
  }

  .post-actions {
    gap: 0;
  }

  .action-button {
    min-width: 45px;
    padding: 0 5px;
  }

  .post-actions .read-count {
    display: none;
  }

  .mobile-nav {
    position: fixed;
    z-index: 50;
    right: 0;
    bottom: 0;
    left: 0;
    display: grid;
    height: calc(63px + env(safe-area-inset-bottom));
    grid-template-columns: 1fr 1fr 50px 1fr 1fr 1fr;
    align-items: center;
    padding: 0 9px env(safe-area-inset-bottom);
    border-top: 1px solid rgba(218, 220, 211, 0.9);
    background: rgba(255, 255, 255, 0.94);
    box-shadow: 0 -8px 24px rgba(30, 51, 38, 0.05);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
  }

  .mobile-nav-item {
    display: flex;
    height: 50px;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    color: #8b928d;
    background: transparent;
    font-size: 8px;
  }

  .mobile-nav-item .icon {
    width: 20px;
    height: 20px;
  }

  .mobile-nav-item.active {
    color: var(--green);
    font-weight: 700;
  }

  .nav-icon-wrap {
    position: relative;
  }

  .nav-icon-wrap i {
    position: absolute;
    top: -5px;
    right: -9px;
    display: grid;
    min-width: 14px;
    height: 14px;
    place-items: center;
    padding: 0 3px;
    border: 1.5px solid #fff;
    border-radius: 7px;
    color: #fff;
    background: var(--orange);
    font-size: 6px;
    font-style: normal;
  }

  .mobile-create-button {
    display: grid;
    width: 45px;
    height: 45px;
    place-items: center;
    justify-self: center;
    border: 4px solid #fff;
    border-radius: 15px 15px 15px 5px;
    color: #fff;
    background: var(--green);
    box-shadow: 0 7px 18px rgba(33, 107, 77, 0.27);
  }

  .mobile-create-button .icon {
    width: 22px;
    height: 22px;
  }

  /* Mobile auth */
  .auth-screen {
    display: block;
    min-height: 100vh;
  }

  .auth-visual {
    display: none;
  }

  .auth-panel {
    display: block;
    min-height: 100vh;
    padding: max(30px, env(safe-area-inset-top)) 21px 32px;
    background:
      radial-gradient(circle at 100% 0%, rgba(205, 226, 211, 0.58), transparent 20rem),
      var(--paper);
  }

  .auth-card {
    margin: 0 auto;
  }

  .auth-mobile-brand {
    display: inline-flex;
    margin-bottom: 48px;
  }

  .auth-heading h2 {
    font-size: 27px;
  }

  .input-wrap {
    height: 49px;
    background: rgba(255, 255, 255, 0.86);
  }

  /* Mobile messages */
  .messages-toolbar {
    margin-bottom: 12px;
  }

  .messages-toolbar .secondary-button {
    display: inline-flex;
    min-height: 35px;
    padding: 0 11px;
    font-size: 9px;
  }

  .messages-layout {
    display: block;
    height: calc(100vh - 180px);
    min-height: 460px;
    border-radius: 14px;
  }

  .conversation-panel {
    height: 100%;
    border-right: 0;
  }

  .messages-layout.chat-open .conversation-panel {
    display: none;
  }

  .chat-panel {
    display: none;
    height: 100%;
  }

  .messages-layout.chat-open .chat-panel {
    display: block;
  }

  .chat-back {
    display: inline-flex;
  }

  .chat-active {
    height: 100%;
  }

  .chat-messages {
    padding: 15px 12px;
  }

  .message-row {
    max-width: 88%;
  }

  .chat-composer {
    padding: 9px 10px calc(9px + env(safe-area-inset-bottom));
  }

  .conversation-head {
    height: 53px;
  }

  .chat-empty {
    padding: 20px;
  }

  /* Mobile profile */
  .profile-toolbar {
    margin-bottom: 11px;
  }

  .profile-toolbar .secondary-button {
    display: none;
  }

  .profile-hero {
    padding: 20px 17px 0;
  }

  .profile-avatar {
    width: 65px;
    height: 65px;
    font-size: 23px;
  }

  .profile-main {
    gap: 12px;
  }

  .profile-name-line {
    flex-wrap: wrap;
    gap: 5px;
  }

  .profile-name-line h2 {
    font-size: 20px;
  }

  .level-badge {
    height: 18px;
  }

  .profile-bio {
    display: -webkit-box;
    overflow: hidden;
    font-size: 9px;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
  }

  .profile-tags {
    display: none;
  }

  .profile-stats {
    margin-top: 19px;
  }

  .profile-stats div {
    flex-direction: column;
    align-items: flex-start;
    gap: 1px;
    padding: 10px 0 12px;
  }

  .profile-stats strong {
    padding-left: 10px;
    font-size: 15px;
  }

  .profile-stats span {
    padding-left: 10px;
    font-size: 7px;
  }

  .profile-content-grid {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 12px;
  }

  .profile-activity-card {
    padding: 15px 13px;
  }

  .profile-aside {
    display: flex;
    flex-direction: column;
  }

  .section-heading {
    flex-wrap: wrap;
  }

  .profile-tabs {
    width: 100%;
  }

  .profile-tab {
    flex: 1;
  }

  .profile-post-stats {
    display: none;
  }

  /* Mobile modals */
  .modal-backdrop {
    align-items: flex-end;
    padding: 0;
  }

  .modal {
    width: 100%;
    max-height: 94vh;
    border-radius: 19px 19px 0 0;
    animation-name: modal-up;
  }

  @keyframes modal-up {
    from {
      opacity: 0;
      transform: translateY(35px);
    }
  }

  .modal-header {
    padding: 20px 18px 12px;
  }

  .modal-header h2 {
    font-size: 19px;
  }

  .create-post-modal form {
    padding: 0 18px calc(18px + env(safe-area-inset-bottom));
  }

  .post-body-input {
    min-height: 155px;
  }

  .composer-submit > span {
    display: none;
  }

  .detail-modal {
    height: 94vh;
    max-height: 94vh;
  }

  .detail-scroll {
    max-height: calc(94vh - 56px);
  }

  .detail-post {
    padding: 19px 17px 16px;
  }

  .detail-post h1 {
    font-size: 21px;
  }

  .comments-section {
    padding: 17px 17px calc(22px + env(safe-area-inset-bottom));
  }

  .search-modal {
    height: 100vh;
    max-height: 100vh;
    margin: 0;
    border-radius: 0;
    animation-name: fade-only;
  }

  .search-modal-head {
    height: calc(62px + env(safe-area-inset-top));
    padding-top: env(safe-area-inset-top);
  }

  .search-body {
    max-height: calc(100vh - 104px);
  }

  .new-message-modal,
  .edit-profile-modal,
  .recommend-friend-modal,
  .friend-request-compose-modal,
  .edit-post-modal,
  .report-modal,
  .notifications-modal,
  .mailbox-modal,
  .rules-modal {
    max-height: 88vh;
    overflow-y: auto;
  }

  .mailbox-modal {
    height: 92vh;
    max-height: 92vh;
  }

  .mailbox-layout {
    display: block;
    max-height: calc(92vh - 82px);
  }

  .mailbox-list {
    max-height: 230px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .mailbox-detail {
    min-height: 250px;
    padding: 18px;
  }

  .edit-profile-modal form {
    padding: 0 18px calc(18px + env(safe-area-inset-bottom));
  }

  .rules-body {
    max-height: none;
    padding: 0 18px calc(20px + env(safe-area-inset-bottom));
  }

  .toast {
    bottom: calc(76px + env(safe-area-inset-bottom));
  }
}

.post-management-links {
  display: none;
}

.pinned-badge.hot-topic {
  color: #a04d2e;
  background: #fff0e8;
}

.pinned-badge.waiting-reply {
  color: #45657b;
  background: #eaf2f8;
}

.pinned-badge.admin-reply {
  color: #766020;
  background: #fff6d8;
}

.post-card.has-admin-reply {
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.94),
    0 0 0 1px rgba(221, 189, 91, 0.16),
    0 12px 34px rgba(31, 61, 42, 0.08);
}

.post-card.is-unanswered-post .post-actions .comments {
  color: #52748a;
  background: #edf4f8;
}

.board-intro h2,
.board-intro p,
.post-card h3,
.post-excerpt,
.detail-post h1,
.comment-text {
  text-wrap: balance;
}

html[data-theme="dark"] .pinned-badge.hot-topic {
  color: #ffc1a8;
  background: rgba(191, 87, 46, 0.2);
}

html[data-theme="dark"] .pinned-badge.waiting-reply {
  color: #c1dff2;
  background: rgba(77, 126, 157, 0.2);
}

html[data-theme="dark"] .pinned-badge.admin-reply {
  color: #f1d789;
  background: rgba(142, 110, 35, 0.24);
}

.avatar-style.sky,
.avatar.sky,
.avatar.sky {
  background: linear-gradient(140deg, #dfeef7, #aac8dc);
}

.avatar-style.coral,
.avatar.coral {
  background: linear-gradient(140deg, #ffe4dc, #eeb3a4);
}

.avatar-style.sage,
.avatar.sage {
  background: linear-gradient(140deg, #e5efdf, #b6cfa9);
}

.avatar-style.sand,
.avatar.sand {
  background: linear-gradient(140deg, #f8eed2, #dfc17c);
}

.avatar-upload-placeholder {
  border: 1px dashed rgba(91, 122, 102, 0.45);
  color: var(--muted);
  background: rgba(255, 255, 255, 0.3);
  font-size: 18px;
}

.founder-seat-counter {
  margin-top: 12px;
  padding: 9px 12px;
  border: 1px solid rgba(197, 155, 56, 0.28);
  border-radius: 12px;
  color: #76591d;
  background: rgba(255, 244, 207, 0.72);
  font-size: 11px;
  font-weight: 700;
}

.founder-seat-strip {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 7px 14px;
  margin-bottom: 14px;
  padding: 12px 15px;
  border: 1px solid rgba(197, 155, 56, 0.24);
  border-radius: 14px;
  color: var(--ui-text-soft);
  background: linear-gradient(135deg, rgba(255, 249, 228, 0.8), rgba(255, 255, 255, 0.62));
  font-size: 10px;
}

.founder-seat-strip strong {
  color: #8a671a;
}

.founder-seat-strip,
.founder-seat-strip span,
.founder-seat-strip strong {
  color: #143d2b;
}

html,
body,
button,
a,
input,
[role="button"] {
  touch-action: manipulation;
}

.profile-stats button {
  display: flex;
  min-width: 0;
  flex-direction: column;
  padding: 0;
  border: 0;
  background: transparent;
  text-align: left;
}

.profile-stats {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}

.profile-stats > div,
.profile-stats > button {
  min-width: 0;
  align-items: flex-start;
  flex-direction: column;
  gap: 1px;
  padding: 13px 8px 15px;
}

.profile-stats > div strong,
.profile-stats > button strong {
  padding-left: 0;
}

.profile-stats > div span,
.profile-stats > button span {
  padding-left: 0;
}

.profile-stats button strong {
  color: inherit;
  font-family: var(--serif);
  font-size: 19px;
}

.profile-stats button span {
  margin-top: 2px;
  color: inherit;
  font-size: 8px;
}

.social-relations-modal {
  width: min(100%, 620px);
  max-height: 84vh;
}

.social-relation-tabs {
  display: flex;
  gap: 4px;
  padding: 0 22px 14px;
  border-bottom: 1px solid var(--ui-border);
}

.social-relation-tabs button {
  min-height: 38px;
  padding: 0 14px;
  border-radius: 10px;
  color: var(--ui-text-muted);
  background: transparent;
  font-size: 11px;
  font-weight: 700;
}

.social-relation-tabs button.active {
  color: var(--green-deep);
  background: var(--green-soft);
}

.social-relation-list {
  display: flex;
  max-height: calc(84vh - 130px);
  flex-direction: column;
  gap: 9px;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 15px 22px 22px;
  -webkit-overflow-scrolling: touch;
}

.social-relation-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--ui-border);
  border-radius: 15px;
  background: var(--ui-surface-soft);
}

.social-relation-identity {
  display: flex;
  min-width: 0;
  flex: 1;
  align-items: center;
  gap: 10px;
  color: var(--ui-text);
  background: transparent;
  text-align: left;
}

.social-relation-identity > span:not(.avatar) {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.social-relation-identity strong {
  overflow: hidden;
  color: var(--ui-text);
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.social-relation-identity small,
.social-relation-identity p {
  overflow: hidden;
  color: var(--ui-text-muted);
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.social-relation-actions {
  display: flex;
  flex-shrink: 0;
  gap: 5px;
}

.social-relation-actions button {
  min-height: 34px;
  padding: 0 10px;
  border: 1px solid var(--ui-border);
  border-radius: 10px;
  color: var(--ui-text);
  background: var(--ui-surface);
  font-size: 10px;
  white-space: nowrap;
}

.social-relation-actions button.mutual {
  color: var(--green);
  border-color: var(--green-soft);
  background: var(--green-soft);
}

.modal-backdrop {
  overscroll-behavior: none;
}

.detail-scroll,
.comment-drawer-list,
.social-relation-list,
.modal {
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

html[data-theme="dark"] .founder-seat-strip {
  color: #e5f2e9;
  border-color: rgba(220, 185, 96, 0.28);
  background: rgba(87, 68, 26, 0.28);
}

html[data-theme="dark"] .founder-seat-strip span,
html[data-theme="dark"] .founder-seat-strip strong {
  color: #f1d98b;
}

@media (max-width: 800px) {
  input,
  select,
  textarea {
    font-size: 16px !important;
  }

  .social-relations-modal {
    height: 88vh;
    max-height: 88vh;
  }

  .social-relation-list {
    max-height: calc(88vh - 130px);
    padding: 12px 16px calc(20px + env(safe-area-inset-bottom));
  }

  .social-relation-row {
    align-items: flex-start;
    flex-direction: column;
  }

  .social-relation-actions {
    width: 100%;
  }

  .social-relation-actions button {
    flex: 1;
  }

  .profile-stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.social-relation-empty {
  padding: 32px 20px;
  border: 0;
  background: transparent;
}

.founder-seat-strip .progress {
  grid-column: 1 / -1;
}

.founder-badge {
  display: inline-flex;
  height: 19px;
  align-items: center;
  gap: 3px;
  padding: 0 7px;
  border: 1px solid rgba(196, 154, 55, 0.24);
  border-radius: 9px;
  color: #805e18;
  background: linear-gradient(135deg, #fff8df, #f1daa0);
  font-size: 8px;
  font-weight: 800;
  white-space: nowrap;
}

.founder-badge.compact {
  height: 16px;
  padding: 0 5px;
  font-size: 7px;
}

.not-found-page {
  display: grid;
  min-height: 100vh;
  place-items: center;
  padding: 28px;
  background:
    radial-gradient(circle at 18% 15%, rgba(177, 224, 198, 0.3), transparent 28rem),
    radial-gradient(circle at 82% 76%, rgba(232, 203, 137, 0.2), transparent 26rem),
    var(--ui-page);
}

.not-found-page > .brand {
  position: absolute;
  top: 24px;
  left: 28px;
}

.not-found-card {
  width: min(100%, 560px);
  padding: 38px;
  border: 1px solid var(--ui-border);
  border-radius: 26px;
  background: var(--ui-surface);
  box-shadow: 0 20px 60px rgba(20, 61, 43, 0.1);
  text-align: center;
}

.not-found-art {
  display: grid;
  width: 78px;
  height: 78px;
  place-items: center;
  margin: 20px auto;
  border-radius: 25px;
  color: var(--green);
  background: var(--green-soft);
}

.not-found-art .icon {
  width: 34px;
  height: 34px;
}

.not-found-card h1 {
  color: var(--ui-text);
  font-family: var(--serif);
  font-size: 30px;
}

.not-found-card p {
  margin-top: 9px;
  color: var(--ui-text-muted);
  line-height: 1.7;
}

.not-found-actions {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 24px;
}

.not-found-actions a {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  padding: 0 16px;
  text-decoration: none;
}

.social-empty-art {
  width: 76px;
  height: 56px;
  margin: 0 auto 12px;
  opacity: 0.82;
  background:
    radial-gradient(circle at 22% 28%, var(--ui-mint) 0 9px, transparent 10px),
    radial-gradient(circle at 62% 36%, var(--ui-amber) 0 7px, transparent 8px),
    linear-gradient(145deg, transparent 42%, var(--ui-blue) 43% 62%, transparent 63%);
}

@media (max-width: 800px) {
  .guest-preview-grid {
    grid-template-columns: 1fr;
  }

  .guest-preview-modal > .primary-button,
  .privacy-settings-modal > .primary-button {
    width: calc(100% - 32px);
    margin-right: 16px;
    margin-left: 16px;
  }
}

@media (max-width: 390px) {
  .auth-panel {
    padding-right: 17px;
    padding-left: 17px;
  }

  .auth-mobile-brand {
    margin-bottom: 35px;
  }

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

  .board-intro-copy {
    width: 91%;
  }

  .board-intro h2 {
    font-size: 16px;
  }

  .board-topics span:nth-child(2) {
    display: none;
  }

  .profile-name-line .level-badge {
    display: none;
  }

  .composer-footer {
    align-items: flex-end;
  }

  .mini-tool.labeled {
    padding: 0 7px;
  }

  .post-meta-right .pinned-badge {
    display: none;
  }
}

@media (max-width: 800px) {
  .messages-actions {
    gap: 5px;
  }

  .messages-actions .secondary-button.add-friend-button {
    position: fixed;
    z-index: 45;
    right: 14px;
    bottom: calc(76px + env(safe-area-inset-bottom));
    min-height: 44px;
    padding: 0 16px;
    border: 1px solid rgba(255, 255, 255, 0.38);
    border-radius: 23px;
    color: #fff;
    background: linear-gradient(135deg, rgba(58, 145, 103, 0.98), rgba(20, 94, 64, 0.98));
    box-shadow:
      inset 0 1px 0 rgba(255, 255, 255, 0.32),
      0 10px 28px rgba(24, 83, 52, 0.3);
    font-size: 10px;
    font-weight: 700;
  }

  .messages-actions .secondary-button.add-friend-button .icon {
    width: 17px;
    height: 17px;
    color: #fff;
  }

  .messages-actions .secondary-button {
    min-height: 34px;
    gap: 4px;
    padding: 0 9px;
    font-size: 8px;
  }

  .messages-actions .secondary-button .icon {
    width: 14px;
    height: 14px;
  }

  .request-badge {
    position: absolute;
    top: -5px;
    right: -4px;
    min-width: 16px;
    height: 16px;
    border: 1.5px solid var(--paper);
    font-size: 6px;
  }

  .profile-id-line {
    margin-top: 5px;
  }

  .profile-id-line strong {
    font-size: 8px;
  }

  .admin-setting-row {
    margin-top: 2px;
  }

  .friend-modal {
    max-height: 91vh;
    overflow-y: auto;
  }

  .friend-id-form {
    padding-right: 17px;
    padding-left: 17px;
  }

  .friend-search-result {
    margin-right: 17px;
    margin-left: 17px;
  }

  .friend-profile-result {
    flex-wrap: wrap;
  }

  .friend-result-actions {
    width: 100%;
    justify-content: flex-end;
  }

  .friend-requests-section {
    max-height: none;
    padding-right: 17px;
    padding-left: 17px;
  }

  .friend-request-row {
    align-items: flex-start;
  }

  .friend-request-actions {
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
  }

  .admin-gate-modal form {
    padding: 3px 18px calc(20px + env(safe-area-inset-bottom));
  }

  .admin-modal {
    height: 92vh;
    max-height: 92vh;
  }

  .admin-modal-header {
    padding-right: 16px;
    padding-left: 18px;
  }

  .admin-summary {
    margin-right: 13px;
    margin-left: 13px;
  }

  .admin-search {
    margin-right: 13px;
    margin-left: 13px;
  }

  .admin-user-list {
    padding-right: 9px;
    padding-left: 9px;
  }

  .admin-user-row {
    flex-wrap: wrap;
    align-items: flex-start;
    padding: 10px;
  }

  .admin-user-copy {
    min-width: calc(100% - 55px);
  }

  .admin-row-actions {
    width: 100%;
    max-width: none;
    justify-content: flex-end;
    padding-left: 50px;
  }

  .admin-footer {
    padding-right: 14px;
    padding-left: 14px;
  }

  .moderation-modal form {
    padding-right: 18px;
    padding-left: 18px;
  }
}

@media (max-width: 800px) {
  .auth-card {
    padding: 20px 17px;
    border-radius: 20px;
  }

  .admin-tabs {
    margin-right: 13px;
    margin-left: 13px;
  }

  .admin-content-row {
    flex-wrap: wrap;
    align-items: flex-start;
  }

  .admin-content-copy {
    min-width: calc(100% - 50px);
  }

  .admin-content-actions {
    width: 100%;
    justify-content: flex-end;
    padding-left: 44px;
  }

  .public-profile-modal {
    max-height: 92vh;
    overflow-y: auto;
  }

  .public-profile-cover {
    padding-right: 18px;
    padding-left: 18px;
  }

  .public-profile-body {
    padding-right: 17px;
    padding-left: 17px;
  }

  .public-profile-actions .primary-button,
  .public-profile-actions .secondary-button {
    flex: 1;
  }

  .profile-like-button {
    flex-basis: 100%;
    justify-content: center;
  }

  .admin-public-edit {
    flex: 0 0 auto;
  }

  .shop-balance {
    margin-right: 15px;
    margin-left: 15px;
  }

  .shop-products {
    grid-template-columns: 1fr;
    padding-right: 15px;
    padding-left: 15px;
  }

  .shop-product {
    display: grid;
    grid-template-columns: 130px 1fr;
  }

  .shop-product-preview {
    height: 100%;
    min-height: 132px;
  }

  .shop-product-copy p {
    min-height: 0;
  }

  .shop-post-preview {
    width: 104px;
    height: 67px;
  }

  .admin-user-edit-modal form {
    max-height: calc(92vh - 80px);
    overflow-y: auto;
    padding-right: 17px;
    padding-left: 17px;
  }

  .shop-page-toolbar .secondary-button {
    display: none;
  }

  .mall-hero {
    grid-template-columns: 1fr;
    gap: 17px;
    padding: 22px 19px;
  }

  .mall-hero h2 {
    font-size: 20px;
  }

  .mall-balance-card {
    width: 100%;
  }

  .mall-balance-card > strong {
    font-size: 29px;
  }

  .mall-section-heading {
    align-items: flex-start;
  }

  .mall-products {
    grid-template-columns: 1fr;
  }

  .mall-products .shop-product {
    display: grid;
    grid-template-columns: 125px 1fr;
  }

  .mall-products .shop-product-preview {
    min-height: 128px;
  }

  .admin-user-row .admin-protected-label {
    margin-left: auto;
  }

  .post-author.profile-link {
    max-width: calc(100% - 85px);
  }

  .membership-market {
    padding: 14px;
    border-radius: 15px;
  }

  .membership-market-head {
    align-items: flex-start;
    flex-direction: column;
    gap: 6px;
  }

  .membership-current {
    text-align: left;
  }

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

  .membership-card > p {
    min-height: 0;
  }

  .promotion-choice {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .promotion-choice-copy {
    min-width: calc(100% - 52px);
  }

  .promotion-choice-price {
    margin-left: 47px;
  }

  .recommend-friend-modal form {
    padding: 0 18px calc(18px + env(safe-area-inset-bottom));
  }

  .friend-request-compose-modal form {
    padding: 0 18px calc(18px + env(safe-area-inset-bottom));
  }

  .edit-post-modal form,
  .report-modal form {
    padding: 0 18px calc(18px + env(safe-area-inset-bottom));
  }

  .report-reasons {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 390px) {
  .shop-product {
    display: block;
  }

  .shop-product-preview {
    min-height: 100px;
  }

  .public-profile-stats strong {
    font-size: 12px;
  }

  .admin-summary strong {
    font-size: 14px;
  }
}

@media (max-width: 800px) {
  .promoter-modal {
    height: 94vh;
    max-height: 94vh;
  }

  .promoter-content {
    max-height: calc(94vh - 76px);
    padding: 0 15px calc(18px + env(safe-area-inset-bottom));
  }

  .promoter-page-toolbar {
    align-items: flex-start;
    flex-direction: column;
    gap: 12px;
  }

  .promoter-page-actions {
    width: 100%;
    justify-content: space-between;
  }

  .promoter-content.promoter-page-content {
    max-height: none;
    padding: 0 0 calc(100px + env(safe-area-inset-bottom));
  }

  .promoter-hero {
    min-height: 205px;
    align-items: flex-start;
    flex-direction: column;
    padding: 21px;
  }

  .promoter-hero h3 {
    font-size: 23px;
  }

  .promoter-seal {
    align-self: flex-end;
  }

  .promoter-level-grid,
  .promoter-rules {
    grid-template-columns: 1fr;
  }

  .promoter-level-card {
    min-height: 0;
  }

  .promoter-level-card b {
    margin-top: 8px;
  }

  .promoter-activation-card,
  .promoter-progress-card {
    padding: 16px;
  }

  .promoter-activation-form .form-grid {
    grid-template-columns: 1fr;
  }

  .promoter-submit {
    width: 100%;
  }

  .promoter-identity-card {
    padding: 20px;
  }

  .promoter-identity-head {
    align-items: flex-start;
    flex-direction: column;
    gap: 8px;
  }

  .promoter-code {
    font-size: clamp(34px, 11vw, 48px);
    letter-spacing: 0.04em;
  }

  .promoter-copy-actions {
    flex-direction: column;
  }

  .promoter-copy-actions .primary-button,
  .promoter-copy-actions .secondary-button {
    width: 100%;
  }

  .promoter-progress-foot {
    align-items: flex-start;
    flex-direction: column;
  }
}

.auth-method-switch {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  padding: 4px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.42);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.9),
    0 6px 18px rgba(32, 77, 49, 0.05);
  backdrop-filter: blur(14px);
}

.auth-method-switch button {
  min-height: 42px;
  padding: 0 10px;
  border: 1px solid transparent;
  border-radius: 10px;
  color: var(--muted);
  background: transparent;
  font-size: 12px;
  font-weight: 800;
  transition: 0.2s ease;
}

.auth-method-switch button.active {
  border-color: rgba(255, 255, 255, 0.9);
  color: var(--green-deep);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.95), rgba(239, 250, 243, 0.76));
  box-shadow:
    inset 0 1px 0 #fff,
    0 5px 15px rgba(34, 82, 51, 0.1);
}

.auth-method-hint {
  margin-top: -6px;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.6;
}

.field.is-primary .input-wrap {
  border-color: rgba(55, 139, 93, 0.48);
  background: rgba(255, 255, 255, 0.88);
  box-shadow:
    inset 0 1px 0 #fff,
    0 0 0 3px rgba(53, 139, 91, 0.08);
}

.field-required-mark {
  margin-left: 4px;
  padding: 2px 6px;
  border-radius: 999px;
  color: var(--green);
  background: var(--green-soft);
  font-size: 8px;
}

.referral-field-highlight {
  padding: 12px;
  border: 1px solid rgba(232, 184, 91, 0.42);
  border-radius: 14px;
  background:
    radial-gradient(circle at 96% 0%, rgba(255, 224, 155, 0.52), transparent 38%),
    linear-gradient(145deg, rgba(255, 253, 244, 0.9), rgba(255, 249, 231, 0.65));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.95),
    0 8px 22px rgba(133, 92, 28, 0.07);
}

.promoter-top-entry {
  min-height: 39px;
  gap: 6px;
  padding: 0 13px;
  color: var(--green-deep);
  font-size: 10px;
  font-weight: 800;
  white-space: nowrap;
}

.mobile-compose-fab {
  display: none;
}

.mobile-comment-drawer {
  display: none;
}

@media (max-width: 768px) {
  .app {
    padding: 0 0 calc(96px + env(safe-area-inset-bottom));
  }

  .mobile-header {
    position: relative;
    z-index: 30;
    top: auto;
    right: auto;
    left: auto;
    height: calc(60px + env(safe-area-inset-top));
  }

  .main-content {
    padding: 14px 14px 0;
  }

  .sidebar,
  .right-rail,
  .quick-compose {
    display: none !important;
  }

  .sidebar,
  .right-rail,
  .category-tabs,
  .feed-heading,
  .page-toolbar,
  .messages-actions .add-friend-button {
    position: static !important;
  }

  .page-toolbar {
    margin-bottom: 14px;
  }

  .toolbar-actions {
    display: none;
  }

  .mobile-header .icon-button,
  .mobile-nav-item {
    min-width: 44px;
    min-height: 44px;
  }

  .app button:not(.inline-link),
  .modal button:not(.inline-link),
  .auth-form button:not(.inline-link) {
    min-height: 40px;
  }

  .mobile-avatar {
    min-width: 40px;
    min-height: 40px;
  }

  .mobile-nav {
    right: 12px;
    bottom: calc(12px + env(safe-area-inset-bottom));
    left: 12px;
    height: 66px;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    padding: 6px;
    border: 1px solid rgba(255, 255, 255, 0.62);
    border-radius: 22px;
    background:
      linear-gradient(145deg, rgba(255, 255, 255, 0.82), rgba(242, 250, 245, 0.66));
    box-shadow:
      inset 0 1px 0 rgba(255, 255, 255, 0.95),
      0 16px 42px rgba(21, 56, 34, 0.18);
    backdrop-filter: blur(24px) saturate(155%);
    -webkit-backdrop-filter: blur(24px) saturate(155%);
    transition:
      transform 0.26s ease,
      opacity 0.2s ease;
  }

  .mobile-nav-item {
    height: 52px;
    gap: 3px;
    border-radius: 15px;
    font-size: 9px;
  }

  .mobile-nav-item.active {
    background: rgba(255, 255, 255, 0.7);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
  }

  .promoter-mobile-nav {
    color: #7256a3;
  }

  .promoter-mobile-nav.active {
    color: #67469e;
    background:
      linear-gradient(135deg, rgba(238, 230, 255, 0.9), rgba(255, 255, 255, 0.68));
  }

  .app.mobile-nav-hidden .mobile-nav {
    opacity: 0;
    pointer-events: none;
    transform: translateY(calc(100% + 30px));
  }

  .mobile-compose-fab {
    position: fixed;
    z-index: 48;
    right: 18px;
    bottom: calc(92px + env(safe-area-inset-bottom));
    display: grid;
    width: 56px;
    height: 56px;
    place-items: center;
    border: 1px solid rgba(255, 255, 255, 0.52);
    border-radius: 19px 19px 19px 7px;
    color: #fff;
    background:
      radial-gradient(circle at 30% 20%, rgba(255, 255, 255, 0.32), transparent 35%),
      linear-gradient(135deg, #3d956d, #176441);
    box-shadow:
      inset 0 1px 0 rgba(255, 255, 255, 0.36),
      0 14px 32px rgba(22, 92, 57, 0.34);
    transition:
      bottom 0.25s ease,
      transform 0.18s ease;
  }

  .mobile-compose-fab:active {
    transform: scale(0.94);
  }

  .mobile-compose-fab .icon {
    width: 25px;
    height: 25px;
  }

  .app.mobile-nav-hidden .mobile-compose-fab {
    bottom: calc(18px + env(safe-area-inset-bottom));
  }

  .messages-actions .secondary-button.add-friend-button {
    right: auto;
    bottom: auto;
    min-height: 40px;
    padding: 0 13px;
    border-radius: 12px;
    color: var(--green-deep);
    background: rgba(255, 255, 255, 0.7);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
    font-size: 9px;
  }

  .messages-actions .secondary-button.add-friend-button .icon {
    color: var(--green);
  }

  .category-tabs {
    overflow-x: auto;
    margin-right: -14px;
    margin-left: -14px;
    padding: 7px 14px;
    border: 0;
    border-radius: 0;
    background: rgba(255, 255, 255, 0.28);
    box-shadow: none;
    scrollbar-width: none;
    backdrop-filter: blur(18px);
  }

  .category-tabs::-webkit-scrollbar {
    display: none;
  }

  .category-tab {
    min-height: 40px;
    padding: 0 15px;
  }

  .post-card,
  .board-intro,
  .mailbox-notice,
  .promoter-level-card,
  .promoter-activation-card,
  .promoter-progress-card,
  .account-card,
  .profile-activity-card {
    border-color: rgba(255, 255, 255, 0.55);
    box-shadow:
      inset 0 1px 0 rgba(255, 255, 255, 0.9),
      0 14px 36px rgba(24, 62, 39, 0.09);
  }

  .post-actions .action-button,
  .detail-actions .action-button,
  .comment-actions button {
    min-width: 40px;
    min-height: 40px;
    justify-content: center;
    padding: 0 9px;
    border-radius: 11px;
    font-size: 9px;
  }

  .comment-actions {
    gap: 5px;
    flex-wrap: wrap;
  }

  .create-post-modal {
    height: auto;
    max-height: calc(var(--mobile-viewport-height, 100dvh) - 18px);
    border-radius: 24px 24px 0 0;
    overflow-y: auto;
  }

  #comment-drawer {
    align-items: flex-end;
    padding-bottom: var(--mobile-keyboard-inset, 0px);
  }

  .mobile-comment-drawer {
    display: flex;
    width: 100%;
    height: min(
      72dvh,
      calc(var(--mobile-viewport-height, 100dvh) - 24px)
    );
    max-height: calc(var(--mobile-viewport-height, 100dvh) - 16px);
    flex-direction: column;
    overflow: hidden;
    padding: 0;
    border: 1px solid rgba(255, 255, 255, 0.64);
    border-radius: 25px 25px 0 0;
    background:
      radial-gradient(circle at 88% 0%, rgba(200, 226, 211, 0.38), transparent 34%),
      linear-gradient(145deg, rgba(255, 255, 255, 0.94), rgba(242, 249, 244, 0.9));
    box-shadow:
      inset 0 1px 0 rgba(255, 255, 255, 0.97),
      0 -24px 70px rgba(12, 41, 24, 0.24);
    backdrop-filter: blur(30px) saturate(150%);
    transition: transform 0.2s ease;
  }

  .comment-drawer-handle {
    display: grid;
    width: 100%;
    min-height: 40px;
    flex: 0 0 auto;
    place-items: center;
    background: transparent;
  }

  .comment-drawer-handle span {
    width: 42px;
    height: 5px;
    border-radius: 999px;
    background: rgba(95, 112, 101, 0.32);
  }

  .comment-drawer-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    padding: 5px 18px 13px;
    border-bottom: 1px solid rgba(151, 171, 157, 0.18);
  }

  .comment-drawer-head h2 {
    margin-top: 3px;
    font-family: var(--serif);
    font-size: 21px;
  }

  .comment-drawer-head p {
    max-width: 270px;
    overflow: hidden;
    margin-top: 3px;
    color: var(--muted);
    font-size: 9px;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .comment-drawer-head-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--muted);
    font-size: 9px;
  }

  .comment-drawer-list {
    display: flex;
    min-height: 0;
    flex: 1;
    flex-direction: column;
    gap: 4px;
    overflow-y: auto;
    overscroll-behavior: contain;
    padding: 13px 14px;
  }

  .comment-drawer-list .comment {
    padding: 10px;
    border: 1px solid rgba(255, 255, 255, 0.72);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.52);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.88);
  }

  .comment-drawer-list .comment-text {
    font-size: 11px;
    line-height: 1.72;
  }

  .comment-drawer-empty {
    display: flex;
    flex: 1;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 6px;
    color: var(--muted);
    text-align: center;
  }

  .comment-drawer-empty .icon {
    width: 34px;
    height: 34px;
    color: var(--green);
  }

  .comment-drawer-composer {
    flex: 0 0 auto;
    padding: 10px 13px calc(12px + env(safe-area-inset-bottom));
    border-top: 1px solid rgba(255, 255, 255, 0.78);
    background: rgba(255, 255, 255, 0.66);
    box-shadow: 0 -10px 24px rgba(32, 66, 44, 0.07);
    backdrop-filter: blur(22px) saturate(145%);
  }

  .comment-reply-context {
    display: flex;
    min-height: 34px;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 7px;
    padding: 5px 10px;
    border-radius: 10px;
    color: var(--green-deep);
    background: var(--green-soft);
    font-size: 9px;
    font-weight: 700;
  }

  .comment-reply-context button {
    min-width: 44px;
    min-height: 40px;
    color: var(--red);
    background: transparent;
    font-size: 9px;
    font-weight: 800;
  }

  .comment-drawer-form {
    display: flex;
    align-items: flex-end;
    gap: 8px;
  }

  .comment-drawer-form .comment-form-input {
    min-height: 46px;
    padding: 6px 7px 6px 12px;
    border-color: rgba(255, 255, 255, 0.8);
    border-radius: 15px;
    background: rgba(255, 255, 255, 0.8);
    box-shadow: inset 0 1px 0 #fff;
  }

  .comment-drawer-form textarea {
    min-height: 32px;
    max-height: 120px;
    overflow-y: auto;
    font-size: 13px;
  }

  .comment-drawer-form .comment-form-input button {
    min-width: 54px;
    min-height: 40px;
    border-radius: 11px;
    font-size: 11px;
  }
}

/* Post detail and comment contrast/layout hardening */

.detail-modal {
  display: flex;
  height: min(92vh, 900px);
  flex-direction: column;
  overflow: hidden;
  color: #1a2e22;
  background: #f7faf8;
}

.detail-topbar {
  flex: 0 0 auto;
  color: #111827;
  background: rgba(255, 255, 255, 0.94);
}

.detail-topbar > span {
  color: #111827;
}

.detail-scroll {
  flex: 1;
  min-height: 0;
  max-height: none;
  background: #f7faf8;
}

.detail-post {
  color: #1a2e22;
  background: #ffffff;
}

.detail-post h1 {
  color: #111827 !important;
  font-weight: 800;
}

.detail-author-copy strong {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  color: #111827 !important;
  font-size: 14px;
  font-weight: 800;
}

.detail-author-copy span {
  color: #4b5563 !important;
  font-size: 12px;
}

.detail-body {
  color: #1f2937;
  font-size: 14px;
  line-height: 1.75;
}

.detail-actions {
  flex-wrap: wrap;
  gap: 8px;
  color: #4b5563;
}

.detail-actions .read-count {
  min-height: 32px;
  margin-left: auto;
  color: #4b5563;
  font-size: 12px;
  white-space: nowrap;
  flex-shrink: 0;
}

.comments-section {
  color: #1a2e22;
  background: #f8faf9;
}

.comments-section > h2 {
  color: #111827;
  font-size: 18px;
  font-weight: 800;
}

.comment-list {
  gap: 10px;
}

.comment {
  display: flex;
  align-items: flex-start;
  gap: 0;
  overflow: hidden;
  padding: 14px 16px;
  border: 1px solid rgba(212, 222, 216, 0.82);
  border-radius: 16px;
  color: #1f2937;
  background: #ffffff;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.95),
    0 7px 22px rgba(30, 64, 43, 0.05);
}

.comment.comment-admin {
  border-color: rgba(204, 173, 90, 0.24);
  background:
    linear-gradient(145deg, rgba(255, 253, 243, 0.98), rgba(255, 249, 228, 0.9));
}

.comment.comment-promoter {
  border-color: rgba(116, 92, 164, 0.22);
}

.comment.forum-bubble-ember,
.comment.forum-bubble-frost {
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.95),
    0 7px 22px rgba(30, 64, 43, 0.05);
}

.comment-avatar-button {
  width: 36px;
  height: 36px;
  margin-right: 12px;
  overflow: hidden;
  flex: 0 0 36px;
  border-radius: 50%;
}

.comment-avatar-button .avatar {
  width: 36px;
  height: 36px;
  margin: 0;
  border-width: 2px;
  font-size: 14px;
  box-shadow: none;
}

.comment-avatar-button .avatar::after {
  inset: -2px;
}

.comment-content {
  min-width: 0;
  flex: 1;
}

.comment-head {
  display: flex;
  min-width: 0;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}

.comment-head .comment-author-button,
.comment-head strong {
  overflow: hidden;
  max-width: 100%;
  color: #111827 !important;
  font-size: 15px;
  font-weight: 800;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.comment-head time {
  margin-left: auto;
  color: #6b7280 !important;
  font-size: 12px;
  white-space: nowrap;
  flex-shrink: 0;
}

.comment-head .author-op {
  color: #245c40;
  background: #e6f3eb;
  font-size: 10px;
  font-weight: 800;
  white-space: nowrap;
}

.comment-text {
  margin-top: 6px;
  color: #1f2937 !important;
  font-size: 15px;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.comment-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 8px;
}

.comment-actions button {
  display: inline-flex;
  min-height: 30px;
  align-items: center;
  gap: 4px;
  padding: 2px 7px;
  border-radius: 8px;
  color: #6b7280 !important;
  background: transparent;
  font-size: 13px;
  line-height: 1;
  white-space: nowrap;
  flex-shrink: 0;
}

.comment-actions .icon {
  width: 14px;
  height: 14px;
}

.comment-delete {
  margin-left: 0 !important;
}

.promoter-user-badge {
  display: inline-flex;
  height: 19px;
  align-items: center;
  gap: 3px;
  padding: 0 7px;
  border: 1px solid rgba(112, 83, 168, 0.2);
  border-radius: 9px;
  color: #624292;
  background: rgba(240, 231, 253, 0.92);
  font-size: 8px;
  font-weight: 800;
  white-space: nowrap;
  flex-shrink: 0;
}

.promoter-user-badge.intermediate {
  color: #4e5f79;
  background: #edf4fb;
}

.promoter-user-badge.senior {
  color: #80560e;
  background: #fff2c9;
}

.promoter-user-badge.compact {
  height: 16px;
  padding: 0 5px;
  font-size: 7px;
}

.promoter-user-badge .icon {
  width: 9px;
  height: 9px;
}

.action-button,
.follow-button,
.category-badge,
.author-badge,
.membership-badge,
.admin-user-badge,
.promoter-user-badge,
.comment-form-input button,
.comment-actions button {
  white-space: nowrap;
  flex-shrink: 0;
}

.detail-comment-bar {
  position: sticky;
  z-index: 12;
  bottom: 0;
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 8px;
  margin: 0;
  padding: 9px 14px calc(9px + env(safe-area-inset-bottom));
  border-top: 1px solid rgba(196, 209, 201, 0.78);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 -8px 24px rgba(30, 64, 43, 0.06);
  backdrop-filter: blur(20px) saturate(145%);
  -webkit-backdrop-filter: blur(20px) saturate(145%);
}

.detail-comment-bar > .avatar {
  width: 32px;
  height: 32px;
  flex: 0 0 32px;
  font-size: 12px;
}

.detail-comment-bar .comment-form-input {
  height: auto;
  min-height: 38px;
  align-items: center;
  padding: 0 6px 0 14px;
  border-color: rgba(197, 211, 201, 0.9);
  border-radius: 19px;
  background: #f8faf9;
}

.detail-comment-bar textarea {
  height: 34px;
  min-height: 34px;
  max-height: 104px;
  overflow-y: auto;
  padding: 7px 0;
  color: #1f2937;
  font-size: 14px;
  line-height: 20px;
}

.detail-comment-bar .comment-form-input button {
  min-width: 64px;
  height: 38px;
  padding: 0 15px;
  border-radius: 19px;
  color: #ffffff;
  background: #216b4d;
  font-size: 13px;
  white-space: nowrap;
  flex-shrink: 0;
}

.detail-reply-context {
  display: flex;
  min-height: 38px;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin: 0 14px;
  padding: 4px 11px;
  border-radius: 12px 12px 0 0;
  color: var(--green-deep);
  background: var(--green-soft);
  font-size: 11px;
  font-weight: 700;
}

.detail-reply-context button {
  min-width: 48px;
  min-height: 30px;
  color: var(--red);
  background: transparent;
  font-size: 11px;
}

@media (max-width: 768px) {
  #post-modal {
    align-items: flex-end;
    padding-top: env(safe-area-inset-top);
    background:
      linear-gradient(to bottom, rgba(15, 42, 27, 0.46), rgba(15, 42, 27, 0.68));
  }

  #post-modal .detail-modal {
    display: flex;
    width: 100%;
    height: min(96dvh, calc(var(--mobile-viewport-height, 100dvh) - 4px));
    max-height: calc(var(--mobile-viewport-height, 100dvh) - 4px);
    flex-direction: column;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.68);
    border-bottom: 0;
    border-radius: 24px 24px 0 0;
    color: #1a2e22;
    background: #f7faf8;
    box-shadow:
      inset 0 1px 0 rgba(255, 255, 255, 0.95),
      0 -20px 70px rgba(7, 26, 14, 0.25);
  }

  .detail-topbar {
    height: calc(56px + env(safe-area-inset-top));
    flex: 0 0 auto;
    padding-top: env(safe-area-inset-top);
    border-radius: 24px 24px 0 0;
    color: #111827;
    background: #f8faf9;
  }

  .detail-topbar > span {
    color: #111827;
    font-size: 15px;
  }

  .detail-scroll {
    flex: 1;
    min-height: 0;
    max-height: none;
    overflow-y: auto;
    background: #f7faf8;
  }

  .detail-post {
    padding: 20px 16px 16px;
    border-radius: 0;
    color: #1a2e22;
    background: #ffffff;
  }

  .detail-post h1 {
    margin-top: 15px;
    color: #111827 !important;
    font-size: 22px;
    line-height: 1.42;
  }

  .detail-author {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .detail-author-copy {
    min-width: 0;
    flex: 1 1 calc(100% - 58px);
  }

  .detail-author-copy strong {
    color: #111827 !important;
    font-size: 15px;
  }

  .detail-author-copy span {
    color: #4b5563 !important;
    font-size: 12px;
  }

  .detail-body {
    color: #1f2937;
    font-size: 15px;
    line-height: 1.72;
  }

  .detail-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 7px;
  }

  .detail-actions .action-button {
    min-width: auto;
    height: 34px;
    padding: 0 11px;
    color: #4b5563;
    font-size: 12px;
    white-space: nowrap;
  }

  .detail-actions .read-count {
    min-height: 34px;
    margin-left: auto;
    color: #4b5563;
    font-size: 12px;
    white-space: nowrap;
  }

  .comment-list {
    gap: 9px;
  }

  .comment {
    padding: 14px 16px;
    border-radius: 16px;
    color: #1f2937;
    background: #ffffff;
  }

  .comment-avatar-button {
    width: 36px;
    height: 36px;
    flex-basis: 36px;
    margin-right: 12px;
    overflow: hidden;
  }

  .comment-avatar-button .avatar {
    width: 36px;
    height: 36px;
  }

  .comment-content {
    flex: 1;
    min-width: 0;
  }

  .comment-head {
    flex-wrap: wrap;
  }

  .comment-head .comment-author-button,
  .comment-head strong {
    color: #111827 !important;
    font-size: 15px;
  }

  .comment-head time {
    margin-left: auto;
    color: #6b7280 !important;
    font-size: 12px;
    white-space: nowrap;
  }

  .comment-text {
    margin-top: 6px;
    color: #1f2937 !important;
    font-size: 15px;
    line-height: 1.5;
  }

  .comment-actions button {
    min-height: 34px;
    color: #6b7280 !important;
    font-size: 13px;
    white-space: nowrap;
  }

  .comments-section {
    padding: 16px 12px 18px;
    color: #1a2e22;
    background: #f8faf9;
  }

  .comments-section > h2 {
    color: #111827;
    font-size: 18px;
  }

  .detail-comment-bar {
    position: relative;
    bottom: auto;
    flex: 0 0 auto;
    padding: 8px 12px calc(8px + env(safe-area-inset-bottom));
    background: rgba(255, 255, 255, 0.96);
  }
}

:root {
  --ui-page: #eef4ef;
  --ui-surface: #ffffff;
  --ui-surface-soft: #f8faf9;
  --ui-surface-raised: rgba(255, 255, 255, 0.88);
  --ui-input: rgba(255, 255, 255, 0.84);
  --ui-border: rgba(203, 216, 207, 0.82);
  --ui-text: #111827;
  --ui-text-soft: #4b5563;
  --ui-text-muted: #6b7280;
  --ui-accent: #216b4d;
  --ui-mint: #dff4e8;
  --ui-amber: #f6e8bd;
  --ui-blue: #dcebf4;
  --ui-coral: #f6ddd5;
}

html[data-theme="dark"],
html.dark,
body.dark {
  --ui-page: #101713;
  --ui-surface: #19241d;
  --ui-surface-soft: #162019;
  --ui-surface-raised: rgba(28, 42, 33, 0.94);
  --ui-input: rgba(39, 55, 45, 0.92);
  --ui-border: rgba(210, 232, 217, 0.16);
  --ui-text: #f0f7f2;
  --ui-text-soft: #c7d5cc;
  --ui-text-muted: #9bada1;
  --ui-accent: #82cfa5;
  --ui-mint: rgba(104, 194, 144, 0.17);
  --ui-amber: rgba(222, 178, 79, 0.17);
  --ui-blue: rgba(113, 165, 199, 0.17);
  --ui-coral: rgba(222, 132, 111, 0.16);
}

.password-toggle {
  min-width: 42px;
  white-space: nowrap;
  flex: 0 0 auto;
}

.select-wrap::after {
  width: 15px;
  height: 15px;
  border: 0;
  background: center / 15px 15px no-repeat
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16' fill='none'%3E%3Cpath d='m4 6 4 4 4-4' stroke='%236b7b71' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  color: transparent;
  content: "";
}

.auth-tab::after {
  opacity: 0;
  transform: scaleX(0.35);
  transition: opacity 0.16s ease, transform 0.18s ease;
}

.auth-tab.active::after {
  opacity: 1;
  transform: scaleX(1);
}

.guest-preview-button {
  display: inline-flex;
  min-height: 38px;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border: 1px solid var(--line);
  border-radius: 10px;
  color: var(--green);
  background: rgba(255, 255, 255, 0.48);
  font-size: 10px;
  font-weight: 700;
}

.topic-suggestions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 10px 0;
  border-top: 1px solid var(--line);
}

.topic-suggestions > span {
  width: 100%;
  color: var(--muted);
  font-size: 9px;
  font-weight: 700;
}

.topic-suggestions button {
  min-height: 32px;
  padding: 0 10px;
  border: 1px solid rgba(91, 145, 113, 0.2);
  border-radius: 999px;
  color: var(--green);
  background: var(--green-soft);
  font-size: 9px;
}

.setting-note {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 8px;
  font-weight: 500;
}

.notification-head-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.notification-head-actions .text-button {
  min-height: 34px;
  color: var(--green);
  font-size: 10px;
  font-weight: 700;
}

.person-chat-state {
  margin-left: auto;
  color: var(--muted);
  font-size: 9px;
  white-space: nowrap;
}

.person-chat-state.available {
  color: var(--green);
  font-weight: 700;
}

.guest-preview-modal,
.privacy-settings-modal,
.confirm-modal {
  width: min(100%, 520px);
}

.guest-preview-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  padding: 0 22px 18px;
}

.guest-preview-grid article {
  padding: 15px;
  border: 1px solid var(--ui-border);
  border-radius: 14px;
  background: var(--ui-surface-soft);
}

.guest-preview-grid strong {
  display: block;
  margin-top: 9px;
  color: var(--ui-text);
  font-size: 12px;
}

.guest-preview-grid p {
  margin-top: 4px;
  color: var(--ui-text-muted);
  font-size: 10px;
  line-height: 1.6;
}

.guest-preview-icon {
  display: grid;
  width: 35px;
  height: 35px;
  place-items: center;
  border-radius: 12px;
}

.guest-preview-icon.mint {
  color: #216b4d;
  background: var(--ui-mint);
}

.guest-preview-icon.amber {
  color: #805b14;
  background: var(--ui-amber);
}

.guest-preview-icon.blue {
  color: #3b6b89;
  background: var(--ui-blue);
}

.guest-preview-modal > .primary-button {
  display: block;
  width: calc(100% - 44px);
  margin: 0 22px 22px;
}

.privacy-setting-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 0 22px 18px;
}

.privacy-setting-list > div {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 3px 12px;
  padding: 13px 14px;
  border: 1px solid var(--ui-border);
  border-radius: 13px;
  background: var(--ui-surface-soft);
}

.privacy-setting-list strong {
  color: var(--ui-text);
  font-size: 12px;
}

.privacy-setting-list span {
  grid-column: 1;
  color: var(--ui-text-muted);
  font-size: 10px;
}

.privacy-setting-list b {
  grid-row: 1 / span 2;
  grid-column: 2;
  align-self: center;
  color: var(--green);
  font-size: 9px;
}

.privacy-settings-modal > .primary-button {
  display: block;
  width: calc(100% - 44px);
  margin: 0 22px 22px;
}

.confirm-modal {
  padding: 26px;
  text-align: center;
}

.confirm-symbol {
  display: grid;
  width: 54px;
  height: 54px;
  place-items: center;
  margin: 0 auto 14px;
  border-radius: 18px;
  color: #9a681b;
  background: var(--ui-amber);
}

.confirm-symbol .icon {
  width: 25px;
  height: 25px;
}

.confirm-modal h2 {
  color: var(--ui-text);
  font-family: var(--serif);
  font-size: 21px;
}

.confirm-modal > p {
  margin-top: 8px;
  color: var(--ui-text-soft);
  font-size: 12px;
  line-height: 1.7;
}

.confirm-modal .modal-form-actions {
  margin-top: 20px;
  justify-content: center;
}

.board-link.active {
  border-color: rgba(80, 143, 105, 0.28);
  background: var(--green-soft);
  color: var(--green-deep);
}

.rail-top-actions {
  display: none;
}

.app.compact-rail-view {
  grid-template-columns: 224px minmax(520px, 1fr);
}

.app.compact-rail-view .right-rail {
  display: none;
}

.post-card,
.shop-product,
.membership-card {
  transition:
    transform 0.18s ease,
    box-shadow 0.22s ease,
    border-color 0.18s ease;
}

.post-card:hover,
.shop-product:hover,
.membership-card:hover {
  transform: translateY(-2px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.9),
    0 16px 38px rgba(26, 70, 44, 0.12);
}

.action-button.liked,
.action-button.favorited {
  animation: action-pop 0.24s ease;
}

@keyframes action-pop {
  50% {
    transform: scale(1.1);
  }
}

.modal {
  animation: modal-pop-in 0.17s ease both;
}

@keyframes modal-pop-in {
  from {
    opacity: 0;
    transform: scale(0.97) translateY(4px);
  }
}

.view {
  animation-duration: 0.18s;
}

.modal-backdrop {
  background:
    radial-gradient(circle at 25% 16%, rgba(177, 225, 204, 0.16), transparent 27rem),
    rgba(9, 24, 14, 0.62);
}

.avatar.coral,
.avatar-style.coral {
  color: #713c34;
  background: linear-gradient(140deg, #ffe7df, #eab5a6);
}

.avatar.sky,
.avatar-style.sky {
  color: #36556b;
  background: linear-gradient(140deg, #e0edf5, #aac7da);
}

.avatar.sage,
.avatar-style.sage {
  color: #405b47;
  background: linear-gradient(140deg, #e5eee2, #b7ceb4);
}

.avatar.sand,
.avatar-style.sand {
  color: #705a2e;
  background: linear-gradient(140deg, #f7efd9, #dec994);
}

html[data-theme="dark"] body {
  color: var(--ui-text);
  background:
    radial-gradient(circle at 12% 10%, rgba(73, 140, 98, 0.16), transparent 26rem),
    radial-gradient(circle at 88% 15%, rgba(139, 109, 52, 0.1), transparent 24rem),
    var(--ui-page);
}

html[data-theme="dark"] .search-trigger,
html[data-theme="dark"] .category-tabs,
html[data-theme="dark"] .feed-filters,
html[data-theme="dark"] .post-card,
html[data-theme="dark"] .detail-post,
html[data-theme="dark"] .comments-section,
html[data-theme="dark"] .comment,
html[data-theme="dark"] .profile-activity-card,
html[data-theme="dark"] .achievement-card,
html[data-theme="dark"] .account-card,
html[data-theme="dark"] .shop-entry,
html[data-theme="dark"] .shop-product,
html[data-theme="dark"] .membership-card,
html[data-theme="dark"] .guest-preview-grid article,
html[data-theme="dark"] .privacy-setting-list > div {
  color: var(--ui-text);
  border-color: var(--ui-border);
  background: var(--ui-surface);
}

html[data-theme="dark"] .detail-modal,
html[data-theme="dark"] .detail-scroll,
html[data-theme="dark"] .detail-post,
html[data-theme="dark"] .comments-section {
  color: var(--ui-text);
  background: var(--ui-surface);
}

html[data-theme="dark"] .detail-topbar,
html[data-theme="dark"] .detail-comment-bar {
  color: var(--ui-text);
  border-color: var(--ui-border);
  background: rgba(25, 36, 29, 0.96);
}

html[data-theme="dark"] .detail-post h1,
html[data-theme="dark"] .detail-author-copy strong,
html[data-theme="dark"] .comments-section > h2,
html[data-theme="dark"] .comment-head .comment-author-button,
html[data-theme="dark"] .comment-head strong {
  color: var(--ui-text) !important;
}

html[data-theme="dark"] .detail-author-copy span,
html[data-theme="dark"] .detail-actions .read-count,
html[data-theme="dark"] .comment-head time {
  color: var(--ui-text-muted) !important;
}

html[data-theme="dark"] .detail-body,
html[data-theme="dark"] .comment-text {
  color: var(--ui-text-soft) !important;
}

html[data-theme="dark"] .comment,
html[data-theme="dark"] .comment.comment-admin {
  background: var(--ui-surface-soft);
}

html[data-theme="dark"] .comment.comment-admin {
  background:
    linear-gradient(145deg, rgba(62, 52, 30, 0.84), rgba(36, 42, 31, 0.92));
}

html[data-theme="dark"] .detail-comment-bar .comment-form-input,
html[data-theme="dark"] .comment-form-input {
  color: var(--ui-text);
  border-color: var(--ui-border);
  background: var(--ui-input);
}

html[data-theme="dark"] input::placeholder,
html[data-theme="dark"] textarea::placeholder,
html[data-theme="dark"] .messages-search input::placeholder {
  color: #91a398;
}

html[data-theme="dark"] .feed-filter.active,
html[data-theme="dark"] .category-tab.active,
html[data-theme="dark"] .profile-tab.active,
html[data-theme="dark"] .mobile-nav-item.active {
  color: var(--ui-text);
  background: rgba(112, 184, 142, 0.16);
}

html[data-theme="dark"] .growth-ring::before {
  background: var(--ui-surface);
}

html[data-theme="dark"] .achievement-badge {
  color: var(--ui-text-soft);
  background: rgba(255, 255, 255, 0.06);
}

html[data-theme="dark"] .page-toolbar h1,
html[data-theme="dark"] .messages-toolbar h1,
html[data-theme="dark"] .conversation-head h2,
html[data-theme="dark"] .profile-tab,
html[data-theme="dark"] .feed-filter,
html[data-theme="dark"] .category-tab,
html[data-theme="dark"] .search-trigger,
html[data-theme="dark"] .search-trigger span,
html[data-theme="dark"] .post-card h3,
html[data-theme="dark"] .post-author-line,
html[data-theme="dark"] .post-excerpt,
html[data-theme="dark"] .post-tags span {
  color: var(--ui-text);
}

html[data-theme="dark"] .post-excerpt,
html[data-theme="dark"] .post-tags span,
html[data-theme="dark"] .post-author-copy > span {
  color: var(--ui-text-soft);
}

html[data-theme="dark"] .messages-search,
html[data-theme="dark"] .search-trigger {
  color: var(--ui-text);
  border-color: var(--ui-border);
  background: var(--ui-input);
}

html[data-theme="dark"] .messages-search input {
  color: var(--ui-text);
}

html[data-theme="dark"] .messages-actions .secondary-button {
  color: var(--ui-text);
  border-color: var(--ui-border);
  background: rgba(255, 255, 255, 0.08);
}

html[data-theme="dark"] .profile-tabs,
html[data-theme="dark"] .auth-tabs {
  border-color: var(--ui-border);
}

html[data-theme="dark"] .guest-preview-button,
html[data-theme="dark"] .topic-suggestions button {
  color: var(--ui-text);
  border-color: var(--ui-border);
  background: rgba(255, 255, 255, 0.07);
}

.mall-products {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.shop-page-toolbar {
  padding-top: 8px;
}

.chat-cosmetic-mint,
.shop-chat-preview.chat-cosmetic-mint {
  background: linear-gradient(135deg, #dff7eb, #b6e5cd);
}

.chat-cosmetic-peach,
.shop-chat-preview.chat-cosmetic-peach {
  background: linear-gradient(135deg, #fff1e9, #f4c6b3);
}

.chat-cosmetic-violet,
.shop-chat-preview.chat-cosmetic-violet {
  background: linear-gradient(135deg, #f3eaff, #d8c1ef);
}

@media (max-width: 800px) {
  .guest-preview-grid {
    grid-template-columns: 1fr;
  }

  .app.compact-rail-view {
    display: block;
  }

  .mall-products {
    grid-template-columns: 1fr;
  }
}

/* Points circulation: bounty, tipping, equipped cosmetics and ledger */

.bounty-choice {
  display: flex;
  align-items: center;
  gap: 11px;
  margin: 11px 0;
  padding: 12px 13px;
  border: 1px solid rgba(197, 155, 56, 0.36);
  border-radius: 13px;
  background:
    radial-gradient(circle at 90% 0%, rgba(255, 226, 147, 0.5), transparent 44%),
    linear-gradient(135deg, rgba(255, 252, 238, 0.94), rgba(255, 245, 218, 0.78));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.94),
    0 8px 22px rgba(133, 96, 26, 0.08);
  cursor: pointer;
}

.bounty-choice > input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.bounty-choice-icon {
  display: grid;
  width: 36px;
  height: 36px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 11px;
  color: #7c5b10;
  background: rgba(255, 255, 255, 0.82);
}

.bounty-choice-copy {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
  gap: 2px;
}

.bounty-choice-copy strong {
  color: #56400e;
  font-size: 10px;
}

.bounty-choice-copy strong b {
  margin-left: 5px;
  color: #94701d;
  font-size: 8px;
}

.bounty-choice-copy small {
  color: #806a3d;
  font-size: 7px;
  line-height: 1.5;
}

.bounty-choice-status {
  flex: 0 0 auto;
  padding: 5px 8px;
  border-radius: 999px;
  color: #765717;
  background: #fff0bd;
  font-size: 8px;
  font-weight: 800;
  white-space: nowrap;
}

.bounty-choice:has(input:checked) {
  border-color: #c99a2c;
  background:
    radial-gradient(circle at 92% 0%, rgba(255, 214, 101, 0.72), transparent 45%),
    linear-gradient(135deg, #fff9e6, #ffedbf);
  box-shadow:
    inset 0 1px 0 #fff,
    0 0 0 3px rgba(197, 155, 56, 0.12),
    0 10px 26px rgba(133, 96, 26, 0.12);
}

.bounty-options {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 7px;
  margin: -3px 0 12px;
  padding: 10px 11px;
  border: 1px dashed rgba(197, 155, 56, 0.34);
  border-radius: 11px;
  background: rgba(255, 251, 235, 0.72);
}

.bounty-options > span {
  margin-right: auto;
  color: var(--ui-text-soft);
  font-size: 9px;
  font-weight: 700;
}

.bounty-options label {
  position: relative;
  cursor: pointer;
}

.bounty-options input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.bounty-options label span {
  display: inline-flex;
  min-height: 32px;
  align-items: center;
  padding: 0 10px;
  border: 1px solid rgba(197, 155, 56, 0.26);
  border-radius: 999px;
  color: #72561a;
  background: rgba(255, 255, 255, 0.68);
  font-size: 9px;
  font-weight: 800;
  white-space: nowrap;
}

.bounty-options input:checked + span {
  color: #fff9e7;
  border-color: #9f7417;
  background: linear-gradient(135deg, #b3882d, #806014);
}

.bounty-options small {
  width: 100%;
  color: #8c7750;
  font-size: 8px;
}

.bounty-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 7px;
  border: 1px solid rgba(197, 155, 56, 0.3);
  border-radius: 999px;
  color: #765817;
  background: linear-gradient(135deg, #fff7dc, #f7e7b1);
  font-size: 8px;
  font-weight: 800;
  white-space: nowrap;
}

.bounty-badge .icon {
  width: 11px;
  height: 11px;
}

.bounty-badge small {
  color: inherit;
  font-size: 7px;
}

.bounty-badge.solved {
  color: #21553a;
  border-color: rgba(62, 126, 86, 0.25);
  background: linear-gradient(135deg, #edf9f0, #d5edd9);
}

.custom-user-title {
  display: inline-flex;
  min-height: 21px;
  align-items: center;
  gap: 3px;
  padding: 0 7px;
  border: 1px solid rgba(197, 155, 56, 0.3);
  border-radius: 999px;
  color: #745615;
  background:
    linear-gradient(135deg, rgba(255, 249, 225, 0.96), rgba(246, 224, 158, 0.88));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.86);
  font-size: 9px;
  font-weight: 800;
  white-space: nowrap;
}

.custom-user-title.compact {
  min-height: 18px;
  padding: 0 5px;
  font-size: 7px;
}

.custom-user-title .icon {
  width: 10px;
  height: 10px;
}

.tip-action {
  color: #7e5d13 !important;
  border-color: rgba(197, 155, 56, 0.24) !important;
  background: rgba(255, 247, 222, 0.72) !important;
}

.content-tip-total,
.comment-tip-total {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: #8a681b;
  font-size: 10px;
  font-weight: 700;
  white-space: nowrap;
}

.content-tip-total .icon,
.comment-tip-total .icon {
  width: 12px;
  height: 12px;
}

.comment-accepted {
  position: relative;
  border-color: rgba(197, 155, 56, 0.42) !important;
  background:
    radial-gradient(circle at 95% 0%, rgba(255, 221, 125, 0.55), transparent 34%),
    linear-gradient(145deg, #fffdf5, #fff7df) !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.96),
    0 10px 26px rgba(134, 99, 25, 0.1) !important;
}

.accepted-answer-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 2px 6px;
  border-radius: 999px;
  color: #fff8df;
  background: linear-gradient(135deg, #a77b20, #c79b38);
  font-size: 7px;
  font-weight: 800;
  white-space: nowrap;
}

.accepted-answer-badge .icon {
  width: 9px;
  height: 9px;
}

.accept-answer-button {
  color: #765817 !important;
  background: rgba(255, 239, 185, 0.7) !important;
}

.comment-tip-button {
  white-space: nowrap;
}

.mall-points-button {
  display: flex;
  width: 100%;
  align-items: flex-start;
  flex-direction: column;
  gap: 2px;
  padding: 0;
  color: #fff;
  background: transparent;
  text-align: left;
}

.mall-points-button strong {
  font-family: Georgia, serif;
  font-size: 34px;
  font-weight: 500;
  line-height: 1;
}

.mall-points-button small {
  color: rgba(255, 255, 255, 0.62);
  font-size: 7px;
}

.shop-product-actions {
  display: flex;
  align-items: stretch;
  flex-direction: column;
  gap: 5px;
}

.shop-renew-button {
  min-height: 27px;
  color: #86641c !important;
  font-size: 8px !important;
}

.custom-title-product-wrap {
  padding: 14px 22px 0;
}

.custom-title-shop-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  padding: 18px;
  border: 1px solid rgba(197, 155, 56, 0.24);
  border-radius: 18px;
  color: #f6edd4;
  background:
    radial-gradient(circle at 88% 10%, rgba(230, 190, 93, 0.24), transparent 30%),
    linear-gradient(135deg, #173b2a, #0d2419);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.18),
    0 16px 40px rgba(8, 30, 18, 0.18);
}

.custom-title-shop-icon {
  display: grid;
  width: 46px;
  height: 46px;
  place-items: center;
  border: 1px solid rgba(255, 227, 151, 0.24);
  border-radius: 14px;
  color: #f0d37c;
  background: rgba(255, 255, 255, 0.08);
}

.custom-title-shop-card h3 {
  margin: 3px 0;
  color: #fff8e6;
  font-family: var(--serif);
  font-size: 17px;
}

.custom-title-shop-card p {
  color: rgba(255, 255, 255, 0.7);
  font-size: 9px;
  line-height: 1.65;
}

.custom-title-shop-card small {
  color: #e6c971;
  font-size: 8px;
}

.tip-modal,
.custom-title-modal {
  width: min(100%, 470px);
}

.tip-option-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  padding: 8px 22px 14px;
}

.tip-option-grid button {
  display: flex;
  min-height: 94px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 4px;
  border: 1px solid rgba(197, 155, 56, 0.3);
  border-radius: 16px;
  color: #6f5419;
  background:
    radial-gradient(circle at 80% 0%, rgba(255, 224, 139, 0.55), transparent 45%),
    var(--ui-surface-soft);
}

.tip-option-grid strong {
  font-family: Georgia, serif;
  font-size: 28px;
  font-weight: 500;
}

.tip-option-grid span {
  font-size: 9px;
  font-weight: 700;
}

.tip-option-grid button:disabled,
.tip-custom-form button:disabled {
  cursor: wait;
  opacity: 0.62;
}

.tip-custom-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 9px;
  padding: 0 22px 14px;
}

.tip-custom-form > label {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 6px;
  color: var(--ui-text-muted);
  font-size: 9px;
  font-weight: 700;
}

.tip-custom-input {
  display: flex;
  min-height: 42px;
  align-items: center;
  gap: 8px;
  padding: 0 12px;
  border: 1px solid var(--ui-border);
  border-radius: 12px;
  background: var(--ui-input);
}

.tip-custom-input:focus-within {
  border-color: var(--ui-accent);
  box-shadow: 0 0 0 3px rgba(33, 107, 77, 0.09);
}

.tip-custom-input input {
  width: 100%;
  min-width: 0;
  color: var(--ui-text);
  background: transparent;
  outline: 0;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
}

.tip-custom-input b {
  flex: 0 0 auto;
  color: var(--ui-text-muted);
  font-size: 9px;
  white-space: nowrap;
}

.tip-custom-form .primary-button {
  min-height: 42px;
  padding: 0 14px;
  white-space: nowrap;
}

.tip-daily-note {
  padding: 0 22px;
  color: var(--ui-text-muted);
  font-size: 9px;
  line-height: 1.6;
  text-align: center;
}

.custom-title-modal form,
.tip-modal .form-error {
  padding: 0 22px 22px;
}

.custom-title-balance {
  margin: 9px 0;
  color: var(--ui-text-muted);
  font-size: 10px;
}

.points-ledger-modal,
.my-cosmetics-modal {
  width: min(100%, 690px);
  max-height: 86vh;
}

.points-ledger-list,
.my-cosmetics-list {
  display: flex;
  max-height: calc(86vh - 120px);
  flex-direction: column;
  gap: 8px;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 0 20px 22px;
  -webkit-overflow-scrolling: touch;
}

.ledger-row,
.my-cosmetic-row {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 12px 13px;
  border: 1px solid var(--ui-border);
  border-radius: 14px;
  background: var(--ui-surface-soft);
}

.ledger-icon {
  display: grid;
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  place-items: center;
  border-radius: 11px;
  color: #7b5b18;
  background: rgba(245, 220, 153, 0.36);
}

.ledger-copy,
.my-cosmetic-row > span:nth-child(2) {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
  gap: 2px;
}

.ledger-copy strong,
.my-cosmetic-row strong {
  overflow: hidden;
  color: var(--ui-text);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ledger-copy small,
.my-cosmetic-row small {
  color: var(--ui-text-muted);
  font-size: 8px;
}

.ledger-amount {
  font-variant-numeric: tabular-nums;
  font-size: 14px;
  font-weight: 800;
  white-space: nowrap;
}

.ledger-amount.positive {
  color: #2f7c53;
}

.ledger-amount.negative {
  color: #b4563f;
}

.ledger-balance {
  min-width: 58px;
  color: var(--ui-text-muted);
  font-size: 8px;
  text-align: right;
  white-space: nowrap;
}

.ledger-loading {
  display: flex;
  min-height: 150px;
  align-items: center;
  justify-content: center;
  gap: 7px;
  color: var(--ui-text-muted);
  font-size: 10px;
}

.my-cosmetic-swatch {
  width: 42px;
  height: 38px;
  flex: 0 0 42px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 12px;
  background: var(--ui-surface);
  box-shadow: 0 5px 14px rgba(35, 65, 45, 0.08);
}

.my-cosmetic-row > button {
  min-height: 34px;
  padding: 0 11px;
  border: 1px solid var(--ui-border);
  border-radius: 10px;
  color: var(--ui-text);
  background: var(--ui-surface);
  font-size: 9px;
  font-weight: 700;
  white-space: nowrap;
}

.my-cosmetic-row.equipped > button {
  color: #745817;
  border-color: rgba(197, 155, 56, 0.28);
  background: #fff4cf;
}

.comment.forum-bubble-mint,
.post-card.forum-bubble-mint,
.detail-post.forum-bubble-mint {
  border-color: rgba(104, 184, 139, 0.35) !important;
  background:
    linear-gradient(145deg, rgba(247, 255, 250, 0.98), rgba(222, 246, 232, 0.94)) !important;
}

.comment.forum-bubble-peach,
.post-card.forum-bubble-peach,
.detail-post.forum-bubble-peach {
  border-color: rgba(225, 158, 126, 0.34) !important;
  background:
    linear-gradient(145deg, rgba(255, 251, 247, 0.98), rgba(255, 231, 219, 0.94)) !important;
}

.comment.forum-bubble-violet,
.post-card.forum-bubble-violet,
.detail-post.forum-bubble-violet {
  border-color: rgba(166, 130, 200, 0.34) !important;
  background:
    linear-gradient(145deg, rgba(255, 252, 255, 0.98), rgba(240, 228, 251, 0.94)) !important;
}

.comment.forum-bubble-amber,
.post-card.forum-bubble-amber,
.detail-post.forum-bubble-amber {
  border-color: rgba(205, 158, 59, 0.4) !important;
  background:
    linear-gradient(145deg, rgba(255, 253, 247, 0.98), rgba(252, 239, 196, 0.94)) !important;
}

.comment.forum-bubble-frost,
.post-card.forum-bubble-frost,
.detail-post.forum-bubble-frost {
  border-color: rgba(111, 171, 212, 0.36) !important;
  background:
    linear-gradient(145deg, rgba(249, 253, 255, 0.98), rgba(223, 241, 252, 0.94)) !important;
}

.message-bubble.chat-cosmetic-amber,
.shop-chat-preview.chat-cosmetic-amber {
  color: #654711;
  border-color: rgba(211, 164, 62, 0.5);
  background: linear-gradient(135deg, #fffaf0, #f5dda4);
}

.message-bubble.chat-cosmetic-frost,
.shop-chat-preview.chat-cosmetic-frost {
  color: #28536b;
  border-color: rgba(111, 171, 212, 0.46);
  background: linear-gradient(135deg, #f7fcff, #dceff9);
}

.shop-chat-preview.chat-cosmetic-mint {
  color: #24513c;
  background: linear-gradient(135deg, #f3fff8, #d5f1e2);
}

.shop-chat-preview.chat-cosmetic-peach {
  color: #713c2b;
  background: linear-gradient(135deg, #fffaf7, #ffe3d5);
}

.shop-chat-preview.chat-cosmetic-violet {
  color: #50346c;
  background: linear-gradient(135deg, #fffaff, #eadcf8);
}

html[data-theme="dark"] .bounty-choice,
html[data-theme="dark"] .bounty-options {
  color: var(--ui-text);
  border-color: rgba(218, 180, 86, 0.26);
  background:
    radial-gradient(circle at 90% 0%, rgba(174, 130, 36, 0.2), transparent 45%),
    var(--ui-surface-soft);
}

html[data-theme="dark"] .bounty-choice-copy strong,
html[data-theme="dark"] .bounty-choice-copy small,
html[data-theme="dark"] .bounty-options > span,
html[data-theme="dark"] .bounty-options small {
  color: var(--ui-text-soft);
}

html[data-theme="dark"] .bounty-choice-copy strong b,
html[data-theme="dark"] .bounty-options label span,
html[data-theme="dark"] .bounty-choice-status,
html[data-theme="dark"] .bounty-badge,
html[data-theme="dark"] .custom-user-title {
  color: #efd88b;
  border-color: rgba(229, 195, 99, 0.3);
  background: rgba(87, 68, 26, 0.55);
}

html[data-theme="dark"] .comment-accepted {
  background:
    radial-gradient(circle at 95% 0%, rgba(170, 128, 36, 0.22), transparent 35%),
    var(--ui-surface-soft) !important;
}

html[data-theme="dark"] .content-tip-total,
html[data-theme="dark"] .comment-tip-total,
html[data-theme="dark"] .shop-renew-button {
  color: #e9cb73 !important;
}

html[data-theme="dark"] .tip-option-grid button {
  color: #ecd17f;
  border-color: rgba(229, 195, 99, 0.25);
  background:
    radial-gradient(circle at 82% 0%, rgba(172, 128, 37, 0.22), transparent 46%),
    var(--ui-surface-soft);
}

html[data-theme="dark"] .tip-custom-input {
  border-color: var(--ui-border);
  background: var(--ui-input);
}

html[data-theme="dark"] .comment.forum-bubble-mint,
html[data-theme="dark"] .comment.forum-bubble-peach,
html[data-theme="dark"] .comment.forum-bubble-violet,
html[data-theme="dark"] .comment.forum-bubble-amber,
html[data-theme="dark"] .comment.forum-bubble-frost {
  color: var(--ui-text);
}

html[data-theme="dark"] .comments-section {
  color: var(--ui-text);
  background: #101813 !important;
}

html[data-theme="dark"] .comment,
html[data-theme="dark"] .comment.comment-admin,
html[data-theme="dark"] .comment.comment-promoter {
  color: #d6e2da !important;
  border-color: rgba(210, 232, 217, 0.14) !important;
  background: #17231b !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.07),
    0 8px 24px rgba(0, 0, 0, 0.2) !important;
}

html[data-theme="dark"] .comment.comment-admin {
  border-color: rgba(216, 183, 91, 0.25) !important;
  background:
    linear-gradient(145deg, #272216, #1c1a14) !important;
}

html[data-theme="dark"] .comment.forum-bubble-mint {
  border-color: rgba(105, 190, 145, 0.24) !important;
  background: linear-gradient(145deg, #15261c, #182a1f) !important;
}

html[data-theme="dark"] .comment.forum-bubble-peach {
  border-color: rgba(229, 158, 126, 0.23) !important;
  background: linear-gradient(145deg, #291d18, #2d201a) !important;
}

html[data-theme="dark"] .comment.forum-bubble-violet {
  border-color: rgba(176, 139, 213, 0.24) !important;
  background: linear-gradient(145deg, #241b2b, #281f30) !important;
}

html[data-theme="dark"] .comment.forum-bubble-amber,
html[data-theme="dark"] .comment.forum-bubble-ember {
  border-color: rgba(219, 177, 71, 0.26) !important;
  background: linear-gradient(145deg, #2a2316, #302719) !important;
}

html[data-theme="dark"] .comment.forum-bubble-frost {
  border-color: rgba(113, 176, 217, 0.24) !important;
  background: linear-gradient(145deg, #16242c, #192b35) !important;
}

html[data-theme="dark"] .comment-accepted {
  border-color: rgba(225, 190, 95, 0.32) !important;
  background:
    radial-gradient(circle at 94% 0%, rgba(171, 128, 35, 0.18), transparent 36%),
    #272216 !important;
}

html[data-theme="dark"] .comment-head .comment-author-button,
html[data-theme="dark"] .comment-head strong,
html[data-theme="dark"] .comments-section > h2 {
  color: #f1f7f3 !important;
}

html[data-theme="dark"] .comment-text {
  color: #d2ded6 !important;
}

html[data-theme="dark"] .comment-head time {
  color: #9fb2a6 !important;
}

html[data-theme="dark"] .comment-actions button,
html[data-theme="dark"] .comment-actions button span {
  color: #abbcb1 !important;
}

/* Dark cosmetic rendering: forum posts/details, chat, shop previews */

:is(html[data-theme="dark"], html.dark) .post-card.forum-bubble-mint,
:is(html[data-theme="dark"], html.dark) .detail-post.forum-bubble-mint {
  color: #eefbf3 !important;
  border-color: rgba(110, 231, 183, 0.27) !important;
  background: linear-gradient(145deg, #10251b, #143022) !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.07),
    0 12px 32px rgba(0, 0, 0, 0.22) !important;
}

:is(html[data-theme="dark"], html.dark) .post-card.forum-bubble-peach,
:is(html[data-theme="dark"], html.dark) .detail-post.forum-bubble-peach {
  color: #fff3ec !important;
  border-color: rgba(253, 186, 116, 0.27) !important;
  background: linear-gradient(145deg, #2a1915, #341f19) !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.07),
    0 12px 32px rgba(0, 0, 0, 0.22) !important;
}

:is(html[data-theme="dark"], html.dark) .post-card.forum-bubble-violet,
:is(html[data-theme="dark"], html.dark) .detail-post.forum-bubble-violet {
  color: #f7efff !important;
  border-color: rgba(196, 181, 253, 0.27) !important;
  background: linear-gradient(145deg, #21172d, #2a1d39) !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.07),
    0 12px 32px rgba(0, 0, 0, 0.22) !important;
}

:is(html[data-theme="dark"], html.dark) .post-card.forum-bubble-amber,
:is(html[data-theme="dark"], html.dark) .post-card.forum-bubble-ember,
:is(html[data-theme="dark"], html.dark) .detail-post.forum-bubble-amber,
:is(html[data-theme="dark"], html.dark) .detail-post.forum-bubble-ember {
  color: #fff3cf !important;
  border-color: rgba(251, 191, 36, 0.3) !important;
  background: linear-gradient(145deg, #211a10, #2b2113) !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.07),
    0 12px 32px rgba(0, 0, 0, 0.22) !important;
}

:is(html[data-theme="dark"], html.dark) .post-card.forum-bubble-frost,
:is(html[data-theme="dark"], html.dark) .detail-post.forum-bubble-frost {
  color: #e5f6ff !important;
  border-color: rgba(125, 211, 252, 0.28) !important;
  background: linear-gradient(145deg, #0f1c2e, #13263e) !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.07),
    0 12px 32px rgba(0, 0, 0, 0.24) !important;
}

:is(html[data-theme="dark"], html.dark) .post-card[class*="forum-bubble-"] h3,
:is(html[data-theme="dark"], html.dark) .detail-post[class*="forum-bubble-"] h1,
:is(html[data-theme="dark"], html.dark) .post-card[class*="forum-bubble-"] .post-author-line,
:is(html[data-theme="dark"], html.dark) .detail-post[class*="forum-bubble-"] .detail-author-copy strong {
  color: #f4faf6 !important;
}

:is(html[data-theme="dark"], html.dark) .post-card[class*="forum-bubble-"] .post-excerpt,
:is(html[data-theme="dark"], html.dark) .detail-post[class*="forum-bubble-"] .detail-body,
:is(html[data-theme="dark"], html.dark) .post-card[class*="forum-bubble-"] .post-author-copy > span,
:is(html[data-theme="dark"], html.dark) .detail-post[class*="forum-bubble-"] .detail-author-copy span,
:is(html[data-theme="dark"], html.dark) .post-card[class*="forum-bubble-"] .post-tags span {
  color: #cbd9d0 !important;
}

:is(html[data-theme="dark"], html.dark) .post-card[class*="forum-bubble-"] .detail-actions .action-button,
:is(html[data-theme="dark"], html.dark) .detail-post[class*="forum-bubble-"] .detail-actions .action-button,
:is(html[data-theme="dark"], html.dark) .post-card[class*="forum-bubble-"] .post-actions .action-button,
:is(html[data-theme="dark"], html.dark) .post-card[class*="forum-bubble-"] .post-actions .read-count {
  color: #d5e3da !important;
  border-color: rgba(229, 244, 235, 0.13) !important;
  background: rgba(255, 255, 255, 0.055) !important;
}

:is(html[data-theme="dark"], html.dark) .message-row .message-bubble.chat-cosmetic-mint,
:is(html[data-theme="dark"], html.dark) .shop-chat-preview.chat-cosmetic-mint,
:is(html[data-theme="dark"], html.dark) .my-cosmetic-swatch.chat-cosmetic-mint {
  color: #eafff2 !important;
  border-color: rgba(110, 231, 183, 0.3) !important;
  background: linear-gradient(135deg, #10251b, #143022) !important;
}

:is(html[data-theme="dark"], html.dark) .message-row .message-bubble.chat-cosmetic-peach,
:is(html[data-theme="dark"], html.dark) .shop-chat-preview.chat-cosmetic-peach,
:is(html[data-theme="dark"], html.dark) .my-cosmetic-swatch.chat-cosmetic-peach {
  color: #fff0e7 !important;
  border-color: rgba(253, 186, 116, 0.3) !important;
  background: linear-gradient(135deg, #2a1915, #34201b) !important;
}

:is(html[data-theme="dark"], html.dark) .message-row .message-bubble.chat-cosmetic-violet,
:is(html[data-theme="dark"], html.dark) .shop-chat-preview.chat-cosmetic-violet,
:is(html[data-theme="dark"], html.dark) .my-cosmetic-swatch.chat-cosmetic-violet {
  color: #f5edff !important;
  border-color: rgba(196, 181, 253, 0.3) !important;
  background: linear-gradient(135deg, #21172d, #2a1d39) !important;
}

:is(html[data-theme="dark"], html.dark) .message-row .message-bubble.chat-cosmetic-amber,
:is(html[data-theme="dark"], html.dark) .shop-chat-preview.chat-cosmetic-amber,
:is(html[data-theme="dark"], html.dark) .my-cosmetic-swatch.chat-cosmetic-amber {
  color: #fff1c6 !important;
  border-color: rgba(251, 191, 36, 0.32) !important;
  background: linear-gradient(135deg, #241b0f, #302313) !important;
}

:is(html[data-theme="dark"], html.dark) .message-row .message-bubble.chat-cosmetic-frost,
:is(html[data-theme="dark"], html.dark) .shop-chat-preview.chat-cosmetic-frost,
:is(html[data-theme="dark"], html.dark) .my-cosmetic-swatch.chat-cosmetic-frost {
  color: #e6f7ff !important;
  border-color: rgba(125, 211, 252, 0.3) !important;
  background: linear-gradient(135deg, #0f1c2e, #13263e) !important;
}

:is(html[data-theme="dark"], html.dark) .message-row .message-bubble.member-bubble-gold {
  color: #ffe9a8 !important;
  border-color: rgba(251, 191, 36, 0.28) !important;
  background: linear-gradient(135deg, #241b0f, #302313) !important;
}

:is(html[data-theme="dark"], html.dark) .message-row .message-bubble.member-bubble-platinum {
  color: #e5f6ff !important;
  border-color: rgba(125, 211, 252, 0.26) !important;
  background: linear-gradient(135deg, #101c29, #16283a) !important;
}

:is(html[data-theme="dark"], html.dark) .message-row .message-bubble.member-bubble-plus {
  color: #f2e9ff !important;
  border-color: rgba(196, 181, 253, 0.28) !important;
  background: linear-gradient(135deg, #20162c, #2b1d3a) !important;
}

:is(html[data-theme="dark"], html.dark) .shop-post-preview.forum-bubble-mint,
:is(html[data-theme="dark"], html.dark) .my-cosmetic-swatch.forum-bubble-mint {
  border-color: rgba(110, 231, 183, 0.27) !important;
  background: linear-gradient(145deg, #10251b, #143022) !important;
}

:is(html[data-theme="dark"], html.dark) .shop-post-preview.forum-bubble-peach,
:is(html[data-theme="dark"], html.dark) .my-cosmetic-swatch.forum-bubble-peach {
  border-color: rgba(253, 186, 116, 0.27) !important;
  background: linear-gradient(145deg, #2a1915, #341f19) !important;
}

:is(html[data-theme="dark"], html.dark) .shop-post-preview.forum-bubble-violet,
:is(html[data-theme="dark"], html.dark) .my-cosmetic-swatch.forum-bubble-violet {
  border-color: rgba(196, 181, 253, 0.27) !important;
  background: linear-gradient(145deg, #21172d, #2a1d39) !important;
}

:is(html[data-theme="dark"], html.dark) .shop-post-preview.forum-bubble-amber,
:is(html[data-theme="dark"], html.dark) .shop-post-preview.forum-bubble-ember,
:is(html[data-theme="dark"], html.dark) .my-cosmetic-swatch.forum-bubble-amber {
  border-color: rgba(251, 191, 36, 0.3) !important;
  background: linear-gradient(145deg, #211a10, #2b2113) !important;
}

:is(html[data-theme="dark"], html.dark) .shop-post-preview.forum-bubble-frost,
:is(html[data-theme="dark"], html.dark) .my-cosmetic-swatch.forum-bubble-frost {
  border-color: rgba(125, 211, 252, 0.28) !important;
  background: linear-gradient(145deg, #0f1c2e, #13263e) !important;
}

:is(html[data-theme="dark"], html.dark) .shop-post-preview[class*="forum-bubble-"] span {
  background: rgba(235, 247, 240, 0.24) !important;
}

:is(html[data-theme="dark"], html.dark) .post-actions .comments,
:is(html[data-theme="dark"], html.dark) .post-card.is-unanswered-post .post-actions .comments {
  color: #d5e3da !important;
  border: 1px solid rgba(229, 244, 235, 0.12);
  background: rgba(255, 255, 255, 0.065) !important;
}

:is(html[data-theme="dark"], html.dark) .my-cosmetics-modal .empty-state {
  color: #cbd8d0 !important;
  border-color: rgba(210, 232, 217, 0.14) !important;
  background: #141c18 !important;
}

:is(html[data-theme="dark"], html.dark) .my-cosmetics-modal .empty-state h3 {
  color: #f0f7f2 !important;
}

:is(html[data-theme="dark"], html.dark) .my-cosmetics-modal .empty-state p {
  color: #aebeb4 !important;
}

:is(html[data-theme="dark"], html.dark) .promotion-choice,
:is(html[data-theme="dark"], html.dark) .promotion-choice:has(input:checked) {
  color: #f5ecd2 !important;
  border-color: rgba(232, 193, 95, 0.27) !important;
  background:
    radial-gradient(circle at 92% 0%, rgba(187, 143, 43, 0.18), transparent 44%),
    linear-gradient(135deg, #201b10, #292113) !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.07),
    0 8px 22px rgba(0, 0, 0, 0.2) !important;
}

:is(html[data-theme="dark"], html.dark) .promotion-choice-icon {
  color: #f0cf76 !important;
  background: rgba(255, 255, 255, 0.075) !important;
}

:is(html[data-theme="dark"], html.dark) .promotion-choice-copy strong,
:is(html[data-theme="dark"], html.dark) .promotion-choice-copy strong b {
  color: #f0d88c !important;
}

:is(html[data-theme="dark"], html.dark) .promotion-choice-copy small {
  color: #c7b98f !important;
}

:is(html[data-theme="dark"], html.dark) .promotion-choice-price {
  color: #ffe8a3 !important;
  border: 1px solid rgba(232, 193, 95, 0.2);
  background: rgba(114, 87, 27, 0.45) !important;
}

:is(html[data-theme="dark"], html.dark) .report-modal textarea,
:is(html[data-theme="dark"], html.dark) .report-modal .input-wrap {
  color: #edf5ef !important;
  border-color: rgba(210, 232, 217, 0.16) !important;
  background: #121b16 !important;
}

:is(html[data-theme="dark"], html.dark) .report-modal textarea:focus {
  border-color: rgba(130, 207, 165, 0.45) !important;
  background: #152019 !important;
  box-shadow: 0 0 0 3px rgba(130, 207, 165, 0.1);
}

:is(html[data-theme="dark"], html.dark) .report-modal .modal-form-actions .secondary-button {
  color: #e7f0ea !important;
  border-color: rgba(210, 232, 217, 0.16) !important;
  background: #17221b !important;
}

@media (max-width: 768px) {
  .bounty-choice,
  .promotion-choice {
    align-items: flex-start;
  }

  .bounty-choice-copy strong b {
    display: block;
    margin: 2px 0 0;
  }

  .bounty-options {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .bounty-options > span,
  .bounty-options small {
    grid-column: 1 / -1;
  }

  .bounty-options label span {
    width: 100%;
    justify-content: center;
    padding: 0 6px;
  }

  .custom-title-product-wrap {
    padding: 13px 15px 0;
  }

  .custom-title-shop-card {
    grid-template-columns: auto minmax(0, 1fr);
    padding: 15px;
  }

  .custom-title-shop-card > button {
    grid-column: 1 / -1;
    min-height: 40px;
  }

  .points-ledger-modal,
  .my-cosmetics-modal {
    height: 88vh;
    max-height: 88vh;
  }

  .points-ledger-list,
  .my-cosmetics-list {
    max-height: calc(88vh - 120px);
    padding: 0 15px calc(18px + env(safe-area-inset-bottom));
  }

  .ledger-row {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 8px;
  }

  .ledger-balance {
    grid-column: 2 / -1;
    text-align: left;
  }

  .my-cosmetic-row {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .my-cosmetic-row > button {
    width: 100%;
    min-height: 40px;
  }

  .comment-actions {
    flex-wrap: wrap;
    row-gap: 7px;
  }

  .comment-actions button,
  .comment-tip-total {
    min-height: 32px;
    white-space: nowrap;
  }

  .tip-custom-form {
    grid-template-columns: 1fr;
  }

  .tip-custom-form .primary-button,
  .tip-custom-input {
    min-height: 44px;
  }
}

/* Mobile detail, modal scrolling and dark-profile hardening */

.detail-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.detail-topbar-title {
  min-width: 0;
  flex: 1;
  overflow: hidden;
}

.detail-topbar-title > span {
  display: block;
  overflow: hidden;
  color: #111827;
  font-family: var(--serif);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.detail-author {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.detail-author-copy {
  min-width: 0;
  flex: 1;
}

.detail-author-side {
  display: flex;
  align-items: center;
  flex: 0 0 auto;
  flex-wrap: nowrap;
  gap: 6px;
}

.detail-author-side .follow-button,
.detail-author-side .category-badge,
.detail-author-side .bounty-badge,
.detail-author-side .pinned-badge {
  align-self: center;
}

.detail-extra-badges {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.detail-actions .action-button,
.detail-actions .read-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  line-height: 1;
}

.detail-actions .read-count {
  white-space: nowrap;
}

.detail-scroll {
  overflow-y: auto;
  overscroll-behavior: contain;
  touch-action: pan-y;
  -webkit-overflow-scrolling: touch;
}

.detail-comment-bar {
  flex-shrink: 0;
}

.profile-tabs {
  color: var(--ui-text-muted);
  background: var(--ui-surface-soft);
}

.profile-tab {
  color: var(--ui-text-muted);
  background: transparent;
}

.profile-tab.active {
  color: var(--ui-text);
  background: var(--ui-surface);
}

.profile-post-row {
  color: var(--ui-text);
  background: var(--ui-surface-soft);
}

.profile-post-copy strong {
  color: var(--ui-text);
}

.profile-post-copy span,
.profile-post-stats {
  color: var(--ui-text-muted);
}

.detail-actions-modal {
  width: min(100%, 440px);
}

.detail-action-menu {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 0 18px 20px;
}

.detail-action-menu > button {
  display: flex;
  width: 100%;
  min-height: 56px;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border: 1px solid var(--ui-border);
  border-radius: 14px;
  color: var(--ui-text);
  background: var(--ui-surface-soft);
  text-align: left;
}

.detail-action-menu > button > .icon {
  width: 20px;
  height: 20px;
  flex: 0 0 20px;
}

.detail-action-menu > button > span {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 2px;
}

.detail-action-menu strong {
  color: inherit;
  font-size: 12px;
}

.detail-action-menu small {
  color: var(--ui-text-muted);
  font-size: 9px;
}

.social-relations-modal,
.notifications-modal,
.points-ledger-modal,
.my-cosmetics-modal,
.edit-profile-modal,
.friend-modal,
.new-message-modal,
.mailbox-modal {
  display: flex;
  max-height: min(82dvh, 760px);
  flex-direction: column;
  overflow: hidden;
}

.social-relations-modal > .modal-header,
.notifications-modal > .modal-header,
.points-ledger-modal > .modal-header,
.my-cosmetics-modal > .modal-header,
.edit-profile-modal > .modal-header,
.friend-modal > .modal-header,
.new-message-modal > .modal-header,
.mailbox-modal > .modal-header,
.social-relation-tabs,
.notification-head-actions {
  flex: 0 0 auto;
}

.social-relation-list,
.notifications-list,
.points-ledger-list,
.my-cosmetics-list {
  min-height: 0;
  max-height: none;
  flex: 1;
  overflow-y: auto;
  overscroll-behavior: contain;
  touch-action: pan-y;
  -webkit-overflow-scrolling: touch;
}

.edit-profile-modal > form {
  min-height: 0;
  flex: 1;
  overflow-y: auto;
  overscroll-behavior: contain;
  touch-action: pan-y;
  -webkit-overflow-scrolling: touch;
}

.new-message-modal .people-list,
.friend-modal .friend-requests-section {
  min-height: 0;
  max-height: none;
  flex: 1;
  overflow-y: auto;
  overscroll-behavior: contain;
  touch-action: pan-y;
  -webkit-overflow-scrolling: touch;
}

.mailbox-modal .mailbox-layout {
  min-height: 0;
  max-height: none;
  flex: 1;
  overflow-y: auto;
  overscroll-behavior: contain;
  touch-action: pan-y;
  -webkit-overflow-scrolling: touch;
}

html[data-theme="dark"] .detail-topbar-title > span {
  color: var(--ui-text);
}

html[data-theme="dark"] .detail-author-side .follow-button {
  color: #a8d6b9;
  border-color: rgba(168, 214, 185, 0.24);
  background: rgba(94, 158, 119, 0.12);
}

html[data-theme="dark"] .detail-author-side .follow-button.following {
  color: var(--ui-text-soft);
  border-color: var(--ui-border);
  background: rgba(255, 255, 255, 0.06);
}

html[data-theme="dark"] .detail-actions .action-button,
html[data-theme="dark"] .detail-actions .action-button span,
html[data-theme="dark"] .detail-actions .action-button .icon {
  color: #d6e5dc !important;
}

html[data-theme="dark"] .detail-actions .action-button {
  border-color: rgba(220, 238, 225, 0.14) !important;
  background: rgba(255, 255, 255, 0.055) !important;
}

html[data-theme="dark"] .detail-actions .action-button.liked {
  color: #f2a0a9 !important;
}

html[data-theme="dark"] .detail-actions .action-button.disliked,
html[data-theme="dark"] .detail-actions .action-button.favorited {
  color: #ecd17f !important;
}

html[data-theme="dark"] .profile-tabs {
  border-color: var(--ui-border);
  background: #111a15;
}

html[data-theme="dark"] .profile-tab {
  color: var(--ui-text-muted) !important;
  background: transparent;
}

html[data-theme="dark"] .profile-tab.active {
  color: var(--ui-text) !important;
  background: rgba(112, 184, 142, 0.16);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

html[data-theme="dark"] .profile-post-row {
  color: var(--ui-text);
  border: 1px solid var(--ui-border);
  background: var(--ui-surface-soft);
}

html[data-theme="dark"] .profile-post-row:hover {
  background: rgba(112, 184, 142, 0.11);
}

html[data-theme="dark"] .profile-post-copy strong {
  color: var(--ui-text);
}

html[data-theme="dark"] .profile-post-copy span,
html[data-theme="dark"] .profile-post-stats {
  color: var(--ui-text-muted);
}

@media (max-width: 768px) {
  #post-modal {
    align-items: flex-end;
    padding-top: env(safe-area-inset-top);
  }

  #post-modal .detail-modal,
  .detail-modal {
    display: flex;
    height: 92vh;
    height: 92dvh;
    max-height: 92vh;
    max-height: 92dvh;
    flex-direction: column;
    overflow: hidden;
  }

  .detail-topbar {
    height: calc(56px + env(safe-area-inset-top));
    min-height: calc(56px + env(safe-area-inset-top));
    flex: 0 0 auto;
    padding: env(safe-area-inset-top) 10px 0;
  }

  .detail-topbar-title {
    min-width: 0;
    flex: 1;
  }

  .detail-topbar-title > span {
    color: #111827;
    font-size: 15px;
    text-align: center;
  }

  .detail-scroll {
    flex: 1;
    min-height: 0;
    max-height: none;
    overflow-y: auto;
    overscroll-behavior: contain;
    touch-action: pan-y;
    -webkit-overflow-scrolling: touch;
  }

  .detail-author {
    align-items: center;
    flex-wrap: nowrap;
    justify-content: space-between;
    gap: 8px;
  }

  .detail-author-copy {
    min-width: 0;
    flex: 1 1 auto;
  }

  .detail-author-side {
    display: flex;
    align-items: center;
    flex: 0 0 auto;
    flex-wrap: nowrap;
    gap: 6px;
  }

  .detail-actions .read-count {
    display: inline-flex;
    min-height: 34px;
    align-items: center;
    gap: 5px;
    margin-left: auto;
    line-height: 1;
  }

  .detail-reply-context {
    flex: 0 0 auto;
  }

  .detail-comment-bar {
    position: relative;
    bottom: auto;
    flex: 0 0 auto;
    flex-shrink: 0;
    padding: 8px 12px max(12px, env(safe-area-inset-bottom));
    background: var(--ui-surface);
  }

  .social-relations-modal,
  .notifications-modal,
  .points-ledger-modal,
  .my-cosmetics-modal,
  .edit-profile-modal,
  .friend-modal,
  .new-message-modal,
  .mailbox-modal {
    height: auto;
    max-height: 82vh;
    max-height: 82dvh;
  }

  .social-relation-list,
  .notifications-list,
  .points-ledger-list,
  .my-cosmetics-list {
    padding-bottom: max(16px, env(safe-area-inset-bottom));
  }

  .edit-profile-modal > form {
    padding-bottom: max(18px, env(safe-area-inset-bottom));
  }

  .detail-action-menu {
    padding-bottom: max(20px, env(safe-area-inset-bottom));
  }

  html[data-theme="dark"] .detail-topbar-title > span {
    color: var(--ui-text);
  }

  html[data-theme="dark"] .detail-comment-bar {
    background: rgba(25, 36, 29, 0.98);
  }
}

@media (max-width: 480px) {
  .admin-summary {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .admin-summary div:nth-child(4) {
    border-left: 0;
    border-top: 1px solid var(--line);
  }

  .admin-summary div:nth-child(5) {
    border-top: 1px solid var(--line);
  }

  .admin-promoter-editor .form-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .admin-user-edit-modal {
    max-height: 92vh;
    max-height: 92dvh;
  }

  .admin-user-edit-modal .modal-form-actions {
    margin-right: -17px;
    margin-bottom: -22px;
    margin-left: -17px;
    padding-right: 17px;
    padding-left: 17px;
  }

  .admin-edit-save-note {
    display: none;
  }

  .admin-edit-section {
    padding: 10px;
  }
}

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