/* ============================================================
   My books · Apple 设计语言(DESIGN-apple.md)
   羊皮纸白底 / SF 系无衬线 / 单一 Action Blue / 摄影优先
   ============================================================ */
:root {
  --paper: #f5f5f7;
  --paper-2: #e8e8ed;
  --card: #ffffff;
  --ink: #1d1d1f;
  --ink-2: #6e6e73;
  --ink-3: #86868b;
  --hairline: rgba(0, 0, 0, 0.12);
  --hairline-soft: rgba(0, 0, 0, 0.08);
  --accent: #0066cc;              /* Action Blue:唯一交互色 */
  --accent-deep: #0066cc;
  --accent-soft: rgba(0, 102, 204, 0.12);
  --star: #1d1d1f;                /* (评分系统已下线;变量仅作占位,无样式引用) */
  --night: #1d1d1f;               /* 深色表面:近黑墨色 */
  --night-2: #272729;             /* product-tile-dark-1 */
  --night-text: #f5f5f7;
  --night-sub: #86868b;
  --wish: #6e6e73;                /* 状态:中性灰 */
  --reading: #0066cc;             /* 状态:Action Blue */
  --done: #1d1d1f;                /* 状态:近黑 */
  --radius-lg: 18px;
  --radius: 18px;
  --radius-sm: 8px;
  --shadow-card: none;            /* 卡片无阴影,靠发丝线与表面色分层 */
  --shadow-card-hover: none;
  --shadow-pop: 0 24px 70px rgba(0, 0, 0, 0.28);   /* 仅弹窗浮层 */
  --cover-shadow: 3px 5px 30px rgba(0, 0, 0, 0.22); /* 全系统唯一投影:产品图专属 */
  --ease: cubic-bezier(0.25, 0.1, 0.25, 1);
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --serif: system-ui, -apple-system, "SF Pro Display", "SF Pro SC", "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --sans: system-ui, -apple-system, "SF Pro Text", "SF Pro SC", "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --nav-h: 56px;

  /* —— 原"液态玻璃"变量全部压平为 Apple 扁平语言(白底+发丝线,零高光零投影) ——
     各玻璃组件规则无需改动,取值即变扁平;透明零阴影用于规避 box-shadow 列表语法限制 */
  --glass-fill: #ffffff;
  --glass-fill-hover: #fafafc;
  --glass-fill-on: #ffffff;
  --glass-edge: rgba(0, 0, 0, 0.1);
  --glass-edge-hover: rgba(0, 0, 0, 0.18);
  --glass-spec: 0 0 0 0 rgba(0, 0, 0, 0);
  --glass-lift: 0 0 0 0 rgba(0, 0, 0, 0);
  --glass-lift-hover: 0 0 0 0 rgba(0, 0, 0, 0);
  --glass-spec-hover: 0 0 0 0 rgba(0, 0, 0, 0);
  --glass-ring: 0 0 0 0 rgba(0, 0, 0, 0);
  --glass-text: #1d1d1f;
  --glass-sheen: linear-gradient(rgba(255, 255, 255, 0), rgba(255, 255, 255, 0));
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scrollbar-gutter: stable; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;          /* Apple:正文 17px,不是 16px */
  line-height: 1.47;
  -webkit-font-smoothing: antialiased;
}

main, .topbar, footer { position: relative; z-index: 1; }

::selection { background: rgba(0, 102, 204, 0.22); }

button { font-family: inherit; cursor: pointer; }
input, select, textarea { font-family: inherit; color: var(--ink); }
img { -webkit-user-drag: none; }
.hidden { display: none !important; }

/* ============ 全局交互反馈:点按不留蓝色聚焦框 ============
   现象:触屏/竖屏点按按钮后元素获得焦点 —— iOS Safari、微信内置 WebView、
        旧版 X5 内核会在元素外沿描一圈默认蓝色 focus ring,并叠加系统级
        点按高亮方块。
   方案:清除二者的默认表现;键盘 Tab 导航改由 :focus-visible 统一呈现
        Action Blue 描边(各组件已声明的 focus-visible 规则优先级更高,
        不受影响:媒体画廊 / 家族卡 / 榜单行 / 页脚链接)。
   ========================================================= */
html {
  -webkit-tap-highlight-color: transparent;   /* 关闭触摸点按的系统高亮方块 */
}

/* 兜底行:必须保留。微信 X5、旧 Android WebView 不支持 :focus-visible,
   会将下一条规则整体丢弃,只能靠本行消除点按蓝框,故不可依赖 :focus-visible
   单独实现。表单控件已有更高优先级的 :focus 反馈(描边/光环),不受影响。 */
:focus { outline: none; }

/* 键盘导航的可见焦点(置于 :focus 之后,同优先级下覆盖之) */
:focus-visible { outline: 2px solid #0071e3; outline-offset: 2px; }

/* ============ 顶部导航(浅色毛玻璃,颜色走 Apple 规范) ============ */
.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(250, 250, 252, 0.8);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  backdrop-filter: saturate(180%) blur(20px);
}

@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .topbar { background: rgba(250, 250, 252, 0.97); }
}

.topbar-inner {
  max-width: 1024px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 18px;
  min-height: 44px;
}

/* 品牌标(按钮,点击返回首页)——需清掉 button 原生外观,悬停反馈与右侧导航项一致 */
.brand {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0;
  border: 0;
  background: transparent;
  font-size: 12px;
  font-weight: 400;
  letter-spacing: -0.01em;
  white-space: nowrap;
  color: rgba(29, 29, 31, 0.8);
  cursor: pointer;
  transition: color 0.2s var(--ease);
}

.brand:hover { color: var(--ink); }
.brand:active { color: var(--ink); }

.brand .logo {
  width: 18px;
  height: 18px;
  border-radius: 4px;
  overflow: hidden;
  display: inline-flex;
}

.brand .logo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* 导航项:纯文字链接,均匀分布(无底色药丸) */
.view-switch {
  display: flex;
  align-items: center;
  gap: 0;
  flex: 1;
  justify-content: space-evenly;
  padding: 0;
  margin-left: 10px;
}

.view-switch button {
  border: 0;
  background: transparent;
  padding: 0 12px;
  font-size: 12px;
  font-weight: 400;
  letter-spacing: -0.01em;
  color: rgba(29, 29, 31, 0.8);
  min-height: 44px;
  transition: color 0.2s var(--ease);
}

.view-switch button:hover {
  color: var(--ink);
  background: transparent;
}

/* apple.com 导航项没有选中态:仅悬停反馈 */

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-basis: auto;
  min-width: 0;
}

.search-box { position: relative; width: 170px; flex: 0 1 170px; min-width: 0; }

.search-box input {
  width: 100%;
  padding: 4px 13px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.05);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  min-height: 28px;
  font-size: 12px;
  letter-spacing: -0.01em;
  color: var(--ink);
  transition: background 0.25s var(--ease), box-shadow 0.25s var(--ease);
}

.search-box input::placeholder { color: rgba(29, 29, 31, 0.45); }
.search-box input:hover { background: rgba(0, 0, 0, 0.08); }
.search-box input:focus {
  outline: none;
  background: #ffffff;
  box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.3);
}

/* 搜索:桌面端为常驻胶囊输入框;竖屏下改由顶栏搜索图标独立展开
   (规则见下方 819px 断点)。桌面端不出现图标与「取消」。 */
#searchBtn { display: none; }

.search-cancel {
  display: none;
  flex: 0 0 auto;
  border: 0;
  background: transparent;
  padding: 0 2px;
  font-size: 14px;
  color: var(--accent);
  cursor: pointer;
}

/* 顶栏功能图标(搜索 / 设置 / 添加书籍):盒模型与配色统一走下方 `.topbar .icon-btn`
   —— 30×30 裸按钮 + currentColor(常态 rgba(29,29,31,.8)、悬停纯黑),
   三个图标同为 18px 内联 SVG、stroke 1.8,描边与视觉尺寸一致,
   不再有 PNG 位图与尺寸打架的问题 */
.topbar .icon-btn {
  width: 30px;
  height: 30px;
  background: transparent;
  border: 0;
  box-shadow: none;
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
  color: rgba(29, 29, 31, 0.8);
}

.topbar .icon-btn::before { display: none; }

.topbar .icon-btn:hover {
  background: transparent;
  border-color: transparent;
  box-shadow: none;
  color: #000;
}

/* 汉堡按钮(仅竖屏显示) */
.mobile-menu-btn {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 34px;
  height: 34px;
  border: 0;
  background: transparent;
  padding: 6px;
  border-radius: 8px;
}

.mobile-menu-btn span {
  display: block;
  height: 1.5px;
  border-radius: 2px;
  background: rgba(29, 29, 31, 0.8);
  transition: transform 0.33s var(--ease), background 0.2s var(--ease);
}

/* 点开后:两条线交叉成 ✕(apple.com 同款变形) */
body.menu-open .mobile-menu-btn span:first-child {
  transform: translateY(3.25px) rotate(45deg);
}

body.menu-open .mobile-menu-btn span:last-child {
  transform: translateY(-3.25px) rotate(-45deg);
}

.mobile-menu-btn:hover { background: transparent; }
.mobile-menu-btn:hover span { background: #000; }
body.menu-open .mobile-menu-btn:hover span { background: #000; }

/* 移动端全屏毛玻璃菜单:从导航栏下方展开揭示(apple.com 同款) */
.mobile-menu {
  position: fixed;
  top: 48px;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 90;
  background: rgba(250, 250, 252, 0.94);
  -webkit-backdrop-filter: saturate(180%) blur(30px);
  backdrop-filter: saturate(180%) blur(30px);
  padding: 34px 30px 40px;
  display: flex;
  flex-direction: column;
  clip-path: inset(0 0 100% 0);
  pointer-events: none;
  transition: clip-path 0.45s var(--ease-out);
}

.mobile-menu.open {
  clip-path: inset(0 0 0% 0);
  pointer-events: auto;
}

/* 展开时把焦点移进对话框本身(tabindex="-1"),键盘用户 Tab 一下即进入第一个导航项。
   容器取焦点时明确不画描边 —— 既避免出现一圈蓝色矩形框,
   也不依赖 :focus-visible 的输入模态启发式(程序化聚焦在某些内核下会被判为可见焦点) */
.mobile-menu:focus,
.mobile-menu:focus-visible { outline: none; }

/* 移动端菜单只承载导航(搜索已独立为顶栏一级入口,原 .mm-search 样式一并删除)。
   顶部留白即菜单内边距的 34px,不再需要额外的 margin-top 为搜索框让位。 */
.mm-links { display: flex; flex-direction: column; }

.mm-links button {
  text-align: left;
  font-family: var(--sans);
  font-size: 28px;
  font-weight: 600;
  letter-spacing: 0.007em;
  line-height: 1.14286;
  color: rgba(29, 29, 31, 0.8);
  background: none;
  border: 0;
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
  padding: 11px 4px;
  opacity: 0;
  transform: translateY(14px);
  transition: color 0.25s var(--ease);
}

.mm-links button:hover {
  color: rgba(29, 29, 31, 0.56);
}

/* 进项级联:基准 80ms,每项 +70ms
   注意:导航项增删时必须同步补/删一组 —— 漏掉的那项 animation-delay 为 0,
   会抢在其它项之前出现(菜单有 4 项、这里只写了 3 条时,「统计」就是这个表现) */
.mobile-menu.open .mm-links button { animation: mm-item 0.45s var(--ease-out) forwards; }
.mobile-menu.open .mm-links button:nth-child(1) { animation-delay: 0.08s; }
.mobile-menu.open .mm-links button:nth-child(2) { animation-delay: 0.15s; }
.mobile-menu.open .mm-links button:nth-child(3) { animation-delay: 0.22s; }
.mobile-menu.open .mm-links button:nth-child(4) { animation-delay: 0.29s; }

@keyframes mm-item {
  to { opacity: 1; transform: none; }
}

.mm-links button:active { color: rgba(29, 29, 31, 0.56); }

.mm-foot { margin-top: auto; }

#mmSettings {
  border: 0;
  background: none;
  font-size: 14px;
  color: rgba(29, 29, 31, 0.72);
  padding: 10px 0;
  transition: color 0.2s var(--ease);
}

#mmSettings:hover { color: var(--ink); }

/* 竖屏/窄屏:logo 与品牌居左(apple.com 移动端同款),右侧仅功能按钮 */
@media (max-width: 819px) {
  .topbar-inner {
    padding: 0 16px;
    flex-wrap: nowrap;
    min-height: 48px;
  }
  .view-switch,
  .search-box,
  #settingsBtn { display: none; }
  #searchBtn { display: inline-flex; }   /* 搜索独立成一级入口,与「添加书籍」平级 */
  .mobile-menu-btn { display: inline-flex; }
  .topbar-actions { flex: 0 0 auto; margin-left: auto; }

  /* —— 搜索展开态:整行让给搜索栏 ——
     点顶栏搜索图标后,收起品牌与其它图标,输入框铺满整行;
     取消 / Esc / 回车提交都会收起(见 app.js 的 openSearchRow / closeSearchRow)。
     字号必须 ≥16px,否则 iOS 聚焦输入框时会把整页放大。 */
  body.search-open .topbar .brand,
  body.search-open .topbar #searchBtn,
  body.search-open .topbar #addBtn,
  body.search-open .topbar .mobile-menu-btn { display: none; }

  body.search-open .topbar .topbar-actions {
    flex: 1 1 auto;
    margin-left: 0;
  }

  body.search-open .topbar .search-box {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    flex: 1 1 auto;
  }

  body.search-open .topbar .search-box input {
    min-height: 36px;
    font-size: 16px;
  }

  body.search-open .topbar .search-cancel { display: inline-flex; }
}

/* ============================================================
   分段控件公共规则(.status-tabs 书架筛选 / .seg 弹窗状态选择)
   此前这两个控件只有 padding/字号,没有底色、边框、圆角 ——
   直接回落成浏览器原生按钮(灰底 + 方角 + native 描边),
   与全站 Apple 扁平胶囊语言脱节。
   现统一到 .btn 体系:白底 + 发丝线 + 999px 胶囊;
   选中态改用 Action Blue 实底胶囊(取代原先的 2px 蓝色内描边)。
   ============================================================ */
.status-tabs,
.seg {
  display: flex;
  align-items: center;
  gap: 8px;
}

.status-tabs button,
.seg button {
  appearance: none;
  -webkit-appearance: none;
  flex: 0 0 auto;
  border: 1px solid var(--glass-edge);
  border-radius: 999px;
  background: var(--glass-fill);
  color: var(--ink-2);
  cursor: pointer;
  transition: background 0.2s var(--ease), border-color 0.2s var(--ease),
              color 0.2s var(--ease);
}

/* 未选中项悬停:与 .btn 悬停同款(白底微亮 + 发丝线加深) */
.status-tabs button:not(.active):hover,
.seg button:not(.active):hover {
  background: var(--glass-fill-hover);
  border-color: var(--glass-edge-hover);
  color: var(--ink);
}

/* 选中项:Action Blue 实底胶囊(全站唯一交互色,与 .btn-primary 同款) */
.status-tabs button.active,
.seg button.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #ffffff;
  font-weight: 600;
  box-shadow: none;
}

.status-tabs button.active::before,
.seg button.active::before {
  content: none;
}

/* ============================================================
   液态玻璃统一组件
   .btn / .icon-btn / .tag-chip / select / 分段控件 共用
   ——glass-* 变量:悬停 = 玻璃变亮 + 镜面高光增强 + 边缘发光;
     选中 = 最亮玻璃 + 镜面高光 + 白色光环
   ============================================================ */
.btn {
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border-radius: 999px;
  padding: 9px 18px;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.02em;
  min-height: 38px;
  white-space: nowrap;
  background: var(--glass-fill);
  -webkit-backdrop-filter: blur(16px) saturate(160%);
  backdrop-filter: blur(16px) saturate(160%);
  border: 1px solid var(--glass-edge);
  box-shadow: var(--glass-spec), var(--glass-lift);
  color: var(--glass-text);
  transition: background 0.25s var(--ease), border-color 0.25s var(--ease),
    box-shadow 0.25s var(--ease), transform 0.12s var(--ease), color 0.25s var(--ease);
}

/* 表面斜向光泽(悬停增强) */
.btn::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  background: var(--glass-sheen);
  opacity: 0.75;
  transition: opacity 0.25s var(--ease);
}

.btn > * { position: relative; }

.btn:hover {
  background: var(--glass-fill-hover);
  border-color: var(--glass-edge-hover);
  box-shadow: var(--glass-spec-hover), var(--glass-lift-hover);
  color: var(--glass-text);
}

.btn:hover::before { opacity: 1; }

.btn:active {
  transform: scale(0.95);   /* apple.com 系统级按压微交互 */
  box-shadow: var(--glass-spec);
}

/* 禁用态:玻璃蒙灰、去除交互反馈(label.btn 无 disabled 属性,用 is-disabled 类) */
.btn:disabled,
.btn.is-disabled {
  opacity: 0.45;
  cursor: not-allowed;
  pointer-events: none;
  box-shadow: var(--glass-spec);
}

/* 主按钮:Action Blue 胶囊(apple.com 签名 CTA) */
.btn-primary {
  background: #0066cc;
  border-color: transparent;
  color: #ffffff;
  box-shadow: none;
}

.btn-primary:hover {
  background: #0077ed;
  border-color: transparent;
  color: #ffffff;
  box-shadow: none;
}

.btn-primary::before { display: none; }

.btn-ghost {
  background: transparent;
  color: var(--accent);
  border-color: var(--accent);
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
}

.btn-ghost:hover {
  background: rgba(0, 102, 204, 0.06);
  color: var(--accent);
  border-color: var(--accent);
}

.btn-danger-tint { color: #e30000; border-color: rgba(0, 0, 0, 0.12); }

.icon-btn {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--glass-edge);
  background: var(--glass-fill);
  -webkit-backdrop-filter: blur(14px) saturate(150%);
  backdrop-filter: blur(14px) saturate(150%);
  box-shadow: var(--glass-spec), var(--glass-lift);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  font-size: 13px;
  color: var(--glass-text);
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.25s var(--ease);
}

.icon-btn::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  background: var(--glass-sheen);
}

.icon-btn:hover {
  background: var(--glass-fill-hover);
  border-color: var(--glass-edge-hover);
  box-shadow: var(--glass-spec-hover), var(--glass-lift-hover);
  color: var(--glass-text);
}

/* 统一高亮同样作用于:标签胶囊(下拉筛选已改为自定义组件,样式见「自定义下拉」段) */
.tag-chip {
  color: var(--glass-text);
}

/* 统一悬停作用于:标签胶囊(搜索框在黑底导航上有专属悬停) */
.tag-chip:hover {
  background: #fafafc;
  border-color: rgba(0, 0, 0, 0.18);
  color: var(--ink);
}

/* ============ 主区域 ============ */
main {
  max-width: 1120px;
  margin: 0 auto;
  padding: 44px 22px 80px;
}

.page-title {
  font-family: var(--sans);
  font-size: clamp(34px, 5vw, 46px);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin: 0 0 8px;
}

.page-sub {
  font-size: 17px;
  color: var(--ink-2);
  margin: 0 0 30px;
  letter-spacing: 0;
}

.page-sub::before { content: '—— '; color: var(--accent); }

/* 工具栏 */
.toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 14px;
  align-items: center;
  margin-bottom: 30px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--hairline-soft);
}

.status-tabs {
  overflow-x: auto;
  max-width: 100%;
  scrollbar-width: none;
}

.status-tabs::-webkit-scrollbar { display: none; }

.status-tabs button {
  padding: 6px 15px;
  font-size: 13.5px;
  font-weight: 500;
  white-space: nowrap;
  min-height: 34px;
}

/* 计数角标:跟随按钮文字色,选中态(蓝底白字)下自动变白 */
.status-tabs em {
  font-style: normal;
  font-size: 12px;
  font-weight: 600;
  color: currentColor;
  opacity: 0.72;
  margin-left: 3px;
}

.status-tabs button.active em { opacity: 1; }

.toolbar-right { display: flex; gap: 10px; margin-left: auto; }

/* ============================================================
   自定义下拉(.sel)
   原生 <select> 展开后的列表由系统绘制,CSS 无法介入 —— 会露出灰底 / 方角 /
   原生高亮,和全站 Apple 扁平语言冲突。这里把原生 select 藏起来(仍作数据源),
   用「胶囊触发按钮 + 圆角浮层面板」接管展开态。
   触发按钮 = 与 .btn 同款白底发丝线胶囊;面板 = 白底 / 18px 圆角 / 单一投影;
   选中项 = Action Blue 实底胶囊(与书架分段控件、.btn-primary 同一语言)。
   ============================================================ */
.sel { position: relative; }

/* 原生 select 保留在 DOM 中(JS 读写 value / options),仅视觉隐藏 */
.sel > select {
  position: absolute;
  left: 0;
  top: 0;
  width: 1px;
  height: 1px;
  opacity: 0;
  padding: 0;
  margin: 0;
  border: 0;
  pointer-events: none;
}

.sel-trigger {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 7px 13px 7px 15px;
  min-height: 36px;
  border: 1px solid rgba(0, 0, 0, 0.12);
  border-radius: 999px;
  background: #ffffff;
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 400;
  letter-spacing: 0;
  color: var(--ink);
  white-space: nowrap;
  cursor: pointer;
  transition: border-color 0.2s var(--ease), background 0.2s var(--ease);
}

.sel-trigger:hover { background: #fafafc; border-color: rgba(0, 0, 0, 0.18); }
.sel-trigger[aria-expanded="true"] { border-color: var(--accent); }

.sel-caret {
  flex: 0 0 auto;
  color: var(--ink-3);
  transition: transform 0.24s var(--ease-out);
}
.sel-trigger[aria-expanded="true"] .sel-caret { transform: rotate(180deg); }

/* 展开面板:下行 8px,右对齐触发按钮 —— 与 .modal-box 同一套浮层语言 */
.sel-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 60;
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 100%;
  max-width: min(280px, 80vw);
  max-height: 320px;
  overflow-y: auto;
  /* 隐藏滚动条,但保留滚动能力(滚轮 / 触屏滑动 / 键盘 ↑↓ Home End 均可);
     与 .status-tabs 同一做法 —— 浅色浮层里露出系统滚动条会破坏整体观感 */
  scrollbar-width: none;        /* Firefox */
  -ms-overflow-style: none;     /* 旧 Edge */
  padding: 6px;
  background: #ffffff;
  border: 1px solid var(--glass-edge);
  border-radius: 18px;
  box-shadow: var(--shadow-pop);
  transform-origin: top right;
  animation: sel-menu-in 0.18s var(--ease-out) both;
}

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

.sel-menu::-webkit-scrollbar { display: none; }   /* Chromium / Safari */

@keyframes sel-menu-in {
  from { opacity: 0; transform: translateY(-6px) scale(0.97); }
  to   { opacity: 1; transform: none; }
}

.sel-option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  width: 100%;
  padding: 9px 14px;
  border: 0;
  border-radius: 12px;
  background: transparent;
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 400;
  color: var(--ink);
  text-align: left;
  white-space: nowrap;
  cursor: pointer;
  transition: background 0.15s var(--ease), color 0.15s var(--ease);
}

.sel-option-text { overflow: hidden; text-overflow: ellipsis; }

.sel-check { flex: 0 0 auto; font-size: 12px; opacity: 0; }

/* 悬停与键盘高亮:浅灰底 */
.sel-option:hover,
.sel-option.active { background: var(--paper); }

/* 选中项:Action Blue 实底(置于悬停之后,悬停时不掉色) */
.sel-option.on {
  background: var(--accent);
  color: #ffffff;
  font-weight: 500;
}
.sel-option.on .sel-check { opacity: 1; }

/* ============ 书架网格 ============ */
.book-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 34px 22px;
}

.book-card {
  background: transparent;
  border: 0;
  padding: 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
  cursor: pointer;
  text-align: left;
}

.card-cover {
  position: relative;
  aspect-ratio: 5 / 7;
  border-radius: 4px 12px 12px 4px;
  overflow: hidden;
  background: var(--paper-2);
  box-shadow: var(--cover-shadow);
  transition: transform 0.4s var(--ease-out), box-shadow 0.4s var(--ease-out);
}

/* 书脊立体感 */
.card-cover::after {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 12px;
  pointer-events: none;
  border-radius: 4px 0 0 4px;
  background: linear-gradient(90deg,
    rgba(0, 0, 0, 0.32),
    rgba(0, 0, 0, 0.08) 38%,
    rgba(255, 255, 255, 0.16) 62%,
    rgba(0, 0, 0, 0.05) 100%);
}

/* 右侧书页压痕 */
.card-cover::before {
  content: '';
  position: absolute;
  right: 0;
  top: 2px;
  bottom: 2px;
  width: 5px;
  pointer-events: none;
  z-index: 1;
  background: repeating-linear-gradient(180deg,
    rgba(255, 255, 255, 0.5) 0 1.5px,
    rgba(0, 0, 0, 0.1) 1.5px 2.5px);
  border-radius: 0 10px 10px 0;
}

.book-card:hover .card-cover {
  transform: translateY(-6px) rotate(-0.6deg);
}

.card-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.cover-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px 14px;
}

.ph-text {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-width: 0;
}

.ph-title {
  font-family: var(--sans);
  font-weight: 650;
  font-size: clamp(1.05rem, 4vw, 1.3rem);
  line-height: 1.28;
  letter-spacing: -0.01em;
  color: #fff;
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.1);
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.ph-author {
  font-size: 11.5px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.8);
  letter-spacing: 0.05em;
  white-space: nowrap;
  overflow: hidden;
  max-width: 100%;
  text-overflow: ellipsis;
}

/* 封面状态徽章(深色薄纱胶囊) */
.status-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 2;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
  padding: 3.5px 10px;
  border-radius: 999px;
  color: #f5f5f7;
  background: rgba(0, 0, 0, 0.55);
  -webkit-backdrop-filter: blur(12px) saturate(150%);
  backdrop-filter: blur(12px) saturate(150%);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.22);
}

/* 书架卡片上的"在线阅读"直达按钮(有电子书文件的书才渲染):
   覆盖左下角,毛玻璃底与状态角标呼应;点击不冒泡(避免同时打开详情) */
.card-read-btn {
  position: absolute;
  left: 10px;
  bottom: 10px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4.5px 11px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 600;
  color: #f5f5f7;
  text-decoration: none;
  background: rgba(0, 0, 0, 0.55);
  -webkit-backdrop-filter: blur(12px) saturate(150%);
  backdrop-filter: blur(12px) saturate(150%);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.22);
  transition: background 0.2s var(--ease), transform 0.2s var(--ease);
}

.card-read-btn:hover,
.card-read-btn:focus-visible {
  background: var(--accent);
  transform: translateY(-1px);
  color: #fff;
  text-decoration: none;
}

.card-info { padding: 0 2px; display: flex; flex-direction: column; gap: 3px; }

.card-title {
  font-family: var(--serif);
  font-weight: 700;
  font-size: 16.5px;
  line-height: 1.4;
  letter-spacing: 0.03em;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-author {
  font-size: 12.5px;
  color: var(--ink-3);
  letter-spacing: 0.05em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.card-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 4px;
}

.card-date { font-size: 12px; color: var(--ink-3); margin-left: auto; letter-spacing: 0.03em; }

/* 状态药丸(行内) */
.status-inline {
  display: inline-flex;
  align-items: center;
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.06em;
  padding: 3px 10px;
  border-radius: 999px;
}

.status-inline.wish { color: var(--wish); background: rgba(110, 110, 115, 0.12); }
.status-inline.reading { color: var(--reading); background: rgba(0, 102, 204, 0.1); }
.status-inline.done { color: var(--done); background: rgba(29, 29, 31, 0.08); }

/* ============ 空状态 ============ */
.empty { text-align: center; padding: 90px 20px; color: var(--ink-2); }

.empty-icon {
  font-family: var(--serif);
  font-size: 40px;
  color: var(--accent);
  opacity: 0.55;
  margin-bottom: 14px;
  letter-spacing: 0.1em;
}

.empty p {
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: var(--ink);
  margin: 0 0 8px;
}

.empty .hint { font-family: var(--sans); font-size: 14.5px; color: var(--ink-2); margin: 0; font-weight: 400; }
.empty .btn { margin-top: 22px; padding: 10px 22px; font-size: 15px; }

/* ============ 统计面板 ============ */
.stats-hero {
  background: var(--night-2);   /* product-tile-dark:扁平近黑瓦片 */
  border-radius: var(--radius-lg);
  padding: 34px 34px 30px;
  color: var(--night-text);
  box-shadow: none;
  position: relative;
  overflow: hidden;
  margin-bottom: 18px;
}

.stats-hero::after {
  content: '书';
  position: absolute;
  right: -14px;
  bottom: -42px;
  font-family: var(--sans);
  font-size: 200px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.04);
  line-height: 1;
  pointer-events: none;
}

.stats-hero h2 {
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 700;
  letter-spacing: 0.06em;
  margin: 0 0 4px;
}

.stats-hero .hero-sub {
  font-size: 13.5px;
  color: var(--night-sub);
  margin: 0 0 26px;
  letter-spacing: 0.04em;
}

.stats-hero-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 22px 14px;
  position: relative;
  z-index: 1;
}

.hstat {
  border-left: 2px solid rgba(41, 151, 255, 0.7);
  padding-left: 14px;
}

.hstat .num {
  display: block;
  font-family: var(--serif);
  font-size: 38px;
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: 0.02em;
  color: var(--night-text);
}

.hstat .num small { font-size: 20px; }
.hstat .label { font-size: 12.5px; color: var(--night-sub); letter-spacing: 0.14em; }

.stats-panels {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

.panel {
  background: var(--card);
  border: 1px solid var(--hairline-soft);
  border-radius: var(--radius-lg);
  padding: 26px 26px 24px;
  box-shadow: var(--shadow-card);
  min-width: 0;
}

.panel h3 {
  font-family: var(--serif);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.06em;
  margin: 0 0 18px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.panel h3::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--hairline-soft);
}

/* 每年读完柱状图 */
.year-chart {
  display: flex;
  align-items: flex-end;
  gap: 18px;
  height: 190px;
  padding-top: 6px;
}

.year-col {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
  min-width: 0;
  height: 100%;
}

.year-bar-wrap {
  flex: 1;
  width: 100%;
  max-width: 50px;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

.year-bar {
  width: 100%;
  border-radius: 8px 8px 2px 2px;
  background: #0066cc;
  min-height: 5px;
  transition: height 0.5s var(--ease-out), filter 0.2s var(--ease);
}

.year-col:hover .year-bar { filter: brightness(1.12); }

.year-num { font-family: var(--serif); font-size: 15px; font-weight: 700; }
.year-label { font-size: 12.5px; color: var(--ink-3); letter-spacing: 0.05em; }

/* 标签云 */
.tag-cloud { display: flex; flex-wrap: wrap; gap: 9px; }

.tag-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid rgba(255, 255, 255, 0.6);
  background: rgba(255, 255, 255, 0.55);
  -webkit-backdrop-filter: blur(14px) saturate(150%);
  backdrop-filter: blur(14px) saturate(150%);
  border-radius: 999px;
  padding: 5px 14px;
  font-size: 13.5px;
  color: var(--glass-text);
  min-height: 32px;
  letter-spacing: 0.04em;
  box-shadow:
    inset 0 1px 1px rgba(255, 255, 255, 0.65),
    0 3px 10px rgba(36, 29, 20, 0.07);
  transition: all 0.2s var(--ease);
}

.tag-chip b { font-size: 11.5px; font-weight: 700; color: var(--glass-text); }

.chart-empty { color: var(--ink-3); font-size: 14px; text-align: center; padding: 34px 0; letter-spacing: 0.05em; }

/* ============ 弹窗 ============ */
.modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgba(0, 0, 0, 0.48);
  display: flex;
  align-items: stretch;
  justify-content: center;
  animation: modal-fade 0.3s var(--ease-out);
}

@keyframes modal-fade { from { opacity: 0; } to { opacity: 1; } }

.modal-box {
  background: var(--card);
  width: 100%;
  max-width: 620px;
  overflow-y: auto;
  padding: 26px 24px 30px;
  display: flex;
  flex-direction: column;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  animation: modal-pop 0.38s var(--ease-out);
  scrollbar-width: none; /* 隐藏滚动条,滚动功能保留 */
}

.modal-box::-webkit-scrollbar { display: none; }

@keyframes modal-pop {
  from { opacity: 0; transform: translateY(16px) scale(0.98); }
  to { opacity: 1; transform: none; }
}

.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--hairline-soft);
}

.modal-head h2 {
  font-family: var(--serif);
  font-size: 24px;
  font-weight: 700;
  letter-spacing: 0.05em;
  margin: 0;
}

/* 表单 */
.form-grid { display: grid; grid-template-columns: 1fr; gap: 16px; }

.field { display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.field-full { grid-column: 1 / -1; }

.field label {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--ink-2);
  letter-spacing: 0.1em;
}

.field .req { color: #e30000; font-style: normal; }

.field-hint { margin: 0; font-size: 12px; color: var(--ink-3); letter-spacing: 0.02em; line-height: 1.5; }

.field input[type="text"],
.field input[type="date"],
.field input[type="number"],
.field textarea,
.cover-actions input[type="text"] {
  border: 1px solid rgba(0, 0, 0, 0.12);
  border-radius: 12px;
  padding: 10px 16px;
  background: #ffffff;
  box-shadow: none;
  min-height: 44px;
  width: 100%;
  font-size: 17px;
  color: var(--ink);
  transition: background 0.2s var(--ease), border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}

/* 多行文本框 */
.field textarea {
  border-radius: 12px;
  padding: 12px 16px;
  resize: vertical;
  min-height: 104px;
  line-height: 1.47;
  font-family: inherit;
}

/* 悬停:边框加深 */
.field input[type="text"]:hover,
.field input[type="date"]:hover,
.field input[type="number"]:hover,
.field textarea:hover,
.cover-actions input[type="text"]:hover {
  border-color: rgba(0, 0, 0, 0.24);
}

.field input:focus, .field textarea:focus,
.cover-actions input[type="text"]:focus {
  outline: none;
  border-color: #0066cc;
  box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.18);
}

/* 状态选择(分段;容器与按钮样式见上方「分段控件公共规则」) */
.seg button {
  flex: 1;
  padding: 7px 4px;
  font-size: 13.5px;
  font-weight: 500;
  min-height: 36px;
}

/* 封面编辑 */
.cover-editor { display: flex; gap: 16px; align-items: flex-start; }

.cover-preview {
  width: 90px;
  height: 126px;
  flex: 0 0 auto;
  border-radius: 4px 10px 10px 4px;
  background: var(--paper-2);
  border: 1px dashed var(--hairline);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  color: var(--ink-3);
  overflow: hidden;
}

.cover-preview img { width: 100%; height: 100%; object-fit: cover; }

.cover-actions { flex: 1; display: flex; flex-direction: column; gap: 10px; min-width: 0; }

/* 电子书文件编辑:横向条状布局(与封面预览区分——这里没有图,只有文件信息) */
.ebook-editor { padding: 10px 14px; border: 1px dashed var(--hairline); border-radius: 10px; background: var(--paper-2); }

.ebook-actions { display: flex; flex-direction: column; gap: 8px; }

.ebook-info { font-size: 12.5px; color: var(--ink-3); letter-spacing: 0.02em; }

.ebook-info .ebook-tag {
  display: inline-block;
  margin-right: 6px;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
  color: var(--accent);
  background: rgba(0, 102, 204, 0.08);
}

/* 豆瓣元数据填充:按钮行 + 候选列表 */
.douban-fetch-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 6px;
}

.douban-btn { font-size: 13px; }

.douban-status { font-size: 12.5px; color: var(--ink-3); }

.douban-candidates {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 4px 0 14px;
  padding: 10px;
  border: 1px solid var(--hairline);
  border-radius: 10px;
  background: var(--paper-2);
}

.douban-candidate {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 7px 10px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: transparent;
  cursor: pointer;
  text-align: left;
  font-size: 13.5px;
  color: var(--ink-1);
  transition: background 0.15s var(--ease), border-color 0.15s var(--ease);
}

.douban-candidate:hover,
.douban-candidate:focus-visible {
  background: var(--paper);
  border-color: var(--accent);
}

.douban-candidate .dc-meta { font-size: 12px; color: var(--ink-3); margin-top: 2px; }

.cover-btns { display: flex; gap: 8px; flex-wrap: wrap; }
.cover-btns .btn { padding: 6px 14px; min-height: 34px; font-size: 13px; }

.form-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid var(--hairline-soft);
}

.form-error { color: #e30000; font-size: 13px; }

.form-foot-btns { display: flex; gap: 10px; margin-left: auto; }
.form-foot-btns .btn { padding: 10px 22px; font-size: 15px; }

/* 详情弹窗 */
.detail-box { max-width: 720px; position: relative; }

.detail-close { position: absolute; top: 20px; right: 20px; z-index: 2; }

.detail-body { display: flex; flex-direction: column; gap: 24px; padding-top: 4px; }

.detail-cover {
  width: 172px;
  flex: 0 0 auto;
  aspect-ratio: 5 / 7;
  border-radius: 4px 14px 14px 4px;
  overflow: hidden;
  box-shadow: var(--cover-shadow);
  align-self: center;
  position: relative;
}

.detail-cover::after {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 12px;
  pointer-events: none;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.32), rgba(0, 0, 0, 0.08) 38%, rgba(255, 255, 255, 0.16) 62%, rgba(0, 0, 0, 0.05) 100%);
}

.detail-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }

.detail-info { flex: 1; min-width: 0; }

.detail-info h2 {
  font-family: var(--serif);
  font-size: 28px;
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1.3;
  margin: 0 0 6px;
}

.detail-author { color: var(--ink-2); font-size: 14.5px; letter-spacing: 0.06em; margin-bottom: 14px; }

.detail-rows { display: flex; flex-direction: column; gap: 10px; margin: 16px 0; }

.detail-row { display: flex; gap: 14px; font-size: 14.5px; flex-wrap: wrap; }
.detail-row .k { color: var(--ink-3); flex: 0 0 3.5em; letter-spacing: 0.1em; font-size: 13px; padding-top: 2px; }
.detail-row .v { flex: 1; min-width: 0; }

.detail-tags { display: flex; flex-wrap: wrap; gap: 7px; }
.detail-tags .tag-chip { cursor: default; min-height: 0; padding: 3px 12px; font-size: 12.5px; }

/* 评分星级(详情页,与状态药丸同行) */
.detail-rating {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-left: auto;
  font-size: 12.5px;
  color: var(--ink-3);
}
.detail-rating .star { color: var(--hairline); font-size: 13px; line-height: 1; }
.detail-rating .star.on { color: #f0a020; }
.detail-rating .star.half { color: #f0a020; opacity: 0.45; }
.detail-rating b { font-weight: 600; color: var(--ink-2); letter-spacing: 0.02em; }

/* ISBN 等需等宽的数字串,便于核对 */
.detail-isbn { font-variant-numeric: tabular-nums; letter-spacing: 0.04em; color: var(--ink-2); }

/* 详情页外链(豆瓣条目) */
.detail-link { color: var(--accent); text-decoration: none; }
.detail-link:hover { text-decoration: underline; }

.detail-review,
.detail-block {
  background: var(--card);
  border: 1px solid var(--hairline-soft);
  border-radius: 12px;
  padding: 16px 20px;
  font-size: 15px;
  line-height: 1.6;
  letter-spacing: 0;
  white-space: pre-wrap;
  word-break: break-word;
  color: var(--ink);
}

.detail-block { display: flex; gap: 14px; align-items: baseline; }
.detail-block + .detail-block { margin-top: 10px; }
.detail-block-k {
  flex: 0 0 3.5em;
  color: var(--ink-3);
  letter-spacing: 0.1em;
  font-size: 13px;
  white-space: nowrap;
}
.detail-block-v { margin: 0; min-width: 0; }

.detail-actions { display: flex; gap: 10px; margin-top: 18px; }
.detail-actions .btn { padding: 9px 20px; font-size: 14px; }

/* 详情弹窗里的心得入口(紧凑玻璃按钮,与其他按钮一致) */
.notes-entry {
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 16px;
  padding: 8px 18px;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.02em;
  min-height: 38px;
  background: var(--glass-fill);
  -webkit-backdrop-filter: blur(16px) saturate(160%);
  backdrop-filter: blur(16px) saturate(160%);
  border: 1px solid var(--glass-edge);
  border-radius: 999px;
  box-shadow: var(--glass-spec), var(--glass-lift);
  font-family: var(--sans);
  color: var(--glass-text);
  cursor: pointer;
  transition: all 0.25s var(--ease);
}

.notes-entry::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  background: var(--glass-sheen);
}

.notes-entry:hover {
  background: var(--glass-fill-hover);
  border-color: var(--glass-edge-hover);
  box-shadow: var(--glass-spec-hover), var(--glass-lift-hover);
}

/* ============ 读书心得子页面 ============ */
.notes-page-head {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 20px;
  margin-bottom: 24px;
}

.notes-book { display: flex; gap: 18px; align-items: center; min-width: 0; }

.notes-book-cover {
  width: 64px;
  flex: 0 0 auto;
  aspect-ratio: 5 / 7;
  border-radius: 3px 8px 8px 3px;
  overflow: hidden;
  box-shadow: var(--cover-shadow);
  position: relative;
  background: var(--paper-2);
}

.notes-book-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }

.notes-book-cover::after {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 6px;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.3), rgba(0, 0, 0, 0.06) 50%, rgba(255, 255, 255, 0.15));
}

.notes-book-cover .ph-text { gap: 3px; padding: 0 4px; }
.notes-book-cover .ph-title { font-size: 10.5px; letter-spacing: 0; -webkit-line-clamp: 3; }
.notes-book-cover .ph-author { display: none; }

.notes-book-info { min-width: 0; }

.notes-book-info h1 {
  font-family: var(--serif);
  font-size: clamp(24px, 4vw, 34px);
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1.25;
  margin: 0 0 8px;
}

.notes-book-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 13.5px;
  color: var(--ink-2);
  letter-spacing: 0.04em;
}

.nm-author { font-weight: 600; color: var(--ink); }
.nm-date { color: var(--ink-3); font-size: 12.5px; }

.notes-page-body { max-width: 860px; margin: 0 auto; }
.notes-page-body .detail-notes { padding: 30px 36px 36px; border-radius: var(--radius-lg); box-shadow: var(--shadow-card); }

@media (max-width: 559.98px) {
  .notes-page-body .detail-notes { padding: 20px 18px 24px; border-radius: var(--radius); }
  .notes-book { gap: 12px; }
  .notes-book-cover { width: 52px; }
}

/* ============ 心得内容块(子页面 + 空状态) ============ */
.detail-notes {
  margin-top: 4px;
  background: var(--card);
  border: 1px solid var(--hairline-soft);
  border-radius: var(--radius);
  padding: 20px 24px 22px;
}

.notes-head {
  font-family: var(--serif);
  font-size: 17px;
  font-weight: 700;
  letter-spacing: 0.08em;
  padding-bottom: 10px;
  margin-bottom: 6px;
  border-bottom: 1px solid var(--hairline-soft);
}

.notes-orn { color: var(--glass-text); margin-right: 6px; }

.notes-state { color: var(--ink-3); font-size: 14px; letter-spacing: 0.03em; padding: 10px 0 4px; }
.notes-error { color: #e30000; }

.notes-retry {
  margin-left: 12px;
  border: 1px solid var(--hairline);
  background: var(--paper-2);
  border-radius: 999px;
  padding: 3px 14px;
  font-size: 12.5px;
  color: var(--glass-text);
}

.notes-retry:hover { background: var(--glass-fill-hover); border-color: var(--glass-edge-hover); }

.markdown-body { font-size: 15px; line-height: 1.6; color: var(--ink); letter-spacing: 0; word-break: break-word; }
.markdown-body > :first-child { margin-top: 0; }
.markdown-body h1, .markdown-body h2, .markdown-body h3,
.markdown-body h4, .markdown-body h5, .markdown-body h6 {
  font-family: var(--serif);
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1.4;
  margin: 1.3em 0 0.5em;
  color: var(--ink);
}
.markdown-body h1 { font-size: 23px; }
.markdown-body h2 { font-size: 20px; padding-bottom: 6px; border-bottom: 1px solid var(--hairline-soft); }
.markdown-body h3 { font-size: 17.5px; }
.markdown-body h4, .markdown-body h5, .markdown-body h6 { font-size: 15.5px; }
.markdown-body p { margin: 0.6em 0; }
.markdown-body a { color: #0066cc; text-decoration-color: rgba(0, 102, 204, 0.4); }
.markdown-body ul, .markdown-body ol { padding-left: 1.5em; margin: 0.6em 0; }
.markdown-body li { margin: 0.3em 0; }
.markdown-body li::marker { color: var(--accent); }
.markdown-body blockquote {
  margin: 0.9em 0;
  padding: 10px 18px;
  border-left: 3px solid var(--accent);
  background: var(--paper);
  border-radius: 0 10px 10px 0;
  color: var(--ink-2);
}
.markdown-body blockquote p { margin: 0.2em 0; }
.markdown-body code {
  background: var(--paper-2);
  padding: 2px 7px;
  border-radius: 6px;
  font-size: 0.88em;
  font-family: Consolas, "Courier New", monospace;
}
.markdown-body pre {
  background: var(--night);
  color: var(--night-text);
  padding: 16px 20px;
  border-radius: 12px;
  overflow-x: auto;
  margin: 0.9em 0;
}
.markdown-body pre code { background: transparent; color: inherit; padding: 0; font-size: 0.86em; }
.markdown-body img { max-width: 100%; border-radius: 12px; display: block; margin: 0.8em 0; }
.markdown-body hr { border: 0; border-top: 1px solid var(--hairline-soft); margin: 1.5em 0; }
.markdown-body table { border-collapse: collapse; width: 100%; margin: 0.9em 0; font-size: 0.93em; }
.markdown-body th, .markdown-body td { border: 1px solid var(--hairline-soft); padding: 7px 12px; text-align: left; }
.markdown-body th { background: var(--paper-2); font-family: var(--serif); }
.markdown-body input[type="checkbox"] { accent-color: var(--accent); margin-right: 4px; }

/* 卡片上的心得标记 */
.has-notes {
  font-size: 11px;
  font-weight: 600;
  color: var(--glass-text);
  background: var(--paper-2);
  border: 1px solid var(--hairline-soft);
  border-radius: 999px;
  padding: 2px 9px;
  letter-spacing: 0.06em;
  white-space: nowrap;
}

/* ============ Toast ============ */
.toast {
  position: fixed;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  background: #1d1d1f;
  color: #f5f5f7;
  padding: 11px 24px;
  border-radius: 999px;
  font-size: 14px;
  letter-spacing: 0;
  z-index: 200;
  box-shadow: 0 10px 36px rgba(0, 0, 0, 0.35);
  max-width: 86vw;
  text-align: center;
  animation: toast-in 0.35s var(--ease-out);
}

@keyframes toast-in {
  from { opacity: 0; transform: translate(-50%, 12px); }
  to { opacity: 1; transform: translate(-50%, 0); }
}

.toast.error { background: #e30000; color: #ffffff; }

/* ============ 页脚(parchment + fine print) ============ */
footer {
  max-width: 1120px;
  margin: 0 auto;
  padding: 26px 22px 40px;
  border-top: 1px solid var(--hairline-soft);
  text-align: center;
  color: var(--ink-3);
  font-size: 12px;
  letter-spacing: 0.02em;
}

footer .orn { color: var(--ink-3); margin: 0 10px; opacity: 0.6; }

footer .footer-tagline { margin: 0; }

/* 备案号:首页底部悬挂,链接到工信部备案管理系统(页面内不显眼但可查) */
footer .footer-legal {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 18px;
  margin: 10px 0 0;
}

footer .footer-legal a {
  color: var(--ink-3);
  text-decoration: none;
  transition: color 0.2s var(--ease);
}

footer .footer-legal a:hover,
footer .footer-legal a:focus-visible {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* 公安联网备案:图标 + 文字,与 ICP 备案并排(公安备案要求图标随行悬挂) */
footer .footer-legal a.beian-ps {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

footer .footer-legal a.beian-ps img {
  width: 14px;
  height: 15px;
  display: block;
}

/* 阅读记录(每次读的起止时间) */
.label-sub { font-weight: 400; color: var(--ink-3); font-size: 12px; letter-spacing: 0.02em; margin-left: 4px; }

.read-logs { display: flex; flex-direction: column; gap: 8px; }

.read-logs:empty { display: none; }

.log-row { display: flex; align-items: center; gap: 8px; }

.log-row input[type="date"] {
  flex: 1;
  min-width: 0;
  border: 1px solid rgba(0, 0, 0, 0.12);
  border-radius: 12px;
  padding: 8px 12px;
  background: #ffffff;
  box-shadow: none;
  min-height: 40px;
  font-size: 14px;
  transition: border-color 0.2s var(--ease), background 0.2s var(--ease);
}

.log-row input[type="date"]:focus {
  outline: none;
  border-color: #0066cc;
  background: #ffffff;
  box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.18);
}

.log-sep { font-size: 12.5px; color: var(--ink-3); flex: 0 0 auto; }

.log-del {
  border: 1px solid var(--hairline);
  background: transparent;
  color: var(--glass-text);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  font-size: 12px;
  flex: 0 0 auto;
  transition: all 0.2s var(--ease);
}

.log-del:hover { background: rgba(227, 0, 0, 0.07); border-color: rgba(227, 0, 0, 0.35); color: #e30000; }

.add-log-btn { padding: 6px 14px; min-height: 34px; font-size: 13px; }

/* 由阅读记录自动推导的汇总(开始/读完日期与读过次数) */
.read-logs-summary { font-size: 12.5px; color: var(--ink-3); line-height: 1.5; margin-top: 2px; }
.read-logs-summary:empty { display: none; }

/* 详情里的阅读记录胶囊 */
.detail-logs { display: flex; flex-wrap: wrap; gap: 6px; }

.log-chip {
  font-size: 12.5px;
  color: var(--ink-2);
  background: var(--paper-2);
  border: 1px solid var(--hairline-soft);
  border-radius: 999px;
  padding: 3px 11px;
  letter-spacing: 0.02em;
}

/* ============ 首页(Apple 式展示页) ============ */
#homeView {
  --home-bg: #ffffff;
  --home-surface: #f5f5f7;
  --home-text: #1d1d1f;
  --home-sub: #6e6e73;
  --home-link: #0066cc;
  --home-dark: #000000;
  --home-dark-text: #f5f5f7;
  --home-dark-sub: #86868b;
  padding: 0;
  overflow-x: clip;
}

/* 首页视图:主容器全出血,Hero 顶到导航栏下方 */
main:has(#homeView:not(.hidden)) { padding: 0 0 80px; max-width: none; }

.home-eyebrow {
  font-family: var(--ent-text);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: #0066cc;               /* 单一强调色:Action Blue */
}

.home-hero {
  min-height: 540px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 64px 24px 72px;
  background: var(--home-bg);
}

.home-hero h1 {
  font-family: var(--ent-display);
  font-size: clamp(44px, 6vw, 80px);
  font-weight: 600;
  letter-spacing: -0.005em;
  line-height: 1.0714285714;
  margin: 18px 0 0;
  color: #1d1d1f;
}

.home-sub {
  font-family: var(--ent-text);
  font-size: clamp(17px, 2.2vw, 24px);
  font-weight: 400;
  color: #6e6e73;
  letter-spacing: 0.01em;
  margin: 18px 0 0;
}

.home-cta-row { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; margin-top: 34px; }
.home-hero .home-cta-row { margin-top: 40px; }

/* apple.com 蓝色 CTA 胶囊 */
.home-cta-row .btn { border-radius: 980px; padding: 12px 28px; font-size: 16px; min-height: 46px; }
.home-cta-row .btn::before { opacity: 0; }
.home-cta-row .btn-primary {
  background: var(--home-link);
  border: 1px solid transparent;
  color: #ffffff;
  box-shadow: none;
}
.home-cta-row .btn-primary:hover {
  background: #0077ed;
  border-color: transparent;
  color: #ffffff;
  box-shadow: none;
}
.home-cta-row .btn-ghost {
  background: transparent;
  border: 1px solid var(--home-link);
  color: var(--home-link);
  box-shadow: none;
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
}
.home-cta-row .btn-ghost:hover {
  background: rgba(0, 102, 204, 0.08);
  border-color: var(--home-link);
  color: var(--home-link);
  box-shadow: none;
}

/* 最新上架:全宽纯黑横幅(明星产品位) */
.home-feature {
  width: 100vw;
  margin-left: calc(50% - 50vw);
  padding: clamp(40px, 5vw, 60px) 24px 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  background: var(--home-dark);
}

.home-feature .home-cover {
  width: clamp(170px, 15vw, 200px);
  margin-top: auto;
}

/* 两列圆角卡片网格(产品卡位) */
.home-grid {
  width: 100vw;
  margin-left: calc(50% - 50vw);
  margin-top: 13px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 13px;
  padding: 0 13px 13px;
  background: var(--home-bg);
}

.home-tile {
  border-radius: 18px;
  padding: 42px 26px 0;
  min-height: 480px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  overflow: hidden;
  position: relative;
  color: var(--tile-fg, #f5f5f7);
}
/* 底色渲染方式与 .ent-scene 完全一致:封面主色 + 102° 明暗薄纱(薄纱随主色深浅自适应) */
.home-tile::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--tile-scrim, linear-gradient(102deg, rgba(0, 0, 0, 0.74) 0%, rgba(0, 0, 0, 0.5) 52%, rgba(0, 0, 0, 0.16) 100%));
}
.home-tile > * { position: relative; z-index: 1; }

.tile-cover {
  width: clamp(160px, 16vw, 205px);
  margin-top: auto;          /* 撑到卡片底部,与 apple.com 产品位一致 */
  aspect-ratio: 5 / 7;
  border-radius: 4px 12px 12px 4px;
  overflow: hidden;
  background: #ffffff;
  box-shadow: var(--cover-shadow);
  cursor: pointer;
  transition: transform 0.45s var(--ease-out), box-shadow 0.45s var(--ease-out);
}

.tile-cover:hover {
  transform: scale(1.04) translateY(-6px);
}

.tile-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }

.tile-title {
  font-family: var(--ent-display);
  font-size: clamp(26px, 2.6vw, 36px);
  font-weight: 600;
  letter-spacing: -0.005em;
  line-height: 1.1;
  margin: 12px 0 0;
  color: inherit;
}

.tile-summary {
  font-family: var(--ent-text);
  font-size: 15px;
  line-height: 1.7;
  letter-spacing: 0.01em;
  color: var(--tile-sub, rgba(245, 245, 247, 0.82));
  max-width: 34em;
  margin: 12px 0 0;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow: hidden;
}

.tile-tagline {
  font-family: var(--ent-text);
  font-size: 17px;
  color: var(--tile-sub, rgba(245, 245, 247, 0.68));
  letter-spacing: 0.01em;
  margin: 10px 0 0;
}

.tile-meta-text {
  font-family: var(--ent-text);
  font-size: 13.5px;
  color: var(--tile-sub, rgba(245, 245, 247, 0.68));
  letter-spacing: 0.01em;
}

.tile-links { display: flex; gap: 22px; margin-top: 16px; margin-bottom: clamp(20px, 2.5vw, 30px); }

@media (max-width: 819px) {
  .home-grid { grid-template-columns: 1fr; padding: 0 13px 13px; }
  .home-tile { min-height: 430px; padding: 34px 20px 0; }
}

.home-cover {
  width: clamp(210px, 26vw, 300px);
  aspect-ratio: 5 / 7;
  border-radius: 4px 16px 16px 4px;
  overflow: hidden;
  box-shadow: var(--cover-shadow);
  cursor: pointer;
  transition: transform 0.45s var(--ease-out);
}

.home-cover:hover {
  transform: scale(1.035) translateY(-8px);
}

.home-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }

.home-title {
  font-family: var(--ent-display);
  font-size: clamp(30px, 3.4vw, 46px);
  font-weight: 600;
  letter-spacing: -0.005em;
  line-height: 1.0714285714;
  margin: 12px 0 0;
  color: var(--home-dark-text);
}

.home-author {
  font-family: var(--ent-text);
  font-size: clamp(15px, 1.8vw, 19px);
  color: var(--home-dark-sub);
  letter-spacing: 0.01em;
  margin: 8px 0 0;
}

.home-meta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 12px;
}

.home-excerpt {
  max-width: 580px;
  font-family: var(--ent-text);
  font-size: clamp(15px, 1.4vw, 19px);
  line-height: 1.6;
  letter-spacing: 0.01em;
  color: var(--home-dark-sub);
  margin: 12px 0 0;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

.home-links { display: flex; gap: clamp(18px, 3vw, 34px); margin-top: 16px; margin-bottom: clamp(22px, 2.6vw, 30px); flex-wrap: wrap; justify-content: center; }

.home-link {
  border: 0;
  background: transparent;
  font-family: var(--ent-text);
  font-size: 17px;
  font-weight: 400;
  letter-spacing: -0.01em;
  color: var(--home-link);
  padding: 6px 2px;
  cursor: pointer;
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s var(--ease), opacity 0.2s var(--ease);
}

.home-link:hover { border-bottom-color: currentColor; }

/* 深色横幅与深色卡片文字色(苹果黑) */
.home-feature { background: var(--home-dark); }
.home-feature .home-eyebrow { color: var(--home-dark-sub); }
.home-feature .home-title { color: var(--home-dark-text); }
.home-feature .home-author,
.home-feature .home-excerpt { color: var(--home-dark-sub); }
.home-feature .home-link { color: #2997ff; }
.home-feature .nm-date { color: var(--home-dark-sub); }


@media (max-width: 559.98px) {
  .home-hero { min-height: 64vh; padding: 60px 18px 70px; }
  .home-links { flex-direction: column; gap: 10px; align-items: center; }
}

/* ==========================================================================
   未完待续 · 复刻 apple.com 首页「Endless entertainment.」media-gallery
   断点 / 卡片尺寸 / 间距 / 字号 / 动效时长均取自 apple.com 线上样式表
   ========================================================================== */
.home-ent {
  /* —— apple.com :root 画廊变量(原值) —— */
  --media-gallery-tile-gap: 13px;
  --media-gallery-dotnav-gap: 12px;
  --media-gallery-section-padding-bottom: var(--media-gallery-dotnav-gap);
  --media-gallery-slide-duration: 800ms;
  --media-gallery-tile-width: 688px;
  --media-gallery-tile-height: calc(var(--media-gallery-tile-width) * 0.5334);
  --media-gallery-headline-margin-bottom: 17px;
  --media-gallery-bottom-content-padding-left: 43px;
  --media-gallery-bottom-content-padding-right: 43px;
  --fam-tile-width: 188px;
  --fam-tile-height: 254px;

  /* —— apple.com dotnav 变量(原值) —— */
  --sk-dotnav-size: 8px;
  --sk-dotnav-margin-block: 8px;
  --sk-dotnav-margin-inline: 8px;
  --sk-dotnav-height: calc(var(--sk-dotnav-margin-block) * 2 + var(--sk-dotnav-size));
  --sk-dotnav-background: rgba(0, 0, 0, 0.42);
  --sk-dotnav-background-hover: rgba(0, 0, 0, 0.54);
  --sk-dotnav-background-current: rgba(0, 0, 0, 0.8);
  --sk-dotnav-timed-track-width: 32px;
  --sk-dotnav-timed-duration: 4000ms;   /* apple: item 4.16s − transitionOffset 0.16s */
  --sk-dotnav-timed-track-color: rgb(0, 0, 0);
  --sk-dotnav-timed-track-background-color: rgba(0, 0, 0, 0.48);
  --sk-dotnav-iconcontrol-icon-size: 24px;
  --sk-dotnav-iconcontrol-content-color: rgba(0, 0, 0, 0.48);
  --sk-dotnav-iconcontrol-content-color-hover: rgba(0, 0, 0, 0.72);
  --sk-dotnav-scrim-solid-iconcontrol-scrim-color: rgb(232, 232, 237);
  --sk-dotnav-scrim-solid-iconcontrol-scrim-color-hover: rgb(236, 236, 240);
  --sk-dotnav-scrim-solid-iconcontrol-scrim-color-active: rgb(223, 223, 228);
  --sk-dotnav-hover-animation-duration: 120ms;

  --ent-display: "SF Pro Display", "SF Pro SC", system-ui, -apple-system, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  --ent-text: "SF Pro Text", "SF Pro SC", system-ui, -apple-system, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;

  width: 100vw;
  margin-left: calc(50% - 50vw);
  background: #f5f5f7;
  overflow: hidden;
}

.endless-entertainment {
  display: flex;
  flex-direction: column;
  background-color: #f5f5f7;
  padding-top: 53px;
  padding-bottom: var(--media-gallery-section-padding-bottom);
}

/* —— 标题 —— */
.media-gallery-headline-container {
  margin-bottom: var(--media-gallery-headline-margin-bottom);
  text-align: center;
}

.media-gallery-headline {
  font-size: 56px;
  line-height: 1.0714285714;
  font-weight: 600;
  letter-spacing: -0.005em;     /* apple.com 英文排版原值 */
  font-family: var(--ent-display);
  color: #000;
  margin: 0;
  padding: 0 20px;
}

/* —— 画廊主体 —— */
.media-gallery {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  width: 100%;
}

.media-gallery-item-container {
  position: relative;
  width: calc(var(--media-gallery-tile-width) + var(--media-gallery-tile-gap));
  height: var(--media-gallery-tile-height);
  margin: 0;
  padding: 0;
  list-style: none;
  touch-action: pan-y;
  outline: none;
}

.media-gallery-item-container:focus-visible {
  outline: 2px solid #0071e3;
  outline-offset: 4px;
}

.media-gallery-item {
  position: absolute;
  top: 0;
  left: 0;
  width: calc(var(--media-gallery-tile-width) + var(--media-gallery-tile-gap));
  height: 100%;
  display: flex;
  justify-content: center;
  background-color: unset;
  transform-style: preserve-3d;
  will-change: transform;
  z-index: 1;
  cursor: pointer;
}

.media-gallery-item.current-item { z-index: 2; }

.media-gallery-wrapper-link {
  display: block;
  position: relative;
  width: var(--media-gallery-tile-width);
  height: 100%;
  pointer-events: none;
  overflow: hidden;
  background-color: #000;
  text-decoration: none !important;
  z-index: 4;
  backface-visibility: hidden;
  transform: translateZ(0);
}

.media-gallery-item.current-item .media-gallery-wrapper-link { pointer-events: all; }

/* —— 第一排大卡:文案居左、封面居右,图片不铺满 —— */

.ent-scene {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: clamp(20px, 3vw, 56px);
  padding-left: var(--media-gallery-bottom-content-padding-left);
  padding-right: calc(var(--media-gallery-bottom-content-padding-right) + 24px);
  color: var(--tile-fg, #f5f5f7);
  overflow: hidden;
}
/* 压暗/提亮薄纱随主色深浅自适应,保证任何配色下文字都可读 */
.ent-scene::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--tile-scrim, linear-gradient(102deg, rgba(0, 0, 0, 0.74) 0%, rgba(0, 0, 0, 0.5) 52%, rgba(0, 0, 0, 0.16) 100%));
}
.ent-scene > * { position: relative; z-index: 1; }

.ent-scene-copy {
  flex: 1 1 auto;
  min-width: 0;
  text-align: left;
  padding-block: clamp(20px, 4vw, 44px);
}

.ent-eyebrow {
  font-family: var(--ent-text);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--tile-sub, rgba(245, 245, 247, 0.62));
  margin: 0;
}

.ent-scene-title {
  font-family: var(--ent-display);
  font-size: clamp(30px, 4.4vw, 62px);
  line-height: 1.06;
  font-weight: 700;
  letter-spacing: -0.015em;
  color: inherit;
  margin: 12px 0 0;
}

.ent-scene-meta {
  font-family: var(--ent-text);
  font-size: clamp(13px, 1.3vw, 17px);
  font-weight: 400;
  letter-spacing: 0.01em;
  color: var(--tile-sub, rgba(245, 245, 247, 0.68));
  margin: 10px 0 0;
}

.ent-scene-note {
  font-family: var(--ent-text);
  font-size: clamp(14px, 1.5vw, 19px);
  line-height: 1.55;
  font-weight: 400;
  letter-spacing: 0.01em;
  color: var(--tile-sub, rgba(245, 245, 247, 0.76));
  margin: 16px 0 0;
  max-width: 34em;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow: hidden;
}

.ent-scene-cover {
  flex: 0 0 auto;
  height: 72%;
  aspect-ratio: 2 / 3;
  border-radius: 5px 14px 14px 5px;
  overflow: hidden;
  box-shadow: var(--cover-shadow);
  background: rgba(255, 255, 255, 0.06);
}
.ent-scene-cover img,
.ent-scene-cover .cover-placeholder { width: 100%; height: 100%; object-fit: cover; display: block; }
.ent-scene-cover .ph-title { font-size: clamp(15px, 1.6vw, 26px); }
.ent-scene-cover .ph-author { font-size: clamp(11px, 1vw, 14px); }

/* —— 第二排小卡:与第一排共用索引的轮播轨(apple.com fam 行同构) —— */
.fam-media-gallery {
  width: 100%;
  margin-top: var(--media-gallery-tile-gap);
}

.fam-media-gallery .media-gallery-item-container {
  width: calc(var(--fam-tile-width) + var(--media-gallery-tile-gap));
  height: var(--fam-tile-height);
}

.fam-media-gallery .media-gallery-item {
  width: calc(var(--fam-tile-width) + var(--media-gallery-tile-gap));
}

.fam-media-gallery .media-gallery-wrapper-link {
  width: var(--fam-tile-width);
}
/* 两侧卡不压暗、无明暗过渡:与当前卡同等亮度呈现(apple 侧卡为静态完整卡面) */

.fam-card {
  position: relative;
  height: 100%;
  border-radius: 18px;
  overflow: hidden;
  color: #f5f5f7;
  cursor: pointer;
  outline: none;
}
.fam-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--card-scrim, linear-gradient(150deg, rgba(0, 0, 0, 0.6) 0%, rgba(0, 0, 0, 0.32) 60%, rgba(0, 0, 0, 0.5) 100%));
}
.fam-card:hover { box-shadow: 0 20px 44px rgba(0, 0, 0, 0.3); }
.fam-card:focus-visible { outline: 2px solid #0071e3; outline-offset: 3px; }
/* 封面取色异步写回时颜色更平滑(渐变本身不可过渡,仅过渡纯色属性) */
.fam-card { transition: color 0.4s ease; }

.fam-chip {
  position: absolute;
  z-index: 2;
  top: 14px;
  left: 16px;
  font-family: var(--ent-text);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: currentColor;
  border: 1px solid currentColor;
  border-radius: 980px;
  padding: 3px 10px;
  opacity: 0.82;
}

.fam-cover {
  position: absolute;
  z-index: 1;
  top: 50%;
  right: 18px;
  transform: translateY(-50%);
  height: 68%;
  aspect-ratio: 2 / 3;
  border-radius: 4px 9px 9px 4px;
  overflow: hidden;
  box-shadow: var(--cover-shadow);
}
.fam-cover img,
.fam-cover .cover-placeholder { width: 100%; height: 100%; object-fit: cover; display: block; }
.fam-cover .ph-title { font-size: 11px; }
.fam-cover .ph-author { font-size: 9px; }

.fam-foot {
  position: absolute;
  z-index: 2;
  left: 18px;
  right: 112px;
  bottom: 16px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  min-width: 0;
}

/* 小卡简介:替代原来的按钮 */
.fam-summary {
  font-family: var(--ent-text);
  font-size: 12.5px;
  line-height: 1.55;
  letter-spacing: 0.01em;
  color: var(--card-soft, rgba(245, 245, 247, 0.7));
  margin: 2px 0 0;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow: hidden;
}

.fam-note {
  font-family: var(--ent-text);
  font-size: 14px;
  line-height: 1.35;
  letter-spacing: -0.01em;
  margin: 0;
  min-width: 0;
}
.fam-note strong {
  display: block;
  font-weight: 600;
  color: currentColor;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.fam-note span {
  display: block;
  font-size: 12.5px;
  font-weight: 400;
  color: var(--card-soft, rgba(245, 245, 247, 0.66));
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.media-gallery-is-sliding { pointer-events: none; }

/* —— 定时 dotnav —— */
.media-gallery-dotnav {
  margin-top: var(--media-gallery-dotnav-gap);
  margin-bottom: var(--media-gallery-dotnav-gap);
  width: 100%;
  height: var(--sk-dotnav-iconcontrol-icon-size);
  position: relative;
  display: flex;
  align-items: center;
  flex-direction: row-reverse;
  justify-content: center;
  order: 4;
}

.dotnav-items {
  margin: 0;
  padding: 0;
  list-style: none;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  height: var(--sk-dotnav-height);
  width: auto;
  max-width: calc(100% - 2 * (var(--sk-dotnav-iconcontrol-icon-size) + 12px));
  overflow: hidden;   /* 位移/隐藏的圆点在列表边缘裁掉(apple 同款) */
}

.dotnav-item { display: block; min-width: 0; }

/* —— 变距 dotnav(apple.com 同款):圆点 > 7 个时按距离分级缩放 ——
   当前=轨道(1.0),距离 1=0.75,距离 2=0.5,更远/窗外=隐藏(scale .5 + 尺寸 0 + 淡出);
   截断类由 JS 按当前点实时分配,形态迁移走 320ms 过渡 */
.dotnav-item.dotnav-trunc-2 { --sk-dotnav-scale: 0.75; }
.dotnav-item.dotnav-trunc-3 { --sk-dotnav-scale: 0.5; }
.dotnav-item.dotnav-trunc-4 {
  --sk-dotnav-scale: 0.5;
  --sk-dotnav-opacity: 0;
  --sk-dotnav-margin-block: 0;
  --sk-dotnav-margin-inline: 0;
  --sk-dotnav-size: 0;
}
.dotnav-item.dotnav-trunc-4 .dotnav-link {
  clip: rect(1px, 1px, 1px, 1px);
  clip-path: inset(0 0 99.9% 99.9%);
  overflow: hidden;
  height: 1px;
  width: 1px;
  padding: 0;
  border: 0;
}
.dotnav-transitioning .dotnav-link { pointer-events: none; }
.dotnav-item.dotnav-transitioning .dotnav-link {
  transition: width 320ms ease-in-out, height 320ms ease-in-out,
              padding-block 320ms ease-in-out, padding-inline 320ms ease-in-out;
}
.dotnav-transitioning .dotnav-link::before {
  transition: background-color var(--sk-dotnav-hover-animation-duration) linear,
              scale 320ms ease-in-out,
              opacity 320ms ease-in-out;
}
/* 旧当前点:轨道收起后再缩尺寸(apple 的 200ms 延迟细节) */
.dotnav-timed .dotnav-previous-current .dotnav-link::before {
  transition: scale 120ms ease-in-out 200ms,
              opacity 320ms ease-in-out,
              background-color var(--sk-dotnav-hover-animation-duration) linear;
}
/* 整排位移:窗口滑动时行内容按 8px×步数回弹(apple 的 shift keyframes) */
@keyframes dotnav-row-shift-left-1 { 0% { translate: 8px 0; } 100% { translate: 0 0; } }
@keyframes dotnav-row-shift-left-2 { 0% { translate: 16px 0; } 100% { translate: 0 0; } }
@keyframes dotnav-row-shift-left-3 { 0% { translate: 24px 0; } 100% { translate: 0 0; } }
@keyframes dotnav-row-shift-right-1 { 0% { translate: -8px 0; } 100% { translate: 0 0; } }
@keyframes dotnav-row-shift-right-2 { 0% { translate: -16px 0; } 100% { translate: 0 0; } }
@keyframes dotnav-row-shift-right-3 { 0% { translate: -24px 0; } 100% { translate: 0 0; } }
.dotnav-item.dotnav-shift-left-1 { animation: dotnav-row-shift-left-1 320ms ease-in-out both; }
.dotnav-item.dotnav-shift-left-2 { animation: dotnav-row-shift-left-2 320ms ease-in-out both; }
.dotnav-item.dotnav-shift-left-3 { animation: dotnav-row-shift-left-3 320ms ease-in-out both; }
.dotnav-item.dotnav-shift-right-1 { animation: dotnav-row-shift-right-1 320ms ease-in-out both; }
.dotnav-item.dotnav-shift-right-2 { animation: dotnav-row-shift-right-2 320ms ease-in-out both; }
.dotnav-item.dotnav-shift-right-3 { animation: dotnav-row-shift-right-3 320ms ease-in-out both; }
/* 窗口边缘圆点的交错淡入/淡出(apple 的 40ms 级联) */
@keyframes dotnav-become-visible { 0% { opacity: 0; scale: 0; } 100% { opacity: 1; scale: 1; } }
@keyframes dotnav-become-invisible { 0% { opacity: 1; } 100% { opacity: 0; } }
/* apple 的级联节奏:fade-in-delay=180ms,进入点按距边 0/1/2 依次 100/140/180ms 淡入 */
.dotnav-item.dotnav-becoming-visible .dotnav-link::before { animation: dotnav-become-visible 140ms ease-in-out both; }
.dotnav-item.dotnav-becoming-visible.dotnav-stagger-1 .dotnav-link::before { animation-delay: 100ms; }
.dotnav-item.dotnav-becoming-visible.dotnav-stagger-2 .dotnav-link::before { animation-delay: 140ms; }
.dotnav-item.dotnav-becoming-visible.dotnav-stagger-3 .dotnav-link::before { animation-delay: 180ms; }
/* 离开点淡出即起跑,按距边 0/1/2 依次 0/40/80ms */
.dotnav-item.dotnav-becoming-invisible .dotnav-link::before { animation: dotnav-become-invisible 140ms ease-in-out both; }
.dotnav-item.dotnav-becoming-invisible.dotnav-stagger-1 .dotnav-link::before { animation-delay: 0ms; }
.dotnav-item.dotnav-becoming-invisible.dotnav-stagger-2 .dotnav-link::before { animation-delay: 40ms; }
.dotnav-item.dotnav-becoming-invisible.dotnav-stagger-3 .dotnav-link::before { animation-delay: 80ms; }

.dotnav-link {
  outline: none;
  box-sizing: content-box;
  display: block;
  position: relative;
  padding-block: var(--sk-dotnav-margin-block);
  padding-inline: var(--sk-dotnav-margin-inline);
  height: var(--sk-dotnav-size);
  width: var(--sk-dotnav-size);
  appearance: none;
  -webkit-appearance: none;
  background: none;
  border: 0;
  cursor: pointer;
  -webkit-user-select: none;
  user-select: none;
  transition: height var(--sk-dotnav-hover-animation-duration) linear,
              width var(--sk-dotnav-hover-animation-duration) linear;
}

.dotnav-link::before {
  content: "";
  display: block;
  border-radius: 999px;
  position: absolute;
  top: calc(50% - var(--sk-dotnav-size) / 2);
  left: calc(50% - var(--sk-dotnav-size) / 2);
  height: var(--sk-dotnav-size);
  width: var(--sk-dotnav-size);
  scale: var(--sk-dotnav-scale, 1);
  opacity: var(--sk-dotnav-opacity, 1);
  background: var(--sk-dotnav-background);
  transition: background-color var(--sk-dotnav-hover-animation-duration) linear,
              scale 320ms ease-in-out,
              opacity 320ms ease-in-out;
}

.dotnav-link:hover::before { background: var(--sk-dotnav-background-hover); }
.current .dotnav-link { cursor: default; }
.current .dotnav-link::before { background: var(--sk-dotnav-background-current); }

.dotnav-timed .dotnav-link { transition: width 250ms linear; }

/* 自动播放态:当前圆点展开成 32px 进度条 */
.dotnav-timed .dotnav-link::after {
  content: "";
  position: absolute;
  display: block;
  inset-block: var(--sk-dotnav-margin-block);
  left: var(--sk-dotnav-margin-inline);
  width: var(--sk-dotnav-size);
  border-radius: 999px;
  opacity: 0;
  animation-iteration-count: 1;
  animation-play-state: paused;
  animation-fill-mode: forwards;
  animation-duration: var(--sk-dotnav-timed-duration);
  animation-timing-function: linear;
}

.dotnav-timed .dotnav-focused .dotnav-link { width: var(--sk-dotnav-timed-track-width); }
.dotnav-timed .dotnav-focused .dotnav-link::before {
  left: calc(50% - 16px);
  width: calc(100% - var(--sk-dotnav-margin-inline) * 2);
  background: var(--sk-dotnav-timed-track-background-color);
  animation: dotnav-timed-dot-expand 250ms ease-in;
}
.dotnav-timed .current.dotnav-focused .dotnav-link { pointer-events: none; }
.dotnav-timed .current.dotnav-focused .dotnav-link::after {
  background: var(--sk-dotnav-background-current);
  animation-name: dotnav-timed-animation;
  animation-play-state: running;
  animation-delay: 160ms;                       /* apple AutoPlay.transitionOffset: 进度条晚 160ms 起跑 */
  opacity: 1;
  transition: opacity 80ms ease-in 240ms;       /* 展开起步后 240ms,80ms 淡入 */
}
.dotnav-timed-paused .current .dotnav-link::after { animation-play-state: paused; }
/* 暂停态要压过运行态:暂停时手动选点,新轨道展开但进度保持冻结 */
.dotnav-timed.dotnav-timed-paused .current.dotnav-focused .dotnav-link::after { animation-play-state: paused; }

@keyframes dotnav-timed-animation {
  0% { width: var(--sk-dotnav-size); }
  100% { width: calc(100% - var(--sk-dotnav-margin-inline) * 2); }
}
@keyframes dotnav-timed-dot-expand {
  0% { left: calc(50% - var(--sk-dotnav-size) / 2); width: 8px; }
  100% { left: calc(50% - 16px); width: 32px; }
}
@keyframes dotnav-timed-dot-shrink {
  0% { left: calc(50% - 16px); width: 32px; }
  100% { left: calc(50% - var(--sk-dotnav-size) / 2); width: 8px; }
}
.dotnav-timed .dotnav-previous-current .dotnav-link::before {
  animation: dotnav-timed-dot-shrink 250ms ease-out;
}

/* —— 播放 / 暂停 —— */
.media-gallery-dotnav-iconcontrol {
  position: absolute;
  top: 0;
  right: calc(12px + env(safe-area-inset-right));
  border-radius: 50%;
  margin: 0;
  padding: 0;
  border: 0;
  cursor: pointer;
  color: var(--sk-dotnav-iconcontrol-content-color);
  background: var(--sk-dotnav-scrim-solid-iconcontrol-scrim-color);
  transition: color var(--sk-dotnav-hover-animation-duration) linear,
              background-color 100ms linear;
}
.media-gallery-dotnav-iconcontrol:hover {
  color: var(--sk-dotnav-iconcontrol-content-color-hover);
  background: var(--sk-dotnav-scrim-solid-iconcontrol-scrim-color-hover);
}
.media-gallery-dotnav-iconcontrol:active {
  background: var(--sk-dotnav-scrim-solid-iconcontrol-scrim-color-active);
}
.media-gallery-dotnav-iconcontrol-icon {
  display: flex;
  justify-content: center;
  align-items: center;
  height: var(--sk-dotnav-iconcontrol-icon-size);
  width: var(--sk-dotnav-iconcontrol-icon-size);
}
.media-gallery-dotnav-iconcontrol-icon svg { height: 100%; fill: currentColor; }
.home-ent .dotnav-iconcontrol-play { display: none; }
.home-ent .dotnav-timed-paused .dotnav-iconcontrol-play { display: block; }
.home-ent .dotnav-timed-paused .dotnav-iconcontrol-pause { display: none; }

.media-gallery-is-sliding { pointer-events: none; }

/* —— 断点(apple.com:1441 / 1069 / 734)—— */
@media (min-width: 1069px) {
  .home-ent {
    --media-gallery-tile-width: min(930px, calc(100vw - 120px));
    --media-gallery-tile-height: calc(var(--media-gallery-tile-width) * 0.5334);
    --media-gallery-headline-margin-bottom: 26px;
    --media-gallery-bottom-content-padding-left: 48px;
    --media-gallery-bottom-content-padding-right: 48px;
    --media-gallery-bottom-content-padding-bottom: 40px;
    /* apple.com fam 行:417 × 234 */
    --fam-tile-width: 417px;
    --fam-tile-height: 234px;
  }
}

@media (min-width: 1441px) {
  .home-ent {
    --media-gallery-tile-width: min(1250px, calc(100vw - 180px));
    --media-gallery-tile-height: calc(var(--media-gallery-tile-width) * 0.5344);
    --media-gallery-bottom-content-padding-left: 70px;
    --media-gallery-bottom-content-padding-right: 70px;
    --media-gallery-bottom-content-padding-bottom: 58px;
    /* apple.com fam 行:470 × 264 */
    --fam-tile-width: 470px;
    --fam-tile-height: 264px;
  }
}

@media (max-width: 1068px) {
  .home-ent {
    --media-gallery-tile-width: min(688px, calc(100vw - 96px));
    --media-gallery-headline-margin-bottom: 17px;
    --media-gallery-bottom-content-padding-left: 43px;
    --media-gallery-bottom-content-padding-right: 43px;
    --media-gallery-bottom-content-padding-bottom: 34px;
    /* apple.com fam 行:188 × 254 */
    --fam-tile-width: 188px;
    --fam-tile-height: 254px;
  }
  .endless-entertainment { padding-top: 36px; }
  .media-gallery-headline { font-size: 32px; line-height: 1.125; letter-spacing: 0.004em; }
  .ent-scene-cover { height: 62%; }
  .ent-scene-note { -webkit-line-clamp: 3; }
}

@media (max-width: 734px) {
  .home-ent {
    --media-gallery-tile-width: min(275px, calc(100vw - 60px));
    --media-gallery-tile-height: calc(var(--media-gallery-tile-width) * 1.8036);
    --media-gallery-dotnav-gap: 10px;
    --media-gallery-bottom-content-padding-left: 22px;
    --media-gallery-bottom-content-padding-right: 22px;
    --media-gallery-bottom-content-padding-bottom: 30px;
    --fam-tile-width: 188px;
    --fam-tile-height: 254px;
    /* 16 个圆点在 375px 宽仍要与播放钮留出余量 */
    --sk-dotnav-margin-inline: 4px;
  }

  /* 大卡在窄屏转竖排:封面上、文案下 */
  .ent-scene {
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    gap: 0;
    padding: 0 var(--media-gallery-bottom-content-padding-left) 26px;
    text-align: center;
  }
  /* 窄屏竖排的暗色渐变固定:文字恒为白,不受取色明暗影响 */
  .ent-scene, .ent-scene-title { color: #f5f5f7; }
  .ent-eyebrow, .ent-scene-meta, .ent-scene-note { color: rgba(245, 245, 247, 0.72); }
  .ent-scene::before {
    background: linear-gradient(rgba(0, 0, 0, 0) 42%, rgba(0, 0, 0, 0.72) 74%),
                linear-gradient(180deg, rgba(0, 0, 0, 0.34) 0%, rgba(255, 255, 255, 0) 260px);
  }
  .ent-scene-cover {
    position: absolute;
    top: 9%;
    left: 50%;
    transform: translateX(-50%);
    height: 44%;
    box-shadow: -14px 18px 40px rgba(0, 0, 0, 0.45);
  }
  .ent-scene-copy { padding-block: 0; flex: 0 0 auto; }
  .ent-eyebrow { font-size: 11px; }
  .ent-scene-title { font-size: 25px; margin-top: 8px; }
  .ent-scene-meta { font-size: 12.5px; margin-top: 6px; }
  .ent-scene-note {
    font-size: 13px;
    line-height: 1.5;
    margin-top: 10px;
    max-width: none;
    -webkit-line-clamp: 3;
  }

  /* 小卡在窄屏:封面居右上、文案靠左下 */
  .fam-foot { right: 84px; bottom: 12px; left: 14px; }
  .fam-chip { top: 11px; left: 14px; }
  .fam-cover { right: 12px; height: 62%; }
  .fam-summary { -webkit-line-clamp: 2; font-size: 11.5px; }
  .fam-note { font-size: 13px; }
  .fam-note span { font-size: 11.5px; }
}

@media (prefers-reduced-motion: reduce) {
  .media-gallery-item { transition: none; }
}

/* ============ 响应式断点 ============ */
@media (max-width: 559.98px) {
  main { padding: 30px 18px 60px; }
  .panel { padding: 22px 20px; }
  .stats-hero { padding: 26px 22px 24px; }
  .hstat .num { font-size: 32px; }
  .modal { align-items: flex-end; }
  .modal-box {
    max-height: 94dvh;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    padding-bottom: max(30px, env(safe-area-inset-bottom));
  }
}

@media (min-width: 560px) {
  .book-grid { grid-template-columns: repeat(3, 1fr); }
  .stats-hero-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (min-width: 820px) {
  .topbar-inner { padding: 0 20px; flex-wrap: nowrap; }
  .topbar-actions { flex: 0 0 auto; }
  .search-box { width: 180px; flex: 0 1 180px; }
  main { padding: 44px 24px 90px; }
  .book-grid { grid-template-columns: repeat(4, 1fr); gap: 38px 24px; }
  .stats-hero-grid { grid-template-columns: repeat(5, 1fr); }
  .stats-panels { grid-template-columns: 1fr 1fr; }
  .panel-wide { grid-column: 1 / -1; }
  .modal { align-items: center; padding: 28px; }
  .modal-box { border-radius: var(--radius-lg); box-shadow: var(--shadow-pop); max-height: calc(100dvh - 56px); }
  .form-grid { grid-template-columns: 1fr 1fr; }
  .detail-body { flex-direction: row; }
  .detail-cover { width: 200px; align-self: flex-start; }
}

@media (min-width: 1100px) {
  .book-grid { grid-template-columns: repeat(5, 1fr); }
}

@media (min-width: 1400px) {
  main { max-width: 1220px; }
  footer { max-width: 1220px; }
  .book-grid { grid-template-columns: repeat(6, 1fr); }
}

/* 触屏优化 */
@media (hover: none) {
  .book-card:hover .card-cover { transform: none; box-shadow: var(--cover-shadow); }
  .book-card:active .card-cover { transform: scale(0.98); }
}

body.modal-open { overflow: hidden; }

/* 移动菜单展开时禁止背景滚动 */
body.menu-open { overflow: hidden; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

/* 书格卡片(封面取色底)上的眉标、星级、链接配色(随主色深浅自适应) */
.home-tile .home-eyebrow { color: var(--tile-sub, rgba(255, 255, 255, 0.62)); }
.home-tile .home-link { color: var(--tile-link, #2997ff); }

/* ============ 榜单(Apple 瓦片节奏:表面色变化即分隔,零装饰性 chrome) ============ */
/* 三个瓦片:parchment 英雄区 → 近黑年度之书 → 白色高分榜 → 近黑-2 重读榜 */
.rank-tile { background: var(--card); }
/* 三个瓦片:parchment 英雄区 → 近黑重读榜 */

.rank-inner {
  max-width: 980px;
  margin: 0 auto;
  padding: 80px 24px;   /* {spacing.section} */
}

/* —— 英雄区(product-tile-parchment) —— */
.rank-hero { background: var(--paper); text-align: center; }
.rank-eyebrow {
  margin: 0 0 14px;
  font-size: 14px; font-weight: 600; letter-spacing: -0.224px;
  color: var(--accent);            /* Action Blue:唯一强调色 */
  text-transform: uppercase;
}
.rank-hero-title {
  margin: 0 0 12px;
  font-family: var(--serif);       /* SF Pro Display 系 */
  font-size: 48px; font-weight: 600; line-height: 1.1; letter-spacing: -0.5px;
}
.rank-hero-sub { margin: 0; font-size: 17px; letter-spacing: -0.374px; color: var(--ink-2); }

/* —— 榜单列表(store-utility-card 的行化:发丝线分隔,零阴影) —— */
.rank-board-title {
  margin: 0 0 6px;
  font-family: var(--serif);
  font-size: 28px; font-weight: 600; line-height: 1.19; letter-spacing: -0.374px;
}
.rank-board-sub { margin: 0 0 28px; font-size: 14px; letter-spacing: -0.224px; color: var(--ink-3); }

.rank-list { list-style: none; margin: 0; padding: 0; }
.rank-row {
  display: flex;
  align-items: center;
  gap: 16px;
  width: 100%;
  padding: 16px 4px;
  background: none;
  border: 0;
  border-bottom: 1px solid var(--hairline-soft);
  text-align: left;
  transition: transform 0.15s var(--ease);
}
.rank-list li:last-child .rank-row { border-bottom: 0; }
.rank-row:active { transform: scale(0.98); }   /* 系统级按压微交互 */
.rank-row:focus-visible { outline: 2px solid #0071e3; outline-offset: 2px; border-radius: 8px; }

.rank-num {
  flex: 0 0 40px;
  font-family: var(--serif);
  font-size: 24px; font-weight: 600; line-height: 1;
  font-variant-numeric: tabular-nums;
  color: var(--ink);
}

.rank-cover { flex: 0 0 44px; }
.rank-cover img,
.rank-cover .cover-placeholder {
  width: 44px; height: 62px;
  border-radius: 4px;
  box-shadow: var(--cover-shadow);  /* 产品投影只落在封面上 */
}
.rank-cover .cover-placeholder .ph-text { display: none; }

.rank-info { flex: 1; min-width: 0; }
.rank-title {
  display: block;
  font-size: 17px; font-weight: 600; line-height: 1.24; letter-spacing: -0.374px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.rank-meta {
  display: block;
  font-size: 14px; line-height: 1.43; letter-spacing: -0.224px;
  color: var(--ink-3);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

.rank-metric { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 6px; }
.rank-count { font-size: 14px; letter-spacing: -0.224px; color: var(--ink-2); }
.rank-count b { font-family: var(--serif); font-size: 20px; font-weight: 600; color: var(--ink); }
.rank-empty { margin: 0; font-size: 14px; color: var(--ink-3); }

/* —— 响应式:834px 双列收单列,640px 标题降级,480px 瓦片收紧 —— */
@media (max-width: 834px) {
  .rank-inner { padding: 64px 24px; }
}
@media (max-width: 640px) {
  .rank-hero-title { font-size: 34px; }
  .rank-inner { padding: 48px 20px; }
}
@media (max-width: 480px) {
  .rank-hero-title { font-size: 28px; }
  .rank-num { flex-basis: 30px; font-size: 20px; }
}

