/* ============ 今日简报 ============ */

:root {
  --bg: #F6F5F2;
  --bg-2: #FFFFFF;
  --card: #FFFFFF;
  --ink: #17171A;
  --ink-2: #55555C;
  --ink-3: #8E8E95;
  --line: #EAE7E1;
  --line-2: #F1EFEA;
  --accent: #D4552F;
  --accent-soft: #FCEDE7;
  --up: #C0392B;
  --down: #1F8A5B;
  --rain: #3A6EA8;
  --rain-soft: rgba(58, 110, 168, .10);
  --radius: 18px;
  --shadow-sm: 0 1px 2px rgba(23, 23, 26, .05);
  --shadow: 0 2px 4px rgba(23, 23, 26, .04), 0 12px 28px -16px rgba(23, 23, 26, .18);
  --bar-h: 52px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #101012;
    --bg-2: #16161A;
    --card: #1A1A1E;
    --ink: #F3F2EE;
    --ink-2: #A8A8B0;
    --ink-3: #75757E;
    --line: #2A2A30;
    --line-2: #232329;
    --accent: #F07A52;
    --accent-soft: #2E1D18;
    --up: #F0736A;
    --down: #4ECB9B;
    --rain: #7FB0E8;
    --rain-soft: rgba(127, 176, 232, .14);
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, .3);
    --shadow: 0 2px 4px rgba(0, 0, 0, .3), 0 12px 28px -16px rgba(0, 0, 0, .6);
  }
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB",
    "Noto Sans SC", "Microsoft YaHei", system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* ============ 顶栏 ============ */

.topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 60;
  padding-top: env(safe-area-inset-top);
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: saturate(180%) blur(16px);
  -webkit-backdrop-filter: saturate(180%) blur(16px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s ease;
}

.topbar.scrolled { border-bottom-color: var(--line); }

.bar-inner {
  max-width: 680px;
  margin: 0 auto;
  height: var(--bar-h);
  padding: 0 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.bar-brand {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: .02em;
  color: var(--ink);
  white-space: nowrap;
}

.bar-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 18%, transparent);
}

.tabs {
  display: flex;
  gap: 2px;
  background: var(--line-2);
  padding: 3px;
  border-radius: 999px;
}

.tab {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--ink-3);
  font-family: inherit;
  font-size: 13px;
  font-weight: 500;
  padding: 5px 13px;
  border-radius: 999px;
  cursor: pointer;
  transition: all .22s cubic-bezier(.4, 0, .2, 1);
  white-space: nowrap;
}

.tab.active {
  background: var(--card);
  color: var(--ink);
  box-shadow: var(--shadow-sm);
  font-weight: 600;
}

/* ============ 面板 ============ */

main { padding-top: calc(var(--bar-h) + env(safe-area-inset-top)); }

.pane { scroll-margin-top: calc(var(--bar-h) + env(safe-area-inset-top)); }

.pane-inner {
  max-width: 680px;
  margin: 0 auto;
  padding: 0 20px calc(96px + env(safe-area-inset-bottom));
}

/* ============ Hero ============ */

.hero { padding: 26px 0 10px; position: relative; }

.hero-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 12.5px;
  letter-spacing: .04em;
  color: var(--ink-3);
  font-variant-numeric: tabular-nums;
}

.hero-meta .issue { color: var(--accent); font-weight: 600; }

.dot {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: currentColor;
  opacity: .45;
  flex: 0 0 auto;
}

h1 {
  margin: 12px 0 0;
  font-family: "Songti SC", "Noto Serif SC", "Source Han Serif SC", Georgia, serif;
  font-size: 38px;
  line-height: 1.16;
  font-weight: 600;
  letter-spacing: -.01em;
}

.lede {
  margin: 12px 0 0;
  font-size: 15px;
  line-height: 1.75;
  color: var(--ink-2);
}

/* ============ 天气 ============ */

.weather-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 22px;
}

.wx {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 15px 16px 13px;
  box-shadow: var(--shadow-sm);
  position: relative;
  overflow: hidden;
}

.wx-city {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12.5px;
  color: var(--ink-3);
  letter-spacing: .02em;
}

.wx-now {
  display: flex;
  align-items: baseline;
  gap: 5px;
  margin-top: 4px;
}

.wx-temp {
  font-size: 32px;
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -.02em;
  font-variant-numeric: tabular-nums;
}

.wx-cond { font-size: 13px; color: var(--ink-2); }

.wx-range {
  margin-top: 3px;
  font-size: 12px;
  color: var(--ink-3);
  font-variant-numeric: tabular-nums;
}

.wx-tip {
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--line-2);
  font-size: 12px;
  line-height: 1.55;
  color: var(--ink-2);
}

.wx-rain {
  position: absolute;
  right: 14px;
  top: 14px;
  font-size: 11px;
  color: var(--rain);
  background: var(--rain-soft);
  padding: 1px 7px;
  border-radius: 999px;
  font-variant-numeric: tabular-nums;
}

/* ============ 区块 ============ */

.block { margin-top: 32px; }

.block-head {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 12px;
}

.block-head .bar {
  width: 3px;
  height: 14px;
  border-radius: 2px;
  background: var(--bc, var(--accent));
}

.block-head h3 {
  margin: 0;
  font-size: 15.5px;
  font-weight: 600;
  letter-spacing: .01em;
}

.block-head .count {
  font-size: 11.5px;
  color: var(--ink-3);
  font-variant-numeric: tabular-nums;
}

/* ============ 快讯 ============ */

.flashes {
  list-style: none;
  margin: 0;
  padding: 0;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.flash { border-top: 1px solid var(--line-2); }
.flash:first-child { border-top: 0; }

.flash-head {
  display: flex;
  gap: 10px;
  padding: 11px 16px;
  cursor: pointer;
  align-items: flex-start;
  transition: background .16s ease;
}

.flash-head:active { background: var(--line-2); }

.flash-idx {
  flex: 0 0 auto;
  font-size: 11.5px;
  color: var(--ink-3);
  font-variant-numeric: tabular-nums;
  width: 15px;
  padding-top: 3px;
  opacity: .75;
}

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

.flash-title {
  font-size: 14.5px;
  font-weight: 500;
  line-height: 1.62;
  color: var(--ink);
}

.flash-meta {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-top: 3px;
  font-size: 11.5px;
  color: var(--ink-3);
}

.flash-tag {
  color: var(--accent);
  border: 1px solid color-mix(in srgb, var(--accent) 40%, transparent);
  border-radius: 4px;
  padding: 0 4px;
  font-size: 10px;
  letter-spacing: .04em;
}

.chev {
  flex: 0 0 auto;
  width: 16px;
  height: 16px;
  margin-top: 3px;
  color: var(--ink-3);
  transition: transform .3s cubic-bezier(.4, 0, .2, 1);
  opacity: .7;
}

.flash.open .chev { transform: rotate(180deg); }

.flash-body {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows .34s cubic-bezier(.4, 0, .2, 1);
}

.flash.open .flash-body { grid-template-rows: 1fr; }

.flash-body > .inner { overflow: hidden; }

.flash-detail {
  padding: 12px 16px 14px 41px;
  font-size: 13.5px;
  line-height: 1.78;
  color: var(--ink-2);
  border-top: 1px dashed var(--line);
  margin: 0 16px 0 0;
}

.flash-detail .src {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 9px;
  font-size: 12px;
  color: var(--ink-3);
}

.flash-detail .src a {
  color: var(--accent);
  text-decoration: none;
  border-bottom: 1px solid color-mix(in srgb, var(--accent) 35%, transparent);
}

/* ============ 演出 ============ */

.event-list {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.ev {
  display: flex;
  gap: 13px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 15px;
  padding: 14px 16px;
  box-shadow: var(--shadow-sm);
  text-decoration: none;
  color: inherit;
}

.ev-date {
  flex: 0 0 auto;
  width: 46px;
  text-align: center;
  border-right: 1px solid var(--line-2);
  padding-right: 12px;
}

.ev-day {
  font-size: 19px;
  font-weight: 600;
  line-height: 1.2;
  font-variant-numeric: tabular-nums;
  letter-spacing: -.01em;
}

.ev-mon {
  font-size: 10.5px;
  color: var(--ink-3);
  letter-spacing: .04em;
}

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

.ev-name {
  font-size: 14.5px;
  font-weight: 600;
  line-height: 1.5;
}

.ev-info {
  margin-top: 3px;
  font-size: 12px;
  color: var(--ink-3);
  line-height: 1.55;
}

.ev-flag {
  display: inline-block;
  margin-top: 6px;
  font-size: 10.5px;
  letter-spacing: .03em;
  padding: 1px 7px;
  border-radius: 5px;
  background: var(--accent-soft);
  color: var(--accent);
  font-weight: 500;
}

.ev-flag.hot {
  background: color-mix(in srgb, #C0392B 12%, transparent);
  color: #C0392B;
}

/* 每条演出：内容 + 垃圾桶 */

.ev-item {
  position: relative;
  transition: opacity .15s ease, transform .15s ease;
}

.ev-item .ev { padding-right: 46px; }

.ev-item.gone {
  opacity: 0;
  transform: translateX(10px);
}

.ev-trash {
  position: absolute;
  right: 8px;
  top: 8px;
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: transparent;
  color: var(--ink-3);
  cursor: pointer;
  opacity: .55;
  transition: all .16s ease;
  -webkit-tap-highlight-color: transparent;
}

.ev-trash svg { width: 15px; height: 15px; }

.ev-trash:hover,
.ev-trash:active {
  opacity: 1;
  color: #C0392B;
  background: color-mix(in srgb, #C0392B 9%, transparent);
}

.ev-region {
  display: inline-block;
  margin-right: 5px;
  padding: 0 5px;
  font-size: 10px;
  line-height: 1.6;
  border-radius: 4px;
  background: var(--line-2);
  color: var(--ink-3);
  vertical-align: 1px;
}

.ev-region.out {
  background: color-mix(in srgb, #6B5BD2 13%, transparent);
  color: #5A4AC0;
}

.ev-blocked {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
  padding: 7px 12px;
  border: 1px dashed var(--line);
  border-radius: 11px;
  font-size: 11.5px;
  color: var(--ink-3);
  line-height: 1.5;
}

.ev-blocked[hidden] { display: none; }
.ev-blocked b { color: var(--ink-2); font-weight: 600; }

.ev-blocked i {
  font-style: normal;
  color: var(--ink-3);
  display: inline-block;
  max-width: 100%;
}

.ev-blocked button {
  flex: 0 0 auto;
  margin-left: auto;
  padding: 3px 9px;
  font-size: 11px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--card);
  color: var(--ink-2);
  cursor: pointer;
}

.ev-hint {
  margin: 8px 2px 0;
  font-size: 11px;
  color: var(--ink-3);
  line-height: 1.5;
}

@media (prefers-color-scheme: dark) {
  .ev-region.out {
    background: rgba(124, 108, 232, .26);
    color: #B6ACFF;
  }

  .ev-trash { opacity: .62; }

  .ev-trash:hover,
  .ev-trash:active {
    color: #F0736A;
    background: rgba(240, 115, 106, .15);
  }

  .ev-blocked button { background: #232329; }
}

.empty-note {
  background: var(--card);
  border: 1px dashed var(--line);
  border-radius: 15px;
  padding: 18px 16px;
  font-size: 13px;
  line-height: 1.7;
  color: var(--ink-3);
}

/* ============ 优惠 ============ */

.deal-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  margin-bottom: 9px;
}

.deal-head {
  padding: 12px 16px 8px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .04em;
  color: var(--ink-3);
}

.deal-row {
  display: flex;
  gap: 10px;
  padding: 10px 16px;
  border-top: 1px solid var(--line-2);
  align-items: flex-start;
}

.deal-brand {
  flex: 0 0 auto;
  width: 62px;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.55;
}

.deal-body { flex: 1 1 auto; min-width: 0; }

.deal-text {
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--ink);
}

.deal-cond {
  margin-top: 2px;
  font-size: 11.5px;
  color: var(--ink-3);
  line-height: 1.55;
}

/* 快餐：品牌收一行，点开展开每一项 */

.bf { border-top: 1px solid var(--line-2); }

.bf-head {
  display: flex;
  align-items: center;
  gap: 9px;
  width: 100%;
  padding: 11px 16px;
  border: none;
  background: transparent;
  font: inherit;
  color: inherit;
  text-align: left;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.bf-brand {
  flex: 0 0 auto;
  font-size: 13.5px;
  font-weight: 600;
  line-height: 1.5;
}

.bf-sum {
  flex: 1 1 auto;
  min-width: 0;
  font-size: 12px;
  color: var(--ink-3);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.bf-n {
  flex: 0 0 auto;
  font-size: 10.5px;
  color: var(--ink-3);
  background: var(--line-2);
  padding: 1px 7px;
  border-radius: 999px;
  font-variant-numeric: tabular-nums;
}

.bf-head .chev { margin-top: 0; }
.bf.open .chev { transform: rotate(180deg); }

.bf-body {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows .3s cubic-bezier(.4, 0, .2, 1);
}

.bf.open .bf-body { grid-template-rows: 1fr; }

.bf-inner { overflow: hidden; }

.bf-item {
  padding: 9px 16px 10px;
  border-top: 1px dashed var(--line-2);
}

.bf-text {
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--ink);
}

.bf-cond {
  margin-top: 2px;
  font-size: 11.5px;
  color: var(--ink-3);
  line-height: 1.55;
}

/* ============ 通用：下一部分 / 按钮 ============ */

.next-pane {
  display: block;
  width: 100%;
  margin: 30px 0 0;
  padding: 13px;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 13px;
  color: var(--ink-3);
  font-family: inherit;
  font-size: 13px;
  cursor: pointer;
  transition: all .18s ease;
}

.next-pane:active { background: var(--line-2); }

.foot-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px;
  margin-top: 12px;
  box-shadow: var(--shadow-sm);
}

.foot-card h3 { margin: 0 0 6px; font-size: 15px; font-weight: 600; }

.foot-card p {
  margin: 0 0 13px;
  font-size: 13px;
  line-height: 1.7;
  color: var(--ink-3);
}

.btn {
  appearance: none;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--ink);
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 500;
  padding: 9px 17px;
  border-radius: 10px;
  cursor: pointer;
  transition: all .18s ease;
}

.btn:active { transform: scale(.98); }
.btn.primary { background: var(--accent); border-color: var(--accent); color: #fff; }

.foot-note {
  margin-top: 22px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  font-size: 11.5px;
  line-height: 1.7;
  color: var(--ink-3);
}

.foot-note p { margin: 0 0 5px; }
.foot-note .sign { opacity: .7; letter-spacing: .04em; }

/* ============ 待办 ============ */

.todo-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px 0 18px;
}

.day-btn {
  appearance: none;
  border: 1px solid var(--line);
  background: var(--card);
  color: var(--ink-2);
  width: 38px;
  height: 38px;
  border-radius: 12px;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  transition: all .16s ease;
}

.day-btn:active { background: var(--line-2); }

.day-mid { text-align: center; }

.day-num {
  font-family: "Songti SC", Georgia, serif;
  font-size: 26px;
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -.01em;
  font-variant-numeric: tabular-nums;
}

.day-sub { font-size: 12px; color: var(--ink-3); letter-spacing: .03em; }
.day-sub.today { color: var(--accent); font-weight: 600; }

.todo-add {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
}

.todo-add input {
  flex: 1 1 auto;
  min-width: 0;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 13px;
  padding: 12px 15px;
  font-family: inherit;
  font-size: 15px;
  color: var(--ink);
  outline: none;
  transition: border-color .18s ease;
}

.todo-add input::placeholder { color: var(--ink-3); opacity: .8; }
.todo-add input:focus { border-color: var(--accent); }

.todo-add button {
  flex: 0 0 auto;
  width: 46px;
  border: 0;
  border-radius: 13px;
  background: var(--accent);
  color: #fff;
  font-size: 22px;
  font-weight: 300;
  line-height: 1;
  cursor: pointer;
  transition: transform .16s ease;
}

.todo-add button:active { transform: scale(.95); }

.todo-stat {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
  font-size: 11.5px;
  color: var(--ink-3);
  font-variant-numeric: tabular-nums;
}

.bar-track {
  flex: 1 1 auto;
  height: 4px;
  background: var(--line);
  border-radius: 999px;
  overflow: hidden;
}

.bar-fill {
  height: 100%;
  width: 0;
  background: var(--accent);
  border-radius: 999px;
  transition: width .35s cubic-bezier(.4, 0, .2, 1);
}

.todo-list {
  list-style: none;
  margin: 0;
  padding: 0;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.todo-list:empty { display: none; }

.todo-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 16px;
  border-top: 1px solid var(--line-2);
}

.todo-item:first-child { border-top: 0; }

.tick {
  flex: 0 0 auto;
  width: 21px;
  height: 21px;
  border: 1.6px solid var(--line);
  border-radius: 50%;
  background: transparent;
  cursor: pointer;
  margin-top: 2px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all .18s ease;
  padding: 0;
}

.tick svg { width: 12px; height: 12px; opacity: 0; transform: scale(.6); transition: all .18s ease; }

.todo-item.done .tick {
  background: var(--accent);
  border-color: var(--accent);
}

.todo-item.done .tick svg { opacity: 1; transform: scale(1); }

.todo-text {
  flex: 1 1 auto;
  font-size: 14.5px;
  line-height: 1.6;
  color: var(--ink);
  word-break: break-word;
  transition: color .18s ease;
}

.todo-item.done .todo-text {
  color: var(--ink-3);
  text-decoration: line-through;
  text-decoration-color: color-mix(in srgb, var(--ink-3) 50%, transparent);
}

.todo-del {
  flex: 0 0 auto;
  border: 0;
  background: transparent;
  color: var(--ink-3);
  font-size: 17px;
  line-height: 1;
  cursor: pointer;
  padding: 2px 2px 2px 8px;
  opacity: .45;
  transition: opacity .16s ease;
}

.todo-del:active { opacity: 1; }

.todo-empty {
  text-align: center;
  padding: 22px 0 4px;
  font-size: 13px;
  color: var(--ink-3);
  opacity: .85;
}

.todo-empty.hide { display: none; }

.tpl { margin-top: 26px; }

.tpl h4 {
  margin: 0 0 10px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .1em;
  color: var(--ink-3);
  text-transform: uppercase;
}

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

.tpl-btn {
  appearance: none;
  border: 1px solid var(--line);
  background: var(--card);
  color: var(--ink-2);
  font-family: inherit;
  font-size: 13px;
  padding: 8px 14px;
  border-radius: 11px;
  cursor: pointer;
  transition: all .16s ease;
}

.tpl-btn:active { background: var(--line-2); }

.tpl-hint {
  margin: 10px 0 0;
  font-size: 11.5px;
  color: var(--ink-3);
  line-height: 1.6;
}

/* ============ 学习 ============ */

.study-head { padding: 26px 0 0; }

.study-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--ink-3);
  letter-spacing: .03em;
}

.st-cat {
  color: var(--accent);
  font-weight: 600;
  background: var(--accent-soft);
  padding: 2px 9px;
  border-radius: 999px;
  font-size: 11.5px;
  letter-spacing: .04em;
}

.study-head h2 {
  margin: 12px 0 0;
  font-family: "Songti SC", "Noto Serif SC", Georgia, serif;
  font-size: 25px;
  line-height: 1.5;
  font-weight: 600;
  letter-spacing: -.005em;
}

.st-points {
  list-style: none;
  margin: 22px 0 0;
  padding: 0;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

.st-points li {
  position: relative;
  padding: 13px 18px 13px 34px;
  font-size: 14px;
  line-height: 1.78;
  color: var(--ink-2);
  border-top: 1px solid var(--line-2);
}

.st-points li:first-child { border-top: 0; }

.st-points li::before {
  content: "";
  position: absolute;
  left: 17px;
  top: 22px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
  opacity: .55;
}

.st-tip {
  margin-top: 14px;
  background: var(--accent-soft);
  border-radius: 15px;
  padding: 14px 16px;
  display: flex;
  gap: 11px;
  align-items: flex-start;
}

.st-tip-label {
  flex: 0 0 auto;
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: .06em;
  color: var(--accent);
  border: 1px solid color-mix(in srgb, var(--accent) 40%, transparent);
  border-radius: 5px;
  padding: 2px 6px;
  margin-top: 2px;
}

.st-tip p {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.75;
  color: var(--ink-2);
}

.st-basis {
  margin-top: 12px;
  font-size: 11.5px;
  line-height: 1.7;
  color: var(--ink-3);
}

.st-progress {
  margin-top: 20px;
  font-size: 12px;
  color: var(--ink-3);
}

.st-progress b { color: var(--accent); font-variant-numeric: tabular-nums; }

/* ============ 预警条 ============ */

.alerts {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 18px;
}

.alert {
  display: flex;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid;
  align-items: flex-start;
}

.alert.warn {
  background: #FDF6E7;
  border-color: #EFD9A8;
}

.alert.danger {
  background: #FCEDE7;
  border-color: #F0C3AE;
}

.alert-lv {
  flex: 0 0 auto;
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: .04em;
  padding: 2px 7px;
  border-radius: 5px;
  margin-top: 1px;
  color: #8A5A00;
  background: #F6E2B4;
}

.alert.danger .alert-lv {
  color: #B03A17;
  background: #F7D2C2;
}

.alert-main { flex: 1 1 auto; min-width: 0; }
.alert-t { font-size: 13.5px; font-weight: 600; line-height: 1.55; color: #3B2B12; }
.alert-d { margin-top: 3px; font-size: 12px; line-height: 1.62; color: #6B5637; }

@media (prefers-color-scheme: dark) {
  .alert.warn { background: #2B2318; border-color: #4A3A22; }
  .alert.danger { background: #2E1E19; border-color: #4C2C22; }
  .alert-lv { background: #4A3A18; color: #F1C978; }
  .alert.danger .alert-lv { background: #4A271C; color: #F3A98C; }
  .alert-t { color: #F0E6D4; }
  .alert-d { color: #C0AF95; }
}

/* ============ 自驾出行 ============ */

.drive {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

.drv-row {
  display: flex;
  gap: 12px;
  padding: 12px 16px;
  border-top: 1px solid var(--line-2);
  align-items: flex-start;
}

.drv-row:first-child { border-top: 0; }

.drv-k {
  flex: 0 0 auto;
  width: 30px;
  font-size: 12px;
  color: var(--ink-3);
  padding-top: 2px;
  letter-spacing: .02em;
}

.drv-v { flex: 1 1 auto; min-width: 0; }

.drv-main {
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--ink);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}

.drv-main b { font-variant-numeric: tabular-nums; font-weight: 600; }

.drv-unit { font-size: 11px; color: var(--ink-3); }

.drv-tag {
  font-size: 10px;
  font-weight: 600;
  padding: 1px 7px;
  border-radius: 5px;
  letter-spacing: .03em;
}

.drv-tag.ok { color: #1F7A4D; background: rgba(31, 122, 77, .1); }
.drv-tag.bad { color: #C0392B; background: rgba(192, 57, 43, .1); }

.drv-note {
  margin-top: 3px;
  font-size: 11.5px;
  line-height: 1.6;
  color: var(--ink-3);
}

.drv-note a { color: var(--accent); text-decoration: none; }

/* ============ 学习：点赞 / 收藏入口 ============ */

.like-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 20px;
}

.like-btn {
  appearance: none;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid var(--line);
  background: var(--card);
  color: var(--ink-2);
  font-family: inherit;
  font-size: 13px;
  font-weight: 500;
  padding: 9px 15px;
  border-radius: 999px;
  cursor: pointer;
  transition: all .18s ease;
}

.like-btn svg { width: 16px; height: 16px; transition: transform .2s ease; }

.like-btn:active { transform: scale(.97); }

.like-btn.on {
  color: var(--accent);
  border-color: color-mix(in srgb, var(--accent) 42%, transparent);
  background: var(--accent-soft);
}

.like-btn.on svg { fill: currentColor; transform: scale(1.06); }

.collect-link {
  appearance: none;
  margin-left: auto;
  border: 0;
  background: transparent;
  color: var(--ink-3);
  font-family: inherit;
  font-size: 12.5px;
  cursor: pointer;
  padding: 6px 0;
}

.collect-link b { color: var(--accent); font-variant-numeric: tabular-nums; }

.like-hint {
  margin: 10px 0 0;
  font-size: 11.5px;
  line-height: 1.65;
  color: var(--ink-3);
}

/* ============ 生活小技巧 ============ */

.tips { display: flex; flex-direction: column; gap: 9px; }

.tip {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 15px;
  padding: 14px 16px 15px;
  box-shadow: var(--shadow-sm);
}

.tip-head {
  display: flex;
  align-items: center;
  gap: 8px;
}

.tip-tag {
  flex: 0 0 auto;
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: .04em;
  color: #2F7D5D;
  background: rgba(47, 125, 93, .1);
  padding: 2px 7px;
  border-radius: 5px;
}

.tip-head h4 {
  flex: 1 1 auto;
  margin: 0;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.5;
}

.tip-like {
  flex: 0 0 auto;
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--ink-3);
  padding: 2px;
  cursor: pointer;
  opacity: .55;
  transition: all .18s ease;
}

.tip-like svg { width: 17px; height: 17px; }

.tip-like.on { color: var(--accent); opacity: 1; }
.tip-like.on svg { fill: currentColor; }

.tip p {
  margin: 7px 0 0;
  font-size: 13px;
  line-height: 1.72;
  color: var(--ink-2);
}

@media (prefers-color-scheme: dark) {
  .tip-tag { color: #6FC79B; background: rgba(111, 199, 155, .13); }
}

/* ============ 本周复盘 ============ */

.review {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 6px 16px 14px;
  box-shadow: var(--shadow-sm);
}

.rv-row {
  display: flex;
  gap: 12px;
  padding: 10px 0;
  border-top: 1px solid var(--line-2);
  font-size: 13px;
  align-items: baseline;
}

.rv-row:first-child { border-top: 0; }

.rv-k { flex: 0 0 auto; width: 76px; color: var(--ink-3); font-size: 12.5px; }
.rv-v { flex: 1 1 auto; color: var(--ink); font-variant-numeric: tabular-nums; }

.rv-note {
  margin: 6px 0 0;
  padding-top: 10px;
  border-top: 1px dashed var(--line);
  font-size: 12.5px;
  line-height: 1.7;
  color: var(--ink-2);
}

/* ============ 收藏抽屉 ============ */

.sheet {
  position: fixed;
  inset: 0;
  z-index: 120;
  pointer-events: none;
}

.sheet.open { pointer-events: auto; }

.sheet-mask {
  position: absolute;
  inset: 0;
  background: rgba(12, 12, 14, .42);
  opacity: 0;
  transition: opacity .26s ease;
  backdrop-filter: blur(2px);
}

.sheet.open .sheet-mask { opacity: 1; }

.sheet-panel {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  max-height: 86vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  border-radius: 22px 22px 0 0;
  transform: translateY(100%);
  transition: transform .3s cubic-bezier(.3, .8, .3, 1);
  box-shadow: 0 -12px 40px -12px rgba(0, 0, 0, .28);
  padding-bottom: env(safe-area-inset-bottom);
}

.sheet.open .sheet-panel { transform: translateY(0); }

.sheet-grip {
  width: 38px;
  height: 4px;
  border-radius: 999px;
  background: var(--line);
  margin: 9px auto 0;
  flex: 0 0 auto;
}

.sheet-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 20px 12px;
  flex: 0 0 auto;
}

.sheet-head h3 { margin: 0; font-size: 16px; font-weight: 600; }

.sheet-close {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--ink-3);
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  padding: 0 4px;
}

.sheet-body {
  flex: 1 1 auto;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 0 20px 8px;
  max-width: 680px;
  width: 100%;
  margin: 0 auto;
}

.pref {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 15px;
  padding: 14px 16px;
  box-shadow: var(--shadow-sm);
}

.pref-empty {
  margin: 0;
  font-size: 13px;
  line-height: 1.7;
  color: var(--ink-3);
}

.pref-row {
  display: flex;
  align-items: baseline;
  gap: 6px;
  font-size: 12.5px;
  color: var(--ink-3);
}

.pref-row b { font-size: 20px; color: var(--accent); font-variant-numeric: tabular-nums; }
.pref-split { margin-left: auto; font-size: 11.5px; }

.pref-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

.pref-tag {
  font-size: 11.5px;
  color: var(--ink-2);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 2px 9px;
}

.pref-tag i {
  font-style: normal;
  color: var(--accent);
  margin-left: 4px;
  font-size: 10.5px;
  font-variant-numeric: tabular-nums;
}

.like-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 12px;
}

.lk {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 12px 14px 13px;
  box-shadow: var(--shadow-sm);
}

.lk-top {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  color: var(--ink-3);
}

.lk-cat {
  color: var(--accent);
  border: 1px solid color-mix(in srgb, var(--accent) 35%, transparent);
  border-radius: 4px;
  padding: 0 5px;
  font-size: 10px;
}

.lk-date { font-variant-numeric: tabular-nums; }

.lk-del {
  margin-left: auto;
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--ink-3);
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
  opacity: .5;
  padding: 0 2px;
}

.lk-title {
  margin-top: 5px;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.55;
}

.lk-body {
  margin-top: 4px;
  font-size: 12.5px;
  line-height: 1.65;
  color: var(--ink-3);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.lk-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 7px;
}

.lk-tags span {
  font-size: 10.5px;
  color: var(--ink-3);
  background: var(--line-2);
  border-radius: 5px;
  padding: 1px 6px;
}

.sheet-foot {
  flex: 0 0 auto;
  display: flex;
  gap: 9px;
  padding: 12px 20px calc(16px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
  background: var(--bg);
  max-width: 680px;
  width: 100%;
  margin: 0 auto;
}

.sheet-foot .btn { flex: 1 1 auto; }
.sheet-foot .btn.primary { flex: 2 1 auto; }

/* ============ 阅读时长 / 速览 ============ */

.read { color: var(--accent); font-variant-numeric: tabular-nums; }

.stale-tag {
  flex: 0 0 auto;
  font-size: 10.5px;
  letter-spacing: .02em;
  padding: 1px 7px;
  border-radius: 999px;
  background: color-mix(in srgb, #B8860B 15%, transparent);
  color: #8A6508;
}

.stale-tag[hidden] { display: none; }

.stale-tag.ahead {
  background: color-mix(in srgb, #2D7A55 13%, transparent);
  color: #1F6448;
}

@media (prefers-color-scheme: dark) {
  .stale-tag {
    background: rgba(232, 195, 116, .16);
    color: #E8C374;
  }

  .stale-tag.ahead {
    background: rgba(96, 200, 148, .16);
    color: #7FD3A8;
  }
}

.quick {
  list-style: none;
  margin: 0;
  padding: 0;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.q {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  border-top: 1px solid var(--line-2);
  cursor: pointer;
  transition: background .16s ease;
}

.q:first-child { border-top: 0; }
.q:active { background: var(--line-2); }

.q-idx {
  flex: 0 0 auto;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 10.5px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-variant-numeric: tabular-nums;
}

.q-text { flex: 1 1 auto; font-size: 13.5px; line-height: 1.52; color: var(--ink); }

.q-tag {
  flex: 0 0 auto;
  font-size: 10px;
  color: var(--ink-3);
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 0 5px;
}

/* ============ 折叠快讯 ============ */

.flash.extra { display: none; }
#flashes.extra-open .flash.extra { display: block; }

.more-btn {
  display: block;
  width: 100%;
  margin-top: 9px;
  padding: 11px;
  background: transparent;
  border: 1px dashed var(--line);
  border-radius: 12px;
  color: var(--ink-3);
  font-family: inherit;
  font-size: 12.5px;
  cursor: pointer;
  transition: background .16s ease;
}

.more-btn:active { background: var(--line-2); }
.more-btn b { color: var(--accent); }

/* ============ 优惠：合并卡 ============ */

.deal-head:not(:first-child) {
  border-top: 1px solid var(--line);
  margin-top: 2px;
  padding-top: 14px;
}

.deal-row.hide { display: none; }

.deal-more {
  display: block;
  width: 100%;
  padding: 10px 16px;
  background: transparent;
  border: 0;
  border-top: 1px solid var(--line-2);
  color: var(--ink-3);
  font-family: inherit;
  font-size: 12px;
  text-align: left;
  cursor: pointer;
}

/* ============ 待办悬浮入口 ============ */

.fab {
  position: fixed;
  right: 16px;
  bottom: calc(20px + env(safe-area-inset-bottom));
  z-index: 70;
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 11px 18px 11px 15px;
  border: 0;
  border-radius: 999px;
  background: var(--ink);
  color: var(--bg);
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 500;
  letter-spacing: .02em;
  box-shadow: 0 6px 22px -6px rgba(0, 0, 0, .45);
  cursor: pointer;
  transition: transform .16s ease;
}

.fab:active { transform: scale(.96); }
.fab svg { width: 17px; height: 17px; }

.fab-badge {
  font-style: normal;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-size: 10.5px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-variant-numeric: tabular-nums;
}

/* ============ 待办抽屉 ============ */

.sheet-todo .sheet-panel { max-height: 90vh; }

.sheet-todo .todo-head {
  position: relative;
  padding: 4px 52px 14px;
  flex: 0 0 auto;
}

.sheet-todo .sheet-close {
  position: absolute;
  right: 12px;
  top: 8px;
  font-size: 20px;
}

.day-btn svg { width: 20px; height: 20px; }

.todo-add-wrap {
  flex: 0 0 auto;
  width: 100%;
  max-width: 680px;
  margin: 0 auto;
  padding: 0 20px;
  box-sizing: border-box;
}

.sheet-note {
  margin: 18px 0 8px;
  font-size: 11px;
  line-height: 1.6;
  color: var(--ink-3);
}

/* ============ 学习标签 / 进阶标记 ============ */

.st-tags { color: var(--ink-3); }

.tip-tag.pro {
  color: #8A5A00;
  background: rgba(184, 134, 11, .14);
}

@media (prefers-color-scheme: dark) {
  .tip-tag.pro { color: #E5BC6A; background: rgba(229, 188, 106, .15); }
}

/* ============ 底部按钮组 ============ */

.foot-btns { display: flex; gap: 8px; flex-wrap: wrap; }
.foot-btns .btn { margin: 0; }

/* ============ Toast ============ */

.toast {
  position: fixed;
  left: 50%;
  bottom: calc(96px + env(safe-area-inset-bottom));
  transform: translate(-50%, 12px);
  background: var(--ink);
  color: var(--bg);
  font-size: 13px;
  padding: 10px 20px;
  border-radius: 999px;
  opacity: 0;
  pointer-events: none;
  transition: all .26s cubic-bezier(.2, .7, .3, 1);
  z-index: 100;
  max-width: 86vw;
  text-align: center;
}

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

/* ============ 动画 ============ */

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.pane-inner > * { animation: fadeUp .45s cubic-bezier(.2, .7, .3, 1) both; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation: none !important; transition: none !important; }
}

@media (min-width: 760px) {
  .bar-inner, .pane-inner { padding-left: 0; padding-right: 0; }
  h1 { font-size: 44px; }
}
