/* ============ 词典栏目专用样式（栏目页/字母列表/详情/搜索/标签） ============ */

/* ---------- 栏目页字母索引（带词数，7 列） ---------- */
.zm-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 10px; }
.zm-grid a {
  display: flex; align-items: baseline; justify-content: center; gap: 6px;
  padding: 10px 0; border: 1px solid var(--line); border-radius: 3px;
  background: #fff; font-size: 20px; font-weight: 700;
}
.zm-grid a:hover { border-color: var(--red); background: var(--hover); }
.zm-grid a i { font-style: normal; font-size: 12px; font-weight: 400; color: var(--ink-light); }

/* ---------- 字母列表页字母导航条（紧凑 7 列，独立于栏目页字母索引） ---------- */
.zm-bar { display: grid; grid-template-columns: repeat(7, 1fr); gap: 8px; margin-bottom: 6px; }
.zm-bar a {
  display: flex; align-items: center; justify-content: center;
  padding: 8px 0; border: 1px solid var(--line); border-radius: 3px;
  background: #fff; font-size: 16px; font-weight: 700;
}
.zm-bar a:hover { border-color: var(--red); background: var(--hover); }
.zm-bar a.on { background: var(--red); border-color: var(--red); color: #fff; }

/* ---------- 词语列表（列表页/搜索页/标签页） ---------- */
.word-list li { list-style: none; padding: 12px 2px; border-bottom: 1px dashed var(--line); }
.word-list li:last-child { border-bottom: none; }
.word-list .t { font-size: 17px; font-weight: 700; }
.word-list .t:hover { color: var(--red); }
.word-list .d { font-size: 13px; color: var(--ink-light); margin-top: 2px; }
.word-list .sp { font-size: 13px; color: #3a6ea5; margin-left: 10px; }

/* 搜索页：再次搜索表单 */
.search-again { display: flex; margin-bottom: 16px; }
.search-again select {
  width: 84px; height: 40px; border: 2px solid var(--ink); border-right: 2px solid var(--line);
  background: #fff; font: inherit; font-size: 14px; outline: none; cursor: pointer; padding: 0 8px;
}
.search-again input {
  flex: 1; height: 40px; border: 2px solid var(--ink); border-left: none; border-right: none;
  background: #fff; padding: 0 14px; font: inherit; font-size: 15px; outline: none;
}
.search-again button {
  width: 92px; height: 40px; border: none; background: var(--red); color: #fff;
  font: inherit; font-size: 15px; letter-spacing: 2px; cursor: pointer;
}
.search-again select:focus, .search-again input:focus { border-color: var(--red); border-right: 2px solid var(--red); }
.search-again input:focus { border-left: none; }

/* ---------- 随机词语块（6 列网格） ---------- */
.hot-grid {
  display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px 10px;
}
.hot-grid a {
  text-align: center; padding: 8px 2px; border: 1px solid var(--line);
  border-radius: 3px; background: #fff; font-size: 15px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.hot-grid a:hover { border-color: var(--red); color: var(--red); background: var(--hover); }

/* ---------- 标签云 ---------- */
.tag-cloud { display: flex; flex-wrap: wrap; gap: 10px; }
.tag-cloud a {
  padding: 4px 14px; border: 1px solid var(--line); border-radius: 20px;
  font-size: 13px; background: #fff;
}
.tag-cloud a:hover { border-color: var(--red); color: var(--red); background: var(--hover); }
.tag-cloud a i { font-style: normal; color: var(--ink-light); margin-left: 4px; }

/* ---------- 详情页 ---------- */
.detail-head { text-align: center; padding: 26px 0 18px; border-bottom: 2px solid var(--ink); }
.detail-head h1 { font-size: 32px; letter-spacing: 4px; display: inline; }
.detail-meta { margin-top: 10px; font-size: 13px; color: var(--ink-light); }
.detail-meta span { margin: 0 10px; }
.pinyin-box {
  text-align: center; padding: 16px 0; font-size: 17px; letter-spacing: 1px;
}
.pinyin-box .fanti { margin-left: 18px; color: var(--ink-light); font-size: 14px; }
.sec-title {
  font-size: 19px; font-weight: 700; letter-spacing: 1px; margin: 26px 0 12px;
  padding-left: 12px; border-left: 4px solid var(--red);
}
.sec-title.qa { color: var(--ink); }
.detail-body h2 { font-size: 17px; margin: 20px 0 8px; padding-bottom: 4px; border-bottom: 1px solid var(--line); }
.detail-body ol, .detail-body ul { padding-left: 26px; }
.detail-body li { margin: 6px 0; }
.detail-body rt { font-size: 11px; color: var(--red); }
.detail-body p { margin: 8px 0; }
.detail-tags { margin-top: 24px; padding-top: 16px; border-top: 1px solid var(--line); }
.detail-tags a {
  display: inline-block; margin: 0 10px 10px 0; padding: 3px 14px;
  border: 1px solid var(--line); border-radius: 20px; font-size: 13px; background: #fff;
}
.detail-tags a:hover { border-color: var(--red); color: var(--red); }

/* ---------- 响应式 ---------- */
@media (max-width: 760px) {
  .zm-grid { grid-template-columns: repeat(4, 1fr); }
  .zm-bar { grid-template-columns: repeat(5, 1fr); }
  .hot-grid { grid-template-columns: repeat(3, 1fr); }
}
