/* ==========================================================================
   岐黄养生 · 组件层
   按钮 / 表单 / 卡片 / 标签 / 列表 / 图表容器 / 空状态
   ========================================================================== */

/* --------------------------------------------------------------------------
   按钮
   -------------------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 40px;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: var(--radius-full);
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  transition: background .18s ease, color .18s ease, border-color .18s ease,
              transform .18s ease, box-shadow .18s ease;
}

.btn .icon {
  width: 16px;
  height: 16px;
}

.btn--primary {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 4px 12px rgba(74, 124, 89, .22);
}

.btn--primary:hover {
  background: var(--primary-600);
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(74, 124, 89, .28);
}

.btn--ghost {
  background: var(--surface);
  border-color: var(--border);
  color: var(--text);
}

.btn--ghost:hover {
  background: var(--primary-50);
  border-color: var(--primary);
  color: var(--primary-700);
}

.btn--soft {
  background: var(--primary-50);
  color: var(--primary-700);
}

.btn--soft:hover {
  background: var(--primary-100);
}

.btn--sm {
  height: 34px;
  padding: 0 14px;
  font-size: 13px;
}

.btn--lg {
  height: 46px;
  padding: 0 24px;
  font-size: 15px;
}

.btn--block {
  width: 100%;
}

.btn:disabled {
  opacity: .55;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.icon-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: var(--surface);
  color: var(--text-2);
  transition: background .18s ease, color .18s ease, border-color .18s ease;
}

.icon-btn:hover {
  background: var(--primary-50);
  border-color: var(--primary);
  color: var(--primary-700);
}

.icon-btn .icon {
  width: 18px;
  height: 18px;
}

.icon-btn .dot {
  position: absolute;
  top: 8px;
  right: 9px;
  width: 7px;
  height: 7px;
  border: 2px solid var(--bg);
  border-radius: 50%;
  background: var(--accent);
}

/* --------------------------------------------------------------------------
   搜索框
   -------------------------------------------------------------------------- */
.searchbox {
  position: relative;
  display: flex;
  align-items: center;
}

.searchbox input {
  width: 100%;
  height: 54px;
  padding: 0 138px 0 48px;
  border: 1px solid var(--border);
  border-radius: var(--radius-full);
  background: var(--surface);
  font-size: 15px;
  box-shadow: var(--shadow-sm);
  transition: border-color .15s ease, box-shadow .15s ease;
}

.searchbox input::placeholder {
  color: var(--text-3);
}

.searchbox input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(74, 124, 89, .12);
}

.searchbox__icon {
  position: absolute;
  left: 18px;
  display: flex;
  color: var(--text-3);
  pointer-events: none;
}

.searchbox__icon .icon {
  width: 19px;
  height: 19px;
}

.searchbox .btn {
  position: absolute;
  right: 6px;
}

/* --------------------------------------------------------------------------
   卡片 / 网格
   -------------------------------------------------------------------------- */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xs);
}

.card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 22px;
  border-bottom: 1px solid var(--border);
}

.card__head h3 {
  font-size: 15px;
}

.card__body {
  padding: 20px 22px;
}

.grid {
  display: grid;
  gap: 16px;
}

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

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

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

.section {
  margin-top: 40px;
}

.home-split {
  display: grid;
  grid-template-columns: minmax(0, 1.65fr) minmax(260px, .85fr);
  align-items: start;
  gap: 24px;
}

.section__head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.section__head h2 {
  font-size: 20px;
  letter-spacing: -.01em;
}

.section__head p {
  margin-top: 4px;
  font-size: 13px;
  color: var(--text-3);
}

.link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  flex: none;
  font-size: 13px;
  font-weight: 600;
  color: var(--primary-600);
  white-space: nowrap;
  transition: color .15s ease;
}

.link:hover {
  color: var(--primary-700);
}

/* --------------------------------------------------------------------------
   首页 Hero
   -------------------------------------------------------------------------- */
.hero {
  position: relative;
  overflow: hidden;
  padding: 44px 44px 38px;
  border: 1px solid #E4EBE0;
  border-radius: var(--radius-xl);
  background: linear-gradient(125deg, #EEF5EF 0%, #F6F4EA 52%, #FAEFE4 100%);
}

.hero::before {
  content: "";
  position: absolute;
  top: -180px;
  right: -120px;
  width: 420px;
  height: 420px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(74, 124, 89, .12), transparent 65%);
}

.hero::after {
  content: "";
  position: absolute;
  right: 80px;
  bottom: -220px;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(232, 168, 124, .18), transparent 65%);
}

.hero__inner {
  position: relative;
  z-index: 1;
  max-width: 760px;
}

.hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border: 1px solid rgba(74, 124, 89, .16);
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, .7);
  color: var(--primary-700);
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: .1em;
}

.hero h1 {
  margin-top: 16px;
  font-family: var(--font-serif);
  font-size: 40px;
  font-weight: 700;
  line-height: 1.28;
  letter-spacing: .02em;
}

.hero h1 em {
  font-style: normal;
  color: var(--primary);
}

.hero__sub {
  margin-top: 12px;
  font-size: 15px;
  color: var(--text-2);
}

.hero .searchbox {
  max-width: 620px;
  margin-top: 26px;
}

.hero__tags {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 14px;
  font-size: 12.5px;
  color: var(--text-3);
}

.hero__tags a {
  padding: 4px 10px;
  border: 1px solid rgba(74, 124, 89, .14);
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, .66);
  color: var(--text-2);
  transition: color .15s ease, border-color .15s ease;
}

.hero__tags a:hover {
  border-color: rgba(74, 124, 89, .35);
  color: var(--primary-700);
}

/* --------------------------------------------------------------------------
   模块入口卡
   -------------------------------------------------------------------------- */
.topic-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.topic-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 22px 20px 18px;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-xs);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

.topic-card:hover {
  transform: translateY(-4px);
  border-color: var(--primary-100);
  box-shadow: var(--shadow);
}

.topic-card__icon {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 14px;
}

.topic-card__icon .icon {
  width: 22px;
  height: 22px;
}

.topic-card h3 {
  font-size: 16px;
}

.topic-card p {
  font-size: 12.5px;
  line-height: 1.65;
  color: var(--text-3);
}

.topic-card__meta {
  margin-top: auto;
  font-size: 12px;
  font-weight: 600;
  color: var(--primary-600);
}

.tint-green {
  background: var(--primary-50);
  color: var(--primary);
}

.tint-amber {
  background: var(--accent-50);
  color: var(--accent-600);
}

.tint-sage {
  background: #EDF3E9;
  color: #6B8E4E;
}

.tint-clay {
  background: #F4EEE8;
  color: #9A7355;
}

.tint-blue {
  background: #EDF1F6;
  color: #5B7794;
}

.tint-rose {
  background: #F8EEEE;
  color: #B06A63;
}

/* --------------------------------------------------------------------------
   个性养生入口卡
   -------------------------------------------------------------------------- */
.wellness-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.wellness-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 24px;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface);
  transition: transform .2s ease, box-shadow .2s ease;
}

.wellness-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

.wellness-card__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.wellness-card h3 {
  margin-top: 4px;
  font-size: 16px;
}

.wellness-card p {
  font-size: 12.5px;
  line-height: 1.65;
  color: var(--text-3);
}

/* --------------------------------------------------------------------------
   百科条目卡 / 图片占位
   -------------------------------------------------------------------------- */
.item-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-xs);
  transition: transform .2s ease, box-shadow .2s ease;
}

.item-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

.item-card__body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 8px;
  padding: 16px 18px 18px;
}

.item-card h3 {
  font-size: 15.5px;
}

.item-card__sub {
  font-size: 12px;
  color: var(--text-3);
}

.item-card__desc {
  display: -webkit-box;
  overflow: hidden;
  font-size: 12.5px;
  line-height: 1.65;
  color: var(--text-2);
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.item-card__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.abbr {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 24px;
  padding: 0 9px;
  border-radius: var(--radius-xs);
  background: var(--primary-700);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .06em;
}

.meta-row {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-top: auto;
  padding-top: 10px;
  border-top: 1px dashed var(--border);
  font-size: 11.5px;
  color: var(--text-3);
}

/* ---- 图片占位(后续可替换为实拍图/SVG 插画) ---- */
.thumb {
  position: relative;
  display: grid;
  place-items: center;
  aspect-ratio: 16 / 9;
  overflow: hidden;
}

.thumb .icon {
  width: 38%;
  height: 38%;
  opacity: .5;
}

.thumb::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 82% 8%, rgba(255, 255, 255, .65), transparent 58%);
}

.thumb--herb {
  background: linear-gradient(140deg, #E8F1E9, #CFE0D2);
  color: #4A7C59;
}

.thumb--diet {
  background: linear-gradient(140deg, #FBF0E7, #F3DDC9);
  color: #B5651D;
}

.thumb--physician {
  background: linear-gradient(140deg, #EEF0F2, #DCE2E6);
  color: #5C6B73;
}

/* --------------------------------------------------------------------------
   标签 / 徽章 / 筛选
   -------------------------------------------------------------------------- */
.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.tag {
  display: inline-flex;
  align-items: center;
  height: 22px;
  padding: 0 9px;
  border-radius: var(--radius-full);
  background: var(--surface-2);
  color: var(--text-2);
  font-size: 11.5px;
}

.tag--green {
  background: var(--primary-50);
  color: var(--primary-700);
}

.tag--amber {
  background: var(--accent-50);
  color: #9A6234;
}

.badge {
  display: inline-flex;
  align-items: center;
  height: 20px;
  padding: 0 8px;
  border-radius: var(--radius-full);
  font-size: 11px;
  font-weight: 600;
}

.badge--green {
  background: var(--primary-50);
  color: var(--primary-700);
}

.badge--amber {
  background: var(--accent-50);
  color: #A76A3C;
}

.badge--gray {
  background: var(--surface-2);
  color: var(--text-2);
}

.badge--clay {
  background: #F4EEE8;
  color: #8A6A4F;
}

.badge--blue {
  background: #EDF1F6;
  color: #4F6580;
}

/* ---- 筛选工具条 ---- */
.toolbar {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 20px;
  padding: 16px 18px;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface);
}

.filter-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.filter-row__label {
  flex: none;
  width: 76px;
  padding-top: 6px;
  font-size: 12.5px;
  color: var(--text-3);
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chip {
  padding: 6px 13px;
  border: 1px solid var(--border);
  border-radius: var(--radius-full);
  background: var(--surface);
  color: var(--text-2);
  font-size: 12.5px;
  transition: background .15s ease, color .15s ease, border-color .15s ease;
}

.chip:hover {
  border-color: var(--primary);
  color: var(--primary-700);
}

.chip.is-active {
  border-color: var(--primary);
  background: var(--primary);
  color: #fff;
}

/* ---- 字母索引 ---- */
.az-index {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 20px;
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface);
}

.az-index button {
  width: 30px;
  height: 30px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: transparent;
  color: var(--text-3);
  font-size: 12.5px;
  font-weight: 600;
  transition: background .15s ease, color .15s ease;
}

.az-index button.has {
  background: var(--primary-50);
  color: var(--primary-700);
}

.az-index button.has:hover {
  background: var(--primary-100);
}

.az-index button.is-active {
  background: var(--primary);
  color: #fff;
}

.az-index button:disabled {
  opacity: .32;
  cursor: default;
}

/* --------------------------------------------------------------------------
   帖子列表
   -------------------------------------------------------------------------- */
.post {
  display: flex;
  gap: 12px;
  padding: 16px 2px;
  border-bottom: 1px solid var(--border);
}

.post:last-child {
  border-bottom: 0;
}

.post__avatar {
  display: grid;
  place-items: center;
  flex: none;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  color: #fff;
  font-size: 14px;
  font-weight: 700;
}

.post__body {
  min-width: 0;
}

.post__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--text-3);
}

.post__title {
  margin: 4px 0 3px;
  font-size: 14.5px;
  font-weight: 600;
  line-height: 1.5;
}

.post__title a:hover {
  color: var(--primary-700);
}

.post__excerpt {
  display: -webkit-box;
  overflow: hidden;
  font-size: 12.5px;
  color: var(--text-3);
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 1;
}

/* --------------------------------------------------------------------------
   今日幸福事 / 引用卡
   -------------------------------------------------------------------------- */
.quote-panel {
  position: relative;
  overflow: hidden;
  padding: 26px;
  border-radius: var(--radius-lg);
  background: linear-gradient(150deg, #3D694A, #2C5036);
  color: #fff;
  box-shadow: var(--shadow);
}

.quote-panel::after {
  content: "\201C";
  position: absolute;
  top: -6px;
  right: 16px;
  font-family: var(--font-serif);
  font-size: 120px;
  line-height: 1;
  opacity: .12;
}

.quote-panel__label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  letter-spacing: .18em;
  opacity: .75;
}

.quote-panel blockquote {
  margin: 14px 0 18px;
  font-family: var(--font-serif);
  font-size: 17px;
  line-height: 1.85;
}

.quote-panel .btn {
  border-color: rgba(255, 255, 255, .25);
  background: rgba(255, 255, 255, .14);
  color: #fff;
}

.quote-panel .btn:hover {
  background: rgba(255, 255, 255, .22);
  color: #fff;
}

/* --------------------------------------------------------------------------
   统计 / 表格 / 进度
   -------------------------------------------------------------------------- */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.stat {
  padding: 18px 20px;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface);
}

.stat__label {
  font-size: 12px;
  color: var(--text-3);
}

.stat__value {
  margin-top: 6px;
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -.02em;
}

.stat__value small {
  margin-left: 2px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-3);
}

.stat__trend {
  margin-top: 2px;
  font-size: 12px;
  color: var(--primary-600);
}

.table {
  width: 100%;
  font-size: 13px;
}

.table th {
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
  color: var(--text-3);
  font-size: 12px;
  font-weight: 600;
  text-align: left;
}

.table td {
  padding: 12px;
  border-bottom: 1px solid var(--border);
}

.table tr:last-child td {
  border-bottom: 0;
}

.progress {
  height: 8px;
  overflow: hidden;
  border-radius: var(--radius-full);
  background: var(--surface-3);
}

.progress__bar {
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #5B9270, #4A7C59);
  transition: width .3s ease;
}

/* --------------------------------------------------------------------------
   Tabs
   -------------------------------------------------------------------------- */
.tabs {
  display: flex;
  gap: 4px;
  overflow-x: auto;
  border-bottom: 1px solid var(--border);
}

.tab {
  position: relative;
  padding: 12px 16px;
  border: 0;
  background: none;
  color: var(--text-2);
  font-size: 13.5px;
  font-weight: 500;
  white-space: nowrap;
}

.tab::after {
  content: "";
  position: absolute;
  right: 16px;
  bottom: -1px;
  left: 16px;
  height: 2px;
  border-radius: 2px;
  background: transparent;
}

.tab.is-active {
  color: var(--primary-700);
  font-weight: 600;
}

.tab.is-active::after {
  background: var(--primary);
}

/* --------------------------------------------------------------------------
   表单
   -------------------------------------------------------------------------- */
.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.field > label {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-2);
}

.input,
.select,
.textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  font-size: 13.5px;
  transition: border-color .15s ease, box-shadow .15s ease;
}

.input:focus,
.select:focus,
.textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(74, 124, 89, .12);
}

.textarea {
  min-height: 110px;
  line-height: 1.7;
  resize: vertical;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

/* ---- 选项(问卷) ---- */
.options {
  display: grid;
  gap: 10px;
}

.option {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  cursor: pointer;
  transition: border-color .15s ease, background .15s ease;
}

.option:hover {
  border-color: var(--primary);
  background: var(--primary-50);
}

.option input {
  accent-color: var(--primary);
}

.option.is-selected {
  border-color: var(--primary);
  background: var(--primary-50);
}

/* ---- 开关 ---- */
.switch {
  position: relative;
  display: inline-flex;
  width: 42px;
  height: 24px;
  flex: none;
}

.switch input {
  width: 0;
  height: 0;
  opacity: 0;
}

.switch span {
  position: absolute;
  inset: 0;
  border-radius: 999px;
  background: var(--surface-3);
  transition: background .2s ease;
}

.switch span::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #fff;
  box-shadow: var(--shadow-xs);
  transition: transform .2s ease;
}

.switch input:checked + span {
  background: var(--primary);
}

.switch input:checked + span::after {
  transform: translateX(18px);
}

/* --------------------------------------------------------------------------
   列表 / 空状态 / 提示
   -------------------------------------------------------------------------- */
.list-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px 0;
  border-bottom: 1px solid var(--border);
}

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

.list-item__main {
  min-width: 0;
  flex: 1;
}

.list-item__title {
  font-size: 13.5px;
  font-weight: 600;
}

.list-item__sub {
  margin-top: 2px;
  font-size: 12px;
  color: var(--text-3);
}

.empty {
  padding: 48px 20px;
  color: var(--text-3);
  font-size: 13px;
  text-align: center;
}

.empty .icon {
  width: 34px;
  height: 34px;
  margin: 0 auto 10px;
  opacity: .45;
}

.notice {
  display: flex;
  gap: 10px;
  padding: 12px 14px;
  border: 1px solid #EBDCC9;
  border-radius: var(--radius);
  background: #FBF6EE;
  color: #7A6748;
  font-size: 12.5px;
  line-height: 1.7;
}

.notice .icon {
  flex: none;
  margin-top: 2px;
}

/* --------------------------------------------------------------------------
   测评 / 结果
   -------------------------------------------------------------------------- */
.assessment-intro__body {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  padding: 32px;
}

.assessment-intro h2 {
  font-size: 24px;
}

.assessment-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  margin: 16px 0 22px;
  font-size: 12.5px;
  color: var(--text-3);
}

.assessment-meta span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.assessment-art {
  display: grid;
  place-items: center;
  flex: none;
  width: 168px;
  height: 168px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #EAF2EC, #D8E8DD);
  color: var(--primary);
}

.assessment-art .icon {
  width: 66px;
  height: 66px;
  opacity: .8;
}

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

.quiz-progress {
  margin: 14px 0 24px;
}

.quiz-question {
  font-size: 20px;
  line-height: 1.6;
}

.quiz-actions {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 24px;
}

.score-list {
  display: grid;
  gap: 12px;
  margin: 22px 0 6px;
}

.score-row {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr) 46px;
  align-items: center;
  gap: 12px;
  font-size: 13px;
}

.score-row .progress {
  display: block;
}

.score-row__name {
  color: var(--text-2);
}

.score-row__value {
  color: var(--text-3);
  font-size: 12px;
  text-align: right;
}

.advice-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 22px;
}

.advice {
  padding: 16px;
  border-radius: var(--radius);
  background: var(--surface-2);
}

.advice h4 {
  margin-bottom: 6px;
  color: var(--primary-700);
  font-size: 13px;
}

.advice p {
  font-size: 12.5px;
  line-height: 1.7;
  color: var(--text-2);
}

.item-card__desc--3 {
  -webkit-line-clamp: 3;
}

/* --------------------------------------------------------------------------
   图表
   -------------------------------------------------------------------------- */
.chart svg {
  width: 100%;
  height: auto;
}

/* --------------------------------------------------------------------------
   今日幸福事
   -------------------------------------------------------------------------- */
.today-card {
  position: relative;
  overflow: hidden;
  padding: 38px 40px;
  border-radius: var(--radius-xl);
  background: linear-gradient(140deg, #3D694A 0%, #2C5036 60%, #24432D 100%);
  color: #fff;
  box-shadow: var(--shadow);
}

.today-card::after {
  content: "\201C";
  position: absolute;
  top: -30px;
  right: 28px;
  font-family: var(--font-serif);
  font-size: 190px;
  line-height: 1;
  opacity: .1;
}

.today-card__label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 11.5px;
  letter-spacing: .2em;
  opacity: .78;
}

.today-card__label .icon {
  width: 16px;
  height: 16px;
}

.today-card__quote {
  position: relative;
  z-index: 1;
  max-width: 44ch;
  margin: 18px 0 26px;
  font-family: var(--font-serif);
  font-size: 24px;
  line-height: 1.75;
}

.today-card__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.today-card .btn {
  border-color: rgba(255, 255, 255, .25);
  background: rgba(255, 255, 255, .14);
  color: #fff;
}

.today-card .btn:hover {
  background: rgba(255, 255, 255, .22);
  color: #fff;
}

.happiness-form {
  display: flex;
  gap: 10px;
}

.happiness-form .input {
  flex: 1;
}

.calendar {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 8px;
}

.calendar__day {
  display: grid;
  place-items: center;
  aspect-ratio: 1;
  border-radius: 10px;
  background: var(--surface-2);
  color: var(--text-3);
  font-size: 12px;
}

.calendar__day .icon {
  width: 15px;
  height: 15px;
}

.calendar__day.is-done {
  background: var(--primary-50);
  color: var(--primary-700);
  font-weight: 600;
}

.calendar__day.is-today {
  outline: 2px solid var(--primary);
  outline-offset: 1px;
}

.quote-feed {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.quote-chip {
  display: flex;
  gap: 12px;
  padding: 16px 18px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}

.quote-chip__index {
  flex: none;
  color: var(--primary);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .08em;
  padding-top: 3px;
}

.quote-chip p {
  font-size: 13px;
  line-height: 1.7;
  color: var(--text-2);
}

/* --------------------------------------------------------------------------
   社区
   -------------------------------------------------------------------------- */
.community-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(260px, .8fr);
  align-items: start;
  gap: 20px;
}

.community-side {
  display: grid;
  gap: 16px;
}

.composer {
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface);
}

.composer__head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
  font-size: 14px;
  font-weight: 600;
}

.composer .field {
  margin-bottom: 10px;
}

.composer__row {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 14px;
  margin-top: 10px;
}

.composer__row .hint {
  margin-right: auto;
}

/* --------------------------------------------------------------------------
   个人中心
   -------------------------------------------------------------------------- */
.profile-hero {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 26px 28px;
}

.profile-avatar {
  display: grid;
  place-items: center;
  flex: none;
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: linear-gradient(135deg, #E8A87C, #D08B5B);
  color: #fff;
  font-size: 26px;
  font-weight: 700;
}

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

.profile-main h2 {
  font-size: 20px;
}

.tab-panel {
  padding-top: 4px;
}

.switch-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
}

.switch-row:last-child {
  border-bottom: 0;
}

.switch-row__title {
  font-size: 13.5px;
  font-weight: 600;
}

.switch-row__desc {
  margin-top: 2px;
  font-size: 12px;
  color: var(--text-3);
}

.form-message {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--primary-700);
}

/* --------------------------------------------------------------------------
   响应式
   -------------------------------------------------------------------------- */
@media (max-width: 1120px) {
  .topic-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

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

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

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

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

  .community-layout,
  .home-split {
    grid-template-columns: 1fr;
  }

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

  .quote-feed {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 680px) {
  .grid--4,
  .grid--3,
  .grid--2 {
    grid-template-columns: 1fr;
  }

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

  .hero {
    padding: 30px 22px;
  }

  .hero h1 {
    font-size: 30px;
  }

  .searchbox input {
    padding-right: 96px;
    font-size: 14px;
  }

  .filter-row {
    flex-direction: column;
    gap: 6px;
  }

  .filter-row__label {
    width: auto;
    padding-top: 0;
  }

  .assessment-intro__body {
    flex-direction: column;
    align-items: flex-start;
    padding: 22px;
  }

  .assessment-art {
    width: 120px;
    height: 120px;
  }

  .today-card {
    padding: 26px 22px;
  }

  .today-card__quote {
    font-size: 19px;
  }

  .profile-hero {
    flex-wrap: wrap;
  }

  .happiness-form {
    flex-direction: column;
  }
}
