    :root {
      --bg-dark: #0c0e1a;
      --bg-card: #161929;
      --bg-card2: #1e2235;
      --accent: #a78bfa;
      --accent2: #818cf8;
      --accent3: #f9a8d4;
      --text-primary: #f1f0ee;
      --text-secondary: #b0afc8;
      --text-muted: #6b6a85;
      --gold: #e5c97e;
      --border: rgba(167,139,250,0.15);
      --border-hv: rgba(167,139,250,0.35);
      --radius: 16px;
      --radius-sm: 10px;
      --radius-full: 9999px;
      /* 过渡曲线 */
      --ease-out: cubic-bezier(.22,1,.36,1);
      --ease-spring: cubic-bezier(.34,1.56,.64,1);
      --t-fast: 140ms;
      --t-norm: 260ms;
    }
    * { margin: 0; padding: 0; box-sizing: border-box; }
    html { scroll-behavior: smooth; }
    body {
      font-family: 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
      background: var(--bg-dark);
      color: var(--text-primary);
      min-height: 100vh;
    }

    /* ===== NAV ===== */
    nav {
      position: sticky; top: 0; z-index: 100;
      display: flex; align-items: center; justify-content: space-between;
      padding: 0 32px; height: 60px;
      background: rgba(12,14,26,0.9);
      backdrop-filter: blur(16px);
      border-bottom: 1px solid var(--border);
      transition: background var(--t-norm), border-color var(--t-norm);
    }
    .nav-logo {
      display: flex; align-items: center; gap: 10px;
      text-decoration: none; color: var(--text-primary);
      font-size: 18px; font-weight: 700;
    }
    .nav-back {
      display: flex; align-items: center; gap: 6px;
      color: var(--text-secondary); text-decoration: none;
      font-size: 14px; padding: 6px 16px;
      border: 1px solid var(--border); border-radius: 50px;
      transition: border-color var(--t-fast), color var(--t-fast), transform var(--t-fast) var(--ease-spring);
    }
    .nav-back:hover { border-color: var(--accent); color: var(--accent); transform: translateX(-2px); }

    /* ===== PAGE LAYOUT ===== */
    .page-wrap {
      max-width: 920px;
      margin: 40px auto;
      padding: 0 20px;
      display: grid;
      grid-template-columns: 200px 1fr;
      gap: 24px;
      align-items: start;
    }

    /* ===== SIDEBAR ===== */
    .sidebar {
      display: flex;
      flex-direction: column;
      gap: 0;
      position: sticky;
      top: 80px;
    }
    .sidebar-profile {
      background: var(--bg-card);
      border: 1px solid var(--border);
      border-radius: var(--radius) var(--radius) 0 0;
      padding: 28px 16px 20px;
      text-align: center;
      border-bottom: none;
    }
    .profile-avatar-big {
      width: 64px; height: 64px; border-radius: 50%;
      background: linear-gradient(135deg, var(--accent), var(--accent2));
      display: flex; align-items: center; justify-content: center;
      font-size: 26px; font-weight: 700; color: #fff;
      margin: 0 auto 12px;
    }
    .profile-name { font-size: 15px; font-weight: 600; margin-bottom: 4px; word-break: break-all; }
    .profile-joined { font-size: 11px; color: var(--text-muted); }
    .sidebar-divider { height: 1px; background: var(--border); margin: 0; }
    .sidebar-menu {
      background: var(--bg-card);
      border: 1px solid var(--border);
      border-top: none;
      border-radius: 0 0 var(--radius) var(--radius);
      overflow: hidden;
      display: flex;
      flex-direction: column;
    }
    .sidebar-menu a {
      display: flex; align-items: center; gap: 10px;
      padding: 12px 16px;
      color: var(--text-secondary); text-decoration: none;
      font-size: 14px;
      transition: background var(--t-fast), color var(--t-fast), transform var(--t-fast) var(--ease-spring);
      border-top: 1px solid var(--border);
    }
    .sidebar-menu a:first-child { border-top: none; }
    .sidebar-menu a:hover { background: var(--bg-card2); color: var(--text-primary); transform: translateX(2px); }
    .sidebar-menu a.active {
      background: linear-gradient(90deg, rgba(167,139,250,0.14), transparent);
      color: var(--accent); font-weight: 500;
      border-left: 3px solid var(--accent);
    }
    .sidebar-menu a .menu-icon { font-size: 15px; flex-shrink: 0; }

    /* ===== MAIN CONTENT ===== */
    .main-content { display: flex; flex-direction: column; gap: 0; }

    .section-card {
      background: var(--bg-card);
      border: 1px solid var(--border);
      border-radius: var(--radius);
      padding: 28px;
    }
    .section-card-title {
      font-size: 16px; font-weight: 600;
      margin-bottom: 24px;
      padding-bottom: 14px;
      border-bottom: 1px solid var(--border);
      display: flex; align-items: center; justify-content: space-between;
      gap: 8px;
    }
    .section-card-title span:first-child { display: flex; align-items: center; gap: 8px; }

    /* ===== 统计概览 ===== */
    .stats-row {
      display: grid;
      grid-template-columns: repeat(3, 1fr);
      gap: 14px;
    }
    .stat-card {
      background: var(--bg-card2);
      border: 1px solid var(--border);
      border-radius: var(--radius-sm);
      padding: 20px 16px;
      text-align: center;
    }
    .stat-num { font-size: 26px; font-weight: 700; color: var(--accent); line-height: 1; }
    .stat-label { font-size: 12px; color: var(--text-muted); margin-top: 6px; }

    /* ===== 表单字段 ===== */
    .field-group {
      display: flex;
      flex-direction: column;
      gap: 18px;
    }
    .field-row {
      display: grid;
      grid-template-columns: 1fr 1fr;
      gap: 16px;
    }
    .field-row.full { grid-template-columns: 1fr; }
    .field-item {
      display: flex;
      flex-direction: column;
      gap: 7px;
    }
    .field-item label {
      font-size: 12px;
      color: var(--text-muted);
      font-weight: 500;
      letter-spacing: 0.02em;
    }
    .field-item input {
      width: 100%;
      padding: 11px 14px;
      background: var(--bg-card2);
      border: 1px solid var(--border);
      border-radius: var(--radius-sm);
      color: var(--text-primary);
      font-size: 14px;
      outline: none;
      transition: border-color 0.2s, box-shadow 0.2s;
      font-family: inherit;
    }
    .field-item input:focus {
      border-color: var(--accent);
      box-shadow: 0 0 0 3px rgba(167,139,250,0.1);
    }
    .field-item input:read-only {
      opacity: 0.45;
      cursor: not-allowed;
    }

    /* ===== 表单状态提示 ===== */
    .form-feedback {
      font-size: 13px;
      min-height: 18px;
      margin-top: 4px;
    }
    .form-feedback.error { color: #f87171; }
    .form-feedback.success { color: #4ade80; }

    /* ===== 按钮 ===== */
    .btn-primary {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      background: linear-gradient(135deg, var(--accent), var(--accent2));
      color: #fff; border: none;
      padding: 11px 28px;
      border-radius: 50px;
      font-size: 14px; font-weight: 600;
      cursor: pointer; transition: opacity var(--t-fast), transform var(--t-fast) var(--ease-spring);
      white-space: nowrap;
    }
    .btn-primary:hover { opacity: 0.9; transform: translateY(-2px); }
    .btn-primary:active { transform: translateY(0); }
    .btn-primary:disabled { opacity: 0.4; cursor: not-allowed; transform: none; }
    .btn-sm {
      padding: 7px 18px;
      font-size: 13px;
    }
    .form-actions {
      display: flex;
      align-items: center;
      gap: 12px;
      margin-top: 22px;
      padding-top: 18px;
      border-top: 1px solid var(--border);
    }

    /* ===== 消息列表 ===== */
    .msg-list-full { display: flex; flex-direction: column; gap: 8px; }
    .msg-row {
      display: flex;
      align-items: flex-start;
      gap: 12px;
      padding: 14px;
      border-radius: var(--radius-sm);
      background: var(--bg-card2);
      cursor: pointer;
      transition: background var(--t-fast);
      border-left: 3px solid transparent;
    }
    .msg-row.unread { border-left-color: var(--accent); }
    .msg-row:hover { background: rgba(167,139,250,0.08); }
    .msg-dot {
      width: 8px; height: 8px;
      border-radius: 50%;
      background: var(--accent);
      flex-shrink: 0;
      margin-top: 5px;
    }
    .msg-dot.read { background: var(--text-muted); }
    .msg-content { flex: 1; min-width: 0; }
    .msg-title-row { font-size: 14px; font-weight: 500; margin-bottom: 4px; }
    .msg-body-row { font-size: 13px; color: var(--text-secondary); line-height: 1.5; }
    .msg-time-row { font-size: 11px; color: var(--text-muted); margin-top: 5px; }
    .msg-empty-full {
      text-align: center;
      padding: 40px;
      color: var(--text-muted);
      font-size: 14px;
    }

    /* ===== 我的纪念馆 ===== */
    .memorials-empty {
      text-align: center;
      padding: 40px;
      color: var(--text-muted);
      font-size: 14px;
    }
    .memorials-empty a {
      color: var(--accent);
      text-decoration: none;
    }
    .memorials-empty a:hover { text-decoration: underline; }

    /* ===== 横向滑动蜡烛卡片 ===== */
    .candles-scroll-wrap {
      position: relative;
    }
    .candles-scroll {
      display: flex;
      gap: 14px;
      overflow-x: auto;
      padding: 4px 2px 14px;
      scroll-snap-type: x mandatory;
      -webkit-overflow-scrolling: touch;
      scrollbar-width: thin;
      scrollbar-color: rgba(167,139,250,0.3) transparent;
    }
    .candles-scroll::-webkit-scrollbar { height: 4px; }
    .candles-scroll::-webkit-scrollbar-track { background: transparent; }
    .candles-scroll::-webkit-scrollbar-thumb { background: rgba(167,139,250,0.35); border-radius: 4px; }
    .candle-card {
      flex: 0 0 160px;
      scroll-snap-align: start;
      background: var(--bg-card2, #1a1a2e);
      border: 1px solid var(--border);
      border-radius: 16px;
      overflow: hidden;
      cursor: pointer;
      transition: transform .18s, box-shadow .18s, border-color .18s;
      text-decoration: none;
      display: block;
    }
    @media (max-width: 600px) {
      .candle-card { flex: 0 0 140px; }
    }
    .candle-card:hover {
      transform: translateY(-4px);
      box-shadow: 0 10px 36px rgba(0,0,0,0.4);
      border-color: rgba(229,201,126,0.55);
    }
    .candle-card-photo {
      width: 100%;
      aspect-ratio: 1/1;
      display: flex;
      align-items: center;
      justify-content: center;
      background: rgba(229,201,126,0.07);
      font-size: 44px;
      overflow: hidden;
    }
    .candle-card-photo img {
      width: 100%; height: 100%; object-fit: cover;
    }
    .candle-card-body {
      padding: 10px 12px 12px;
    }
    .candle-card-name {
      font-size: 14px;
      font-weight: 700;
      color: var(--text-primary);
      white-space: nowrap;
      overflow: hidden;
      text-overflow: ellipsis;
      margin-bottom: 3px;
    }
    .candle-card-meta {
      font-size: 11px;
      color: var(--text-muted);
      white-space: nowrap;
      overflow: hidden;
      text-overflow: ellipsis;
      margin-bottom: 5px;
    }
    .candle-card-lit {
      font-size: 11px;
      color: rgba(229,201,126,0.8);
    }
    /* 左右箭头 */
    .scroll-arrow {
      position: absolute;
      top: 50%;
      transform: translateY(-60%);
      width: 32px; height: 32px;
      background: rgba(30,30,50,0.85);
      border: 1px solid var(--border);
      border-radius: 50%;
      display: flex; align-items: center; justify-content: center;
      cursor: pointer;
      font-size: 14px;
      color: var(--text-primary);
      z-index: 2;
      transition: background .15s, opacity .15s;
      user-select: none;
    }
    .scroll-arrow:hover { background: rgba(167,139,250,0.25); }
    .scroll-arrow.left  { left: -14px; }
    .scroll-arrow.right { right: -14px; }
    .scroll-arrow.hidden { opacity: 0; pointer-events: none; }

    /* ===== MEMORIALS GRID ===== */
    .my-memorials-grid {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
      gap: 16px;
      padding-top: 4px;
    }
    .my-memorial-card {
      background: var(--bg-card2, #1a1a2e);
      border: 1px solid var(--border);
      border-radius: 16px;
      overflow: hidden;
      cursor: pointer;
      transition: transform .18s, box-shadow .18s, border-color .18s;
      text-decoration: none;
      display: block;
    }
    .my-memorial-card:hover {
      transform: translateY(-4px);
      box-shadow: 0 12px 40px rgba(0,0,0,0.4);
      border-color: var(--accent, #a78bfa);
    }
    .my-mc-photo {
      width: 100%;
      aspect-ratio: 1/1;
      display: flex;
      align-items: center;
      justify-content: center;
      background: rgba(167,139,250,0.07);
      font-size: 30px;
      overflow: hidden;
    }
    .my-mc-photo img {
      width: 100%;
      height: 100%;
      object-fit: cover;
    }
    .my-mc-body {
      padding: 8px 10px 10px;
    }
    .my-mc-name {
      font-size: 13px;
      font-weight: 600;
      color: var(--text-primary);
      margin-bottom: 3px;
      white-space: nowrap;
      overflow: hidden;
      text-overflow: ellipsis;
    }
    .my-mc-meta {
      font-size: 11px;
      color: var(--text-muted);
      margin-bottom: 4px;
      white-space: nowrap;
      overflow: hidden;
      text-overflow: ellipsis;
    }
    .my-mc-date {
      font-size: 11px;
      color: var(--text-muted);
    }
    .my-mc-stray {
      display: inline-flex;
      align-items: center;
      gap: 3px;
      font-size: 10px;
      background: rgba(251,191,36,0.18);
      color: #d97706;
      padding: 1px 7px;
      border-radius: 20px;
      font-weight: 600;
      vertical-align: middle;
      margin-left: 4px;
    }

    /* ===== TOAST ===== */
    .toast {
      position: fixed; bottom: 32px; left: 50%;
      transform: translateX(-50%) translateY(0);
      background: var(--bg-card2);
      border: 1px solid var(--border-hv);
      color: var(--text-primary);
      padding: 12px 28px;
      border-radius: var(--radius-full); font-size: 14px;
      box-shadow: 0 8px 32px rgba(0,0,0,.5), 0 0 0 1px rgba(255,255,255,.04);
      backdrop-filter: blur(12px);
      transition: opacity .3s var(--ease-out), transform .3s var(--ease-out);
      z-index: 9999;
      pointer-events: none;
    }

    /* ===== 响应式 ===== */
    @media (max-width: 700px) {
      .page-wrap { grid-template-columns: 1fr; }
      .sidebar { position: static; }
      .stats-row { grid-template-columns: 1fr 1fr; }
      .field-row { grid-template-columns: 1fr; }
      nav { padding: 0 16px; }
      .section-card { padding: 20px 16px; }
    }
