/* =========================================================
   ひかぼんノート（Kindle MVP） — 専用スタイル
   すべて .hn- 接頭辞でスコープ（既存CSSへの干渉ゼロ）
   世界観: あつ森×北欧ナチュラルカフェ（クリーム #fdf8f0 × 茶アウトライン #6f4518）
   ========================================================= */
.hn-app {
  --hn-cream: #fdf8f0;
  --hn-paper: #fffdf8;
  --hn-brown: #6f4518;
  --hn-brown-soft: rgba(111, 69, 24, 0.55);
  --hn-line: rgba(111, 69, 24, 0.16);
  --hn-rule: rgba(111, 69, 24, 0.10);
  --hn-accent: #e07a2e;
  --hn-accent-soft: rgba(224, 122, 46, 0.12);
  --hn-leaf: #5f8f4e;
  --hn-leaf-soft: rgba(95, 143, 78, 0.13);
  --hn-text: #4a2f12;
  --hn-sub: #8a6a48;
  --hn-shadow: 0 4px 0 rgba(111, 69, 24, 0.22);
  font-family: 'Hiragino Maru Gothic ProN', 'Noto Sans JP', -apple-system, sans-serif;
  color: var(--hn-text);
  background: var(--hn-cream);
  border: 3px solid var(--hn-brown);
  border-radius: 22px;
  box-shadow: var(--hn-shadow);
  padding: 18px 18px 14px;
  margin-bottom: 22px;
  position: relative;
}
[data-theme="dark"] .hn-app {
  --hn-cream: #22262D;
  --hn-paper: #2A2F38;
  --hn-brown: #DFBA84;
  --hn-brown-soft: rgba(223, 186, 132, 0.58);
  --hn-line: rgba(255, 255, 255, 0.14);
  --hn-rule: rgba(255, 255, 255, 0.08);
  --hn-accent: #E79B4C;
  --hn-accent-soft: rgba(231, 155, 76, 0.18);
  --hn-leaf: #6BC692;
  --hn-leaf-soft: rgba(107, 198, 146, 0.16);
  --hn-text: #F0EDE7;
  --hn-sub: #CBC5BA;
  --hn-shadow: 0 4px 12px rgba(0, 0, 0, 0.32);
}
.hn-app *, .hn-modal * { box-sizing: border-box; }
.hn-ico { width: 16px; height: 16px; flex-shrink: 0; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.hn-ico.sm { width: 13px; height: 13px; }
.hn-ico.lg { width: 22px; height: 22px; }

/* ---------- ヘッダー ---------- */
.hn-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.hn-brand { display: flex; align-items: center; gap: 10px; min-width: 0; }
.hn-brand-badge { width: 40px; height: 40px; border-radius: 12px; background: var(--hn-accent); color: #fff; display: grid; place-items: center; border: 2.5px solid var(--hn-brown); box-shadow: 0 2px 0 rgba(111,69,24,.25); flex-shrink: 0; }
.hn-brand h2 { margin: 0; font-size: 1.12rem; font-weight: 900; letter-spacing: .02em; color: var(--hn-text); }
.hn-brand p { margin: 2px 0 0; font-size: .74rem; color: var(--hn-sub); }
.hn-head-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }

/* ---------- ボタン ---------- */
.hn-btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; font: inherit; font-size: .8rem; font-weight: 800; padding: 8px 14px; border-radius: 999px; border: 2px solid var(--hn-brown); background: var(--hn-paper); color: var(--hn-text); cursor: pointer; box-shadow: 0 2px 0 rgba(111,69,24,.22); transition: transform .12s ease, box-shadow .12s ease, background .12s; white-space: nowrap; }
.hn-btn:hover { transform: translateY(-1px); box-shadow: 0 3px 0 rgba(111,69,24,.25); }
.hn-btn:active { transform: translateY(1px); box-shadow: 0 1px 0 rgba(111,69,24,.25); }
.hn-btn.primary { background: var(--hn-accent); color: #fff; }
.hn-btn.leaf { background: var(--hn-leaf); color: #fff; }
.hn-btn.ghost { border-color: var(--hn-line); box-shadow: none; background: transparent; }
.hn-btn.sm { font-size: .72rem; padding: 5px 10px; border-width: 1.5px; }
.hn-btn:disabled { opacity: .55; cursor: wait; transform: none; }
.hn-iconbtn { display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 10px; border: 1.5px solid transparent; background: transparent; color: var(--hn-sub); cursor: pointer; transition: background .12s, color .12s; }
.hn-iconbtn:hover { background: var(--hn-accent-soft); color: var(--hn-accent); }
.hn-iconbtn.on { color: #e0a800; }
.hn-iconbtn.danger:hover { background: rgba(220, 38, 38, .1); color: #dc2626; }

/* ---------- タブ ---------- */
.hn-tabs { display: inline-flex; padding: 4px; gap: 4px; background: var(--hn-paper); border: 2px solid var(--hn-brown); border-radius: 999px; margin-bottom: 14px; max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.hn-tabs::-webkit-scrollbar { display: none; }
.hn-tab { display: inline-flex; align-items: center; gap: 6px; font: inherit; font-size: .8rem; font-weight: 800; padding: 7px 16px; border-radius: 999px; border: none; background: transparent; color: var(--hn-sub); cursor: pointer; white-space: nowrap; }
.hn-tab.active { background: var(--hn-brown); color: var(--hn-cream); }

/* ---------- 本セレクター ---------- */
.hn-books { display: flex; gap: 8px; align-items: center; overflow-x: auto; padding: 2px 2px 10px; margin-bottom: 6px; scrollbar-width: thin; -webkit-overflow-scrolling: touch; }
.hn-bookchip { display: inline-flex; align-items: center; gap: 8px; flex-shrink: 0; max-width: 230px; font: inherit; font-size: .76rem; font-weight: 800; padding: 5px 12px 5px 5px; border-radius: 14px; border: 2px solid var(--hn-line); background: var(--hn-paper); color: var(--hn-text); cursor: pointer; }
.hn-bookchip.active { border-color: var(--hn-brown); box-shadow: 0 2px 0 rgba(111,69,24,.22); background: var(--hn-accent-soft); }
.hn-bookchip img, .hn-cover-ph { width: 26px; height: 36px; border-radius: 4px; object-fit: cover; flex-shrink: 0; }
.hn-cover-ph { display: grid; place-items: center; background: var(--hn-leaf-soft); color: var(--hn-leaf); }
.hn-bookchip span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hn-bookchip .hn-count { font-size: .66rem; color: var(--hn-sub); font-weight: 700; flex-shrink: 0; }
.hn-select { font: inherit; font-size: .76rem; font-weight: 700; padding: 7px 10px; border-radius: 12px; border: 2px dashed var(--hn-brown-soft); background: transparent; color: var(--hn-text); max-width: 240px; flex-shrink: 0; cursor: pointer; }

/* ---------- 2カラム本体 ---------- */
.hn-grid { display: grid; grid-template-columns: 1fr; gap: 14px; }
.hn-pane { background: var(--hn-paper); border: 2px solid var(--hn-brown); border-radius: 18px; padding: 14px; min-width: 0; }
.hn-pane-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; margin-bottom: 10px; }
.hn-pane-title { display: flex; align-items: center; gap: 6px; font-size: .9rem; font-weight: 900; margin: 0; }
.hn-pill { font-size: .66rem; font-weight: 800; padding: 2px 8px; border-radius: 999px; background: var(--hn-accent-soft); color: var(--hn-accent); }

.hn-search { position: relative; margin-bottom: 10px; }
.hn-search .hn-ico { position: absolute; left: 11px; top: 50%; transform: translateY(-50%); color: var(--hn-sub); }
.hn-input, .hn-textarea { width: 100%; font: inherit; font-size: .84rem; color: var(--hn-text); background: var(--hn-cream); border: 1.5px solid var(--hn-line); border-radius: 12px; padding: 9px 12px; outline: none; transition: border-color .12s, box-shadow .12s; }
.hn-search .hn-input { padding-left: 32px; }
.hn-input:focus, .hn-textarea:focus { border-color: var(--hn-accent); box-shadow: 0 0 0 3px var(--hn-accent-soft); }
.hn-textarea { resize: vertical; line-height: 1.7; min-height: 64px; }

/* ハイライト 1件1行リスト */
.hn-hl-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; max-height: 620px; overflow-y: auto; padding-right: 2px; }
.hn-hl { display: grid; grid-template-columns: 6px 1fr; gap: 10px; padding: 10px 10px 8px 8px; border-radius: 12px; border: 1.5px solid var(--hn-line); background: var(--hn-cream); transition: border-color .15s, box-shadow .2s; }
.hn-hl:hover { border-color: var(--hn-brown-soft); }
.hn-hl.flash { box-shadow: 0 0 0 3px var(--hn-accent); }
.hn-hl-bar { border-radius: 4px; background: #f2c94c; }
.hn-hl-text { font-size: .84rem; line-height: 1.7; margin: 0; word-break: break-word; }
.hn-hl-text mark { background: rgba(242, 201, 76, .55); color: inherit; border-radius: 3px; padding: 0 1px; }
.hn-hl-meta { display: flex; align-items: center; justify-content: space-between; gap: 6px; margin-top: 4px; flex-wrap: wrap; }
.hn-loc { font-size: .66rem; font-weight: 800; color: var(--hn-sub); background: var(--hn-paper); border: 1px solid var(--hn-line); padding: 1px 7px; border-radius: 999px; }
.hn-hl-actions { display: flex; gap: 2px; align-items: center; flex-wrap: wrap; }
.hn-hl-note { margin-top: 6px; font-size: .76rem; color: var(--hn-sub); background: var(--hn-paper); border-radius: 8px; padding: 6px 9px; border: 1px dashed var(--hn-line); white-space: pre-wrap; }
.hn-hl-note-edit { margin-top: 6px; }
.hn-chipbtn { display: inline-flex; align-items: center; gap: 4px; font: inherit; font-size: .68rem; font-weight: 800; padding: 3px 8px; border-radius: 999px; border: 1.5px solid var(--hn-line); background: var(--hn-paper); color: var(--hn-sub); cursor: pointer; }
.hn-chipbtn:hover { border-color: var(--hn-accent); color: var(--hn-accent); }

/* ---------- 手帳見開き ---------- */
.hn-mode { display: inline-flex; gap: 4px; padding: 3px; border-radius: 999px; background: var(--hn-cream); border: 1.5px solid var(--hn-line); }
.hn-mode button { display: inline-flex; align-items: center; gap: 5px; font: inherit; font-size: .72rem; font-weight: 800; padding: 5px 11px; border-radius: 999px; border: none; background: transparent; color: var(--hn-sub); cursor: pointer; white-space: nowrap; }
.hn-mode button.active { background: var(--hn-leaf); color: #fff; }
.hn-mode button.active.fun { background: #d9577a; }
.hn-spread { display: grid; grid-template-columns: 1fr; gap: 0; border: 2px solid var(--hn-brown); border-radius: 14px; overflow: hidden; background: var(--hn-paper); position: relative; }
.hn-page { padding: 14px 16px; min-width: 0; background-image: repeating-linear-gradient(to bottom, transparent 0, transparent 27px, var(--hn-rule) 27px, var(--hn-rule) 28px); }
.hn-page + .hn-page { border-top: 2px dashed var(--hn-line); }
.hn-field { margin-bottom: 14px; }
.hn-field:last-child { margin-bottom: 0; }
.hn-label { display: flex; align-items: center; gap: 6px; font-size: .78rem; font-weight: 900; margin-bottom: 6px; color: var(--hn-text); }
.hn-label .hn-ico { color: var(--hn-accent); }
.hn-label small { font-weight: 700; color: var(--hn-sub); font-size: .66rem; }
.hn-learning { display: grid; grid-template-columns: 24px 1fr; gap: 8px; align-items: start; margin-bottom: 8px; }
.hn-num { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font-size: .72rem; font-weight: 900; background: var(--hn-leaf); color: #fff; margin-top: 6px; }

.hn-todos { list-style: none; margin: 0 0 8px; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.hn-todo { display: grid; grid-template-columns: 26px 1fr 30px; gap: 6px; align-items: center; }
.hn-check { width: 22px; height: 22px; border-radius: 7px; border: 2px solid var(--hn-brown); background: var(--hn-paper); display: grid; place-items: center; cursor: pointer; color: #fff; padding: 0; }
.hn-check.done { background: var(--hn-leaf); border-color: var(--hn-leaf); }
.hn-todo input.hn-input { padding: 6px 10px; }
.hn-todo.done input.hn-input { text-decoration: line-through; color: var(--hn-sub); }
.hn-todo-add { display: grid; grid-template-columns: 1fr auto; gap: 6px; }

.hn-pane-foot { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 10px; font-size: .7rem; color: var(--hn-sub); }
.hn-saved { display: inline-flex; align-items: center; gap: 4px; }

/* ---------- 空状態 ---------- */
.hn-empty { text-align: center; padding: 26px 16px; border: 2px dashed var(--hn-brown-soft); border-radius: 16px; background: var(--hn-paper); }
.hn-empty h3 { margin: 8px 0 6px; font-size: .98rem; font-weight: 900; }
.hn-empty p { margin: 0 auto 14px; font-size: .8rem; color: var(--hn-sub); line-height: 1.6; max-width: 520px; }
.hn-steps { display: grid; grid-template-columns: 1fr; gap: 8px; max-width: 640px; margin: 0 auto 16px; text-align: left; }
.hn-step { display: flex; gap: 10px; align-items: flex-start; background: var(--hn-cream); border: 1.5px solid var(--hn-line); border-radius: 12px; padding: 10px 12px; font-size: .78rem; line-height: 1.5; }
.hn-step b { display: block; font-size: .8rem; }
.hn-empty-actions { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; }
.hn-mini-empty { font-size: .8rem; color: var(--hn-sub); text-align: center; padding: 18px 8px; }

/* ---------- ダッシュボード ---------- */
.hn-stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-bottom: 14px; }
.hn-stat { background: var(--hn-paper); border: 2px solid var(--hn-brown); border-radius: 16px; padding: 12px 14px; }
.hn-stat .k { font-size: .7rem; font-weight: 800; color: var(--hn-sub); display: flex; align-items: center; gap: 5px; }
.hn-stat .v { font-size: 1.5rem; font-weight: 900; margin-top: 2px; }
.hn-stat .v small { font-size: .7rem; color: var(--hn-sub); margin-left: 3px; }
.hn-dash-group { margin-bottom: 12px; }
.hn-dash-book { display: flex; align-items: center; justify-content: space-between; gap: 6px; font-size: .78rem; font-weight: 900; margin-bottom: 6px; }
.hn-linkbtn { font: inherit; font-size: .7rem; font-weight: 800; color: var(--hn-accent); background: none; border: none; cursor: pointer; padding: 2px 4px; display: inline-flex; align-items: center; gap: 3px; }
.hn-result { padding: 9px 10px; border-radius: 12px; border: 1.5px solid var(--hn-line); background: var(--hn-cream); margin-bottom: 7px; cursor: pointer; }
.hn-result:hover { border-color: var(--hn-accent); }
.hn-result-book { font-size: .68rem; font-weight: 800; color: var(--hn-sub); margin-bottom: 3px; display: flex; gap: 6px; align-items: center; }

/* ---------- プライバシー注記 ---------- */
.hn-privacy { display: flex; gap: 8px; align-items: flex-start; font-size: .7rem; color: var(--hn-sub); line-height: 1.55; margin-top: 12px; padding: 8px 10px; border-radius: 12px; background: var(--hn-leaf-soft); }
.hn-privacy .hn-ico { color: var(--hn-leaf); margin-top: 1px; }

/* ---------- スマホ下部クイック操作バー ---------- */
.hn-bottombar { position: sticky; bottom: 8px; z-index: 5; display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; margin-top: 12px; padding: 5px; border-radius: 18px; background: var(--hn-brown); box-shadow: 0 6px 18px rgba(74, 47, 18, .3); }
.hn-bottombar button { display: flex; flex-direction: column; align-items: center; gap: 2px; font: inherit; font-size: .64rem; font-weight: 800; padding: 7px 2px 6px; border-radius: 13px; border: none; background: transparent; color: rgba(253, 248, 240, .78); cursor: pointer; min-height: 48px; }
.hn-bottombar button.active { background: var(--hn-cream); color: var(--hn-brown); }
[data-theme="dark"] .hn-bottombar button { color: rgba(43, 36, 30, .8); }
[data-theme="dark"] .hn-bottombar button.active { color: var(--hn-text); }

/* スマホ: 表示ペイン切替 */
@media (max-width: 767px) {
  .hn-app { padding: 14px 12px 10px; border-radius: 18px; }
  .hn-app[data-mpane="highlights"] .hn-pane-notebook { display: none; }
  .hn-app[data-mpane="notebook"] .hn-pane-highlights { display: none; }
  .hn-hl-list { max-height: none; }
  .hn-head-actions .hn-btn-import-top { display: none; }
  .hn-btn, .hn-chipbtn { min-height: 36px; }
  .hn-iconbtn { width: 36px; height: 36px; }
}

/* タブレット / PC: 2カラム */
@media (min-width: 768px) {
  .hn-bottombar { display: none; }
  .hn-grid { grid-template-columns: minmax(280px, 0.9fr) minmax(0, 1.25fr); align-items: start; }
  .hn-pane-notebook { position: sticky; top: calc(var(--header-actual-height, 108px) + 12px); }
  .hn-stats { grid-template-columns: repeat(4, 1fr); }
  .hn-steps { grid-template-columns: repeat(3, 1fr); }
  .hn-dash-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; align-items: start; }
}
/* 広い画面: 手帳を左右見開きに */
@media (min-width: 1180px) {
  .hn-spread { grid-template-columns: 1fr 1fr; }
  .hn-page + .hn-page { border-top: none; border-left: 2px dashed var(--hn-line); }
  .hn-spread::after { content: ''; position: absolute; top: 0; bottom: 0; left: 50%; width: 18px; transform: translateX(-50%); background: linear-gradient(to right, transparent, rgba(111,69,24,.08), transparent); pointer-events: none; }
}

/* ---------- 取り込みモーダル ---------- */
.hn-modal { position: fixed; inset: 0; z-index: 100000; display: none; align-items: center; justify-content: center; padding: 16px; background: rgba(43, 28, 12, .45); font-family: 'Hiragino Maru Gothic ProN', 'Noto Sans JP', -apple-system, sans-serif; }
.hn-modal.open { display: flex; }
.hn-modal-card { --hn-cream: #fdf8f0; --hn-paper: #fffdf8; --hn-brown: #6f4518; --hn-line: rgba(111,69,24,.16); --hn-accent: #e07a2e; --hn-accent-soft: rgba(224,122,46,.12); --hn-leaf: #5f8f4e; --hn-leaf-soft: rgba(95,143,78,.13); --hn-text: #4a2f12; --hn-sub: #8a6a48; --hn-brown-soft: rgba(111,69,24,.55); width: min(640px, 100%); max-height: calc(100vh - 32px); overflow-y: auto; background: var(--hn-cream); color: var(--hn-text); border: 3px solid var(--hn-brown); border-radius: 22px; box-shadow: 0 6px 0 rgba(111,69,24,.3); padding: 18px; }
[data-theme="dark"] .hn-modal-card { --hn-cream: #22262D; --hn-paper: #2A2F38; --hn-brown: #DFBA84; --hn-line: rgba(255,255,255,.14); --hn-accent: #E79B4C; --hn-accent-soft: rgba(231,155,76,.18); --hn-leaf: #6BC692; --hn-leaf-soft: rgba(107,198,146,.16); --hn-text: #F0EDE7; --hn-sub: #CBC5BA; --hn-brown-soft: rgba(223,186,132,.58); }
[data-theme="dark"] .hn-brand-badge,
[data-theme="dark"] .hn-btn.primary,
[data-theme="dark"] .hn-btn.leaf,
[data-theme="dark"] .hn-seg button.active,
[data-theme="dark"] .hn-mode button.active,
[data-theme="dark"] .hn-num,
[data-theme="dark"] .hn-check.done { color: #191612; }
[data-theme="dark"] .hn-mode button.active.fun { background: #F48FB1; color: #1F1218; }
[data-theme="dark"] .hn-genre-pill.active .hn-pill { background: rgba(25, 22, 18, 0.22); color: #191612; }
[data-theme="dark"] .hn-sync.is-error,
[data-theme="dark"] .hn-sync.is-auth,
[data-theme="dark"] .hn-sync.is-premium,
[data-theme="dark"] .hn-sync.is-too_large,
[data-theme="dark"] .hn-preview.warn { color: #F5C97B; border-color: rgba(245, 201, 123, 0.38); }
[data-theme="dark"] .hnq-count.over,
[data-theme="dark"] .hnq-errors { color: #FCA5A5; }
.hn-modal-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 12px; }
.hn-modal-head h3 { margin: 0; font-size: 1rem; font-weight: 900; display: flex; align-items: center; gap: 8px; }
.hn-howto { font-size: .76rem; line-height: 1.65; color: var(--hn-sub); background: var(--hn-paper); border: 1.5px solid var(--hn-line); border-radius: 12px; padding: 10px 12px; margin: 0 0 12px; }
.hn-howto ol { margin: 4px 0 0; padding-left: 18px; }
.hn-howto code { font-size: .74rem; background: var(--hn-accent-soft); color: var(--hn-accent); padding: 1px 6px; border-radius: 6px; }
.hn-modal .hn-textarea { min-height: 170px; font-size: .8rem; background: var(--hn-paper); }
.hn-modal-row { display: grid; grid-template-columns: 1fr; gap: 8px; margin: 10px 0; }
.hn-preview { font-size: .76rem; font-weight: 800; color: var(--hn-leaf); min-height: 1.2em; }
.hn-preview.warn { color: #c2410c; }
.hn-modal-foot { display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; align-items: center; margin-top: 12px; }
.hn-spin { width: 14px; height: 14px; border: 2px solid rgba(255,255,255,.5); border-top-color: #fff; border-radius: 50%; animation: hn-spin .7s linear infinite; }
@keyframes hn-spin { to { transform: rotate(360deg); } }
@media (min-width: 600px) { .hn-modal-row { grid-template-columns: 1fr 1fr; } }

/* 従来版ノート（折りたたみ） */
.hn-legacy { margin-top: 6px; border: 1.5px dashed var(--border-color, rgba(111,69,24,.25)); border-radius: 14px; padding: 4px 14px; }
.hn-legacy > summary { cursor: pointer; font-size: .82rem; font-weight: 800; color: var(--text-sub, #8a6a48); padding: 10px 0; list-style: none; display: flex; align-items: center; gap: 6px; }
.hn-legacy > summary::-webkit-details-marker { display: none; }
.hn-legacy[open] > summary { margin-bottom: 8px; }

@media (prefers-reduced-motion: reduce) {
  .hn-btn, .hn-hl, .hn-spin { transition: none; animation: none; }
}

/* ===== v2: クラウド同期表示・本棚紐付け・プラン案内・引用カード ===== */
.hn-sync { display: inline-flex; align-items: center; gap: 5px; font-size: .68rem; font-weight: 700; color: var(--hn-sub); padding: 4px 10px; border-radius: 999px; border: 1.5px solid var(--hn-line); background: var(--hn-paper); white-space: nowrap; }
.hn-sync[hidden] { display: none; }
.hn-sync .hn-ico { width: 13px; height: 13px; }
.hn-sync.is-ok { color: var(--hn-leaf); border-color: var(--hn-leaf-soft); }
.hn-sync.is-syncing .hn-ico { animation: hn-pulse 1.1s ease-in-out infinite; }
.hn-sync.is-error, .hn-sync.is-auth, .hn-sync.is-premium, .hn-sync.is-too_large { color: #b45309; border-color: rgba(180, 83, 9, .3); }
.hn-sync.is-local { color: var(--hn-accent); border-color: var(--hn-accent-soft); }
.hn-sync-exit { font: inherit; font-size: .64rem; font-weight: 800; border: none; background: transparent; color: var(--hn-sub); text-decoration: underline; cursor: pointer; padding: 0 0 0 4px; }
@keyframes hn-pulse { 0%, 100% { opacity: 1; } 50% { opacity: .35; } }

.hn-linkbanner { margin: 0 0 12px; padding: 10px 12px; border: 1.5px dashed var(--hn-line); border-radius: 14px; background: var(--hn-paper); }
.hn-linkbanner-head { display: flex; align-items: center; gap: 6px; font-size: .76rem; font-weight: 800; color: var(--hn-text); margin-bottom: 8px; }
.hn-linkbanner-list { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.hn-linkcand { display: inline-flex; align-items: center; gap: 8px; max-width: 280px; font: inherit; text-align: left; padding: 5px 10px 5px 5px; border-radius: 12px; border: 1.5px solid var(--hn-line); background: var(--hn-cream); color: var(--hn-text); cursor: pointer; transition: border-color .12s, transform .12s; }
.hn-linkcand:hover { border-color: var(--hn-accent); transform: translateY(-1px); }
.hn-linkcand img, .hn-linkcand .hn-cover-ph { width: 26px; height: 36px; border-radius: 4px; object-fit: cover; flex: none; }
.hn-linkcand-t { font-size: .74rem; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.hn-linkcand-s { font-size: .62rem; color: var(--hn-sub); white-space: nowrap; }

.hn-lock { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 16px; margin-top: 14px; }
.hn-lock-main { padding: 18px; border: 2px solid var(--hn-line); border-radius: 18px; background: var(--hn-paper); }
.hn-lock-main h3 { margin: 10px 0 12px; font-size: 1.05rem; font-weight: 800; color: var(--hn-text); }
.hn-lock-feats { list-style: none; margin: 0 0 14px; padding: 0; display: grid; gap: 10px; }
.hn-lock-feats li { display: flex; gap: 10px; align-items: flex-start; }
.hn-lock-feats li > .hn-ico { width: 18px; height: 18px; color: var(--hn-accent); flex: none; margin-top: 2px; }
.hn-lock-feats b { display: block; font-size: .82rem; color: var(--hn-text); }
.hn-lock-feats span { font-size: .72rem; color: var(--hn-sub); }
.hn-lock-cta { display: flex; gap: 8px; flex-wrap: wrap; }
.hn-lock-price { margin: 8px 0 0; font-size: .7rem; color: var(--hn-sub); }
.hn-lock-kept { display: flex; gap: 6px; align-items: flex-start; margin: 10px 0 0; font-size: .72rem; color: var(--hn-leaf); }
.hn-lock-dev { display: block; margin-top: 12px; font-size: .68rem; opacity: .8; }
.hn-lock-sample { padding: 14px; border: 2px solid var(--hn-line); border-radius: 18px; background: var(--hn-cream); opacity: .92; }
.hn-lock-sample-title { display: flex; align-items: center; gap: 6px; font-size: .74rem; font-weight: 800; color: var(--hn-sub); margin-bottom: 8px; }
.hn-lock-sample .hn-hls { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
@media (max-width: 767px) {
  .hn-lock { grid-template-columns: 1fr; }
  .hn-lock-sample { order: -1; }
  .hn-sync { font-size: .62rem; padding: 3px 8px; }
}

.hnq-card { width: min(980px, 100%); }
.hnq-body { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; margin: 10px 0 12px; }
.hnq-form { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.hnq-label { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; font-size: .76rem; font-weight: 800; color: var(--hn-text); margin-top: 4px; }
.hnq-count { font-size: .66rem; font-weight: 700; color: var(--hn-sub); }
.hnq-count.over { color: #b91c1c; }
.hnq-ta { min-height: 92px; }
.hnq-quote { font-family: "Hiragino Mincho ProN", "Yu Mincho", "Noto Serif JP", serif; min-height: 78px; }
.hnq-hint { font-size: .66rem; color: var(--hn-sub); }
.hnq-errors { margin: 2px 0 0; padding-left: 18px; font-size: .7rem; color: #b91c1c; }
.hnq-errors:empty { display: none; }
.hnq-law { display: flex; gap: 6px; align-items: flex-start; margin-top: 4px; padding: 8px 10px; border-radius: 10px; background: var(--hn-leaf-soft); color: var(--hn-text); font-size: .66rem; line-height: 1.55; }
.hnq-ico { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.hnq-preview { display: flex; align-items: flex-start; justify-content: center; min-width: 0; }
.hnq-preview canvas { width: 100%; max-width: 440px; height: auto; aspect-ratio: 1 / 1; border-radius: 14px; box-shadow: 0 4px 14px rgba(111, 69, 24, .14); background: #fdf8f0; }
.hnq-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.hnq-actions [hidden] { display: none; }
.hnq-disabled { opacity: .5; }
@media (max-width: 767px) {
  .hnq-body { grid-template-columns: 1fr; }
  .hnq-preview { order: -1; }
  .hnq-preview canvas { max-width: 300px; }
}

/* ---------- 全冊ダッシュボード拡張: 今日のハイライト / 読書分析 / 本棚ライブラリ ---------- */
.hn-today { background: var(--hn-paper); border: 2px solid var(--hn-brown); border-radius: 18px; padding: 14px 16px; margin-bottom: 14px; }
.hn-today-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.hn-today-date { font-size: .72rem; font-weight: 800; color: var(--hn-sub); }
.hn-today-quote { position: relative; margin: 0; padding: 12px 14px 12px 20px; background: var(--hn-cream); border-radius: 14px; }
.hn-today-quote .hn-hl-bar { position: absolute; left: 8px; top: 12px; bottom: 12px; width: 4px; border-radius: 4px; }
.hn-today-quote p { margin: 0; font-size: .95rem; line-height: 1.85; white-space: pre-wrap; word-break: break-word; }
.hn-today-book { display: flex; align-items: center; gap: 10px; margin-top: 10px; font-size: .78rem; }
.hn-today-book img, .hn-today-book .hn-cover-ph { width: 32px; height: 46px; border-radius: 4px; object-fit: cover; flex-shrink: 0; }
.hn-today-book b { display: block; font-weight: 800; }
.hn-today-book span { color: var(--hn-sub); }
.hn-today-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.hn-today-digest { margin-top: 12px; padding-top: 12px; border-top: 1.5px dashed var(--hn-line); font-size: .78rem; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; }
.hn-today-digest.is-note { color: var(--hn-sub); }
.hn-today-digest label { display: inline-flex; align-items: center; gap: 6px; cursor: pointer; font-weight: 800; }
.hn-today-digest input[type="checkbox"] { width: 16px; height: 16px; accent-color: var(--hn-accent); }
.hn-digest-chans { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; }
.hn-digest-chan { font-weight: 700 !important; }
.hn-digest-chan small { font-weight: 600; color: var(--hn-sub); font-size: .68rem; }
.hn-digest-chan.is-off { color: var(--hn-sub); }
.hn-digest-hint { flex-basis: 100%; margin: 0; font-size: .68rem; color: var(--hn-sub); }

.hn-analytics { margin-bottom: 14px; }
.hn-stats-sub { margin-bottom: 12px; }
.hn-analytics-grid { display: grid; grid-template-columns: 1fr; gap: 12px; }
.hn-an-block { background: var(--hn-cream); border-radius: 14px; padding: 12px; min-width: 0; }
.hn-an-title { font-size: .72rem; font-weight: 800; color: var(--hn-sub); margin-bottom: 8px; }
.hn-heat-filters { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; margin-bottom: 8px; }
.hn-heat-chk { display: inline-flex; align-items: center; gap: 4px; font-size: .68rem; font-weight: 800; color: var(--hn-text); cursor: pointer; background: var(--hn-paper); border: 1.5px solid var(--hn-line); border-radius: 999px; padding: 3px 9px 3px 7px; user-select: none; }
.hn-heat-chk input[type="checkbox"] { width: 13px; height: 13px; accent-color: var(--hn-accent); margin: 0; cursor: pointer; }
.hn-heat-wrap { overflow-x: auto; scrollbar-width: none; padding: 2px 4px 2px 2px; }
.hn-heat-months, .hn-heat { display: grid; gap: 3px; width: 100%; min-width: 240px; }
.hn-heat-months { font-size: .6rem; color: var(--hn-sub); margin-bottom: 4px; }
.hn-heat-months span { white-space: nowrap; }
.hn-heat { grid-template-rows: repeat(7, 1fr); }
.hn-heat i, .hn-heat-legend i { display: block; aspect-ratio: 1; border-radius: 3px; background: var(--hn-rule); }
.hn-heat i { cursor: pointer; transition: transform .1s ease, box-shadow .1s ease; }
.hn-heat i:hover { transform: scale(1.15); box-shadow: 0 0 0 1.5px var(--hn-brown-soft); }
.hn-heat i.is-sel { box-shadow: 0 0 0 2px var(--hn-brown); }
.hn-heat i.lv1, .hn-heat-legend i.lv1 { background: rgba(224, 122, 46, .28); }
.hn-heat i.lv2, .hn-heat-legend i.lv2 { background: rgba(224, 122, 46, .5); }
.hn-heat i.lv3, .hn-heat-legend i.lv3 { background: rgba(224, 122, 46, .75); }
.hn-heat i.lv4, .hn-heat-legend i.lv4 { background: var(--hn-accent); }
.hn-heat-legend { display: flex; align-items: center; justify-content: flex-end; gap: 3px; font-size: .6rem; color: var(--hn-sub); margin-top: 6px; }
.hn-heat-legend i { width: 10px; }
.hn-heat-detail { margin-top: 8px; padding: 7px 10px; border-radius: 10px; background: var(--hn-paper); border: 1px dashed var(--hn-line); font-size: .68rem; display: flex; flex-direction: column; gap: 5px; line-height: 1.45; }
.hn-heat-detail-top { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
.hn-heat-detail-date { font-weight: 900; color: var(--hn-accent); background: var(--hn-accent-soft); padding: 1px 7px; border-radius: 999px; white-space: nowrap; }
.hn-heat-detail-body { color: var(--hn-text); font-weight: 700; min-width: 0; word-break: break-word; }
.hn-heat-books { display: flex; flex-wrap: wrap; align-items: center; gap: 5px; }
.hn-heat-booklink { font: inherit; font-size: .66rem; font-weight: 800; color: var(--hn-brown); background: var(--hn-cream); border: 1.5px solid var(--hn-line); border-radius: 999px; padding: 2px 9px; cursor: pointer; display: inline-flex; align-items: center; gap: 3px; transition: all .12s; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hn-heat-booklink:hover { border-color: var(--hn-accent); color: var(--hn-accent); background: var(--hn-accent-soft); transform: translateY(-1px); }
.hn-heat-bookspan { font-size: .66rem; font-weight: 700; color: var(--hn-sub); }
.hn-heat-bookmore { font-size: .64rem; font-weight: 700; color: var(--hn-sub); }
.hn-bars { display: grid; grid-template-columns: repeat(12, 1fr); gap: 4px; height: 120px; align-items: end; }
.hn-bar { display: flex; flex-direction: column; align-items: center; justify-content: flex-end; height: 100%; gap: 3px; }
.hn-bar span { display: block; width: 100%; max-width: 18px; background: var(--hn-accent); border-radius: 4px 4px 2px 2px; }
.hn-bar small { font-size: .58rem; color: var(--hn-sub); }
.hn-donut-wrap { display: flex; align-items: center; gap: 14px; }
.hn-donut { position: relative; width: 104px; height: 104px; border-radius: 50%; flex-shrink: 0; }
.hn-donut span { position: absolute; inset: 22px; border-radius: 50%; background: var(--hn-cream); display: grid; place-items: center; font-weight: 900; font-size: 1.1rem; }
.hn-donut span small { font-size: .62rem; color: var(--hn-sub); }
.hn-donut-legend { list-style: none; margin: 0; padding: 0; font-size: .72rem; display: grid; gap: 4px; min-width: 0; }
.hn-donut-legend li { display: flex; align-items: center; gap: 6px; }
.hn-donut-legend i { width: 10px; height: 10px; border-radius: 3px; flex-shrink: 0; }
.hn-donut-legend b { margin-left: auto; padding-left: 8px; }
.hn-an-note { margin: 10px 0 0; font-size: .66rem; color: var(--hn-sub); line-height: 1.6; }

.hn-library { margin-bottom: 14px; }
.hn-library .hn-pane-head { flex-wrap: wrap; gap: 8px; }
.hn-lib-tools { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.hn-lib-sort { width: auto; padding: 6px 10px; font-size: .74rem; }
.hn-seg { display: inline-flex; border: 2px solid var(--hn-brown); border-radius: 999px; overflow: hidden; }
.hn-seg button { font: inherit; font-size: .72rem; font-weight: 800; display: inline-flex; align-items: center; gap: 4px; padding: 5px 10px; border: 0; background: var(--hn-paper); color: var(--hn-text); cursor: pointer; }
.hn-seg button.active { background: var(--hn-accent); color: #fff; }
.hn-lib-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(112px, 1fr)); gap: 12px; }
.hn-lib-card { font: inherit; text-align: left; display: flex; flex-direction: column; gap: 4px; padding: 8px; border: 2px solid var(--hn-line); border-radius: 14px; background: var(--hn-cream); color: var(--hn-text); cursor: pointer; transition: transform .12s ease, border-color .12s; min-width: 0; }
.hn-lib-card:hover { transform: translateY(-2px); border-color: var(--hn-brown); }
.hn-lib-cover { display: block; aspect-ratio: 2 / 3; border-radius: 8px; overflow: hidden; background: var(--hn-leaf-soft); }
.hn-lib-cover img, .hn-lib-cover .hn-cover-ph { width: 100%; height: 100%; object-fit: cover; border-radius: 0; }
.hn-lib-title { font-size: .76rem; font-weight: 800; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.hn-lib-meta { font-size: .66rem; color: var(--hn-sub); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hn-lib-count { font-size: .68rem; font-weight: 800; color: var(--hn-accent); display: inline-flex; align-items: center; gap: 3px; }
.hn-lib-tablewrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.hn-lib-table { width: 100%; border-collapse: collapse; font-size: .76rem; min-width: 560px; }
.hn-lib-table th { text-align: left; font-size: .68rem; color: var(--hn-sub); font-weight: 800; padding: 6px 8px; border-bottom: 2px solid var(--hn-line); white-space: nowrap; }
.hn-lib-table td { padding: 6px 8px; border-bottom: 1px solid var(--hn-rule); vertical-align: middle; }
.hn-lib-table tbody tr { cursor: pointer; }
.hn-lib-table tbody tr:hover, .hn-lib-table tbody tr:focus { background: var(--hn-accent-soft); outline: none; }
.hn-lib-table .num { text-align: right; font-weight: 800; }
.hn-lib-table .ttl { font-weight: 800; max-width: 260px; }
.hn-lib-table .cv img, .hn-lib-table .cv .hn-cover-ph { width: 28px; height: 40px; border-radius: 4px; object-fit: cover; }
@media (min-width: 900px) {
  .hn-analytics-grid { grid-template-columns: 1.4fr 1fr 1fr; }
}

/* ---------- 取り込みモーダル: ファイル取り込み（ドラッグ＆ドロップ） ---------- */
.hn-dropzone { display: flex; align-items: center; gap: 10px; margin: 0 0 10px; padding: 12px 14px; border: 2px dashed var(--hn-line); border-radius: 14px; background: var(--hn-paper); cursor: pointer; font-size: .78rem; transition: border-color .12s, background .12s; }
.hn-dropzone:hover, .hn-dropzone.is-over { border-color: var(--hn-accent); background: var(--hn-accent-soft); }
.hn-dropzone small { display: block; margin-top: 2px; font-size: .68rem; color: var(--hn-sub); line-height: 1.5; }

/* ---------- 読書ポートフォリオ帯グラフ ---------- */
.hn-portfolio-bar { display: flex; height: 12px; border-radius: 999px; overflow: hidden; background: var(--hn-rule); margin-top: 10px; box-shadow: inset 0 1px 2px rgba(0,0,0,.1); }
.hn-portfolio-segment { height: 100%; transition: width .3s ease; }

/* ---------- 本棚ライブラリ: ジャンル絞り込みピル ＆ エクスポート ---------- */
.hn-genre-pills { display: flex; gap: 6px; align-items: center; overflow-x: auto; padding: 2px 2px 8px; margin-bottom: 12px; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.hn-genre-pills::-webkit-scrollbar { display: none; }
.hn-genre-pill { display: inline-flex; align-items: center; gap: 5px; font: inherit; font-size: .74rem; font-weight: 800; padding: 5px 11px; border-radius: 999px; border: 1.5px solid var(--hn-line); background: var(--hn-cream); color: var(--hn-sub); cursor: pointer; white-space: nowrap; transition: all .12s; }
.hn-genre-pill:hover { border-color: var(--hn-brown); color: var(--hn-text); }
.hn-genre-pill.active { background: var(--hn-brown); color: var(--hn-cream); border-color: var(--hn-brown); }
.hn-genre-pill .hn-pill { font-size: .62rem; padding: 1px 6px; }
.hn-genre-pill.active .hn-pill { background: rgba(255, 255, 255, .25); color: #fff; }
.hn-lib-export-grp { display: inline-flex; gap: 6px; align-items: center; }

/* ---------- Chrome拡張機能案内バナー（ライト・ダーク両対応） ---------- */
.hn-ext-banner { background: var(--hn-leaf-soft); border: 1.5px solid var(--hn-leaf); border-radius: 12px; padding: 10px 12px; margin-bottom: 12px; font-size: .76rem; display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.hn-ext-banner-text { display: flex; align-items: center; gap: 8px; color: var(--hn-text); min-width: 0; }
.hn-ext-banner-text .hn-ico { color: var(--hn-leaf); }

/* ---------- 本格DBビュー強化（多冊数ジャンプ・ファセット・表プレビュー） ---------- */
.hn-select-jump { border-style: solid; border-color: var(--hn-brown); background: var(--hn-paper); font-weight: 800; max-width: 260px; }
.hn-lib-filterbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 12px; }
.hn-lib-search { flex: 1 1 240px; margin-bottom: 0; }
.hn-dash-facets { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.hn-chipbtn.is-on { background: var(--hn-brown); color: var(--hn-cream); border-color: var(--hn-brown); }
.hn-color-dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; flex-shrink: 0; box-shadow: inset 0 0 0 1px rgba(0,0,0,.15); }
.hn-lib-snippet { font-size: .64rem; color: var(--hn-sub); line-height: 1.45; background: var(--hn-paper); border: 1px dashed var(--hn-line); border-radius: 7px; padding: 4px 6px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.hn-lib-tododot { width: 7px; height: 7px; border-radius: 50%; background: var(--hn-leaf); display: inline-block; }
.hn-table-sub { font-size: .66rem; font-weight: 600; color: var(--hn-sub); margin-top: 2px; }
.hn-table-note { max-width: 300px; font-size: .72rem; color: var(--hn-text); }
.hn-table-note-clamp { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; line-height: 1.5; }
.hn-db-badge { display: inline-flex; align-items: center; font-size: .64rem; font-weight: 800; padding: 2px 7px; border-radius: 999px; white-space: nowrap; }
.hn-db-badge.is-open { background: var(--hn-accent-soft); color: var(--hn-accent); }
.hn-db-badge.is-done { background: var(--hn-leaf-soft); color: var(--hn-leaf); }
.hn-dash-results { max-height: 540px; overflow-y: auto; padding-right: 2px; }

/* ---------- Phase 3: 読書ノートとつながる開催中のお知らせ（控えめなカフェ風カード） ---------- */
.hn-salerec { margin-top: 14px; background: var(--hn-paper); border-Style: dashed; border-width: 2px; border-color: var(--hn-brown-soft); }
.hn-salerec-sub { font-size: .68rem; font-weight: 700; color: var(--hn-sub); margin-left: 4px; }
.hn-salerec-grid { display: grid; grid-template-columns: 1fr; gap: 10px; }
.hn-salerec-card { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 14px; border: 1.5px solid var(--hn-line); background: var(--hn-cream); min-width: 0; }
.hn-salerec-cover { width: 38px; height: 54px; border-radius: 5px; object-fit: cover; flex-shrink: 0; }
.hn-salerec-body { flex: 1; min-width: 0; }
.hn-salerec-meta { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; font-size: .64rem; font-weight: 700; color: var(--hn-sub); margin-bottom: 3px; }
.hn-salerec-title { font-size: .78rem; font-weight: 800; color: var(--hn-text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hn-salerec-reason { font-size: .68rem; color: var(--hn-sub); margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hn-salerec-act { flex-shrink: 0; }
.hn-salerec-collapsed { margin-top: 12px; padding: 8px 12px; border-radius: 12px; border: 1px dashed var(--hn-line); display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: .7rem; color: var(--hn-sub); }
@media (min-width: 900px) {
  .hn-salerec-grid { grid-template-columns: repeat(3, 1fr); }
}

/* ---------- 10世代タイムマシン（保存履歴一覧・1クリック復元モーダル） ---------- */
.hn-rev-list { display: flex; flex-direction: column; gap: 8px; max-height: 380px; overflow-y: auto; padding-right: 4px; }
.hn-rev-item { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 12px; border-radius: 12px; border: 1.5px solid var(--hn-line); background: var(--hn-paper); }
.hn-rev-item.is-latest { border-color: var(--hn-leaf); background: var(--hn-cream); }
.hn-rev-main { flex: 1; min-width: 0; }
.hn-rev-meta { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; font-size: .68rem; color: var(--hn-sub); margin-bottom: 4px; }
.hn-rev-ver { font-weight: 800; color: var(--hn-text); font-size: .74rem; }
.hn-rev-badge { display: inline-flex; align-items: center; padding: 1px 7px; border-radius: 999px; font-size: .64rem; font-weight: 800; background: var(--hn-accent-soft); color: var(--hn-accent); }
.hn-rev-item.is-latest .hn-rev-badge { background: var(--hn-leaf-soft); color: var(--hn-leaf); }
.hn-rev-time { font-variant-numeric: tabular-nums; }
.hn-rev-counts { font-weight: 700; }
.hn-rev-snippet { font-size: .72rem; color: var(--hn-text); line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; word-break: break-word; }
.hn-rev-act { flex-shrink: 0; }
.hn-rev-empty { padding: 22px 14px; text-align: center; font-size: .76rem; color: var(--hn-sub); border: 1px dashed var(--hn-line); border-radius: 12px; background: var(--hn-paper); line-height: 1.6; }
.hn-rev-subnote { font-size: .7rem; font-weight: 700; color: var(--hn-sub); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 65%; }
.hn-linkbtn.hn-linkbtn-danger { color: #b91c1c; }
html[data-theme="dark"] .hn-linkbtn.hn-linkbtn-danger { color: #fca5a5; }
html[data-theme="dark"] .hn-pane-title .hn-pill { color: #fde68a; background: rgba(217, 119, 6, 0.28); }
html[data-theme="dark"] .ku-guest-sample-btn { background: linear-gradient(135deg, #b45309, #92400e); border-color: #d97706; color: #ffffff; }
html[data-theme="dark"] .ku-guest-free-badge { color: #7dd3fc !important; background: rgba(14, 165, 233, 0.18) !important; border-color: rgba(125, 211, 252, 0.42) !important; }
html[data-theme="dark"] .ku-guest-reg-pill { color: #fdba74 !important; border-color: #fb923c !important; }
html[data-theme="dark"] .hikabon-stamp-trigger { color: #fca5a5; border-color: rgba(248, 113, 113, 0.48); background: rgba(239, 68, 68, 0.15); }
html[data-theme="dark"] .hikabon-stamp-trigger.is-plus-stamp { color: #ddd6fe; border-color: rgba(196, 181, 253, 0.52); background: rgba(124, 58, 237, 0.2); }
html[data-theme="dark"] .prem-plus-subnote { color: #ddd6fe !important; }
html[data-theme="dark"] .billing-preparing-note { color: #fde68a !important; background: rgba(245, 158, 11, 0.14) !important; border-color: rgba(245, 158, 11, 0.45) !important; }
