/* ============================================================
   大锤妙记 4.0 · 1:1 对齐「大锤同步」极简设计语言
   纯白画布 + 48px 微网格 + 钴蓝 #2350dc + 曜石黑 + 深色星夜模式 · 零 Emoji
   ============================================================ */

:root {
  --notes-bg: #ffffff;
  --notes-surface: #ffffff;
  --notes-tint: #f5f7fb;
  --notes-stage: #f3f5f9;
  --notes-ink: #0f172a;
  --notes-ink-2: #475569;
  --notes-muted: #5b677b;
  --notes-faint: #8492a6;
  --notes-rule: rgba(15, 23, 42, 0.08);
  --notes-rule-strong: rgba(15, 23, 42, 0.14);
  --cobalt: #2350dc;
  --cobalt-hover: #1a3fb8;
  --cobalt-deep: #1b40b8;
  --cobalt-soft: #eef3ff;
  --obsidian: #111827;
  --obsidian-hover: #1f2937;
  --ok-green: #0f766e;
  --ok-soft: #ecfdf5;
  --danger: #dc2626;
  --danger-soft: #fef2f2;
  --warn: #b45309;
  --warn-soft: #fffbeb;
  --notes-shadow: 0 1px 2px rgba(15, 23, 42, 0.03), 0 14px 34px -16px rgba(15, 23, 42, 0.09);
  --notes-grid-line: rgba(15, 23, 42, 0.032);
  --notes-ease: cubic-bezier(0.22, 1, 0.36, 1);

  /* 兼容 /admin/ 与共享变量 */
  --paper: #ffffff;
  --surface: #ffffff;
  --ink: #0f172a;
  --secondary: #475569;
  --muted: #5b677b;
  --rule: rgba(15, 23, 42, 0.08);
  --rule-strong: rgba(15, 23, 42, 0.14);
}

html[data-theme="dark"] {
  color-scheme: dark;
  --notes-bg: #0b0f19;
  --notes-surface: #111827;
  --notes-tint: #161f32;
  --notes-stage: #0f172a;
  --notes-ink: #f1f5f9;
  --notes-ink-2: #cbd5e1;
  --notes-muted: #94a3b8;
  --notes-faint: #64748b;
  --notes-rule: rgba(148, 163, 184, 0.14);
  --notes-rule-strong: rgba(148, 163, 184, 0.24);
  --cobalt: #5c8aff;
  --cobalt-hover: #7aa0ff;
  --cobalt-deep: #93b4ff;
  --cobalt-soft: rgba(92, 138, 255, 0.15);
  --obsidian: #f8fafc;
  --obsidian-hover: #e2e8f0;
  --ok-green: #34d399;
  --ok-soft: rgba(52, 211, 153, 0.14);
  --danger: #f87171;
  --danger-soft: rgba(248, 113, 113, 0.14);
  --warn: #fbbf24;
  --warn-soft: rgba(251, 191, 36, 0.14);
  --notes-shadow: 0 2px 6px rgba(0, 0, 0, 0.3), 0 16px 36px -14px rgba(0, 0, 0, 0.5);
  --notes-grid-line: rgba(148, 163, 184, 0.05);

  --paper: #0b0f19;
  --surface: #111827;
  --ink: #f1f5f9;
  --secondary: #cbd5e1;
  --muted: #94a3b8;
  --rule: rgba(148, 163, 184, 0.14);
  --rule-strong: rgba(148, 163, 184, 0.24);
}

*, *::before, *::after { box-sizing: border-box; }

body.notes-page {
  margin: 0;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  background: var(--notes-bg);
  color: var(--notes-ink);
  font-family: "XinHammer Sans", "PingFang SC", -apple-system, BlinkMacSystemFont, "Microsoft YaHei", sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: clip;
  padding-bottom: env(safe-area-inset-bottom, 0px);
}

.notes-main {
  flex: 1 0 auto;
}

.notes-page .wrap {
  width: min(74rem, calc(100% - 2.25rem));
  max-width: none;
  margin-inline: auto;
}

.notes-page a {
  text-decoration: none;
}

.notes-page button {
  font-family: inherit;
  cursor: pointer;
}

/* ============================================================
   1. 60px 大锤同步同款极简磨砂顶栏
   ============================================================ */
.notes-header-wrap {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--notes-rule);
}

html[data-theme="dark"] .notes-header-wrap {
  background: rgba(11, 15, 25, 0.86);
}

.site-header.studio-nav.notes-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 60px;
  border-bottom: 0;
  padding-block: 6px;
  padding-inline: 0;
  background: transparent;
  position: static;
}

.notes-brand-group {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex: none;
  min-width: 0;
}

.site-header.studio-nav.notes-header .notes-brand-group .identity {
  display: inline-flex;
  flex-direction: row;
  align-items: center;
  gap: 10px;
  min-height: 40px;
  text-decoration: none;
}

.notes-brand-group .brand-icon {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  object-fit: contain;
  flex: none;
}

.notes-brand-text {
  display: inline-flex;
  flex-direction: column;
  line-height: 1.05;
  gap: 2px;
}

.site-header.studio-nav.notes-header .notes-brand-text .wordmark {
  font-family: "XinHammer Logo EN", var(--sans);
  font-size: 0.72rem;
  font-weight: 720;
  letter-spacing: 0.03em;
  color: var(--cobalt);
  line-height: 1.05;
}

.site-header.studio-nav.notes-header .notes-brand-text .brand-name {
  padding-left: 0;
  border-left: 0;
  font-family: "XinHammer Logo CN", var(--sans);
  font-size: 1.06rem;
  font-weight: 840;
  letter-spacing: 0.015em;
  color: var(--notes-ink);
  white-space: nowrap;
}

.notes-back-link {
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--notes-muted);
  padding: 3px 10px;
  border-radius: 999px;
  border: 1px solid var(--notes-rule-strong);
  transition: color 140ms ease, border-color 140ms ease;
  white-space: nowrap;
}

.notes-back-link:hover {
  color: var(--cobalt);
  border-color: var(--cobalt);
}

.notes-header-actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
}

.notes-header-pill {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid var(--notes-rule-strong);
  background: var(--notes-surface);
  color: var(--notes-ink-2);
  font-size: 0.8rem;
  font-weight: 600;
  white-space: nowrap;
  transition: border-color 140ms ease, color 140ms ease;
}

.notes-header-pill:hover {
  border-color: var(--cobalt);
  color: var(--cobalt);
}

.notes-icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 999px;
  border: 1px solid var(--notes-rule-strong);
  background: var(--notes-surface);
  color: var(--notes-ink-2);
  flex: none;
  padding: 0;
  transition: color 140ms ease, border-color 140ms ease, background 140ms ease;
}

.notes-icon-btn:hover {
  color: var(--cobalt);
  border-color: var(--cobalt);
}

.notes-icon-btn-sm {
  width: 32px;
  height: 32px;
}

.notes-icon-btn.is-open {
  color: var(--cobalt);
  border-color: var(--cobalt);
  background: var(--cobalt-soft);
}

.icon-moon { display: none; }
html[data-theme="dark"] .icon-sun { display: none; }
html[data-theme="dark"] .icon-moon { display: block; }

.notes-header .site-account-pill {
  min-height: 36px;
  padding: 0 12px;
  font-size: 0.8rem;
  border-radius: 999px;
  border: 1px solid var(--notes-rule-strong);
  background: var(--notes-surface);
  color: var(--notes-ink);
  flex: none;
}

.notes-header .site-account-pill:hover {
  border-color: var(--cobalt);
  color: var(--cobalt);
}

/* ============================================================
   2. 按钮原子体系（1:1 复刻大锤同步）
   ============================================================ */
.notes-btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 22px;
  border: 1px solid var(--obsidian);
  border-radius: 999px;
  background: var(--obsidian);
  color: #ffffff;
  font-size: 0.9rem;
  font-weight: 600;
  white-space: nowrap;
  transition: background 140ms ease, opacity 140ms ease, transform 120ms ease;
}

html[data-theme="dark"] .notes-btn-primary {
  color: #0b0f19;
}

.notes-btn-primary:hover { background: var(--obsidian-hover); }
.notes-btn-primary:active { transform: scale(0.985); }
.notes-btn-primary:disabled { opacity: 0.45; cursor: not-allowed; pointer-events: none; }

.notes-btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid var(--notes-rule-strong);
  border-radius: 999px;
  background: var(--notes-surface);
  color: var(--notes-ink);
  font-size: 0.88rem;
  font-weight: 600;
  white-space: nowrap;
  transition: border-color 140ms ease, color 140ms ease, background 140ms ease;
}

.notes-btn-outline:hover {
  border-color: var(--cobalt);
  color: var(--cobalt);
}

.notes-btn-outline.is-active {
  border-color: var(--cobalt);
  background: var(--cobalt-soft);
  color: var(--cobalt);
}

.notes-btn-outline:disabled { opacity: 0.45; cursor: not-allowed; pointer-events: none; }

.notes-btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: transparent;
  color: var(--notes-ink-2);
  font-size: 0.84rem;
  font-weight: 560;
  white-space: nowrap;
  transition: background 140ms ease, color 140ms ease;
}

.notes-btn-ghost:hover {
  background: var(--notes-tint);
  color: var(--notes-ink);
}

.notes-btn-sm { min-height: 38px; padding: 0 16px; font-size: 0.84rem; }
.notes-btn-xs { min-height: 32px; padding: 0 12px; font-size: 0.78rem; }

.notes-ghost-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: 32px;
  padding: 0 10px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--notes-muted);
  font-size: 0.8rem;
  font-weight: 560;
  white-space: nowrap;
  transition: color 140ms ease, background 140ms ease;
}

.notes-ghost-link:hover {
  color: var(--cobalt);
  background: var(--cobalt-soft);
}

/* ============================================================
   3. 48px 极淡微网格可折叠首屏（右上同位锁定，零偏移）
   ============================================================ */
.notes-hero-band {
  position: relative;
  border-bottom: 1px solid var(--notes-rule);
  background-color: var(--notes-bg);
  background-image:
    linear-gradient(to right, var(--notes-grid-line) 1px, transparent 1px),
    linear-gradient(to bottom, var(--notes-grid-line) 1px, transparent 1px);
  background-size: 48px 48px;
}

.notes-hero-compact {
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 58px;
  padding-block: 10px;
}

.notes-hero-full {
  padding-block: 10px 28px;
}

html[data-hero-collapsed="true"] .notes-hero-compact { display: flex; }
html[data-hero-collapsed="true"] .notes-hero-full { display: none; }

.notes-compact-meta {
  font-size: 0.82rem;
  color: var(--notes-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

.notes-hero-toprow {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 38px;
  margin-bottom: 16px;
}

.notes-eyebrow {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--cobalt);
  letter-spacing: 0.02em;
}

.notes-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr);
  gap: clamp(1.5rem, 3.5vw, 3rem);
  align-items: center;
}

.notes-hero-copy h1 {
  font-size: clamp(1.85rem, 3.4vw, 2.75rem);
  font-weight: 760;
  line-height: 1.18;
  letter-spacing: -0.025em;
  color: var(--notes-ink);
  margin: 0 0 14px;
}

.notes-hero-copy h1 span {
  color: var(--cobalt);
}

.notes-hero-lead {
  font-size: 0.96rem;
  color: var(--notes-ink-2);
  max-width: 36rem;
  margin: 0 0 20px;
}

.notes-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.notes-hero-media {
  margin: 0;
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid var(--notes-rule);
  background: var(--notes-stage);
  box-shadow: var(--notes-shadow);
}

.notes-hero-media img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  display: block;
}

/* ============================================================
   4. 工作台容器、一体化工具栏与按需场景抽屉
   ============================================================ */
.notes-workspace {
  padding-block: 20px 56px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.notes-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.notes-cat-wrap {
  position: relative;
  min-width: 0;
  max-width: 100%;
  flex: 1 1 auto;
}

.notes-cat-wrap.can-scroll-right .notes-filter-tabs {
  mask-image: linear-gradient(to right, #000 calc(100% - 26px), transparent);
  -webkit-mask-image: linear-gradient(to right, #000 calc(100% - 26px), transparent);
}

.notes-cat-wrap.can-scroll-left .notes-filter-tabs {
  mask-image: linear-gradient(to right, transparent, #000 22px);
  -webkit-mask-image: linear-gradient(to right, transparent, #000 22px);
}

.notes-cat-wrap.can-scroll-left.can-scroll-right .notes-filter-tabs {
  mask-image: linear-gradient(to right, transparent, #000 22px, #000 calc(100% - 26px), transparent);
  -webkit-mask-image: linear-gradient(to right, transparent, #000 22px, #000 calc(100% - 26px), transparent);
}

.notes-filter-tabs {
  display: flex;
  align-items: center;
  gap: 6px;
  overflow-x: auto;
  scrollbar-width: none;
  padding-block: 2px;
}

.notes-filter-tabs::-webkit-scrollbar { display: none; }
.notes-filter-tabs[hidden] { display: none; }

.notes-tab {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 34px;
  padding: 0 13px;
  border-radius: 999px;
  border: 1px solid var(--notes-rule);
  background: var(--notes-surface);
  color: var(--notes-ink-2);
  font-size: 0.82rem;
  font-weight: 600;
  white-space: nowrap;
  flex: none;
  transition: all 140ms ease;
}

.notes-tab em {
  font-style: normal;
  font-size: 0.72rem;
  opacity: 0.72;
  font-variant-numeric: tabular-nums;
}

.notes-tab:hover {
  border-color: var(--cobalt);
  color: var(--cobalt);
}

.notes-tab[aria-selected="true"] {
  background: var(--obsidian);
  border-color: var(--obsidian);
  color: #ffffff;
}

html[data-theme="dark"] .notes-tab[aria-selected="true"] {
  color: #0b0f19;
}

.notes-tab.is-zero-hit {
  opacity: 0.45;
}

.notes-toolbar-right {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
  flex: none;
}

.notes-search-box {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 36px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid var(--notes-rule-strong);
  background: var(--notes-surface);
  color: var(--notes-muted);
  transition: border-color 140ms ease, box-shadow 140ms ease;
}

.notes-search-box[hidden] { display: none; }

.notes-search-box:focus-within {
  border-color: var(--cobalt);
  box-shadow: 0 0 0 3px var(--cobalt-soft);
}

.notes-search-box input {
  border: 0;
  background: transparent;
  color: var(--notes-ink);
  font-family: inherit;
  font-size: 0.85rem;
  width: 210px;
  outline: none;
}

.notes-search-box input::placeholder {
  color: var(--notes-faint);
}

.notes-search-box input::-webkit-search-cancel-button {
  -webkit-appearance: none;
}

.notes-search-clear {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border: 0;
  border-radius: 999px;
  background: var(--notes-tint);
  color: var(--notes-muted);
  padding: 0;
}

.notes-search-clear[hidden] { display: none; }
.notes-search-clear:hover { color: var(--notes-ink); }

.notes-opts-trigger {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 36px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid var(--notes-rule-strong);
  background: var(--notes-surface);
  color: var(--notes-ink-2);
  font-size: 0.8rem;
  font-weight: 600;
  white-space: nowrap;
  transition: border-color 140ms ease, color 140ms ease, background 140ms ease;
}

.notes-opts-trigger[hidden] { display: none; }

.notes-opts-trigger:hover,
.notes-opts-trigger[aria-expanded="true"],
.notes-opts-trigger.is-active {
  border-color: var(--cobalt);
  color: var(--cobalt);
  background: var(--cobalt-soft);
}

.notes-opts-trigger svg {
  transition: transform 160ms ease;
}

.notes-opts-trigger[aria-expanded="true"] svg {
  transform: rotate(180deg);
}

/* 按需展开的场景套装抽屉 */
.notes-scenes-drawer {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 16px;
  border: 1px solid var(--notes-rule);
  background: var(--notes-tint);
}

.notes-scenes-drawer[hidden] { display: none; }

.notes-scenes-label {
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--notes-muted);
  margin-right: 2px;
}

.notes-scene-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 30px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid var(--notes-rule-strong);
  background: var(--notes-surface);
  color: var(--notes-ink-2);
  font-size: 0.78rem;
  font-weight: 600;
  transition: all 140ms ease;
}

.notes-scene-pill em {
  font-style: normal;
  font-size: 0.7rem;
  opacity: 0.72;
  font-variant-numeric: tabular-nums;
}

.notes-scene-pill:hover {
  border-color: var(--cobalt);
  color: var(--cobalt);
}

.notes-scene-pill[aria-pressed="true"] {
  border-color: var(--cobalt);
  background: var(--cobalt);
  color: #ffffff;
}

/* ============================================================
   5. 统一浮层收纳菜单（··· · 1:1 复刻大锤同步）
   ============================================================ */
.notes-menu-anchor {
  position: relative;
  display: inline-flex;
}

.notes-popover-menu {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  z-index: 80;
  min-width: 176px;
  padding: 6px;
  border-radius: 14px;
  border: 1px solid var(--notes-rule-strong);
  background: var(--notes-surface);
  box-shadow: 0 14px 36px -8px rgba(15, 23, 42, 0.24), 0 2px 8px rgba(15, 23, 42, 0.08);
  display: flex;
  flex-direction: column;
  gap: 2px;
  animation: notesMenuIn 90ms ease-out;
}

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

.notes-popover-menu.is-up {
  top: auto;
  bottom: calc(100% + 6px);
}

.has-open-menu,
.pick-prompt-card:has(.notes-popover-menu:not([hidden])),
.pick-quote-card:has(.notes-popover-menu:not([hidden])),
.pick-rich-card:has(.notes-popover-menu:not([hidden])),
.idea-list > li:has(.notes-popover-menu:not([hidden])),
.vault-shelf-head:has(.notes-popover-menu:not([hidden])),
.idea-panel:has(.notes-popover-menu:not([hidden])) {
  position: relative;
  z-index: 45;
}

@keyframes notesMenuIn {
  from { opacity: 0; transform: translateY(-4px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.notes-menu-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  min-height: 34px;
  padding: 6px 10px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: var(--notes-ink);
  font-family: inherit;
  font-size: 0.82rem;
  font-weight: 560;
  text-align: left;
  white-space: nowrap;
  text-decoration: none;
  cursor: pointer;
  transition: background 120ms ease, color 120ms ease;
}

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

.notes-menu-item:hover {
  background: var(--notes-tint);
  color: var(--cobalt);
}

.notes-menu-item.is-active {
  color: var(--cobalt);
  background: var(--cobalt-soft);
}

.notes-menu-item.is-danger { color: var(--danger); }
.notes-menu-item.is-danger:hover { background: var(--danger-soft); color: var(--danger); }

.notes-menu-item.is-armed-danger,
.notes-menu-item.is-armed-danger:hover {
  background: var(--danger);
  color: #ffffff;
}

.notes-menu-divider {
  height: 1px;
  margin: 4px 6px;
  background: var(--notes-rule);
}

/* ============================================================
   6. 货架区与二级筛选
   ============================================================ */
.vault-content {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.vault-slot {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.vault-slot:empty { display: none; }

.vault-shelf {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.vault-shelf[hidden] { display: none; }

.vault-shelf-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.vault-shelf-title {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.vault-shelf-title h3 {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  font-size: 1.12rem;
  font-weight: 740;
  letter-spacing: -0.015em;
  color: var(--notes-ink);
}

.notes-count-num {
  display: inline-flex;
  align-items: center;
  padding: 1px 8px;
  border-radius: 999px;
  background: var(--notes-tint);
  border: 1px solid var(--notes-rule);
  color: var(--notes-muted);
  font-style: normal;
  font-size: 0.74rem;
  font-weight: 650;
  font-variant-numeric: tabular-nums;
}

.vault-shelf-desc {
  margin: 0;
  font-size: 0.84rem;
  color: var(--notes-muted);
}

.vault-shelf-actions {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex: none;
}

.vault-subtag-bar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}

.vault-subtag-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: 28px;
  padding: 0 11px;
  border-radius: 999px;
  border: 1px solid var(--notes-rule);
  background: var(--notes-surface);
  color: var(--notes-ink-2);
  font-size: 0.76rem;
  font-weight: 600;
  transition: all 140ms ease;
}

.vault-subtag-chip span {
  font-size: 0.7rem;
  opacity: 0.7;
  font-variant-numeric: tabular-nums;
}

.vault-subtag-chip:hover {
  border-color: var(--cobalt);
  color: var(--cobalt);
}

.vault-subtag-chip[aria-pressed="true"] {
  border-color: var(--cobalt);
  background: var(--cobalt-soft);
  color: var(--cobalt);
}

/* 场景套装横幅 */
.vault-scene-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  padding: 14px 18px;
  border-radius: 18px;
  border: 1px solid rgba(35, 80, 220, 0.24);
  background: linear-gradient(180deg, var(--cobalt-soft) 0%, var(--notes-surface) 100%);
}

.vault-scene-banner h3 {
  margin: 0 0 2px;
  font-size: 1.04rem;
  font-weight: 740;
  color: var(--notes-ink);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

/* 通用操作小按钮（1:1 复刻 .sync-act-btn） */
.notes-act-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  min-height: 30px;
  padding: 0 10px;
  border-radius: 8px;
  border: 1px solid var(--notes-rule);
  background: var(--notes-surface);
  color: var(--notes-ink-2);
  font-size: 0.78rem;
  font-weight: 600;
  white-space: nowrap;
  text-decoration: none;
  transition: border-color 140ms ease, color 140ms ease, background 140ms ease;
}

.notes-act-btn:hover {
  border-color: var(--cobalt);
  color: var(--cobalt);
  background: var(--cobalt-soft);
}

.notes-act-btn.is-primary {
  background: var(--cobalt);
  border-color: var(--cobalt);
  color: #ffffff;
}

.notes-act-btn.is-primary:hover {
  background: var(--cobalt-hover);
  color: #ffffff;
}

.notes-act-btn.is-copied,
.notes-btn-primary.is-copied,
.notes-btn-outline.is-copied {
  border-color: var(--ok-green);
  background: var(--ok-soft);
  color: var(--ok-green);
}

.card-micro-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-width: 30px;
  height: 30px;
  padding: 0 7px;
  border-radius: 8px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--notes-muted);
  font-size: 0.76rem;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  transition: color 140ms ease, background 140ms ease, border-color 140ms ease;
}

.card-micro-btn:hover {
  background: var(--notes-tint);
  color: var(--notes-ink);
}

.card-fav-btn.is-active {
  color: var(--warn);
}

.card-like-btn.is-active {
  color: var(--cobalt);
  background: var(--cobalt-soft);
}

/* ============================================================
   7. 妙软件卡片网格（3 列极简白卡）
   ============================================================ */
.notes-software-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.software-card,
.software-card-static {
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 10px;
  padding: 15px 16px;
  border-radius: 18px;
  border: 1px solid var(--notes-rule);
  background: var(--notes-surface);
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.03);
  transition: border-color 150ms ease, transform 150ms ease;
}

.software-card:hover,
.software-card-static:hover {
  border-color: var(--notes-rule-strong);
}

.software-card-main {
  display: flex;
  flex-direction: column;
  gap: 10px;
  color: inherit;
  flex: 1;
}

.software-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.software-icon-wrap {
  width: 40px;
  height: 40px;
  border-radius: 11px;
  border: 1px solid var(--notes-rule);
  background: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  flex: none;
}

html[data-theme="dark"] .software-icon-wrap {
  background: rgba(255, 255, 255, 0.94);
  border-color: rgba(255, 255, 255, 0.14);
}

.software-icon {
  width: 30px;
  height: 30px;
  object-fit: contain;
  border-radius: 6px;
}

.software-monogram {
  font-size: 0.96rem;
  font-weight: 760;
  color: var(--cobalt);
}

.software-tags-wrap {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.software-tag {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 7px;
  font-size: 0.71rem;
  font-weight: 650;
  background: var(--notes-tint);
  color: var(--notes-ink-2);
  white-space: nowrap;
}

.software-tag-web { background: var(--ok-soft); color: var(--ok-green); }
.software-tag-mac { background: var(--cobalt-soft); color: var(--cobalt); }
.software-tag-pin { background: var(--cobalt-soft); color: var(--cobalt); }

.software-copy {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.software-copy strong {
  font-size: 0.94rem;
  font-weight: 700;
  color: var(--notes-ink);
  line-height: 1.35;
}

.software-copy small {
  font-size: 0.82rem;
  color: var(--notes-muted);
  line-height: 1.5;
}

.software-card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--notes-rule);
}

.software-host {
  font-size: 0.74rem;
  color: var(--notes-faint);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.software-foot-actions {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  flex: none;
}

.software-link-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  color: var(--notes-muted);
  font-size: 0.86rem;
  transition: color 140ms ease, background 140ms ease;
}

.software-card:hover .software-link-action,
.software-link-action:hover {
  color: var(--cobalt);
  background: var(--cobalt-soft);
}

/* ============================================================
   8. 妙idea · 1:1 大锤同步极简投递画布 + 双态工作区
   ============================================================ */
.idea-columns {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr);
  gap: 16px;
  align-items: start;
}

.idea-panel {
  padding: 18px;
  border-radius: 20px;
  border: 1px solid var(--notes-rule);
  background: var(--notes-surface);
  box-shadow: var(--notes-shadow);
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.idea-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.idea-panel-title-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.idea-panel-title-row h4 {
  margin: 0;
  font-size: 0.98rem;
  font-weight: 720;
  color: var(--notes-ink);
}

.notes-mode-badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 9px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  background: var(--notes-tint);
  color: var(--notes-muted);
}

.notes-mode-badge.is-private {
  background: var(--cobalt-soft);
  color: var(--cobalt);
}

.notes-mode-badge.is-public {
  background: var(--ok-soft);
  color: var(--ok-green);
}

.notes-coin-pill {
  display: inline-flex;
  align-items: center;
  padding: 2px 9px;
  border-radius: 999px;
  border: 1px solid rgba(180, 83, 9, 0.24);
  background: var(--warn-soft);
  color: var(--warn);
  font-size: 0.72rem;
  font-weight: 650;
  white-space: nowrap;
}

.notes-coin-pill.is-earned {
  border-color: rgba(15, 118, 110, 0.26);
  background: var(--ok-soft);
  color: var(--ok-green);
}

.idea-profile {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.idea-account-name {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--notes-muted);
}

.idea-gate {
  padding: 16px;
  border-radius: 16px;
  border: 1px solid rgba(35, 80, 220, 0.18);
  background: linear-gradient(180deg, var(--cobalt-soft) 0%, var(--notes-surface) 100%);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.idea-gate[hidden] { display: none; }

.idea-gate-desc {
  margin: 0;
  font-size: 0.86rem;
  color: var(--notes-ink-2);
}

.idea-gate-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.idea-editor-wrap {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.idea-editor-wrap[hidden] { display: none; }

/* 1:1 复刻 .sync-composer */
.notes-composer {
  border-radius: 18px;
  border: 1px solid var(--notes-rule-strong);
  background: var(--notes-surface);
  overflow: hidden;
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

.notes-composer:focus-within {
  border-color: var(--cobalt);
  box-shadow: 0 0 0 3px var(--cobalt-soft);
}

.notes-composer-body {
  padding: 12px 16px 8px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.notes-title-input {
  width: 100%;
  border: 0;
  border-bottom: 1px solid var(--notes-rule);
  padding: 4px 0 8px;
  background: transparent;
  color: var(--notes-ink);
  font-family: inherit;
  font-size: 0.92rem;
  font-weight: 650;
  outline: none;
}

.notes-title-input[hidden] { display: none; }
.notes-title-input::placeholder { color: var(--notes-faint); font-weight: 450; }

.notes-textarea {
  width: 100%;
  min-height: 82px;
  max-height: 280px;
  resize: vertical;
  border: 0;
  padding: 4px 0;
  background: transparent;
  color: var(--notes-ink);
  font-family: inherit;
  font-size: 16px;
  line-height: 1.6;
  outline: none;
}

.notes-textarea::placeholder { color: var(--notes-faint); }

.notes-composer-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 14px 10px;
  border-top: 1px solid var(--notes-rule);
}

.notes-composer-tools {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.notes-tool-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 32px;
  padding: 0 10px;
  border-radius: 9px;
  border: 1px solid var(--notes-rule-strong);
  background: var(--notes-surface);
  color: var(--notes-ink-2);
  font-size: 0.78rem;
  font-weight: 600;
  transition: all 140ms ease;
}

.notes-tool-btn:hover,
.notes-tool-btn[aria-pressed="true"] {
  border-color: var(--cobalt);
  color: var(--cobalt);
  background: var(--cobalt-soft);
}

.notes-composer-submit {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.idea-char-count {
  font-size: 0.74rem;
  color: var(--notes-muted);
  font-variant-numeric: tabular-nums;
}

.idea-char-count[hidden] { display: none; }
.idea-char-count.is-near-limit { color: var(--warn); }
.idea-char-count.is-at-limit { color: var(--danger); font-weight: 700; }

.idea-feedback {
  margin: 0;
  font-size: 0.82rem;
  color: var(--cobalt);
  font-weight: 560;
}

.idea-feedback[hidden] { display: none; }

.idea-tools-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
}

.idea-tools-row[hidden] { display: none; }

.idea-tag-bar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}

.idea-list-status {
  margin: 0;
  font-size: 0.84rem;
  color: var(--notes-muted);
}

.idea-list-status:empty { display: none; }

.idea-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.idea-list > li {
  padding: 13px 15px;
  border-radius: 15px;
  border: 1px solid var(--notes-rule);
  background: var(--notes-surface);
  display: flex;
  flex-direction: column;
  gap: 8px;
  transition: border-color 150ms ease;
}

.idea-list > li:hover { border-color: var(--notes-rule-strong); }

.idea-list > li.is-pinned {
  border-color: rgba(35, 80, 220, 0.3);
  background: linear-gradient(180deg, var(--cobalt-soft) 0%, var(--notes-surface) 44px);
}

.idea-list > li.is-editing {
  border-color: var(--cobalt);
  box-shadow: 0 0 0 2px var(--cobalt-soft);
}

.idea-item-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.idea-item-head h4 {
  margin: 0;
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--notes-ink);
}

.idea-text {
  margin: 0;
  font-size: 0.89rem;
  color: var(--notes-ink-2);
  white-space: pre-wrap;
  word-break: break-word;
  line-height: 1.62;
}

.idea-inline-link {
  color: var(--cobalt);
  text-decoration: underline;
  text-underline-offset: 2px;
  word-break: break-all;
}

.idea-inline-tag {
  border: 0;
  padding: 0 5px;
  border-radius: 6px;
  background: var(--cobalt-soft);
  color: var(--cobalt);
  font-size: 0.82rem;
  font-weight: 600;
}

.idea-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding-top: 6px;
  border-top: 1px solid var(--notes-rule);
}

.idea-card-footer time {
  font-size: 0.74rem;
  color: var(--notes-faint);
  font-variant-numeric: tabular-nums;
}

.idea-card-actions {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  flex-wrap: wrap;
}

.idea-more-button {
  align-self: flex-start;
}

/* ============================================================
   9. 妙提示词、妙言妙句、妙Skill 极简卡片（2–3 高频键 + ···）
   ============================================================ */
.vault-prompt-grid,
.vault-quote-grid,
.vault-rich-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.pick-prompt-card,
.pick-rich-card {
  height: 100%;
  padding: 16px 18px;
  border-radius: 18px;
  border: 1px solid var(--notes-rule);
  background: var(--notes-surface);
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.03);
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: border-color 150ms ease, box-shadow 150ms ease;
}

.pick-prompt-card:hover,
.pick-rich-card:hover {
  border-color: var(--notes-rule-strong);
}

.pick-prompt-card.is-select-mode {
  cursor: pointer;
  user-select: none;
}

.pick-prompt-card.is-pack-selected {
  border-color: var(--cobalt);
  box-shadow: 0 0 0 2px var(--cobalt-soft);
}

.pick-prompt-card.is-spotlight,
.pick-quote-card.is-spotlight,
.pick-rich-card.is-spotlight,
.software-card.is-spotlight {
  border-color: var(--cobalt);
  box-shadow: 0 0 0 3px var(--cobalt-soft);
}

.pick-prompt-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.pick-prompt-title-group {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.pick-pack-check {
  width: 17px;
  height: 17px;
  accent-color: var(--cobalt);
  flex: none;
  cursor: pointer;
}

.pick-index-num {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--notes-faint);
  flex: none;
}

.pick-prompt-title-group h4,
.pick-rich-card h4 {
  margin: 0;
  font-size: 0.96rem;
  font-weight: 720;
  color: var(--notes-ink);
  line-height: 1.38;
}

.pick-head-right {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  flex: none;
}

.pick-prompt-summary,
.pick-rich-summary {
  margin: 0;
  font-size: 0.84rem;
  color: var(--notes-ink-2);
  line-height: 1.55;
}

/* 按需变量填空条 */
.pick-vars-bar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  padding: 8px 11px;
  border-radius: 12px;
  background: var(--notes-tint);
  border: 1px dashed var(--notes-rule-strong);
}

.pick-vars-label {
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--cobalt);
}

.pick-var-field {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.76rem;
  color: var(--notes-ink-2);
}

.pick-var-field input {
  height: 28px;
  width: 144px;
  padding: 0 9px;
  border-radius: 8px;
  border: 1px solid var(--notes-rule-strong);
  background: var(--notes-surface);
  color: var(--notes-ink);
  font-family: inherit;
  font-size: 0.8rem;
  outline: none;
}

.pick-var-field input:focus {
  border-color: var(--cobalt);
}

/* 极简代码块（1:1 对齐 .sync-text-body） */
.pick-snippet-wrap {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.pick-snippet-box {
  margin: 0;
  padding: 11px 14px;
  border-radius: 12px;
  border: 1px solid var(--notes-rule);
  background: var(--notes-tint);
  color: var(--notes-ink);
  font-size: 0.85rem;
  line-height: 1.62;
}

.pick-snippet-box.is-code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.8rem;
  line-height: 1.55;
}

.pick-snippet-inner {
  display: block;
  white-space: pre-wrap;
  word-break: break-word;
}

.pick-snippet-wrap.is-collapsed .pick-snippet-inner {
  display: -webkit-box;
  -webkit-line-clamp: 5;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.pick-expand-toggle {
  align-self: flex-start;
  border: 0;
  background: transparent;
  color: var(--cobalt);
  font-size: 0.78rem;
  font-weight: 600;
  padding: 2px 4px;
  border-radius: 6px;
}

.pick-expand-toggle:hover {
  background: var(--cobalt-soft);
}

.pick-prompt-foot,
.pick-rich-foot,
.pick-quote-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
  padding-top: 8px;
  margin-top: auto;
  border-top: 1px solid var(--notes-rule);
}

.pick-meta-hint {
  font-size: 0.74rem;
  color: var(--notes-faint);
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pick-open-link {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--cobalt);
}

.pick-open-link:hover { text-decoration: underline; }

/* 妙言妙句 · 极简白瓷画廊卡（首条置顶主主张曜石黑点睛） */
.vault-quote-grid > li.is-quote-span {
  grid-column: 1 / -1;
}

.pick-quote-card {
  height: 100%;
  padding: 18px 20px;
  border-radius: 18px;
  border: 1px solid var(--notes-rule);
  background: var(--notes-surface);
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.03);
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: border-color 150ms ease;
}

.pick-quote-card:hover {
  border-color: var(--notes-rule-strong);
}

.pick-quote-card.is-quote-obsidian {
  background: #111827;
  border-color: #1f2937;
  color: #f8fafc;
}

html[data-theme="dark"] .pick-quote-card.is-quote-obsidian {
  background: #161f32;
  border-color: rgba(92, 138, 255, 0.34);
}

.pick-quote-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.pick-quote-meta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.pick-quote-index {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--cobalt);
}

.pick-quote-card.is-quote-obsidian .pick-quote-index {
  color: #93b4ff;
}

.pick-quote-meta h4 {
  margin: 0;
  font-size: 0.88rem;
  font-weight: 650;
  color: var(--notes-muted);
}

.pick-quote-card.is-quote-obsidian .pick-quote-meta h4 {
  color: #cbd5e1;
}

.pick-quote-text {
  margin: 0;
  padding-left: 14px;
  border-left: 2px solid var(--cobalt);
  font-size: 1.05rem;
  font-weight: 650;
  line-height: 1.65;
  color: var(--notes-ink);
  white-space: pre-wrap;
}

.pick-quote-card.is-quote-obsidian .pick-quote-text {
  font-size: 1.24rem;
  color: #ffffff;
  border-left-color: #5c8aff;
}

.pick-quote-note {
  margin: 0;
  font-size: 0.84rem;
  color: var(--notes-muted);
  line-height: 1.55;
}

.pick-quote-card.is-quote-obsidian .pick-quote-note {
  color: #94a3b8;
}

.pick-quote-source {
  font-size: 0.78rem;
  color: var(--notes-muted);
}

.pick-quote-card.is-quote-obsidian .pick-quote-foot {
  border-top-color: rgba(148, 163, 184, 0.16);
}

.pick-quote-card.is-quote-obsidian .pick-quote-source {
  color: #cbd5e1;
}

.pick-quote-card.is-quote-obsidian .card-micro-btn {
  color: #cbd5e1;
}

.pick-quote-card.is-quote-obsidian .card-micro-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
}

.pick-quote-card.is-quote-obsidian .notes-icon-btn {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.16);
  color: #e2e8f0;
}

.pick-quote-card.is-quote-obsidian .software-tag {
  background: rgba(92, 138, 255, 0.2);
  color: #bfdbfe;
}

/* 搜索高亮 */
.notes-hit-mark {
  background: rgba(35, 80, 220, 0.16);
  color: inherit;
  border-radius: 3px;
  padding: 0 2px;
}

html[data-theme="dark"] .notes-hit-mark {
  background: rgba(92, 138, 255, 0.28);
}

/* 空状态（1:1 复刻 .sync-empty） */
.vault-empty-card {
  padding: 44px 24px;
  text-align: center;
  border-radius: 20px;
  border: 1px dashed var(--notes-rule-strong);
  background: var(--notes-tint);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.vault-empty-card h3 {
  margin: 0;
  font-size: 1rem;
  color: var(--notes-ink);
}

.vault-empty-card p {
  margin: 0;
  font-size: 0.85rem;
  color: var(--notes-muted);
}

.vault-empty-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin-top: 8px;
}

/* ============================================================
   10. 多选打包批量工具条（1:1 复刻 .sync-batch-bar）
   ============================================================ */
.vault-pack-bar {
  position: fixed;
  left: 50%;
  bottom: max(18px, env(safe-area-inset-bottom, 18px));
  transform: translateX(-50%);
  z-index: 70;
  width: min(74rem, calc(100% - 1.5rem));
  padding: 10px 16px;
  border-radius: 16px;
  border: 1px solid rgba(35, 80, 220, 0.32);
  background: var(--notes-surface);
  box-shadow: 0 18px 42px -12px rgba(15, 23, 42, 0.28);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.vault-pack-left {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.86rem;
  font-weight: 650;
  color: var(--notes-ink);
}

.vault-pack-actions {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

/* ============================================================
   11. 分享图弹窗（1:1 复刻 .sync-dialog）
   ============================================================ */
.notes-share-dialog {
  width: min(560px, calc(100% - 24px));
  max-height: min(88vh, 840px);
  padding: 0;
  border: 1px solid var(--notes-rule-strong);
  border-radius: 22px;
  background: var(--notes-surface);
  color: var(--notes-ink);
  box-shadow: 0 24px 64px -16px rgba(15, 23, 42, 0.28);
  overflow: hidden;
}

.notes-share-dialog::backdrop {
  background: rgba(15, 23, 42, 0.54);
  backdrop-filter: blur(4px);
}

.notes-share-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 15px 20px;
  border-bottom: 1px solid var(--notes-rule);
}

.notes-share-head h3 {
  margin: 0;
  font-size: 1rem;
  font-weight: 740;
}

.notes-share-themes {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  padding: 12px 20px 0;
}

.notes-share-preview {
  padding: 14px 20px;
  max-height: 54vh;
  overflow: auto;
  display: flex;
  justify-content: center;
}

.notes-share-img {
  max-width: 100%;
  height: auto;
  border-radius: 14px;
  border: 1px solid var(--notes-rule);
  display: block;
}

.notes-share-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  padding: 12px 20px 16px;
  border-top: 1px solid var(--notes-rule);
}

.notes-share-foot-actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

/* 兼容 notes-extras.js 生成的按钮类 */
.idea-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 36px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid var(--notes-rule-strong);
  background: var(--notes-surface);
  color: var(--notes-ink);
  font-size: 0.82rem;
  font-weight: 600;
  white-space: nowrap;
  text-decoration: none;
  cursor: pointer;
}

.idea-button:hover { border-color: var(--cobalt); color: var(--cobalt); }
.idea-button-primary { background: var(--obsidian); border-color: var(--obsidian); color: #ffffff; }
html[data-theme="dark"] .idea-button-primary { color: #0b0f19; }
.idea-button-primary:hover { background: var(--obsidian-hover); color: #ffffff; }
html[data-theme="dark"] .idea-button-primary:hover { color: #0b0f19; }
.idea-button-sm { min-height: 34px; padding: 0 13px; font-size: 0.8rem; }

.idea-card-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 30px;
  padding: 0 10px;
  border-radius: 8px;
  border: 1px solid var(--notes-rule);
  background: var(--notes-surface);
  color: var(--notes-ink-2);
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
}

.idea-card-btn:hover { border-color: var(--cobalt); color: var(--cobalt); background: var(--cobalt-soft); }
.idea-card-btn.is-copied { border-color: var(--ok-green); background: var(--ok-soft); color: var(--ok-green); }

/* ============================================================
   12. 回到顶部、非阻塞 Toast、1:1 极轻贴底页脚
   ============================================================ */
.notes-back-top {
  position: fixed;
  right: 20px;
  bottom: max(22px, env(safe-area-inset-bottom, 22px));
  z-index: 55;
  width: 38px;
  height: 38px;
  border-radius: 999px;
  border: 1px solid var(--notes-rule-strong);
  background: var(--notes-surface);
  color: var(--notes-ink-2);
  box-shadow: var(--notes-shadow);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  transition: color 140ms ease, border-color 140ms ease, transform 140ms ease;
}

.notes-back-top[hidden] { display: none; }
.notes-back-top:hover { color: var(--cobalt); border-color: var(--cobalt); transform: translateY(-2px); }
.notes-back-top.has-pack-bar { bottom: 84px; }

.notes-toast {
  position: fixed;
  left: 50%;
  bottom: max(20px, env(safe-area-inset-bottom, 20px));
  transform: translateX(-50%);
  z-index: 120;
  max-width: min(92vw, 420px);
  padding: 9px 16px;
  border-radius: 20px;
  background: var(--obsidian);
  color: #ffffff;
  font-size: 0.84rem;
  font-weight: 600;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.24);
  display: inline-flex;
  align-items: center;
  gap: 10px;
  pointer-events: none;
}

.notes-toast[hidden] { display: none; }
html[data-theme="dark"] .notes-toast { color: #0b0f19; }

.notes-toast-act {
  pointer-events: auto;
  border: 0;
  border-radius: 999px;
  padding: 3px 10px;
  background: rgba(255, 255, 255, 0.18);
  color: inherit;
  font-size: 0.78rem;
  font-weight: 700;
  white-space: nowrap;
}

html[data-theme="dark"] .notes-toast-act { background: rgba(11, 15, 25, 0.14); }

.notes-footer {
  margin-top: auto;
  padding-block: 0 22px;
  background: transparent;
}

.notes-footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-top: 16px;
  border-top: 1px solid var(--notes-rule);
  font-size: 0.78rem;
  color: var(--notes-muted);
}

.notes-footer-brand {
  white-space: nowrap;
}

.notes-footer-links {
  display: inline-flex;
  align-items: center;
  gap: 16px;
  white-space: nowrap;
}

.notes-footer-links a {
  color: var(--notes-muted);
  transition: color 140ms ease;
}

.notes-footer-links a:hover { color: var(--cobalt); }

/* ============================================================
   13. 后台 /admin/ 完整样式兼容区
   ============================================================ */
.admin-suite-bar {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px;
  margin-bottom: 14px;
  padding: 4px;
  border: 1px solid var(--notes-rule);
  border-radius: 999px;
  background: var(--notes-tint);
}

.admin-suite-bar a {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 2px 12px;
  border-radius: 999px;
  color: var(--notes-ink-2);
  font-size: 0.8rem;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
}

.admin-suite-bar a[aria-current="page"] {
  background: var(--obsidian);
  color: #ffffff;
}

.admin-studio { max-width: 74rem; margin-inline: auto; padding-block: 24px 56px; }
.admin-panel { padding: 20px; }
.admin-panel-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; padding-bottom: 14px; border-bottom: 1px solid var(--notes-rule); }
.admin-profile { display: inline-flex; align-items: center; gap: 8px; }
.admin-tabs { display: inline-flex; gap: 4px; margin-top: 14px; padding: 4px; border: 1px solid var(--notes-rule); border-radius: 999px; background: var(--notes-tint); align-self: flex-start; }
.admin-tab { min-height: 36px; padding: 4px 16px; border: 0; border-radius: 999px; background: transparent; color: var(--notes-ink-2); font-size: 0.88rem; font-weight: 620; }
.admin-tab[aria-selected="true"] { color: #ffffff; background: var(--obsidian); }
.admin-picks-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); align-items: start; gap: 24px; margin-top: 14px; }
.admin-field-label { display: block; margin-bottom: 5px; font-size: 0.86rem; font-weight: 650; color: var(--notes-ink); }
.admin-cat-picker { display: grid; gap: 8px; }
.admin-cat-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.admin-cat-chip { min-height: 32px; padding: 2px 12px; border: 1px solid var(--notes-rule-strong); border-radius: 999px; background: var(--notes-surface); color: var(--notes-ink-2); font-size: 0.82rem; font-weight: 600; }
.admin-cat-chip.is-selected { border-color: var(--obsidian); background: var(--obsidian); color: #ffffff; }
.admin-two-col { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.idea-form { display: grid; gap: 12px; }
.idea-form label { display: grid; gap: 5px; font-size: 0.84rem; font-weight: 600; color: var(--notes-ink-2); }
.idea-form input:not([type="checkbox"]), .idea-form textarea { width: 100%; padding: 9px 12px; border-radius: 12px; border: 1px solid var(--notes-rule-strong); background: var(--notes-surface); color: var(--notes-ink); font-family: inherit; font-size: 0.9rem; }
.idea-label-row { display: flex; align-items: center; justify-content: space-between; }
.idea-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.admin-more-fields { padding: 12px 14px; border: 1px solid var(--notes-rule); border-radius: 14px; background: var(--notes-tint); }
.admin-more-fields summary { font-size: 0.86rem; font-weight: 620; color: var(--notes-ink-2); cursor: pointer; }
.admin-more-grid { display: grid; gap: 10px; margin-top: 10px; }
.admin-check-label { display: flex !important; align-items: center; gap: 8px; cursor: pointer; }
.admin-picks-side { display: grid; gap: 12px; }
.admin-edit-banner { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 14px; border-radius: 12px; border: 1px solid rgba(35, 80, 220, 0.28); background: var(--cobalt-soft); color: var(--cobalt); font-size: 0.85rem; font-weight: 620; }
.admin-picks-filter { display: flex; flex-wrap: wrap; gap: 6px; }
.admin-pick-item-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px; }
.admin-pick-item-title { display: inline-flex; align-items: center; flex-wrap: wrap; gap: 6px; }
.admin-pick-snippet { margin: 6px 0 0; padding: 8px 10px; border-radius: 10px; background: var(--notes-tint); color: var(--notes-ink-2); font-size: 0.82rem; white-space: pre-wrap; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.admin-pick-url { display: inline-block; margin-top: 4px; color: var(--cobalt); font-size: 0.8rem; word-break: break-all; }

/* ============================================================
   14. 响应式（平板 + 手机 320px–430px 严格 0px 溢出）
   ============================================================ */
@media (max-width: 60rem) {
  .notes-software-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .idea-columns { grid-template-columns: 1fr; }
  .admin-picks-layout { grid-template-columns: 1fr; }
}

@media (max-width: 56rem) {
  .notes-hero-grid { grid-template-columns: 1fr; }
  .vault-prompt-grid,
  .vault-quote-grid,
  .vault-rich-grid { grid-template-columns: 1fr; }
}

@media (max-width: 40rem) {
  .notes-page .wrap { width: calc(100% - 1.5rem); }
  .notes-back-link { display: none; }
  .notes-brand-text .wordmark { display: none; }
  .notes-brand-text .brand-name { font-size: 1rem; }
  .site-header.studio-nav.notes-header { gap: 0.45rem; }
  .notes-header-actions { gap: 5px; }
  .notes-header .site-account-pill { padding: 0 9px; font-size: 0.76rem; }
  .notes-header-pill { padding: 0 9px; font-size: 0.76rem; }
  .notes-toolbar-right { width: 100%; }
  .notes-search-box { flex: 1; min-width: 0; }
  .notes-search-box input { width: 100%; font-size: 16px; }
  .notes-software-list { grid-template-columns: 1fr; }
  .idea-panel { padding: 14px; }
  .pick-prompt-card,
  .pick-rich-card,
  .pick-quote-card { padding: 14px; }
  .notes-composer-body { padding: 10px 14px 6px; }
  .notes-composer-foot { padding: 8px 12px; }
  .notes-footer-inner { font-size: 0.75rem; }
  .notes-footer-links { gap: 12px; }
}

@media (max-width: 24rem) {
  .notes-page .wrap { width: calc(100% - 1rem); }
  .notes-brand-group .brand-icon { width: 28px; height: 28px; }
  .site-header.studio-nav.notes-header .notes-brand-text .brand-name { font-size: 0.92rem; }
  .notes-icon-btn { width: 32px; height: 32px; }
  .notes-header .site-account-pill { min-height: 32px; padding: 0 7px; font-size: 0.72rem; }
  .notes-header-pill { min-height: 32px; padding: 0 7px; font-size: 0.72rem; }
}
