/* ============================================
   PufferWork · 河豚工作台 成熟风格样式
   设计语言：温暖奶油底 + 珊瑚橙主色 + 衬线标题
   柔和圆角 / 层次阴影 / 精致间距
   ============================================ */

:root {
  /* 主色板（成熟暖色系） */
  --primary: #E56B3A;
  --primary-deep: #CF5526;
  --primary-soft: #FBEFE7;
  --primary-light: #F5B48E;
  --cream: #FFF8F1;
  --cream-deep: #F6EADF;
  --ink: #3B3228;
  --ink-soft: #6E6152;
  --muted: #8A7667;
  --line: #EDE3D8;
  --pink: #E87F9F;
  --pink-deep: #D75F86;
  --green: #5FA87C;
  --blue: #5B9FC9;

  --bg: #F6F1EA;
  --bg-deep: #EFE7DC;
  --surface: #FFFFFF;

  /* 圆角与阴影 */
  --radius: 16px;
  --radius-sm: 10px;
  --radius-xs: 8px;
  --shadow-sm: 0 1px 2px rgba(59,50,40,.05);
  --shadow: 0 1px 3px rgba(59,50,40,.06), 0 10px 28px -14px rgba(59,50,40,.18);
  --shadow-lg: 0 12px 36px -12px rgba(59,50,40,.28);

  /* 字体 */
  --font-head: 'Noto Serif SC', 'Songti SC', 'STSong', serif;
  --font-body: 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', system-ui, sans-serif;
  --font-num: 'Inter', 'Noto Sans SC', system-ui, sans-serif;

  /* ��容旧引用（避免遗漏） */
  --puffer-orange: #E56B3A;
  --puffer-orange-deep: #CF5526;
  --puffer-orange-light: #F5B48E;
  --puffer-cream: #FFF8F1;
  --puffer-cream-deep: #F6EADF;
  --puffer-brown: #3B3228;
  --puffer-brown-mid: #6E6152;
  --puffer-pink: #F3A8C0;
  --puffer-pink-deep: #D75F86;
  --puffer-spike: #6B3A1A;
  --puffer-belly: #FFF8F1;
  --bg-pattern: #EFE7DC;
  --text: #3B3228;
  --text-soft: #6E6152;
  --border: #3B3228;
  --shadow-offset: 0px;
  --font-pixel: 'Inter', 'Noto Sans SC', system-ui, sans-serif;
  --font-mono: 'Noto Sans SC', system-ui, sans-serif;
  --font-cn: 'Noto Sans SC', system-ui, sans-serif;
  --font-body: 'Noto Sans SC', system-ui, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  height: 100%;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}

body {
  background:
    radial-gradient(1200px 600px at 85% -10%, rgba(229,107,58,.07), transparent 60%),
    radial-gradient(900px 500px at -10% 30%, rgba(229,107,58,.05), transparent 55%),
    linear-gradient(180deg, #FAF6F0 0%, var(--bg) 40%, var(--bg-deep) 100%);
  min-height: 100vh;
  overflow-x: hidden;
}

/* 浮动光斑背景（柔和化） */
.bg-bubbles {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}
.bg-bubbles span {
  position: absolute;
  width: 160px; height: 160px;
  background: radial-gradient(circle at 35% 35%, rgba(255,244,214,.9), rgba(229,107,58,.06) 62%, transparent 70%);
  filter: blur(2px);
  border-radius: 50%;
  animation: float 26s ease-in-out infinite;
  opacity: 0;
}
.bg-bubbles span:nth-child(1){ left: 4%;  top: 18%; animation-duration: 30s; }
.bg-bubbles span:nth-child(2){ left: 22%; top: 62%; animation-duration: 34s; animation-delay: -6s; width: 110px; height: 110px; }
.bg-bubbles span:nth-child(3){ left: 36%; top: 8%;  animation-duration: 28s; animation-delay: -12s; }
.bg-bubbles span:nth-child(4){ left: 52%; top: 44%; animation-duration: 36s; animation-delay: -3s; width: 90px; height: 90px; }
.bg-bubbles span:nth-child(5){ left: 68%; top: 76%; animation-duration: 32s; animation-delay: -18s; }
.bg-bubbles span:nth-child(6){ left: 82%; top: 22%; animation-duration: 29s; animation-delay: -9s; width: 120px; height: 120px; }
.bg-bubbles span:nth-child(7){ left: 90%; top: 58%; animation-duration: 35s; animation-delay: -15s; }
.bg-bubbles span:nth-child(8){ left: 60%; top: 88%; animation-duration: 31s; animation-delay: -22s; width: 100px; height: 100px; }

@keyframes float {
  0%   { transform: translateY(24px) scale(.92); opacity: 0; }
  15%  { opacity: .55; }
  55%  { opacity: .4; }
  100% { transform: translateY(-110vh) scale(1.05); opacity: 0; }
}

/* ===== 背景：河豚主题像素漂浮物（爱心 / 星星 / 小河豚） ===== */
.bg-motes {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}
.mote {
  position: absolute;
  display: block;
  opacity: 0;
  animation: moteDrift 26s ease-in-out infinite;
  will-change: transform;
}
/* 像素爱心（7×6，块=4px） */
.mote-heart { width: 28px; height: 24px; --ms: 1; }
.mote-heart::before {
  content: '';
  display: block;
  width: 4px; height: 4px;
  background: #E56B3A;
  box-shadow:
    4px 0, 8px 0, 20px 0, 24px 0,
    0 4px, 4px 4px, 8px 4px, 12px 4px, 16px 4px, 20px 4px, 24px 4px,
    0 8px, 4px 8px, 8px 8px, 12px 8px, 16px 8px, 20px 8px, 24px 8px,
    4px 12px, 8px 12px, 12px 12px, 16px 12px, 20px 12px,
    8px 16px, 12px 16px, 16px 16px,
    12px 20px;
}
/* 像素星星（5×5，块=3px） */
.mote-star { width: 15px; height: 15px; --ms: 1; }
.mote-star::before {
  content: '';
  display: block;
  width: 3px; height: 3px;
  background: #F2B45C;
  box-shadow:
    6px 0,
    3px 3px, 6px 3px, 9px 3px,
    0 6px, 3px 6px, 6px 6px, 9px 6px, 12px 6px,
    3px 9px, 9px 9px,
    3px 12px, 9px 12px;
}
/* 小河豚（复用 puffer.png） */
.mote-puff { width: 34px; height: 34px; --ms: 1; }
.mote-puff::before {
  content: '';
  display: block;
  width: 100%; height: 100%;
  background: url('assets/puffer.png') center / contain no-repeat;
}
/* 位置与动画参数 */
.mote-heart.h1 { left: 11%; top: 62%; --ms: 1.7;  animation-duration: 25s; }
.mote-heart.h2 { left: 76%; top: 78%; --ms: 1.25; animation-duration: 30s; animation-delay: -11s; }
.mote-star.s1  { left: 30%; top: 48%; --ms: 1.15; animation-duration: 22s; animation-delay: -4s; }
.mote-star.s2  { left: 88%; top: 32%; --ms: 1.5;  animation-duration: 27s; animation-delay: -15s; }
.mote-star.s3  { left: 5%;  top: 24%; --ms: 1;    animation-duration: 24s; animation-delay: -9s; }
.mote-puff.p1  { left: 60%; top: 66%; --ms: 1.25; animation-duration: 28s; animation-delay: -13s; }
.mote-puff.p2  { left: 42%; top: 16%; --ms: 1.6;  animation-duration: 24s; animation-delay: -19s; }

@keyframes moteDrift {
  0%   { transform: translate3d(0, 16vh, 0) rotate(-7deg) scale(var(--ms, 1)); opacity: 0; }
  14%  { opacity: .72; }
  50%  { opacity: .55; transform: translate3d(16px, -44vh, 0) rotate(5deg) scale(calc(var(--ms, 1) * 1.05)); }
  86%  { opacity: .42; }
  100% { transform: translate3d(-12px, -108vh, 0) rotate(-4deg) scale(var(--ms, 1)); opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .bg-bubbles span, .mote { animation: none !important; opacity: .3 !important; }
}

/* ============= 布局 ============= */
.app {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 232px 1fr;
  grid-template-rows: 68px 1fr;
  grid-template-areas:
    "header header"
    "sidebar content";
  min-height: 100vh;
  max-width: 1400px;
  margin: 0 auto;
  padding: 14px;
  gap: 14px;
}

/* ============= 通用卡片基底 ============= */
.pixel-border {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  position: relative;
}

/* ============= 按钮 ============= */
.pixel-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 18px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: transform .12s ease, box-shadow .18s ease, background .18s ease, border-color .18s ease;
  border-radius: 12px;
  user-select: none;
  white-space: nowrap;
}
.pixel-btn:hover {
  background: var(--cream);
  border-color: #E4D5C4;
  box-shadow: 0 4px 12px -4px rgba(59,50,40,.16);
  transform: translateY(-1px);
}
.pixel-btn:active { transform: translateY(0) scale(.98); box-shadow: var(--shadow-sm); }
.pixel-btn.primary {
  background: linear-gradient(135deg, #EF7A48, var(--primary) 55%, var(--primary-deep));
  color: #fff;
  border-color: transparent;
  box-shadow: 0 6px 16px -6px rgba(229,107,58,.5);
}
.pixel-btn.primary:hover {
  background: linear-gradient(135deg, #F08A5C, var(--primary) 55%, #D85C2C);
  border-color: transparent;
}
.pixel-btn.ghost {
  background: transparent;
  border-style: solid;
  box-shadow: none;
  color: var(--ink-soft);
}
.pixel-btn.ghost:hover { background: var(--cream); color: var(--ink); border-color: var(--line); }
.pixel-btn.danger { background: var(--pink-deep); color: #fff; border-color: transparent; box-shadow: 0 6px 16px -6px rgba(215,95,134,.5); }
.pixel-btn.danger:hover { background: #C94E76; border-color: transparent; }

.pixel-input, .pixel-textarea, .pixel-select {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid var(--line);
  background: var(--surface);
  font-family: var(--font-body);
  font-size: 14px;
  color: var(--ink);
  border-radius: 12px;
  outline: none;
  transition: border-color .18s ease, box-shadow .18s ease, background .18s ease;
}
.pixel-input:focus, .pixel-textarea:focus, .pixel-select:focus {
  border-color: var(--primary);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(229,107,58,.14);
}
.pixel-input::placeholder, .pixel-textarea::placeholder { color: var(--muted); }
.pixel-textarea { min-height: 90px; resize: vertical; line-height: 1.7; }
.pixel-select { appearance: none; -webkit-appearance: none; padding-right: 34px;
  background-image: linear-gradient(45deg, transparent 50%, var(--ink-soft) 50%),
                    linear-gradient(135deg, var(--ink-soft) 50%, transparent 50%);
  background-position: calc(100% - 17px) 50%, calc(100% - 12px) 50%;
  background-size: 5px 5px;
  background-repeat: no-repeat;
}

.icon-btn {
  width: 40px; height: 40px;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid var(--line);
  background: var(--surface);
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: transform .12s, box-shadow .18s, background .18s;
  color: var(--ink);
  border-radius: 12px;
}
.icon-btn:hover { background: var(--cream); }
.icon-btn:active { transform: scale(.96); }

.link-btn {
  background: none; border: none; color: var(--primary-deep);
  font-family: var(--font-body); font-size: 13px; font-weight: 600; cursor: pointer;
  text-decoration: none;
  padding: 2px 4px;
  border-radius: 6px;
  transition: color .15s, background .15s;
}
.link-btn:hover { color: var(--primary); background: var(--primary-soft); }

.badge {
  display: inline-block;
  padding: 4px 12px;
  background: linear-gradient(135deg, #F08A5C, var(--primary));
  color: #fff;
  border: none;
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .3px;
  border-radius: 999px;
  box-shadow: 0 3px 10px -3px rgba(229,107,58,.5);
}
.badge.green { background: linear-gradient(135deg, #6FC08D, var(--green)); box-shadow: 0 3px 10px -3px rgba(95,168,124,.5); }
.badge.pink  { background: linear-gradient(135deg, #F09AB4, var(--pink-deep)); box-shadow: 0 3px 10px -3px rgba(215,95,134,.5); }
.badge.gray  { background: #ECE4D8; color: var(--ink-soft); box-shadow: none; }

.muted { color: var(--muted); font-size: 13px; }

/* ============= Header ============= */
.app-header {
  grid-area: header;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 18px;
  background: rgba(255,252,248,.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  height: 68px;
  border-radius: var(--radius);
  border: 1px solid rgba(237,227,216,.9);
  box-shadow: var(--shadow-sm);
}
.header-left { display: flex; align-items: center; gap: 14px; }
.logo {
  width: 46px; height: 46px;
  background: linear-gradient(135deg, #FFF4E6, var(--cream));
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
}
.puffer-logo { width: 100%; height: 100%; object-fit: contain; border-radius: 10px; }
.brand-title {
  font-family: var(--font-head);
  font-size: 17px;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: .2px;
  line-height: 1.2;
}
.brand-sub {
  font-family: var(--font-body);
  font-size: 12px;
  color: var(--muted);
  margin-top: 3px;
  letter-spacing: .3px;
}
.header-right { display: flex; align-items: center; gap: 10px; }
.sync-pill {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 7px 14px;
  border: 1px solid var(--line);
  background: var(--surface);
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 600;
  color: var(--ink-soft);
  cursor: pointer;
  border-radius: 999px;
  box-shadow: var(--shadow-sm);
  transition: border-color .18s, background .18s;
}
.sync-pill:hover { border-color: #E4D5C4; background: var(--cream); }
.sync-dot {
  width: 8px; height: 8px;
  background: var(--green);
  border-radius: 50%;
  box-shadow: 0 0 0 3px rgba(95,168,124,.16);
}
.sync-dot.cloud { background: var(--primary); box-shadow: 0 0 0 3px rgba(229,107,58,.16); }
.sync-dot.error { background: var(--pink-deep); box-shadow: 0 0 0 3px rgba(215,95,134,.16); animation: syncPulse 1.4s ease-in-out infinite; }
@keyframes syncPulse { 0%,100% { transform: scale(1); opacity: 1; } 50% { transform: scale(1.3); opacity: .65; } }

/* ============= Sidebar ============= */
.sidebar {
  grid-area: sidebar;
  background: rgba(255,252,248,.82);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(237,227,216,.9);
  border-radius: var(--radius);
  padding: 14px 10px;
  display: flex; flex-direction: column;
  gap: 6px;
  height: calc(100vh - 96px);
  position: sticky; top: 14px;
  box-shadow: var(--shadow-sm);
}
.nav { display: flex; flex-direction: column; gap: 4px; flex: 1; }
.nav-item {
  position: relative;
  display: flex; align-items: center; gap: 11px;
  padding: 11px 14px;
  background: transparent;
  border: none;
  border-radius: 12px;
  font-family: var(--font-body);
  font-size: 14.5px;
  font-weight: 500;
  color: var(--ink-soft);
  cursor: pointer;
  text-align: left;
  transition: background .18s ease, color .18s ease, transform .12s ease;
}
.nav-item::before {
  content: '';
  position: absolute; left: 4px; top: 50%; transform: translateY(-50%) scaleY(0);
  width: 3px; height: 20px; border-radius: 3px;
  background: var(--primary);
  transition: transform .2s ease;
}
.nav-item:hover { background: var(--cream); color: var(--ink); }
.nav-item:active { transform: scale(.98); }
.nav-item.active {
  background: var(--primary-soft);
  color: var(--primary-deep);
  font-weight: 700;
}
.nav-item.active::before { transform: translateY(-50%) scaleY(1); }
.nav-icon { font-size: 17px; opacity: .9; }
.nav-item.active .nav-icon { opacity: 1; }
.sidebar-footer {
  margin-top: auto;
  background: linear-gradient(160deg, #FFF8F1, #FDF0E6);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 12px 10px;
  text-align: center;
  box-shadow: var(--shadow-sm);
}
.mascot-mini img { width: 56px; height: 56px; border-radius: 12px; cursor: pointer; transition: transform .2s ease; }
.mascot-quote { font-family: var(--font-body); font-size: 12.5px; color: var(--ink-soft); margin-top: 6px; font-weight: 500; }

/* 胖头鱼交互：戳一下鼓起来 + 气泡弹入 */
.mascot-img, .mascot-mini img { cursor: pointer; transition: transform .2s ease; }
.mascot-img.puff, .mascot-mini img.puff { animation: mascotPuff .6s ease; }
.mascot-bubble.pop { animation: bubblePop .35s ease; }
@keyframes mascotPuff {
  0%   { transform: scale(1) rotate(0); }
  35%  { transform: scale(1.18) rotate(-6deg); }
  60%  { transform: scale(.94) rotate(4deg); }
  100% { transform: scale(1) rotate(0); }
}
@keyframes bubblePop {
  0%   { transform: scale(.85); opacity: .4; }
  60%  { transform: scale(1.05); opacity: 1; }
  100% { transform: scale(1); opacity: 1; }
}

/* ============= Content ============= */
.content {
  grid-area: content;
  padding: 0 0 88px 0;
  min-width: 0;
}

.page { display: none; animation: fade .22s ease; }
.page.active { display: block; }
@keyframes fade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

.page-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 16px;
  flex-wrap: wrap;
  gap: 12px;
}
.page-title {
  font-family: var(--font-head);
  font-size: 22px;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: .2px;
}
.page-sub { color: var(--muted); font-size: 13.5px; margin-top: 5px; }
.page-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }

/* ============= 仪表板 ============= */
.mascot-hero {
  display: flex; align-items: center; gap: 12px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 8px 14px 8px 8px;
  box-shadow: var(--shadow);
}
.mascot-img { width: 52px; height: 52px; border-radius: 12px; }
.mascot-bubble {
  font-family: var(--font-body);
  font-size: 14px;
  color: var(--ink);
  max-width: 220px;
  font-weight: 500;
}

.stat-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-bottom: 14px;
}
.stat-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-bottom: 18px;
}
.water-mini {
  background: linear-gradient(135deg, #EAF5FB 0%, #D5ECF6 100%);
  color: #2C5F7C;
  border-color: #CDE4F0 !important;
  padding: 16px;
  position: relative;
  overflow: hidden;
  min-height: 130px;
  display: flex;
  flex-direction: column;
}
.water-mini::after {
  content: '💧';
  position: absolute; right: -6px; bottom: -10px;
  font-size: 72px; opacity: .12; transform: rotate(-12deg);
}
.water-mini .stat-value {
  font-size: 24px;
  margin-top: 4px;
  display: flex;
  align-items: baseline;
  gap: 4px;
}
.water-mini .water-unit { font-family: var(--font-body); font-size: 13px; opacity: .75; font-weight: 500; }
.water-mini-bar {
  height: 8px;
  background: rgba(255,255,255,.7);
  border-radius: 999px;
  margin-top: 10px;
  overflow: hidden;
  box-shadow: inset 0 1px 2px rgba(44,95,124,.12);
}
.water-mini .water-fill {
  height: 100%;
  background: linear-gradient(90deg, #8ED0EA, #4FA3CE);
  border-radius: 999px;
  width: 0%;
  transition: width .45s ease;
}
.water-mini-actions {
  margin-top: auto;
  padding-top: 10px;
  display: flex;
  gap: 8px;
}
.water-mini-actions .pixel-btn {
  flex: 1;
  background: rgba(255,255,255,.85);
  border-color: #C9E2EF;
  border-radius: 10px;
  font-size: 16px;
  font-weight: 700;
  color: #2C5F7C;
  box-shadow: none;
}
.water-mini-actions .pixel-btn.primary {
  background: linear-gradient(135deg, #6DBFE2, #3E93C0);
  color: #fff;
  border-color: transparent;
}
.pixel-btn.tiny {
  padding: 6px 12px;
  font-size: 14px;
  line-height: 1.2;
}
.stat-card {
  padding: 16px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
  transition: transform .18s ease, box-shadow .22s ease;
}
.stat-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.stat-card::after {
  content: ''; position: absolute; right: -18px; top: -18px;
  width: 72px; height: 72px;
  background: rgba(229,107,58,.05);
  border-radius: 50%;
}
.stat-orange { background: linear-gradient(135deg, #F0824A, var(--primary-deep)); color: #fff; border-color: transparent; }
.stat-orange::after { background: rgba(255,255,255,.14); }
.stat-cream { background: linear-gradient(160deg, #FFF9F1, #FFF3E6); }
.stat-pink  { background: linear-gradient(160deg, #FCE9EF, #FADAE5); }
.stat-brown { background: linear-gradient(135deg, #4A3A2E, #3B3228); color: #fff; border-color: transparent; }
.stat-brown::after { background: rgba(255,255,255,.08); }
.stat-icon { position: absolute; right: 14px; top: 14px; font-size: 22px; line-height: 1; opacity: .9; }
.stat-label { font-family: var(--font-body); font-size: 12px; font-weight: 600; letter-spacing: .6px; opacity: .8; }
.stat-value { font-family: var(--font-num); font-size: 30px; font-weight: 700; line-height: 1.15; margin-top: 8px; letter-spacing: -.5px; }
.stat-sub { font-family: var(--font-body); font-size: 13px; margin-top: 6px; opacity: .8; font-weight: 500; }

.dash-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 14px;
}

.card { padding: 18px; background: var(--surface); }
.card-head {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 14px; gap: 10px; flex-wrap: wrap;
}
.card-head h3 {
  font-family: var(--font-head);
  font-size: 15px;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: .2px;
  display: flex; align-items: center; gap: 6px;
}

.mini-list { list-style: none; display: flex; flex-direction: column; gap: 9px; }
.mini-list li { display: flex; align-items: center; gap: 9px; font-size: 14px; }
.mini-list li.empty { color: var(--muted); font-style: italic; justify-content: center; padding: 14px 0; }
.mini-list .check {
  width: 18px; height: 18px;
  border: 1.5px solid #D9CCBC;
  background: #fff;
  flex-shrink: 0;
  border-radius: 6px;
  display: inline-flex; align-items: center; justify-content: center;
  transition: background .15s, border-color .15s;
}
.mini-list .check.done { background: var(--primary); border-color: var(--primary); color: #fff; }
.mini-list .check.done::after { content: '✓'; font-size: 11px; font-weight: 700; }

.today-train { padding: 8px 0; }
.today-train .muscle { font-family: var(--font-body); font-size: 15px; font-weight: 700; color: var(--primary-deep); }
.today-train .desc  { color: var(--ink-soft); font-size: 14px; margin-top: 8px; line-height: 1.6; }
.today-train.is-rest .muscle { color: var(--muted); }

.quick-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}
.quick-tile {
  display: flex; flex-direction: column; align-items: center; gap: 7px;
  padding: 14px 8px;
  background: var(--cream);
  border: 1px solid var(--line);
  border-radius: 12px;
  font-family: var(--font-body);
  font-size: 13.5px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: transform .12s, box-shadow .18s, background .18s, border-color .18s;
}
.quick-tile:hover { background: var(--surface); border-color: #E4D5C4; transform: translateY(-2px); box-shadow: 0 6px 14px -6px rgba(59,50,40,.18); }
.quick-tile:active { transform: scale(.97); }
.qt-icon { font-size: 22px; }

/* ============= 待办 ============= */
.seg {
  display: inline-flex;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 12px;
  padding: 3px;
  box-shadow: var(--shadow-sm);
  gap: 2px;
}
.seg-btn {
  padding: 7px 14px;
  background: transparent;
  border: none;
  border-radius: 9px;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  color: var(--ink-soft);
  transition: background .16s, color .16s;
}
.seg-btn.active { background: linear-gradient(135deg, #F08A5C, var(--primary)); color: #fff; box-shadow: 0 3px 8px -3px rgba(229,107,58,.45); }
.seg-btn:hover:not(.active) { background: var(--cream); color: var(--ink); }

.todo-list { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.todo-item {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: var(--shadow-sm);
  position: relative;
  transition: box-shadow .18s, transform .12s, opacity .2s;
}
.todo-item:hover { box-shadow: var(--shadow); }
.todo-item.done { opacity: .55; }
.todo-item.done .ti-text { text-decoration: line-through; text-decoration-color: var(--muted); }
.todo-check {
  width: 24px; height: 24px;
  border: 2px solid #D9CCBC;
  background: #fff;
  cursor: pointer;
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  transition: background .15s, border-color .15s, transform .12s;
}
.todo-check:hover { border-color: var(--primary); transform: scale(1.06); }
.todo-check.done { background: var(--primary); border-color: var(--primary); color: #fff; }
.todo-check.done::after { content: '✓'; font-weight: 700; }
.ti-text { flex: 1; font-size: 14.5px; }
.ti-meta { display: flex; gap: 6px; align-items: center; }
.ti-prio {
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--cream);
  color: var(--ink-soft);
}
.ti-prio.high { background: #FDE8EE; color: var(--pink-deep); }
.ti-prio.mid  { background: var(--primary-soft); color: var(--primary-deep); }
.ti-prio.low  { background: #F0EBE3; color: var(--ink-soft); }
.ti-actions { display: flex; gap: 6px; }
.ti-actions button {
  width: 32px; height: 32px;
  border: 1px solid var(--line);
  background: var(--surface);
  cursor: pointer;
  border-radius: 9px;
  font-size: 14px;
  color: var(--ink-soft);
  box-shadow: none;
  transition: background .15s, color .15s, transform .12s;
}
.ti-actions button:hover { background: var(--cream); transform: translateY(-1px); }
.ti-actions button:active { transform: scale(.95); }
.ti-actions .del { color: var(--pink-deep); }
.ti-actions .del:hover { background: #FDE8EE; }
.todo-empty { text-align: center; padding: 36px 10px; color: var(--muted); font-size: 14px; }

/* ============= 健身 ============= */
.week-strip {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 8px;
}
.wd {
  text-align: center;
  padding: 12px 4px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  font-family: var(--font-body);
  font-size: 13px;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  position: relative;
  transition: transform .12s, box-shadow .18s, border-color .18s;
}
.wd:hover { transform: translateY(-2px); border-color: #E4D5C4; box-shadow: 0 6px 14px -6px rgba(59,50,40,.18); }
.wd .wd-name { display: block; font-weight: 700; }
.wd .wd-plan { display: block; font-size: 11px; color: var(--muted); margin-top: 4px; }
.wd.is-today { background: linear-gradient(160deg, #FDF1E6, var(--primary-soft)); border-color: var(--primary-light); color: var(--primary-deep); }
.wd.is-today .wd-plan { color: rgba(207,85,38,.75); }
.wd.is-rest { background: #F3EDE4; }
.wd.is-done::after {
  content: '✓';
  position: absolute; top: -6px; right: -6px;
  width: 20px; height: 20px;
  background: var(--green);
  color: #fff;
  border: 2px solid #fff;
  border-radius: 50%;
  font-size: 11px; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 2px 6px rgba(95,168,124,.4);
}

.today-plan { margin-top: 14px; }
.today-plan-body .plan-tag {
  display: inline-block; padding: 4px 11px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 600;
  margin-right: 6px;
  margin-bottom: 6px;
  background: var(--cream);
  color: var(--ink-soft);
}
.plan-tag.rest { background: #F3EDE4; color: var(--ink-soft); }
.plan-tag.muscle { background: linear-gradient(135deg, #F3A8C0, var(--pink-deep)); color: #fff; border-color: transparent; }
.today-plan-body p { font-size: 14px; color: var(--ink-soft); margin: 4px 0 8px; line-height: 1.7; }

.train-list { list-style: none; display: flex; flex-direction: column; gap: 12px; }
.train-item {
  padding: 14px;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 14px;
  box-shadow: var(--shadow-sm);
  display: flex; align-items: flex-start; gap: 14px;
  transition: box-shadow .18s;
}
.train-item:hover { box-shadow: var(--shadow); }
.train-date {
  width: 58px; text-align: center;
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 600;
  padding: 8px 4px;
  background: linear-gradient(160deg, #FDF1E6, var(--primary-soft));
  color: var(--primary-deep);
  border: 1px solid var(--primary-light);
  border-radius: 12px;
  flex-shrink: 0;
}
.train-date .d { font-size: 17px; font-weight: 800; display: block; margin-top: 2px; font-family: var(--font-num); }
.train-body { flex: 1; }
.train-muscle {
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 700;
  color: var(--ink);
}
.train-content { font-size: 14px; color: var(--ink-soft); margin-top: 6px; white-space: pre-wrap; word-break: break-word; line-height: 1.7; }
.train-foot { display: flex; gap: 6px; margin-top: 10px; align-items: center; }
.train-foot .pill {
  font-size: 12px; font-weight: 600; padding: 3px 10px; border: 1px solid var(--line);
  background: var(--cream);
  border-radius: 999px;
  color: var(--ink-soft);
}
.train-foot .del-btn { margin-left: auto; }
.train-empty { text-align: center; padding: 36px 10px; color: var(--muted); }
.day-nav { display: flex; gap: 6px; align-items: center; }
.day-nav .pill { min-width: 34px; padding: 6px 12px; cursor: pointer; border-radius: 10px; font-size: 14px; font-weight: 700; }
.day-now { font-family: var(--font-body); font-size: 12px; font-weight: 600; }
.day-label { font-family: var(--font-head); font-size: 15px; font-weight: 700; color: var(--ink); margin: 6px 0 2px; }
.day-summary { font-size: 13px; color: var(--muted); margin-bottom: 12px; }
.train-foot .pill[data-act="edit-train"] { background: var(--primary-soft); color: var(--primary-deep); border-color: var(--primary-light); cursor: pointer; }
.train-foot .pill[data-act="edit-train"]:hover { background: var(--primary-light); color: #fff; }

/* ============= 素材库 ============= */
.category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
  margin-bottom: 14px;
}
.cat-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 16px;
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  transition: transform .12s, box-shadow .18s, border-color .18s;
  position: relative;
}
.cat-card:hover { transform: translateY(-3px); border-color: #E4D5C4; box-shadow: var(--shadow); }
.cat-card:active { transform: scale(.97); }
.cat-card.active {
  background: linear-gradient(160deg, #FFF3E8, var(--primary-soft));
  border-color: var(--primary-light);
  color: var(--primary-deep);
}
.cat-card .cc-icon { font-size: 22px; }
.cat-card .cc-name { font-family: var(--font-body); font-weight: 700; font-size: 15px; margin-top: 6px; }
.cat-card .cc-count { font-family: var(--font-num); font-size: 12px; font-weight: 600; margin-top: 4px; opacity: .65; }

.search-wrap { width: 240px; }

.material-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 12px;
}
.material-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: var(--shadow-sm);
  padding: 10px;
  display: flex; flex-direction: column; gap: 6px;
  transition: transform .12s, box-shadow .18s;
}
.material-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.material-thumb {
  width: 100%;
  aspect-ratio: 16/10;
  background: var(--cream);
  border: 1px solid var(--line);
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 28px;
  overflow: hidden;
  position: relative;
}
.material-thumb img { width: 100%; height: 100%; object-fit: cover; }
.material-thumb .play {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: 32px; color: #fff;
  background: rgba(59,50,40,.28);
  pointer-events: none;
  text-shadow: 0 2px 8px rgba(0,0,0,.3);
}
.material-name { font-weight: 700; font-size: 14px; }
.material-meta {
  display: flex; gap: 4px; flex-wrap: wrap;
  font-size: 11px;
}
.material-tag {
  padding: 2px 8px; background: var(--cream);
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ink-soft);
  font-weight: 500;
}
.material-actions { display: flex; gap: 6px; margin-top: auto; }
.material-actions button {
  flex: 1;
  padding: 7px;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 9px;
  font-family: var(--font-body);
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: none;
  transition: background .15s, color .15s;
}
.material-actions button:hover { background: var(--cream); }
.material-actions .del { color: var(--pink-deep); }
.material-actions .del:hover { background: #FDE8EE; }

.material-empty, .post-empty {
  text-align: center; padding: 36px 10px; color: var(--muted);
}

/* ============= 推文/AI视频 共用 ============= */
.post-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 14px;
}
.post-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: var(--shadow-sm);
  padding: 14px;
  display: flex; flex-direction: column; gap: 8px;
  transition: transform .12s, box-shadow .18s;
}
.post-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.post-card .pc-head {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
}
.post-card .pc-title { font-family: var(--font-body); font-weight: 700; font-size: 15px; }
.post-card .pc-cover {
  width: 100%; aspect-ratio: 4/3;
  background: var(--cream);
  border: 1px solid var(--line);
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 28px;
  overflow: hidden;
}
.post-card .pc-cover img { width: 100%; height: 100%; object-fit: cover; }
.post-card .pc-content { font-size: 13px; color: var(--ink-soft); line-height: 1.65; max-height: 6.5em; overflow: hidden; }
.post-card .pc-foot { display: flex; gap: 6px; align-items: center; }
.post-card .pc-actions { display: flex; gap: 6px; margin-top: auto; }
.post-card .pc-actions button {
  flex: 1; padding: 7px;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 9px;
  font-family: var(--font-body);
  font-size: 12.5px; font-weight: 600; cursor: pointer;
  transition: background .15s, color .15s;
}
.post-card .pc-actions button:hover { background: var(--cream); }
.post-card .pc-actions .del { color: var(--pink-deep); }
.post-card .pc-actions .del:hover { background: #FDE8EE; }

/* ============= Modal ============= */
.modal-mask {
  position: fixed; inset: 0;
  background: rgba(59,50,40,.45);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 100;
  display: none;
  align-items: center; justify-content: center;
  padding: 16px;
}
.modal-mask.show { display: flex; animation: fade .18s ease; }
.modal {
  width: 100%;
  max-width: 520px;
  max-height: 88vh;
  background: var(--surface);
  display: flex; flex-direction: column;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}
.modal-head {
  padding: 16px 20px;
  background: linear-gradient(135deg, #F0824A, var(--primary-deep));
  color: #fff;
  display: flex; align-items: center; justify-content: space-between;
}
.modal-head h3 { font-family: var(--font-head); font-size: 15px; font-weight: 700; letter-spacing: .3px; }
.modal-close {
  background: none; border: none; color: rgba(255,255,255,.9); font-size: 26px; line-height: 1; cursor: pointer;
  padding: 0 6px; border-radius: 8px;
  transition: background .15s;
}
.modal-close:hover { background: rgba(255,255,255,.16); }
.modal-body { padding: 20px; overflow: auto; flex: 1; }
.modal-foot {
  padding: 14px 20px;
  display: flex; justify-content: flex-end; gap: 10px;
  border-top: 1px solid var(--line);
  background: var(--cream);
}
.form-row { margin-bottom: 16px; }
.form-row label {
  display: block;
  font-family: var(--font-body);
  font-size: 13px; font-weight: 700;
  color: var(--ink);
  margin-bottom: 7px;
}
.form-row .row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.file-hint { font-size: 12px; color: var(--muted); margin-top: 5px; }
.checkbox-row { display: flex; align-items: center; gap: 8px; font-size: 14px; }
.preview-thumb {
  width: 100%;
  max-height: 220px;
  background: var(--cream);
  border: 1px solid var(--line);
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
  margin-top: 8px;
}
.preview-thumb img, .preview-thumb video { max-width: 100%; max-height: 220px; border-radius: 8px; }

/* ============= Toast ============= */
.toast {
  position: fixed;
  left: 50%; top: 24px;
  transform: translateX(-50%) translateY(-16px);
  background: var(--ink);
  color: #fff;
  border: none;
  border-radius: 14px;
  box-shadow: 0 12px 32px -8px rgba(59,50,40,.4);
  padding: 12px 22px;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 600;
  z-index: 200;
  opacity: 0;
  pointer-events: none;
  transition: transform .22s ease, opacity .22s ease;
}
.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}
.toast.success { background: linear-gradient(135deg, #6FC08D, var(--green)); }
.toast.error   { background: linear-gradient(135deg, #EF96AE, var(--pink-deep)); }
.toast.info    { background: linear-gradient(135deg, #6FB4DC, var(--blue)); }

/* 留言未读红点角标（A 方案） */
.msg-badge {
  position: absolute; top: 8px; right: 10px;
  min-width: 18px; height: 18px; padding: 0 5px;
  background: var(--pink-deep);
  color: #fff; border: 2px solid #fff;
  border-radius: 999px; font-size: 10px; line-height: 14px; text-align: center;
  font-family: var(--font-num); font-weight: 700;
  box-shadow: 0 2px 6px rgba(215,95,134,.45);
  z-index: 2; pointer-events: none;
}
.msg-badge[hidden] { display: none; }
.bn-item .msg-badge { top: 1px; right: 50%; transform: translateX(16px); }
/* 系统通知开关按钮（B 方案） */
#msgNotifyToggle.active { background: linear-gradient(135deg, #F08A5C, var(--primary)); color: #fff; border-color: transparent; box-shadow: 0 4px 12px -4px rgba(229,107,58,.45); }

/* ============= Bottom Nav (移动) ============= */
.bottom-nav {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  display: none;
  background: rgba(255,252,248,.92);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-top: 1px solid var(--line);
  z-index: 50;
  padding: 5px 0 calc(5px + env(safe-area-inset-bottom)) 0;
}
.bn-item {
  position: relative;
  flex: 1;
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  background: none; border: none;
  padding: 6px 2px;
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
  transition: color .16s;
  border-radius: 10px;
}
.bn-item span { font-size: 18px; }
.bn-item.active { color: var(--primary-deep); }
.bn-item.active span { transform: scale(1.12); }

/* ============= 响应式 ============= */
@media (max-width: 900px) {
  .app {
    grid-template-columns: 1fr;
    grid-template-areas: "header" "content";
    padding: 10px;
    padding-bottom: 74px;
    gap: 10px;
  }
  .sidebar { display: none; }
  .dash-grid { grid-template-columns: 1fr; }
  .bottom-nav { display: flex; }
  .app-header { padding: 6px 12px; height: 60px; border-radius: 14px; }
  .brand-title { font-size: 15px; }
  .brand-sub { display: none; }
  .puffer-logo { width: 38px; height: 38px; }
  .logo { width: 38px; height: 38px; border-radius: 12px; }
  .stat-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .page-title { font-size: 19px; }
  .search-wrap { width: 100%; }
  .week-strip { gap: 5px; }
  .wd { padding: 8px 2px; font-size: 12px; }
  .wd .wd-name { font-size: 12px; }
  .wd .wd-plan { font-size: 10px; }
}

@media (max-width: 480px) {
  .stat-grid { grid-template-columns: 1fr 1fr; }
  .stat-row { grid-template-columns: 1fr 1fr; gap: 10px; }
  .page-head { flex-direction: column; align-items: flex-start; }
  .page-actions { width: 100%; }
  .seg-btn { padding: 6px 11px; font-size: 12px; }
  .mascot-hero { width: 100%; }
  .mascot-bubble { max-width: none; }
  .train-item { flex-direction: column; }
  .train-date { width: 100%; }
}

@media (min-width: 1200px) {
  .dash-grid { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
}

/* ============= 补充（动态生成类） ============= */
.msg-empty { text-align: center; padding: 30px 10px; color: var(--muted); font-size: 14px; }
.msg-time { font-size: 11px; color: var(--muted); }
.gm-del { flex: none !important; padding: 4px 10px !important; }

/* ============= 心愿墙 ============= */
.wish-hero {
  display: flex; align-items: center; gap: 14px;
  padding: 16px 20px; margin-bottom: 20px;
  background:
    radial-gradient(circle at 90% 10%, rgba(229,107,58,.10), transparent 42%),
    linear-gradient(135deg, #FFF9F1, #FFF1E4);
  border-radius: 18px;
}
.wish-hero .wh-icon { font-size: 30px; flex-shrink: 0; }
.wish-hero .wh-text { font-size: 13.5px; color: var(--ink-soft); line-height: 1.7; }
.wish-hero .wh-text b { color: var(--primary-deep); font-weight: 700; }

.wish-wall {
  columns: 3;
  column-gap: 16px;
}
/* 响应式：放在 .wish-wall 基础规则之后，避免被后面的 columns:3 覆盖 */
@media (max-width: 900px) {
  .wish-wall { columns: 2; column-gap: 12px; }
  /* 移动端底栏遮挡：滚动内容底部多留安全空间 */
  .content { padding-bottom: 112px; }
  /* 移动端：隐藏会飘到标题区中间的背景小河豚，避免视觉干扰 */
  .mote-puff.p2 { display: none; }
}
@media (max-width: 480px) {
  .wish-wall { columns: 1; }
  .wish-hero .wh-text { font-size: 15px; }
}
.wish-note {
  break-inside: avoid;
  margin-bottom: 16px;
  padding: 24px 20px 16px;
  position: relative;
  border-radius: 6px 18px 14px 6px;
  box-shadow: 0 6px 20px -8px rgba(59,50,40,.22);
  transform: rotate(var(--tilt, 0deg));
  transition: transform .22s ease, box-shadow .25s ease, z-index 0s;
  animation: wishIn .35s ease backwards;
  display: flex;
  flex-direction: column;
  text-align: center;
  min-height: 152px;
}
.wish-note:hover {
  transform: rotate(0deg) translateY(-5px) scale(1.02);
  box-shadow: 0 16px 34px -12px rgba(59,50,40,.32);
  z-index: 3;
}
@keyframes wishIn { from { opacity: 0; transform: rotate(var(--tilt,0deg)) translateY(14px) scale(.96); } to { opacity: 1; transform: rotate(var(--tilt,0deg)) translateY(0) scale(1); } }
/* 胶带 */
.wish-note::before {
  content: '';
  position: absolute; top: -9px; left: 50%; transform: translateX(-50%) rotate(-2deg);
  width: 72px; height: 17px;
  background: rgba(255,255,255,.55);
  border-radius: 2px;
  box-shadow: 0 1px 3px rgba(59,50,40,.08);
}
.wish-icon { font-size: 26px; line-height: 1; margin-bottom: 2px; }
.wish-text {
  font-size: 14.5px; line-height: 1.75; color: #4A3B2E; font-weight: 500;
  margin-top: 6px; word-break: break-word; white-space: pre-wrap;
}
.wish-foot {
  display: flex; align-items: center; gap: 8px;
  margin-top: auto; padding-top: 12px;
  border-top: 1px dashed rgba(74,59,46,.22);
  font-size: 11.5px; font-weight: 600; color: rgba(74,59,46,.62);
  text-align: left;
}
.wish-who { display: inline-flex; align-items: center; gap: 3px; }
.wish-date { margin-left: auto; opacity: .75; }
.wish-del {
  border: none; cursor: pointer;
  width: 22px; height: 22px; border-radius: 50%;
  background: rgba(255,255,255,.6); color: rgba(74,59,46,.55);
  font-size: 11px; line-height: 1;
  display: inline-flex; align-items: center; justify-content: center;
  transition: background .15s, color .15s, transform .12s;
}
.wish-del:hover { background: rgba(215,95,134,.85); color: #fff; transform: scale(1.1); }
/* 心愿点亮：TA 看到后的反馈 */
.wish-lit-btn {
  border: 1px solid rgba(229,107,58,.45); cursor: pointer;
  background: rgba(255,255,255,.75); color: var(--primary-deep);
  font-size: 11px; font-weight: 700;
  border-radius: 999px; padding: 3px 9px;
  transition: background .15s, transform .12s, box-shadow .15s;
}
.wish-lit-btn:hover { background: var(--primary); color: #fff; transform: scale(1.06); box-shadow: 0 3px 10px -3px rgba(229,107,58,.5); }
.wish-lit {
  display: inline-flex; align-items: center; gap: 3px;
  color: #D96C8F; font-weight: 700;
  background: rgba(255,255,255,.65); border-radius: 999px; padding: 3px 9px;
}
/* 便签底色 */
.note-peach { background: linear-gradient(160deg, #FFE9D8, #FFD9BC); }
.note-mint  { background: linear-gradient(160deg, #DFF3E9, #C8EBD9); }
.note-sky   { background: linear-gradient(160deg, #DFF0FB, #C4E2F6); }
.note-lilac { background: linear-gradient(160deg, #EDE7FB, #DBD2F5); }
.note-lemon { background: linear-gradient(160deg, #FFF7DA, #FFEDBA); }
/* 写心愿弹窗 */
.wish-icon-pick { display: flex; flex-wrap: wrap; gap: 8px; }
.wish-icon-opt {
  width: 42px; height: 42px;
  border: 1px solid var(--line); background: var(--surface);
  border-radius: 12px; font-size: 20px; cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
  transition: transform .12s, border-color .15s, background .15s, box-shadow .15s;
}
.wish-icon-opt:hover { transform: translateY(-2px); border-color: #E4D5C4; }
.wish-icon-opt.sel {
  background: var(--primary-soft); border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(229,107,58,.16);
  transform: translateY(-2px) scale(1.06);
}
/* switch 开关 */
.switch { display: inline-flex; align-items: center; gap: 9px; cursor: pointer; font-size: 14px; color: var(--ink); user-select: none; }
.switch input { position: absolute; opacity: 0; width: 0; height: 0; }
.switch span {
  position: relative; width: 42px; height: 24px;
  background: #E4DACB; border-radius: 999px;
  transition: background .2s ease;
  flex-shrink: 0;
}
.switch span::after {
  content: ''; position: absolute; top: 3px; left: 3px;
  width: 18px; height: 18px; background: #fff; border-radius: 50%;
  box-shadow: 0 1px 3px rgba(59,50,40,.25);
  transition: transform .2s ease;
}
.switch input:checked + span { background: linear-gradient(135deg, #F08A5C, var(--primary)); }
.switch input:checked + span::after { transform: translateX(18px); }
/* 空状态 */
.wish-empty {
  column-span: all;
  text-align: center; padding: 56px 20px 48px;
  background:
    radial-gradient(circle at 50% 0%, rgba(229,107,58,.08), transparent 60%),
    rgba(255,255,255,.6);
  border: 1.5px dashed var(--line);
  border-radius: 20px;
  display: flex; flex-direction: column; align-items: center; gap: 0;
}
.we-glow {
  width: 84px; height: 84px; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #FFF3E2, var(--primary-soft));
  box-shadow: 0 0 0 10px rgba(229,107,58,.06), 0 10px 26px -10px rgba(229,107,58,.35);
  display: flex; align-items: center; justify-content: center;
  animation: weFloat 3.2s ease-in-out infinite;
}
@keyframes weFloat { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-7px); } }
.we-icon { font-size: 38px; line-height: 1; filter: drop-shadow(0 4px 10px rgba(229,107,58,.35)); }
.we-title {
  font-family: var(--font-head); font-size: 19px; font-weight: 700; color: var(--ink);
  margin-top: 20px;
}
.we-sub {
  font-size: 13.5px; color: var(--muted); line-height: 1.9;
  margin: 8px 0 22px;
}
.wish-empty .pixel-btn { padding: 11px 26px; font-size: 14.5px; }

/* ============= 待办排版优化 ============= */
.todo-item { align-items: flex-start; }
.todo-check { margin-top: 2px; }
.ti-main {
  flex: 1; min-width: 0;
  display: flex; flex-direction: column; gap: 6px;
}
.ti-text {
  font-size: 14.5px; line-height: 1.65; color: var(--ink);
  word-break: break-word; white-space: pre-wrap;
  font-weight: 500;
}
.todo-item.done .ti-text { color: var(--muted); }
.ti-meta {
  display: flex; flex-wrap: wrap; align-items: center; gap: 6px;
}
.ti-date {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 11.5px; font-weight: 600; color: var(--ink-soft);
  background: var(--cream); border: 1px solid var(--line);
  border-radius: 999px; padding: 2px 9px;
}
.ti-prio {
  font-family: var(--font-body);
  font-size: 11px; font-weight: 700;
  padding: 2px 10px;
  border-radius: 999px;
  letter-spacing: .3px;
}
.ti-actions { display: flex; gap: 6px; margin-top: 0; flex-shrink: 0; }
.ti-actions button { width: 32px; height: 32px; }

/* ============= 高端质感精修 ============= */
/* 页面标题渐变装饰线 */
.page-title { position: relative; padding-bottom: 10px; }
.page-title::after {
  content: '';
  position: absolute; left: 0; bottom: 0;
  width: 44px; height: 3px; border-radius: 3px;
  background: linear-gradient(90deg, var(--primary), var(--primary-light));
}
/* 数字渐变（普通统计卡） */
.stat-value { background: linear-gradient(180deg, #5A4A3B, var(--ink)); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.stat-orange .stat-value, .stat-brown .stat-value, .water-mini .stat-value { background: none; -webkit-text-fill-color: currentColor; }
/* 主按钮内高光 */
.pixel-btn.primary { box-shadow: inset 0 1px 0 rgba(255,255,255,.28), 0 6px 16px -6px rgba(229,107,58,.5); }
/* 滚动条 */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #E2D5C3; border-radius: 8px; border: 2px solid var(--bg); }
::-webkit-scrollbar-thumb:hover { background: #D3C2AB; }
::selection { background: rgba(229,107,58,.22); }
/* 底部导航 7 项适配 */
.bn-item small { font-size: 10px; }
.bn-item span { font-size: 17px; }
/* modal 上浮动画 */
.modal { animation: modalUp .28s cubic-bezier(.2,.8,.3,1) backwards; }
@keyframes modalUp { from { opacity: 0; transform: translateY(26px) scale(.97); } to { opacity: 1; transform: none; } }
/* ===== 待办日历合并 ===== */
#todoDayBar { margin: 14px 0 12px; }
.todo-day-bar {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding: 10px 14px; border-radius: 14px;
  background: linear-gradient(135deg, #FFF3E6, #FFE9D8);
  border: 1px solid #F0D9C2;
}
.tdb-label { font-family: var(--font-head); font-size: 15px; font-weight: 700; color: var(--primary-deep); margin-right: auto; }
.cal-bottom { display: flex; justify-content: center; margin-top: 12px; }
.cal-top .cal-title { font-size: 16px; }

/* ===== 每日星座 ===== */
.horo-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.horo-card { padding: 18px; }
.horo-head { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.horo-icon {
  width: 52px; height: 52px; flex-shrink: 0; display: flex; align-items: center; justify-content: center;
  font-size: 28px; border-radius: 14px; background: var(--cream); border: 1px solid var(--line);
}
.horo-card.sign-gemini .horo-icon { background: #E8F1FB; border-color: #C4D9F0; }
.horo-card.sign-libra  .horo-icon { background: #FDEBF1; border-color: #F2C3D3; }
.horo-name { font-family: var(--font-head); font-size: 17px; font-weight: 700; color: var(--ink); }
.horo-date { font-size: 11px; color: var(--muted); font-family: var(--font-body); font-weight: 500; margin-left: 4px; }
.horo-tag { font-size: 12px; color: var(--ink-soft); margin-top: 2px; }
.horo-stars { margin-left: auto; font-size: 14px; letter-spacing: 1px; color: #F2B45C; }
.horo-stars .off { color: #E5D9C9; }
.horo-row { display: flex; gap: 10px; align-items: baseline; padding: 7px 0; border-top: 1px dashed var(--line); font-size: 13.5px; line-height: 1.65; color: var(--ink-soft); }
.horo-row:first-of-type { border-top: none; }
.hr-label {
  flex-shrink: 0; width: 34px; text-align: center; font-size: 11px; font-weight: 700; color: var(--primary-deep);
  background: #FFEFE2; border-radius: 999px; padding: 2px 0;
}
.horo-foot { margin-top: 10px; font-size: 12px; color: var(--muted); }
.horo-note { margin-top: 10px; text-align: center; font-size: 12.5px; color: var(--ink-soft); }
@media (max-width: 640px) {
  .horo-grid { grid-template-columns: 1fr; }
}

/* ===== 每日祈福抽签 ===== */
.fortune-card { text-align: center; }
.fortune-body { padding: 20px 16px; min-height: 130px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; }
.fortune-bamboo { font-size: 64px; line-height: 1; }
.fortune-pick { margin-top: 4px; }
.fortune-done { font-size: 13.5px; color: var(--ink-soft); line-height: 1.7; max-width: 420px; }
.ft-sign {
  display: inline-block; padding: 4px 14px; border-radius: 999px; font-size: 14px; font-weight: 700;
}
.ft-sign.lv-upper { background: linear-gradient(135deg,#FFF3D6,#FFDF9E); color:#8A5A00; border:1px solid #F0C768; }
.ft-sign.lv-good  { background: linear-gradient(135deg,#FFEFE2,#FFD9BC); color:#C0561F; border:1px solid #F0B98F; }
.ft-sign.lv-mid   { background: linear-gradient(135deg,#F0F6EC,#DCEBD3); color:#4C7A38; border:1px solid #BCD6AB; }
.ft-sign.lv-low   { background: linear-gradient(135deg,#EFEFEF,#DDDDDD); color:#6B6B6B; border:1px solid #CCCCCC; }
.ft-text { font-family: var(--font-head); font-size: 17px; font-weight: 700; color: var(--ink); line-height: 1.6; max-width: 420px; }
.ft-tip { font-size: 13px; color: var(--ink-soft); line-height: 1.7; max-width: 420px; }
.ft-date { font-size: 11.5px; color: var(--muted); }
@keyframes fortuneShake {
  0%,100% { transform: rotate(0); }
  20% { transform: rotate(-12deg) translateX(-2px); }
  40% { transform: rotate(10deg) translateX(2px); }
  60% { transform: rotate(-8deg); }
  80% { transform: rotate(6deg); }
}
.fortune-bamboo.shake { animation: fortuneShake .7s ease; }

/* 喝水分人：各自记录 */
.water-mini-ta { font-size: 11px; color: var(--ink-soft); margin-top: 3px; font-weight: 600; }

/* 祈福抽签：两人双栏 */
.fortune-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; width: 100%; }
.fortune-col { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 14px 12px; border-radius: 14px; background: var(--cream); border: 1px solid var(--line); }
.fortune-col.ta-col { background: #FDF3F6; border-color: #F2D5DE; }
.fortune-title { font-family: var(--font-head); font-size: 14px; font-weight: 700; color: var(--ink-soft); margin-bottom: 2px; }
@media (max-width: 480px) { .fortune-grid { grid-template-columns: 1fr; } }
