/* 个人中心子页面 - 符合静照自明主题色 */

.profile-sub-page {
  min-height: 0;
  background:
    linear-gradient(135deg, rgba(var(--accent-rgb), 0.08), transparent 36%),
    linear-gradient(315deg, rgba(var(--accent-rgb), 0.06), transparent 34%),
    var(--bg, #f4f3ee);
  padding-bottom: 40px;
}


/* 顶部导航 */
.profile-sub-topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: 40px 1fr 40px;
  align-items: center;
  padding: 14px 16px;
  background: rgba(255, 253, 247, 0.92);
  border-bottom: 1px solid var(--line, #ddd6c7);
  backdrop-filter: saturate(180%) blur(12px);
}


.profile-sub-back {
  width: 34px;
  height: 34px;
  padding: 0;
  border: 1px solid var(--line, #ddd6c7);
  border-radius: 50%;
  background: transparent;
  color: var(--ink, #202321);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.15s ease;
}

.profile-sub-back:hover {
  background: rgba(0, 0, 0, 0.04);
}


.profile-sub-back svg {
  width: 18px;
  height: 18px;
}

.profile-sub-title {
  text-align: center;
  font-size: 17px;
  font-weight: 600;
  color: var(--ink, #202321);
  letter-spacing: 0.5px;
}


.profile-sub-topbar-spacer {
  width: 40px;
}

/* 主体 */
.profile-sub-body {
  padding: 16px;
}

/* 通用卡片 - 暖白底 */
.profile-card {
  background: var(--app-panel-surface, #faf7ee);
  border-radius: var(--card-radius);
  padding: 20px;
  margin-bottom: 16px;
  border: var(--card-border);
  box-shadow: var(--card-shadow);
}


/* 签到中心 - 每日签到头部 */
.checkin-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 20px;
}

.checkin-header-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: rgba(var(--accent-rgb), 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}


.checkin-header-icon svg {
  width: 24px;
  height: 24px;
  color: var(--cinnabar, #b94132);
}

.checkin-header-text h2 {
  font-size: 20px;
  font-weight: 600;
  color: var(--ink, #202321);
  margin: 0 0 4px;
}


.checkin-header-text p {
  font-size: 13px;
  color: var(--muted, #68706a);
  margin: 0;
}

/* 积分双卡片 */
.checkin-points-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 20px;
}

.checkin-point-card {
  background: var(--surface-strong, #ece8dc);
  border-radius: 12px;
  padding: 16px;
}


.checkin-point-card-label {
  font-size: 13px;
  color: var(--muted, #68706a);
  margin-bottom: 6px;
}

.checkin-point-card-value {
  font-size: 28px;
  font-weight: 700;
  color: var(--ink, #202321);
}


/* 签到按钮 - 主题色 */
.checkin-button {
  width: 100%;
  padding: 16px;
  border-radius: var(--radius-md);
  border: 0;
  background: var(--cinnabar, #b94132);
  color: #fff;
  font-size: 17px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s ease;
}

.checkin-button:hover:not(:disabled) {
  background: var(--accent-dark, #8b352c);
}

.checkin-button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

/* 统计双卡片 */
.checkin-stats-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 16px;
}

.checkin-stat-card {
  background: rgba(255, 253, 247, 0.96);
  border-radius: 14px;
  padding: 18px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  border: 0.5px solid var(--line, #ddd6c7);
  box-shadow: 0 1px 3px rgba(33, 36, 31, 0.04);
}


.checkin-stat-icon {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: rgba(var(--accent-rgb), 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}


.checkin-stat-icon svg {
  width: 20px;
  height: 20px;
  color: var(--cinnabar, #b94132);
}

.checkin-stat-text-label {
  font-size: 13px;
  color: var(--muted, #68706a);
  margin-bottom: 2px;
}

.checkin-stat-text-value {
  font-size: 20px;
  font-weight: 700;
  color: var(--ink, #202321);
}


/* 区块标题行 */
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.section-header h3 {
  font-size: 16px;
  font-weight: 600;
  color: var(--ink, #202321);
  margin: 0;
}


.section-header a {
  font-size: 14px;
  color: var(--cinnabar, #b94132);
  text-decoration: none;
  cursor: pointer;
}

.section-header a:hover {
  text-decoration: underline;
}


.section-desc {
  font-size: 13px;
  color: var(--muted, #68706a);
  margin: 0 0 12px;
}

/* 空提示块 */
.empty-tip {
  background: var(--surface-strong, #ece8dc);
  border-radius: 12px;
  padding: 14px 16px;
  font-size: 13px;
  color: var(--muted, #68706a);
  display: flex;
  align-items: center;
  gap: 8px;
}


.empty-tip svg {
  width: 18px;
  height: 18px;
  color: var(--cinnabar, #b94132);
  flex-shrink: 0;
}

/* 签到记录列表 */
.record-item {
  background: rgba(255, 253, 247, 0.96);
  border-radius: 14px;
  padding: 18px 16px;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 14px;
  border: 0.5px solid var(--line, #ddd6c7);
  box-shadow: 0 1px 3px rgba(33, 36, 31, 0.04);
}


.record-item-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: rgba(var(--accent-rgb), 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}


.record-item-icon svg {
  width: 22px;
  height: 22px;
  color: var(--cinnabar, #b94132);
}

.record-item-body {
  flex: 1;
  min-width: 0;
}

.record-item-date {
  font-size: 16px;
  font-weight: 600;
  color: var(--ink, #202321);
  margin-bottom: 2px;
}


.record-item-desc {
  font-size: 13px;
  color: var(--muted, #68706a);
}

.record-item-points {
  font-size: 20px;
  font-weight: 700;
  color: var(--cinnabar, #b94132);
  flex-shrink: 0;
}

.record-item-view-btn {
  background: transparent;
  border: 1px solid var(--cinnabar, #b94132);
  color: var(--cinnabar, #b94132);
  border-radius: 6px;
  padding: 4px 14px;
  font-size: 13px;
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.15s, color 0.15s;
}

.record-item-view-btn:hover {
  background: var(--cinnabar, #b94132);
  color: #fffdf7;
}


/* 兑换页头部 */
.exchange-header-card {
  background: rgba(255, 253, 247, 0.96);
  border-radius: 14px;
  padding: 20px;
  margin-bottom: 16px;
  border: 0.5px solid var(--line, #ddd6c7);
  box-shadow: 0 1px 3px rgba(33, 36, 31, 0.04);
}


.exchange-header-card h3 {
  font-size: 18px;
  font-weight: 600;
  color: var(--ink, #202321);
  margin: 0 0 6px;
}


.exchange-header-card p {
  font-size: 13px;
  color: var(--muted, #68706a);
  margin: 0 0 14px;
}

.exchange-tip {
  background: var(--surface-strong, #ece8dc);
  border-radius: 12px;
  padding: 12px 14px;
  font-size: 13px;
  color: var(--muted, #68706a);
}


/* 兑换商品网格 */
.exchange-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.exchange-product-card {
  background: rgba(255, 253, 247, 0.96);
  border-radius: 14px;
  padding: 18px 14px;
  display: flex;
  flex-direction: column;
  border: 0.5px solid var(--line, #ddd6c7);
  box-shadow: 0 1px 3px rgba(33, 36, 31, 0.04);
}


.exchange-product-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.exchange-product-name {
  font-size: 16px;
  font-weight: 600;
  color: var(--ink, #202321);
}


.exchange-product-tag {
  font-size: 12px;
  color: var(--cinnabar, #b94132);
  background: rgba(var(--accent-rgb), 0.1);
  padding: 3px 8px;
  border-radius: 6px;
}


.exchange-product-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: rgba(var(--accent-rgb), 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 12px;
}


.exchange-product-icon svg {
  width: 22px;
  height: 22px;
  color: var(--cinnabar, #b94132);
}

.exchange-product-note {
  font-size: 13px;
  color: var(--muted, #68706a);
  line-height: 1.5;
  margin-bottom: 14px;
  flex: 1;
}

.exchange-product-points-label {
  font-size: 14px;
  font-weight: 600;
  color: var(--ink, #202321);
  margin-bottom: 10px;
}

.exchange-product-vip-points-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--cinnabar, #b94132);
  margin-bottom: 10px;
  margin-top: -6px;
}


.exchange-product-button {
  width: 100%;
  padding: 12px;
  border-radius: 10px;
  border: 0;
  background: var(--surface-strong, #ece8dc);
  color: var(--muted, #68706a);
  font-size: 14px;
  font-weight: 500;
  cursor: not-allowed;
}

.exchange-product-button.available {
  background: var(--cinnabar, #b94132);
  color: #fff;
  cursor: pointer;
}

.exchange-product-button.available:hover {
  background: var(--accent-dark, #8b352c);
}

/* 灵石管理页 */
.recharge-header-card {
  background: rgba(255, 253, 247, 0.96);
  border-radius: 14px;
  padding: 24px 20px;
  border: 0.5px solid var(--line, #ddd6c7);
  box-shadow: 0 1px 3px rgba(33, 36, 31, 0.04);
  margin-bottom: 20px;
}

.recharge-dual-balance {
  display: flex;
  align-items: stretch;
  gap: 0;
}

.recharge-balance-block {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.recharge-balance-divider {
  width: 1px;
  background: var(--line, #ddd6c7);
  margin: 0 18px;
  flex-shrink: 0;
}

.recharge-balance-top {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 14px;
}

.recharge-balance-icon {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: rgba(var(--accent-rgb), 0.10);
  color: var(--cinnabar, #b94132);
  font-size: 18px;
  font-weight: 800;
  flex-shrink: 0;
}

.recharge-balance-icon.ai-quota {
  background: rgba(var(--accent-rgb), 0.10);
  color: var(--cinnabar, #b94132);
  font-size: 15px;
}

.recharge-balance-icon.download-quota {
  background: rgba(var(--accent-rgb), 0.10);
  color: var(--cinnabar, #b94132);
}

.recharge-balance-icon.download-quota svg {
  width: 18px;
  height: 18px;
}

.recharge-balance-label {
  font-size: 13px;
  color: var(--muted, #68706a);
  margin-bottom: 8px;
}

.recharge-balance-value {
  font-size: 28px;
  line-height: 1.05;
  font-weight: 800;
  color: var(--ink, #202321);
  margin-bottom: 8px;
}

.recharge-balance-note {
  display: block;
  color: var(--muted, #68706a);
  font-size: 11px;
  line-height: 1.45;
}

.recharge-header-card p {
  margin: 0 0 14px;
  font-size: 13px;
  color: var(--muted, #68706a);
}

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

.recharge-section-label {
  font-size: 13px;
  color: var(--muted, #68706a);
  margin: 2px 0 0;
  padding-left: 4px;
}

.recharge-options-card {
  background: rgba(255, 253, 247, 0.96);
  border-radius: 14px;
  padding: 18px 18px 18px;
  border: 0.5px solid var(--line, #ddd6c7);
  box-shadow: 0 1px 3px rgba(33, 36, 31, 0.04);
}

/* 充值商城卡片内导航栏 - 参考 paipan-nav 风格 */
.recharge-nav {
  list-style: none;
  margin: 0 0 18px 0;
  padding: 6px;
  display: flex;
  width: 100%;
  flex-wrap: nowrap;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  white-space: nowrap;
  gap: 6px;
  border-radius: 10px;
  background: rgba(32, 35, 33, 0.06);
  touch-action: pan-x;
  user-select: none;
  -webkit-user-select: none;
  scrollbar-width: none;
  scroll-behavior: smooth;
  box-sizing: border-box;
}

.recharge-nav::-webkit-scrollbar {
  display: none;
}

.recharge-nav-item {
  flex: 1 1 0;
  min-width: 0;
  min-height: 40px;
  padding: 0 16px;
  margin: 0;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--muted, #8e8e93);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  transition: color 0.18s ease, background 0.18s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

.recharge-nav-item:hover {
  color: var(--cinnabar, #b94132);
}

.recharge-nav-item-selected {
  background: var(--cinnabar, #b94132) !important;
  color: #fffdf7 !important;
  font-weight: 700;
  border: 0 !important;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(var(--accent-rgb), 0.24);
}

.recharge-pane[hidden] {
  display: none;
}

.recharge-options-head {
  margin-bottom: 16px;
}

.recharge-options-head h3 {
  margin: 0 0 8px;
  font-size: 17px;
  color: var(--ink, #202321);
}

.recharge-options-head p {
  margin: 0;
  font-size: 13px;
  color: var(--muted, #68706a);
}

.recharge-tier-card {
  border: 0.5px solid var(--line, #ddd6c7);
  border-radius: 16px;
  background: #f7f7f7;
  box-shadow: 0 1px 3px rgba(33, 36, 31, 0.04);
  padding: 18px 14px;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}

.recharge-tier-card:disabled {
  pointer-events: none;
}

.recharge-tier-card:hover:not(:disabled) {
  transform: translateY(-2px);
}

.recharge-tier-card.active {
  border-color: var(--cinnabar, #b94132);
  background: rgba(255, 253, 247, 0.96);
  box-shadow: 0 10px 22px rgba(var(--accent-rgb), 0.10);
}

.recharge-tier-card.disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.recharge-tier-name {
  font-size: 13px;
  font-weight: 700;
  color: var(--muted, #68706a);
  margin-bottom: 8px;
}

.recharge-tier-gems {
  font-size: 22px;
  font-weight: 800;
  color: var(--ink, #202321);
  margin-bottom: 6px;
}

.recharge-tier-price {
  font-size: 14px;
  color: var(--cinnabar, #b94132);
  font-weight: 700;
}

.recharge-pay-card {
  margin-top: 22px;
  padding-top: 8px;
}


.recharge-pay-button {
  width: 100%;
  padding: 14px 20px;
  border: 0;
  border-radius: 18px;
  background: var(--cinnabar, #b94132);
  color: #fff;
  font-size: 18px;
  font-weight: 800;
  cursor: pointer;
}

.recharge-pay-button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.recharge-pay-button.ai-quota {
  background: var(--cinnabar, #b94132);
}

.recharge-pay-button.ai-quota:hover:not(:disabled) {
  background: var(--accent-dark, #8b352c);
}

.recharge-pay-button.download-quota {
  background: var(--cinnabar, #b94132);
}

.recharge-pay-button.download-quota:hover:not(:disabled) {
  background: var(--accent-dark, #8b352c);
}

.ai-quota-tier.active {
  border-color: var(--cinnabar, #b94132) !important;
  background: rgba(255, 253, 247, 0.96) !important;
  box-shadow: 0 10px 22px rgba(var(--accent-rgb), 0.10) !important;
}

.download-quota-tier.active {
  border-color: var(--cinnabar, #b94132) !important;
  background: rgba(255, 253, 247, 0.96) !important;
  box-shadow: 0 10px 22px rgba(var(--accent-rgb), 0.10) !important;
}

.theme-appearance-panel {
  width: min(100%, 760px);
  margin: 0 auto;
  padding: 8px 0 24px;
}

.theme-appearance-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 22px;
}

.theme-appearance-head h2 {
  margin: 0 0 8px;
  font-size: 20px;
  color: var(--ink, #202321);
}

.theme-appearance-head p {
  margin: 0;
  font-size: 13px;
  color: var(--muted, #68706a);
}

.theme-appearance-head p strong {
  color: var(--cinnabar, #b94132);
}

.theme-current-mark {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  flex: 0 0 36px;
  color: var(--cinnabar, #b94132);
}

.theme-current-mark svg {
  width: 21px;
  height: 21px;
}

.theme-season-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 14px;
}

.theme-season-option {
  min-width: 0;
  min-height: 68px;
  padding: 8px 12px 8px 10px;
  display: flex;
  align-items: center;
  gap: 12px;
  border: 1px solid var(--line, #ddd6c7);
  border-radius: 999px;
  background: rgba(255, 254, 251, 0.82);
  color: var(--ink, #202321);
  text-align: left;
  cursor: pointer;
  transition: border-color .18s ease, background-color .18s ease, box-shadow .18s ease, transform .18s ease;
}

.theme-season-option:hover {
  transform: translateX(2px);
  border-color: rgba(var(--accent-rgb), 0.45);
}

.theme-season-option.active {
  border-color: var(--cinnabar, #b94132);
  background: rgba(var(--accent-rgb), 0.07);
  box-shadow: 0 0 0 2px rgba(var(--accent-rgb), 0.10);
}

.theme-season-copy {
  min-width: 0;
  display: flex;
  flex: 1 1 auto;
  align-items: baseline;
  gap: 10px;
}

.theme-season-option strong {
  font-size: 16px;
}

.theme-season-option small {
  font-size: 12px;
  color: var(--muted, #68706a);
}

.theme-season-swatch {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  flex: 0 0 48px;
  border-radius: 50%;
  color: #fff;
}

.theme-season-swatch svg {
  width: 22px;
  height: 22px;
}

.theme-season-option.spring .theme-season-swatch { background: #2e8b6f; }
.theme-season-option.summer .theme-season-swatch { background: #b94132; }
.theme-season-option.autumn .theme-season-swatch { background: #b17824; }
.theme-season-option.winter .theme-season-swatch { background: #3f7f9d; }
.theme-season-option.begonia .theme-season-swatch { background: #a14e61; }
.theme-season-option.turquoise .theme-season-swatch { background: #27858a; }
.theme-season-option.dusk .theme-season-swatch { background: #735f8f; }
.theme-season-option.ink .theme-season-swatch { background: #315f62; }
.theme-season-option.celadon .theme-season-swatch { background: #6b9b8a; }
.theme-season-option.indigo .theme-season-swatch { background: #3d5a80; }
.theme-season-option.tea .theme-season-swatch { background: #8b6f4e; }
.theme-season-option.plum .theme-season-swatch { background: #8c4a6a; }
.theme-season-option.darkblue .theme-season-swatch { background: #3a5a72; }
.theme-season-option.ochre .theme-season-swatch { background: #a8693c; }
.theme-season-option.bamboo .theme-season-swatch { background: #5e8c6a; }
.theme-season-option.rouge .theme-season-swatch { background: #9d435a; }
.theme-season-option.smoke .theme-season-swatch { background: #5d6470; }
.theme-season-option.darkgreen .theme-season-swatch { background: #2d4a35; }
.theme-season-option.zitan .theme-season-swatch { background: #4a2c3a; }
.theme-season-option.azure .theme-season-swatch { background: #1f6fa8; }
.theme-season-option.golden .theme-season-swatch { background: #c8a83a; }
.theme-season-option.silver .theme-season-swatch { background: #95a0a8; }
.theme-season-option.moonwhite .theme-season-swatch { background: #668aa8; }
.theme-season-option.lotus .theme-season-swatch { background: #a45b76; }
.theme-season-option.pine .theme-season-swatch { background: #3f6954; }
.theme-season-option.jadepurple .theme-season-swatch { background: #6c5b88; }

.theme-season-check {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  flex: 0 0 28px;
  border: 1px solid var(--line, #ddd6c7);
  border-radius: 50%;
  color: transparent;
  background: #fffefb;
}

.theme-season-check svg {
  width: 16px;
  height: 16px;
}

.theme-season-option.active .theme-season-check {
  border-color: var(--cinnabar, #b94132);
  background: var(--cinnabar, #b94132);
  color: #fff;
}

@media (max-width: 760px) {
  .theme-appearance-panel { padding: 6px 0 20px; }
  .theme-appearance-head { margin-bottom: 18px; }
  .theme-season-option { min-height: 64px; }
}

@media (max-width: 760px) {
  /* 子页面 main-content 内边距与 profile.html 保持一致 */
  body[data-page^="profile-"] .main-content {
    padding: 0 14px 96px;
  }

  body[data-page^="profile-"] .profile-sub-body {
    padding: 0;
  }

  body[data-page^="profile-"] .profile-sub-topbar {
    padding: 14px 0;
  }

  .recharge-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
  }
  .recharge-tier-card {
    padding: 14px 10px;
  }
  .recharge-tier-gems {
    font-size: 18px;
  }
  .recharge-tier-price {
    font-size: 12px;
  }
  .recharge-pay-card {
    margin-top: 18px;
  }
  .recharge-pay-button {
    width: 100%;
  }
  .recharge-dual-balance {
    flex-direction: row;
  }
  .recharge-balance-divider {
    margin: 0 8px;
  }
  .recharge-balance-top {
    min-height: 66px;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    margin-bottom: 10px;
  }
  .recharge-balance-icon {
    width: 30px;
    height: 30px;
    border-radius: 8px;
    font-size: 15px;
  }
  .recharge-balance-label {
    font-size: 12px;
    line-height: 1.35;
    margin-bottom: 0;
  }
  .recharge-balance-value {
    font-size: 24px;
  }
  .recharge-balance-note {
    font-size: 10px;
  }
  .recharge-balance-icon {
    width: 32px;
    height: 32px;
    font-size: 16px;
  }
}

@media (max-width: 420px) {
  .recharge-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* 个人信息页 */
.profile-info-group {
  background: rgba(255, 253, 247, 0.96);
  border-radius: 14px;
  overflow: hidden;
  margin-bottom: 16px;
  border: 0.5px solid var(--line, #ddd6c7);
  box-shadow: 0 1px 3px rgba(33, 36, 31, 0.04);
}


.profile-info-row {
  display: flex;
  align-items: center;
  width: 100%;
  padding: 16px;
  border: 0;
  border-bottom: 0.5px solid var(--line, #ddd6c7);
  cursor: pointer;
  text-align: left;
  background: transparent;
  font: inherit;
  color: inherit;
  box-sizing: border-box;
  margin: 0;
  outline: none;
}

a.profile-info-row[aria-disabled="true"] {
  pointer-events: none;
  opacity: 0.58;
}

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

.profile-info-row-label {
  flex: 1;
  min-width: 0;
}

.profile-info-row-title {
  font-size: 15px;
  font-weight: 500;
  color: var(--ink, #202321);
  margin-bottom: 2px;
}


.profile-info-row-desc {
  font-size: 12px;
  color: var(--muted, #68706a);
}

.profile-info-row-value {
  flex: 0 1 46%;
  min-width: 0;
  overflow: hidden;
  font-size: 14px;
  color: var(--muted, #68706a);
  margin-right: 8px;
  text-align: right;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.profile-info-row-arrow {
  flex: 0 0 auto;
  color: var(--line, #ddd6c7);
}

.profile-info-row-arrow svg {
  width: 16px;
  height: 16px;
}

/* 安全与设置 */
body[data-page="profile-settings"] .profile-sub-body {
  width: 100%;
  max-width: 760px;
}

.profile-settings-list .profile-info-row {
  min-height: 78px;
  gap: 14px;
  text-decoration: none;
}

.profile-settings-logout-row {
  min-height: 78px;
  gap: 14px;
  text-decoration: none;
}

.profile-settings-row-icon {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: rgba(var(--accent-rgb), 0.1);
  color: var(--cinnabar);
}

.profile-settings-row-icon svg {
  width: 18px;
  height: 18px;
}

.profile-settings-list .profile-info-row-title {
  display: block;
  margin: 0;
  font-weight: 700;
}

.profile-settings-toggle-row {
  cursor: default;
}

.profile-settings-toggle-row .profile-info-row-label {
  min-width: 0;
}

.profile-settings-toggle-row .notification-switch {
  flex: 0 0 52px;
  margin-left: auto;
}

.profile-settings-logout-group {
  margin-top: 18px;
}

.profile-settings-logout-row .profile-settings-row-icon,
.profile-settings-logout-row .profile-info-row-title {
  color: var(--cinnabar);
}

.profile-settings-delete-row {
  min-height: 78px;
  gap: 14px;
}

.profile-settings-delete-row .profile-settings-row-icon,
.profile-settings-delete-row .profile-info-row-title {
  color: var(--cinnabar);
}

.profile-settings-list .profile-info-row-desc {
  display: block;
  margin-top: 4px;
}

.profile-settings-list {
  overflow: visible;
}

.profile-language-setting {
  position: relative;
}

.profile-language-setting > .profile-info-row {
  border-bottom: 0.5px solid var(--line, #ddd6c7);
}

.profile-language-current {
  flex: 0 0 auto;
  color: var(--muted, #68706a);
  font-size: 14px;
  white-space: nowrap;
}

.profile-language-menu {
  position: absolute;
  z-index: 30;
  top: 62px;
  right: 16px;
  width: 156px;
  padding: 6px;
  border: 0.5px solid var(--line, #ddd6c7);
  border-radius: 8px;
  background: #fffdf7;
  box-shadow: 0 10px 28px rgba(33, 36, 31, 0.15);
}

.profile-language-menu[hidden] {
  display: none;
}

.profile-language-menu button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  min-height: 42px;
  padding: 0 12px;
  border: 0;
  border-radius: 6px;
  color: var(--ink, #202321);
  background: transparent;
  font: inherit;
  font-size: 14px;
  cursor: pointer;
}

.profile-language-menu button:hover,
.profile-language-menu button[aria-selected="true"] {
  color: var(--cinnabar);
  background: rgba(var(--accent-rgb), 0.1);
}

.profile-language-menu button svg {
  width: 16px;
  height: 16px;
  opacity: 0;
}

.profile-language-menu button[aria-selected="true"] svg {
  opacity: 1;
}

/* 编辑表单 */
.profile-edit-form {
  background: rgba(255, 253, 247, 0.96);
  border-radius: 14px;
  padding: 20px;
  margin-bottom: 16px;
  border: 0.5px solid var(--line, #ddd6c7);
  box-shadow: 0 1px 3px rgba(33, 36, 31, 0.04);
}

.profile-account-edit-page .profile-sub-body {
  width: 100%;
  max-width: 620px;
}

.profile-edit-current {
  margin: 0 0 16px;
  padding: 12px 14px;
  border: 1px solid var(--line, #ddd6c7);
  border-radius: 8px;
  background: var(--surface-strong, #ece8dc);
  color: var(--muted, #68706a);
  font-size: 13px;
  overflow-wrap: anywhere;
}

.profile-edit-field {
  display: block;
  margin-bottom: 14px;
}

.profile-edit-field > span {
  display: block;
  margin: 0 0 7px;
  color: var(--ink, #202321);
  font-size: 13px;
  font-weight: 700;
}

.profile-edit-submit:disabled {
  cursor: not-allowed;
  opacity: 0.58;
}


.profile-edit-input {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid var(--line, #ddd6c7);
  border-radius: var(--radius-md);
  background: var(--surface-strong, #ece8dc);
  color: var(--ink, #202321);
  font-size: 15px;
  margin-bottom: 10px;
  box-sizing: border-box;
  outline: none;
  transition: border-color 0.15s ease;
}


.profile-edit-input:focus {
  border-color: var(--cinnabar, #b94132);
}

.profile-edit-hint {
  font-size: 12px;
  color: var(--muted, #68706a);
  margin-bottom: 14px;
}

.profile-edit-submit {
  width: 100%;
  padding: 14px;
  border-radius: 10px;
  border: 0;
  background: var(--cinnabar, #b94132);
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s ease;
}

.profile-edit-submit:hover {
  background: var(--accent-dark, #8b352c);
}

.profile-edit-cancel {
  width: 100%;
  padding: 14px;
  border-radius: 10px;
  border: 0;
  background: var(--surface-strong, #ece8dc);
  color: var(--muted, #68706a);
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  margin-top: 10px;
}


.section-label {
  font-size: 13px;
  color: var(--muted, #68706a);
  margin: 20px 0 10px;
  padding-left: 4px;
}

/* ===== 邀请奖励页 ===== */
.invite-link-card,
.invite-code-card,
.invite-rules-card,
.invite-progress-card {
  margin-bottom: 16px;
}

.invite-link-row {
  display: flex;
  gap: 10px;
  align-items: stretch;
}

.invite-link-input {
  flex: 1;
  min-width: 0;
  user-select: none;
  -webkit-user-select: none;
  height: 44px;
  padding: 0 14px;
  border: 1px solid var(--line, #ddd6c7);
  border-radius: 10px;
  background: var(--surface-strong, #ece8dc);
  color: var(--ink, #202321);
  font-size: 13px;
  font-weight: 600;
  outline: none;
  overflow: hidden;
  text-overflow: ellipsis;
}

.invite-link-input:focus {
  border-color: var(--line, #ddd6c7);
}

.invite-link-tip {
  margin: 10px 0 0;
  font-size: 12px;
  color: var(--muted, #68706a);
  line-height: 1.6;
}

.invite-code-row {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
}

.invite-code-value {
  flex: 1;
  min-width: 0;
  font-size: 22px;
  font-weight: 900;
  color: var(--cinnabar, #b94132);
  letter-spacing: 0.05em;
  overflow: hidden;
  text-overflow: ellipsis;
}

.invite-copy-btn {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 44px;
  padding: 0 16px;
  border: 0;
  border-radius: 10px;
  background: linear-gradient(160deg, var(--accent-light, #c95c4c), var(--cinnabar, #b94132));
  color: #fffdf7;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
  transition: box-shadow 0.18s ease, transform 0.12s ease;
  box-shadow: 0 8px 18px rgba(var(--accent-rgb), 0.2);
}

.invite-copy-btn:active {
  transform: translateY(1px);
}

.invite-copy-btn i {
  width: 16px;
  height: 16px;
}

/* 邀请统计双卡片 */
.invite-stats-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 16px;
}

.invite-stat-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 18px 16px;
  border: 1px solid var(--line, #ddd6c7);
  border-radius: 14px;
  background: rgba(255, 253, 247, 0.96);
  box-shadow: 0 8px 20px rgba(33, 36, 31, 0.05);
}

.invite-stat-icon {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #fffdf7;
  flex-shrink: 0;
}

.invite-stat-icon i {
  width: 22px;
  height: 22px;
}

.invite-stat-icon.tone-cinnabar {
  background: linear-gradient(135deg, var(--accent-dark, #8b352c), var(--cinnabar, #b94132));
}

.invite-stat-icon.tone-gold {
  background: linear-gradient(135deg, var(--accent-dark, #8b352c), var(--cinnabar, #b94132));
}

.invite-stat-text {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.invite-stat-label {
  font-size: 12px;
  font-weight: 700;
  color: var(--muted, #68706a);
}

.invite-stat-value {
  font-size: 20px;
  font-weight: 900;
  color: var(--ink, #202321);
  line-height: 1.2;
}

/* 奖励规则 */
.invite-rule-item {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 14px 0;
  border-bottom: 0.5px solid var(--line, #ddd6c7);
}

.invite-rule-item:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.invite-rule-item:first-child {
  padding-top: 0;
}

.invite-rule-icon {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #fffdf7;
  flex-shrink: 0;
}

.invite-rule-icon i {
  width: 20px;
  height: 20px;
}

.invite-rule-icon.tone-cinnabar {
  background: linear-gradient(135deg, var(--accent-dark, #8b352c), var(--cinnabar, #b94132));
}

.invite-rule-icon.tone-gold {
  background: linear-gradient(135deg, var(--accent-dark, #8b352c), var(--cinnabar, #b94132));
}

.invite-rule-body {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.invite-rule-body strong {
  font-size: 15px;
  font-weight: 800;
  color: var(--ink, #202321);
}

.invite-rule-body p {
  margin: 0;
  font-size: 13px;
  line-height: 1.6;
  color: var(--muted, #68706a);
}

.invite-rule-body em {
  font-style: normal;
  font-weight: 800;
  color: var(--cinnabar, #b94132);
}

/* 里程碑进度 */
.invite-progress-info {
  font-size: 14px;
  font-weight: 800;
  color: var(--ink, #202321);
  margin-bottom: 10px;
}

.invite-progress-info span:first-child {
  color: var(--cinnabar, #b94132);
  font-size: 20px;
}

.invite-progress-track {
  width: 100%;
  height: 10px;
  border-radius: 999px;
  background: rgba(32, 35, 33, 0.08);
  overflow: hidden;
}

.invite-progress-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--cinnabar, #b94132), var(--accent-light, #c95c4c));
  transition: width 0.4s ease;
  width: 0;
}

.invite-progress-tip {
  margin: 10px 0 0;
  font-size: 12px;
  color: var(--muted, #68706a);
  line-height: 1.6;
}

/* 复制成功提示气泡 */
.invite-toast {
  position: fixed;
  left: 50%;
  bottom: 80px;
  transform: translateX(-50%) translateY(20px);
  padding: 12px 22px;
  border-radius: 12px;
  background: rgba(var(--accent-rgb), 0.94);
  color: #fffdf7;
  font-size: 14px;
  font-weight: 700;
  white-space: nowrap;
  z-index: 9999;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.22);
}

.invite-toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* 电脑端布局：与主页面风格一致，不再是拉伸的手机页面 */
@media (min-width: 761px) {
  /* 去掉手机式渐变背景，改为和主页面一样的纯色 */
  .profile-sub-page {
    background: var(--bg, #f4f3ee);
    padding-bottom: 0;
  }

  /* 顶部栏改为和主页面 topbar 一致的风格 */
  .profile-sub-topbar {
    position: static;
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 0 0 20px;
    background: transparent;
    border-bottom: none;
    backdrop-filter: none;
  }

  .profile-sub-back {
    width: 36px;
    height: 36px;
    border: 1px solid var(--line, #ddd6c7);
    border-radius: 50%;
    background: var(--portal-panel, #fffefb);
    flex-shrink: 0;
  }

  .profile-sub-title {
    text-align: left;
    font-size: 24px;
    font-weight: 700;
  }

  .profile-sub-topbar-spacer {
    display: none;
  }

  /* 主体内容铺满 */
  .profile-sub-body {
    padding: 0;
    max-width: none;
  }

  /* 卡片统一风格 */
  .profile-card {
    padding: 24px;
    border-radius: 18px;
    margin-bottom: 18px;
  }

  .section-label {
    font-size: 14px;
    font-weight: 700;
    margin: 24px 0 12px;
    padding-left: 0;
  }

  /* ===== 个人信息页：两栏并排 ===== */
  body[data-page="profile-info"] .profile-sub-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
    align-items: start;
  }

  body[data-page="profile-info"] .section-label {
    grid-column: 1 / -1;
  }

  body[data-page="profile-info"] #info-editor {
    grid-column: 1 / -1;
  }

  /* ===== 签到中心：左主右辅 ===== */
  body[data-page="profile-checkin"] .profile-sub-body {
    display: grid;
    grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
    gap: 18px;
    align-items: start;
  }

  body[data-page="profile-checkin"] .checkin-left-col {
    display: flex;
    flex-direction: column;
    gap: 16px;
  }

  body[data-page="profile-checkin"] .checkin-right-col {
    display: flex;
    flex-direction: column;
    gap: 16px;
  }

  body[data-page="profile-checkin"] .checkin-stats-row {
    grid-template-columns: 1fr 1fr;
  }

  /* ===== 签到记录页：多列网格 ===== */
  body[data-page="profile-checkin-records"] .profile-sub-body {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
  }

  body[data-page="profile-checkin-records"] .profile-card {
    margin-bottom: 0;
  }

  body[data-page="profile-checkin-records"] #records-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 14px;
  }

  body[data-page="profile-checkin-records"] .record-item {
    margin-bottom: 0;
  }

  /* ===== 兑换记录页：与签到记录页一致的多列网格 ===== */
  body[data-page="profile-exchange-records"] .profile-sub-body {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
  }

  body[data-page="profile-exchange-records"] .profile-card {
    margin-bottom: 0;
  }

  body[data-page="profile-exchange-records"] #records-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 14px;
  }

  body[data-page="profile-exchange-records"] .record-item {
    margin-bottom: 0;
  }

  /* ===== 兑换页：3 列商品网格 ===== */
  body[data-page="profile-mall"] .exchange-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
  }

  body[data-page="profile-mall"] .exchange-product-card {
    padding: 22px 20px;
  }

  body[data-page="profile-mall"] .exchange-header-card {
    margin-bottom: 20px;
  }

  /* ===== 邀请页：单栏布局，避免 section-label 与卡片错位 ===== */
  body[data-page="profile-invite"] .profile-sub-body {
    display: flex;
    flex-direction: column;
    gap: 0;
    align-items: stretch;
  }

  body[data-page="profile-invite"] .section-label {
    margin-top: 24px;
  }

  body[data-page="profile-invite"] .section-label:first-child {
    margin-top: 0;
  }

  body[data-page="profile-invite"] .invite-link-card,
  body[data-page="profile-invite"] .invite-code-card,
  body[data-page="profile-invite"] .invite-rules-card,
  body[data-page="profile-invite"] .invite-progress-card {
    margin-bottom: 0;
  }

  body[data-page="profile-invite"] .invite-stats-row {
    margin-bottom: 0;
  }

  body[data-page="profile-invite"] .invite-progress-card {
    margin-bottom: 0;
  }

} /* 结束 @media (min-width: 761px) */

/* ===== 会员中心页 ===== */
.profile-vip-panel {
  padding: 20px;
}

.profile-vip-panel .profile-vip-status-card {
  background: transparent;
  border: 0;
  border-radius: 0;
  padding: 0 0 16px;
  margin-bottom: 0;
  box-shadow: none;
}

.profile-vip-panel-divider {
  height: 1px;
  background: var(--portal-soft-line, rgba(32, 35, 33, 0.08));
  margin: 0 0 16px;
}

.profile-vip-benefits-label {
  font-size: 14px;
  font-weight: 700;
  color: var(--ink, #202321);
  margin-bottom: 12px;
}

.profile-vip-status-card {
  background: linear-gradient(135deg, rgba(var(--accent-rgb), 0.16), rgba(var(--accent-rgb), 0.04) 70%), rgba(255, 253, 247, 0.96);
  border: 1px solid rgba(var(--accent-rgb), 0.28);
  border-radius: 18px;
  padding: 24px 20px;
  margin-bottom: 16px;
  box-shadow: 0 1px 3px rgba(33, 36, 31, 0.04);
}

/* 每日历法通知 */
.notification-settings {
  width: min(100%, 720px);
  margin: 0 auto;
}

.notification-control-panel,
.notification-schedule,
.notification-preview {
  background: rgba(255, 253, 247, 0.96);
  border: 1px solid var(--line, #ddd6c7);
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(33, 36, 31, 0.06);
}

.notification-control-panel {
  overflow: hidden;
}

.notification-control-row {
  min-height: 84px;
  padding: 16px 18px;
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr) 52px;
  align-items: center;
  gap: 12px;
}

.notification-control-icon {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: var(--cinnabar, #b94132);
  background: rgba(var(--accent-rgb), 0.11);
}

.notification-control-icon svg {
  width: 22px;
  height: 22px;
}

.notification-control-copy {
  min-width: 0;
}

.notification-control-copy h2 {
  margin: 0 0 4px;
  font-size: 16px;
  line-height: 1.3;
  color: var(--ink, #202321);
}

.notification-control-copy p {
  margin: 0;
  font-size: 13px;
  line-height: 1.45;
  color: var(--muted, #68706a);
}

.notification-switch {
  width: 50px;
  height: 30px;
  position: relative;
  display: block;
}

.notification-switch input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.notification-switch span {
  position: absolute;
  inset: 0;
  border-radius: 15px;
  background: #b7bbb8;
  transition: background 0.18s ease;
}

.notification-switch span::after {
  content: '';
  position: absolute;
  width: 26px;
  height: 26px;
  top: 2px;
  left: 2px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 5px rgba(33, 36, 31, 0.24);
  transition: transform 0.18s ease;
}

.notification-switch input:checked + span {
  background: var(--cinnabar, #b94132);
}

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

.notification-switch input:focus-visible + span {
  outline: 2px solid var(--cinnabar, #b94132);
  outline-offset: 3px;
}

.notification-switch input:disabled + span {
  opacity: 0.55;
}

body[data-notification-loading="1"] .notification-switch span {
  visibility: hidden;
}

body[data-notification-loading="1"] .notification-switch::after {
  content: '';
  position: absolute;
  width: 18px;
  height: 18px;
  top: 6px;
  left: 16px;
  border: 2px solid rgba(var(--accent-rgb), 0.22);
  border-top-color: var(--cinnabar, #b94132);
  border-radius: 50%;
  animation: notification-state-loading 0.7s linear infinite;
}

@keyframes notification-state-loading {
  to { transform: rotate(360deg); }
}

.notification-state {
  min-height: 65px;
  padding: 13px 18px;
  border-top: 1px solid var(--line, #ddd6c7);
  display: flex;
  align-items: flex-start;
  gap: 10px;
  background: rgba(33, 36, 31, 0.018);
}

.notification-state-dot {
  width: 8px;
  height: 8px;
  margin-top: 6px;
  border-radius: 50%;
  flex: 0 0 auto;
  background: #8b928d;
}

.notification-state[data-state="enabled"] .notification-state-dot { background: #2e8b6f; }
.notification-state[data-state="error"] .notification-state-dot,
.notification-state[data-state="unavailable"] .notification-state-dot { background: var(--cinnabar, #b94132); }

.notification-state strong {
  display: block;
  font-size: 14px;
  line-height: 1.35;
  color: var(--ink, #202321);
}

.notification-state p {
  margin: 3px 0 0;
  font-size: 12px;
  line-height: 1.5;
  color: var(--muted, #68706a);
}

.notification-schedule {
  min-height: 68px;
  margin-top: 14px;
  padding: 14px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.notification-schedule span,
.notification-schedule strong {
  display: block;
}

.notification-schedule span {
  margin-bottom: 3px;
  font-size: 12px;
  color: var(--muted, #68706a);
}

.notification-schedule strong {
  font-size: 15px;
  color: var(--ink, #202321);
}

.notification-schedule svg {
  width: 20px;
  height: 20px;
  color: var(--cinnabar, #b94132);
}

.notification-preview {
  margin-top: 14px;
  padding: 15px 16px 16px;
}

.notification-preview-head {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
  color: var(--muted, #68706a);
  font-size: 12px;
}

.notification-preview-app,
.notification-preview-app img {
  width: 24px;
  height: 24px;
  border-radius: 6px;
}

.notification-preview-head time {
  white-space: nowrap;
}

.notification-preview > strong {
  display: block;
  font-size: 15px;
  color: var(--ink, #202321);
  margin-bottom: 4px;
}

.notification-preview > p {
  margin: 0;
  font-size: 14px;
  line-height: 1.55;
  color: var(--ink, #202321);
  overflow-wrap: anywhere;
}

@media (max-width: 520px) {
  .notification-control-row {
    grid-template-columns: 42px minmax(0, 1fr) 50px;
    padding: 15px 14px;
    gap: 10px;
  }

  .notification-control-icon {
    width: 42px;
    height: 42px;
  }

  .notification-state,
  .notification-schedule {
    padding-left: 14px;
    padding-right: 14px;
  }
}

.profile-vip-status-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 18px;
}

.profile-vip-redeem-button {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border: 1px solid rgba(var(--accent-rgb), .28);
  border-radius: 999px;
  background: rgba(var(--accent-rgb), .08);
  color: var(--accent-dark, #8b352c);
  font: inherit;
  font-size: 13px;
  cursor: pointer;
}
.profile-vip-redeem-button svg,
.profile-vip-redeem-button i { width: 16px; height: 16px; }
.profile-vip-redeem-button:hover { background: rgba(var(--accent-rgb), .15); }

.profile-vip-redeem-open { overflow: hidden; }
.profile-vip-redeem-modal[hidden] { display: none !important; }
.profile-vip-redeem-modal {
  position: fixed;
  inset: 0;
  z-index: 10030;
  display: grid;
  place-items: center;
  padding: 18px;
}
.profile-vip-redeem-backdrop {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  background: rgba(32, 35, 33, .48);
  cursor: pointer;
}
.profile-vip-redeem-dialog {
  position: relative;
  z-index: 1;
  width: min(100%, 420px);
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--cinnabar, #b94132) 34%, var(--line, #ddd6c7));
  border-radius: 12px;
  background: var(--surface, #fffdf7);
  box-shadow: 0 22px 60px rgba(32, 35, 33, .28);
}
.profile-vip-redeem-header {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 8px 10px 8px 16px;
  background: var(--surface, #fffdf7);
  border-bottom: 0;
  color: var(--ink, #202321);
}
.profile-vip-redeem-header h2 {
  flex: 1 1 auto;
  min-width: 0;
  margin: 0;
  font-size: 16px;
  line-height: 1.35;
}
.profile-vip-redeem-close {
  display: inline-grid;
  width: 32px;
  height: 32px;
  flex: 0 0 32px;
  place-items: center;
  padding: 0;
  border: 1px solid color-mix(in srgb, var(--cinnabar, #b94132) 45%, transparent);
  border-radius: 50%;
  /* 主题色淡底 + 主题色圆圈描边：无论弹窗头部什么颜色，圆圈都清晰可见。 */
  background: color-mix(in srgb, var(--cinnabar, #b94132) 10%, transparent);
  color: var(--cinnabar, #b94132);
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
}
.profile-vip-redeem-close:hover,
.profile-vip-redeem-close:focus-visible {
  background: color-mix(in srgb, var(--cinnabar, #b94132) 20%, transparent);
  border-color: var(--cinnabar, #b94132);
  color: var(--cinnabar, #b94132);
  outline: 0;
}
.profile-vip-redeem-form {
  display: grid;
  gap: 10px;
  padding: 18px 16px 16px;
}
.profile-vip-redeem-form label {
  color: var(--ink, #202321);
  font-size: 13px;
  font-weight: 700;
}
.profile-vip-redeem-form input {
  width: 100%;
  min-height: 42px;
  padding: 0 12px;
  border: 1px solid var(--line, #ddd6c7);
  border-radius: 8px;
  background: var(--surface-strong, #f4f1e8);
  color: var(--ink, #202321);
  font: inherit;
  box-sizing: border-box;
}
.profile-vip-redeem-form input:focus { border-color: var(--cinnabar, #b94132); outline: 2px solid color-mix(in srgb, var(--cinnabar, #b94132) 22%, transparent); }
.profile-vip-redeem-error { margin: 0; color: var(--cinnabar, #b94132); font-size: 12px; }
.profile-vip-redeem-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 4px; }
.profile-vip-redeem-actions button {
  min-height: 38px;
  padding: 0 14px;
  border-radius: 8px;
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}
.profile-vip-redeem-cancel { border: 1px solid var(--line, #ddd6c7); background: transparent; color: var(--ink, #202321); }
.profile-vip-redeem-submit { border: 1px solid var(--cinnabar, #b94132); background: var(--cinnabar, #b94132); color: #fffdf7; }
.profile-vip-redeem-submit:disabled { opacity: .6; cursor: wait; }

.profile-vip-status-icon {
  width: 52px;
  height: 52px;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--accent-dark, #8b352c), var(--cinnabar, #b94132));
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 8px 18px rgba(var(--accent-rgb), 0.22);
}

.profile-vip-status-icon svg,
.profile-vip-status-icon i {
  width: 26px;
  height: 26px;
  color: #fffdf7;
}

.profile-vip-status-info {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.profile-vip-status-badge {
  display: inline-flex;
  align-items: center;
  align-self: flex-start;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  background: var(--surface-strong, #ece8dc);
  color: var(--muted, #68706a);
  letter-spacing: 0.04em;
}

.profile-vip-status-badge.active {
  background: linear-gradient(135deg, var(--accent-dark, #8b352c), var(--cinnabar, #b94132));
  color: #fffdf7;
  box-shadow: 0 4px 10px rgba(var(--accent-rgb), 0.25);
}

.profile-vip-status-text {
  font-size: 16px;
  font-weight: 700;
  color: var(--ink, #202321);
  line-height: 1.3;
}

.profile-vip-status-detail {
  display: flex;
  align-items: stretch;
  gap: 0;
  margin-bottom: 18px;
}

.profile-vip-status-detail-item {
  flex: 1 1 0;
  min-width: 0;
}

.profile-vip-status-detail-label {
  display: block;
  font-size: 13px;
  color: var(--muted, #68706a);
  margin-bottom: 6px;
}

.profile-vip-status-detail-item strong {
  font-size: 20px;
  font-weight: 800;
  color: var(--cinnabar, #b94132);
  line-height: 1.2;
}

.profile-vip-status-detail-divider {
  width: 1px;
  background: rgba(var(--accent-rgb), 0.22);
  margin: 0 18px;
  flex-shrink: 0;
}

.profile-vip-status-button {
  width: 100%;
  padding: 14px 20px;
  border: 0;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--accent-dark, #8b352c), var(--cinnabar, #b94132));
  color: #fffdf7;
  font-size: 16px;
  font-weight: 800;
  cursor: pointer;
  transition: box-shadow 0.18s ease, transform 0.12s ease;
  box-shadow: 0 8px 18px rgba(var(--accent-rgb), 0.22);
}

.profile-vip-status-button:hover {
  box-shadow: 0 12px 24px rgba(var(--accent-rgb), 0.28);
}

.profile-vip-status-button:active {
  transform: translateY(1px);
}

.profile-vip-status-button.renew {
  background: linear-gradient(135deg, var(--accent-dark, #8b352c), var(--cinnabar, #b94132));
  box-shadow: 0 8px 18px rgba(var(--accent-rgb), 0.22);
}

.profile-vip-status-button.renew:hover {
  box-shadow: 0 12px 24px rgba(var(--accent-rgb), 0.28);
}

/* 会员权益列表 */
.profile-vip-benefits-list {
  padding: 0;
  margin-bottom: 0;
}

.profile-vip-benefit-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 0;
  border-bottom: 0.5px solid var(--portal-soft-line, rgba(32, 35, 33, 0.08));
}

.profile-vip-benefit-item:last-child {
  border-bottom: 0;
}

.profile-vip-benefit-icon {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(var(--accent-rgb), 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.profile-vip-benefit-icon svg,
.profile-vip-benefit-icon i {
  width: 22px;
  height: 22px;
  color: var(--cinnabar, #b94132);
}

.profile-vip-benefit-body {
  flex: 1;
  min-width: 0;
}

.profile-vip-benefit-body strong {
  display: block;
  font-size: 15px;
  font-weight: 700;
  color: var(--ink, #202321);
  margin-bottom: 2px;
}

.profile-vip-benefit-body p {
  margin: 0;
  font-size: 13px;
  color: var(--muted, #68706a);
  line-height: 1.5;
}

/* 会员套餐 - 横向滑动卡片（类似哔哩哔哩） */
/* 页面整体布局：上方滚动 + 下方固定 */
body[data-page="profile-vip"] .main-content {
  display: flex;
  flex-direction: column;
  height: 100vh;
  max-height: 100vh;
  padding-top: 0;
  padding-bottom: 0;
  overflow: hidden;
}

.profile-vip-page {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  padding-bottom: 0;
}

.profile-vip-scroll {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.profile-vip-scroll::-webkit-scrollbar {
  display: none;
}

.profile-vip-footer {
  flex-shrink: 0;
  background: rgba(255, 253, 247, 0.98);
  border-top: 1px solid var(--line, #ddd6c7);
  border-radius: 18px 18px 0 0;
  box-shadow: 0 -6px 18px rgba(33, 36, 31, 0.06);
  padding: 16px 16px calc(14px + env(safe-area-inset-bottom, 0px));
  backdrop-filter: saturate(180%) blur(12px);
  z-index: 20;
}

.profile-vip-footer-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--ink, #202321);
  margin-bottom: 10px;
}

.profile-vip-plans {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding: 4px 0 8px;
  margin-bottom: 12px;
}

.profile-vip-plans::-webkit-scrollbar {
  display: none;
}

.profile-vip-plan-card {
  flex: 0 0 110px;
  width: 110px;
  height: 110px;
  scroll-snap-align: center;
  position: relative;
  background: rgba(255, 253, 247, 0.96);
  border: 1.5px solid var(--line, #ddd6c7);
  border-radius: 14px;
  padding: 12px 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  box-shadow: 0 1px 3px rgba(33, 36, 31, 0.04);
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.12s ease, background 0.18s ease;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.profile-vip-plan-card:hover:not(.disabled) {
  border-color: var(--cinnabar, #b94132);
  box-shadow: 0 6px 14px rgba(var(--accent-rgb), 0.12);
}

.profile-vip-plan-card:active:not(.disabled) {
  transform: translateY(1px);
}

/* 选中状态 */
.profile-vip-plan-card.selected {
  border-color: var(--cinnabar, #b94132);
  background: linear-gradient(180deg, rgba(var(--accent-rgb), 0.06), rgba(255, 253, 247, 0.96));
  box-shadow: 0 6px 14px rgba(var(--accent-rgb), 0.14);
}

.profile-vip-plan-card.selected:hover {
  border-color: var(--cinnabar, #b94132);
}

/* 推荐标签 */
.profile-vip-plan-card.featured {
  border-color: rgba(var(--accent-rgb), 0.4);
}

.profile-vip-plan-card.featured.selected {
  border-color: var(--cinnabar, #b94132);
}

/* 勾选图标 - 默认隐藏 */
.profile-vip-plan-check {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--line, #ddd6c7);
  display: grid;
  place-items: center;
  color: #fffdf7;
  transition: background 0.18s ease;
}

.profile-vip-plan-check svg {
  width: 12px;
  height: 12px;
}

.profile-vip-plan-card.selected .profile-vip-plan-check {
  background: var(--cinnabar, #b94132);
}

/* disabled 状态 */
.profile-vip-plan-card.disabled {
  cursor: default;
  opacity: 0.6;
}

.profile-vip-plan-card.disabled:hover {
  border-color: var(--line, #ddd6c7);
  box-shadow: 0 1px 3px rgba(33, 36, 31, 0.04);
}

.profile-vip-plan-card.disabled:active {
  transform: none;
}

.profile-vip-plan-card.featured.disabled {
  border-color: rgba(var(--accent-rgb), 0.4);
}

.profile-vip-plan-card.member {
  cursor: default;
}

.profile-vip-plan-tag {
  position: absolute;
  top: -1px;
  left: 50%;
  transform: translateX(-50%);
  padding: 2px 10px;
  border-radius: 0 0 8px 8px;
  font-size: 10px;
  font-weight: 800;
  background: linear-gradient(135deg, var(--accent-dark, #8b352c), var(--cinnabar, #b94132));
  color: #fffdf7;
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.profile-vip-plan-name {
  font-size: 13px;
  font-weight: 700;
  color: var(--ink, #202321);
  margin-bottom: 4px;
  margin-top: 2px;
}

.profile-vip-plan-price {
  font-size: 18px;
  font-weight: 900;
  color: var(--cinnabar, #b94132);
  line-height: 1.1;
  margin-bottom: 2px;
}

.profile-vip-plan-desc {
  font-size: 10px;
  color: var(--muted, #68706a);
  line-height: 1.3;
  margin-bottom: 0;
}

/* 底部支付按钮 - 占满整行 */
.profile-vip-pay-button {
  width: 100%;
  padding: 14px 20px;
  border: 0;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--accent-dark, #8b352c), var(--cinnabar, #b94132));
  color: #fffdf7;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  transition: box-shadow 0.18s ease, transform 0.12s ease, opacity 0.18s ease;
  box-shadow: 0 8px 18px rgba(var(--accent-rgb), 0.22);
}

.profile-vip-pay-button:hover:not(:disabled) {
  box-shadow: 0 12px 24px rgba(var(--accent-rgb), 0.28);
}

.profile-vip-pay-button:active:not(:disabled) {
  transform: translateY(1px);
}

.profile-vip-pay-button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  box-shadow: none;
}

/* 电脑端：套餐固定3列不滚动 */
@media (min-width: 761px) {
  body[data-page="profile-vip"] .main-content {
    height: 100vh;
    max-height: 100vh;
  }

  body[data-page="profile-vip"] .profile-vip-scroll {
    padding: 0;
  }

  body[data-page="profile-vip"] .profile-sub-body {
    max-width: 720px;
    margin: 0 auto;
    width: 100%;
  }

  body[data-page="profile-vip"] .profile-vip-footer {
    max-width: 720px;
    margin: 0 auto;
    width: 100%;
  }

  body[data-page="profile-vip"] .profile-vip-plans {
    display: grid;
    grid-template-columns: repeat(3, 130px);
    gap: 16px;
    overflow-x: visible;
    scroll-snap-type: none;
    padding: 0;
    justify-content: center;
  }

  body[data-page="profile-vip"] .profile-vip-plan-card {
    flex: none;
    width: 130px;
    height: 130px;
    min-width: unset;
    max-width: unset;
    scroll-snap-align: none;
    padding: 14px 8px;
  }

  body[data-page="profile-vip"] .profile-vip-plan-name {
    font-size: 14px;
  }

  body[data-page="profile-vip"] .profile-vip-plan-price {
    font-size: 20px;
  }

  body[data-page="profile-vip"] .profile-vip-plan-desc {
    font-size: 11px;
  }
}

/* App 通知管理：沿用仙真宝诰的外层面板与独立圆角条目。 */
body[data-page="profile-notifications"] .profile-sub-page,
body[data-page="profile-notifications"] .profile-sub-body,
.notification-settings {
  width: 100%;
  max-width: none;
}

body[data-page="profile-notifications"] .profile-sub-page {
  min-height: 0;
  padding-bottom: 0;
}

.notification-control-panel {
  width: 100%;
  padding: 20px;
  border: 1px solid var(--portal-soft-line, rgba(32, 35, 33, 0.08));
  border-radius: 18px;
  background: var(--portal-panel, rgba(255, 253, 247, 0.92));
  box-shadow: var(--portal-warm-shadow, 0 18px 48px rgba(46, 41, 33, 0.1));
}

.notification-control-list {
  display: grid;
  gap: 14px;
}

.notification-control-row {
  min-height: 76px;
  padding: 20px;
  grid-template-columns: 32px minmax(0, 1fr) 52px;
  gap: 14px;
  border: 1px solid var(--portal-soft-line, rgba(32, 35, 33, 0.08));
  border-radius: var(--radius-lg, 18px);
  background: var(--portal-panel, rgba(255, 253, 247, 0.92));
  box-shadow: var(--portal-warm-shadow, 0 18px 48px rgba(46, 41, 33, 0.1));
}

.notification-control-icon {
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: var(--radius-sm, 8px);
  background: rgba(var(--accent-rgb), 0.11);
  color: var(--cinnabar, #b94132);
  box-shadow: inset 0 0 0 1px rgba(var(--accent-rgb), 0.10);
}

.notification-control-icon svg {
  width: 15px;
  height: 15px;
}

.notification-control-copy h3 {
  margin: 0;
  font-size: 16px;
  line-height: 1.4;
  letter-spacing: 0;
  color: var(--ink, #202321);
}

.notification-live {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (max-width: 520px) {
  .notification-control-panel {
    padding: 16px;
  }

  .notification-control-row {
    min-height: 76px;
    padding: 16px;
    grid-template-columns: 32px minmax(0, 1fr) 50px;
    gap: 12px;
  }
}

@media (max-width: 760px) {
  body[data-page="profile-notifications"] .main-content {
    min-height: 100svh;
    padding: max(18px, env(safe-area-inset-top)) 14px max(14px, env(safe-area-inset-bottom));
    display: flex;
    flex-direction: column;
  }

  body[data-page="profile-notifications"] .topbar {
    flex: 0 0 auto;
  }

  body[data-page="profile-notifications"] .notification-page,
  body[data-page="profile-notifications"] .notification-settings {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
  }

  body[data-page="profile-notifications"] .notification-control-panel {
    flex: 1 1 auto;
  }
}
