/* ================================================================
   足球资料库 · 页面样式 page-db.css
   结构对齐 90vs / titan007 真实页面：洲别Tab + 热门赛事行 + 协会徽标墙 + 联赛详情
   依赖：firstpage-v13.css
   配色：V13 蓝白数据舱 品牌蓝 #0A55D5 / 深 #013080 / 浅 #E3F5FF
   ================================================================ */

/* ---------- 顶部标题 ---------- */
.db-top { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 26px 4px 20px; }
.db-top .eyebrow { color: #5A7FBF; font-size: 11px; letter-spacing: 1.4px; text-transform: uppercase; }
.db-top h1 { font-size: clamp(23px, 3vw, 32px); margin: 8px 0 8px; color: #013080; font-weight: 700; line-height: 1.25; }
.db-top h1 .grad { color: #0A55D5; }
.db-top .hero-desc { max-width: 640px; color: #5A6C88; font-size: 13px; line-height: 1.7; }
.db-top-stat { display: flex; gap: 8px; flex-shrink: 0; }
.db-stat-card { min-width: 78px; padding: 10px 12px; text-align: center; background: #fff; border: 1px solid rgba(10,85,213,.14); border-radius: 12px; }
.db-stat-card b { display: block; font-size: 20px; color: #0A55D5; font-variant-numeric: tabular-nums; line-height: 1.2; }
.db-stat-card span { display: block; margin-top: 3px; font-size: 11px; color: #7E95B7; }

/* ---------- 栏目导航（洲别Tab + 搜索） ---------- */
.db-channel { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 0; margin-bottom: 12px; overflow: hidden; }
.db-channel-tabs { display: flex; flex-wrap: wrap; gap: 2px; padding: 0 8px; }
.db-channel-tabs button {
  padding: 14px 14px; font-size: 13px; color: #5A6C88; background: transparent;
  border: 0; border-bottom: 3px solid transparent; cursor: pointer; transition: .18s; white-space: nowrap;
}
.db-channel-tabs button:hover { color: #0A55D5; }
.db-channel-tabs button.active { color: #0A55D5; font-weight: 600; border-bottom-color: #0A55D5; }
.db-ct-ico { width: 16px; height: 16px; object-fit: contain; vertical-align: -3px; margin-right: 5px; }
.db-channel-search { display: flex; gap: 6px; padding: 9px 12px 9px 0; flex-shrink: 0; }
.db-channel-search input {
  width: 200px; height: 34px; padding: 0 12px; font-size: 12px; color: #1B4F8C;
  background: #F4F8FF; border: 1px solid rgba(10,85,213,.18); border-radius: 8px; outline: none;
}
.db-channel-search input:focus { border-color: #0A55D5; box-shadow: 0 0 0 3px rgba(10,85,213,.1); }
.db-channel-search button {
  height: 34px; padding: 0 14px; font-size: 12px; color: #fff; background: #0A55D5;
  border: 0; border-radius: 8px; cursor: pointer;
}
.db-channel-search button:hover { background: #013080; }

/* ---------- 热门赛事行 ---------- */
.db-hot { display: flex; align-items: flex-start; gap: 12px; padding: 11px 16px; margin-bottom: 18px; }
.db-hot-label { flex-shrink: 0; font-size: 12px; font-weight: 600; color: #0A55D5; padding-top: 2px; }
.db-hot-label::after { content: ' ›'; color: #9BB2D0; }
.db-hot-links { display: flex; flex-wrap: wrap; gap: 4px 0; }
.db-hot-links a {
  font-size: 12px; color: #3E5578; text-decoration: none; padding: 0 10px;
  border-right: 1px solid #E1EAF8; line-height: 1.6;
}
.db-hot-links a:last-child { border-right: 0; }
.db-hot-links a:hover, .db-hot-links a.active { color: #0A55D5; font-weight: 600; }

/* ---------- 徽标墙（对齐 titan007：浅灰底 + 密集白卡 + 真实徽标） ---------- */
.db-stage { margin-bottom: 20px; }
#dbStageWall { padding: 14px; background: #F1F5FA; border: 1px solid #E2EAF6; border-radius: 10px; }
.db-stage-head { display: flex; align-items: baseline; gap: 12px; padding: 0 2px 12px; }
.db-stage-head h2 { font-size: 17px; color: #013080; font-weight: 600; margin: 0; }
.db-stage-head span { font-size: 12px; color: #7E95B7; }
.db-assoc-grid { display: grid; grid-template-columns: repeat(10, minmax(0, 1fr)); gap: 8px; }
.db-assoc-card {
  display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 10px 4px 8px;
  background: #fff; border: 1px solid #E4EAF4; border-radius: 5px;
  cursor: pointer; transition: border-color .18s, box-shadow .18s, transform .18s; text-align: center;
}
.db-assoc-card:hover { transform: translateY(2px); border-color: #0A55D5; box-shadow: 0 6px 16px rgba(1,48,128,.12); }
.db-assoc-badge {
  width: 100%; height: 78px; display: flex; align-items: center; justify-content: center;
  background: #fff; border-radius: 4px; overflow: hidden;
  color: #0A55D5; font-size: 15px; font-weight: 700;
}
.db-assoc-badge img { max-width: 76px; max-height: 76px; width: 90%; height: 90%; object-fit: contain; }
.db-assoc-name { font-size: 12px; color: #2B3A50; font-weight: 500; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.db-assoc-meta { font-size: 10px; color: #92A1B8; }
.db-assoc-caret { display: inline-block; width: 0; height: 0; margin-left: 4px; vertical-align: middle; border-left: 3px solid transparent; border-right: 3px solid transparent; border-top: 4px solid #9BB2D0; }
.db-empty { padding: 36px 12px; text-align: center; color: #7E95B7; font-size: 13px; grid-column: 1 / -1; }

/* ---------- 徽标悬停浮层（两级联动，对齐 titan007） ----------
   第一层：联赛网格（4 列，带下拉箭头）；第二层：移到联赛才出赛季 */
.db-hover {
  position: absolute; z-index: 9999; display: none;
  width: 590px; max-height: calc(100vh - 24px); overflow-y: auto;
  background: #fff; border: 1px solid #D8E4F4; border-radius: 3px;
  box-shadow: 0 14px 44px rgba(1,48,128,.20); color: #2B3A50;
}
.db-hover.show { display: block; }
.db-hover-leagues { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2px 12px; padding: 16px 18px 18px; align-content: start; }
.db-hover-lg {
  border: 0; background: transparent; cursor: pointer; padding: 6px 2px; font-size: 14px;
  color: #3B4C63; text-align: left; font-family: inherit; white-space: nowrap; border-radius: 3px;
}
.db-hover-lg i {
  display: inline-block; width: 0; height: 0; margin-left: 5px; vertical-align: middle;
  border-left: 3px solid transparent; border-right: 3px solid transparent; border-top: 4px solid #9BB2D0;
}
.db-hover-lg:hover, .db-hover-lg.active { color: #0A55D5; font-weight: 600; }
.db-hover-lg:hover i, .db-hover-lg.active i { border-top-color: #0A55D5; }
/* 第二层：联赛赛季 */
.db-hover-sub {
  position: absolute; z-index: 10000; display: none;
  width: 300px; max-height: calc(100vh - 24px); overflow-y: auto;
  background: #fff; border: 1px solid #D8E4F4; border-radius: 3px;
  box-shadow: 0 12px 36px rgba(1,48,128,.22); color: #2B3A50;
}
.db-hover-sub.show { display: block; }
.db-hover-sub-title {
  padding: 12px 16px; font-size: 14px; font-weight: 600; color: #0A55D5;
  background: #F4F8FF; border-bottom: 1px solid #E4EAF4; border-radius: 3px 3px 0 0;
}
.db-hover-sub-ico { width: 20px; height: 20px; object-fit: contain; vertical-align: -5px; margin-right: 7px; }
.db-hover-sub-seasons { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 12px; padding: 14px 16px 18px; align-content: start; }
.db-hover-sub-seasons a, .db-hover-sub-seasons span {
  font-size: 14px; color: #3B4C63; line-height: 1.9; text-decoration: none; white-space: nowrap;
}
.db-hover-sub-seasons a:hover { color: #0A55D5; text-decoration: underline; }
.db-hover-none { grid-column: 1 / -1; color: #92A1B8; }
@media (max-width: 700px) {
  .db-hover { width: min(92vw, 420px); }
  .db-hover-leagues { grid-template-columns: 1fr 1fr; }
  .db-hover-sub { width: min(88vw, 280px); }
}

/* ---------- 联赛详情 ---------- */
.db-stage.panel { padding: 0; overflow: hidden; }
.db-detail-head { padding: 16px 18px 12px; border-bottom: 1px solid #EEF4FF; }
.db-back { padding: 0; margin-bottom: 8px; font-size: 12px; color: #0A55D5; background: transparent; border: 0; cursor: pointer; }
.db-back:hover { text-decoration: underline; }
.db-detail-title-row { display: flex; align-items: center; gap: 10px; }
.db-detail-title-row img { width: 40px; height: 40px; object-fit: contain; }
.db-detail-head h2 { font-size: 20px; color: #013080; margin: 0 0 4px; }
.db-detail-meta { font-size: 12px; color: #7E95B7; }
.db-tabs { display: flex; gap: 4px; padding: 10px 14px 0; border-bottom: 2px solid #E3F5FF; }
.db-tabs button {
  padding: 9px 18px; font-size: 13px; color: #5A6C88; background: transparent;
  border: 0; border-bottom: 2px solid transparent; margin-bottom: -2px; cursor: pointer; transition: .18s;
}
.db-tabs button:hover { color: #0A55D5; }
.db-tabs button.active { color: #0A55D5; font-weight: 600; border-bottom-color: #0A55D5; }
.db-tabpane { display: none; padding: 16px 18px 18px; min-height: 200px; }
.db-tabpane.active { display: block; }

/* ---------- 球队网格（联赛详情） ---------- */
.db-team-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); gap: 12px; }
.db-team-card {
  display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 12px 6px;
  background: #fff; border: 1px solid rgba(10,85,213,.12); border-radius: 10px;
  cursor: pointer; transition: .18s; text-align: center;
}
.db-team-card:hover { transform: translateY(2px); border-color: #0A55D5; box-shadow: 0 6px 16px rgba(10,85,213,.1); }
.db-team-card.active { border-color: #0A55D5; background: #F0F6FF; }
.db-team-badge {
  width: 46px; height: 46px; display: flex; align-items: center; justify-content: center;
  border-radius: 8px; background: linear-gradient(135deg,#E3F5FF,#C7E4FF); color: #0A55D5;
  font-size: 15px; font-weight: 700; overflow: hidden; padding: 2px;
}
.db-team-badge img { width: 100%; height: 100%; object-fit: contain; }
.db-tname { font-size: 12px; color: #1B4F8C; font-weight: 500; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.db-tmeta { font-size: 10px; color: #7E95B7; }

/* ---------- 表格 ---------- */
.db-table-scroll { overflow-x: auto; }
.db-table { width: 100%; border-collapse: collapse; font-size: 12px; }
.db-table th { position: sticky; top: 0; padding: 9px 10px; text-align: left; white-space: nowrap; color: #1B4F8C; font-weight: 500; background: #F4F8FF; border-bottom: 1px solid rgba(10,85,213,.14); }
.db-table td { padding: 9px 10px; color: #3E5578; border-bottom: 1px solid #EEF4FF; white-space: nowrap; }
.db-table tbody tr:hover { background: #F7FBFF; }
.db-table .db-num { font-variant-numeric: tabular-nums; }
.db-table .db-home { color: #013080; font-weight: 600; }
.db-table .db-score { color: #0A55D5; font-weight: 700; font-variant-numeric: tabular-nums; }
.db-result-win { color: #0A55D5; font-weight: 600; }
.db-result-draw { color: #7E95B7; }
.db-result-lose { color: #ED8936; }
.db-table-more { text-align: center; padding-top: 14px; }
.db-table-more button { padding: 8px 24px; font-size: 12px; color: #0A55D5; background: #F4F8FF; border: 1px solid rgba(10,85,213,.22); border-radius: 8px; cursor: pointer; }
.db-table-more button:hover { background: #E3F5FF; }
.db-record-tip { padding: 14px 16px; margin-bottom: 12px; background: #F4F8FF; border: 1px dashed rgba(10,85,213,.22); border-radius: 8px; color: #5A7FBF; font-size: 12px; }
.db-tbl-note { margin-top: 14px; font-size: 11px; color: #9BB2D0; line-height: 1.7; }
.db-catalog-note { color: #ED8936; font-weight: 600; }
.db-detail-meta a { color: #0A55D5; text-decoration: none; }
.db-detail-meta a:hover { text-decoration: underline; }
.db-catalog-empty { display: flex; flex-direction: column; align-items: center; gap: 8px; line-height: 1.7; }
.db-catalog-empty b { color: #1B4F8C; font-size: 14px; }
.db-catalog-empty span { color: #9BB2D0; font-size: 12px; }
.db-catalog-seasons { color: #5A7FBF; font-size: 12px; }
.db-catalog-seasons a { color: #0A55D5; text-decoration: none; }

/* ---------- 搜索结果提示 ---------- */
.db-search-note { padding: 10px 14px; margin-bottom: 12px; font-size: 12px; color: #5A7FBF; background: #F0F6FF; border-radius: 8px; }

/* ---------- 移动端 ---------- */
@media (max-width: 1180px) { .db-assoc-grid { grid-template-columns: repeat(8, minmax(0, 1fr)); } }
@media (max-width: 860px) {
  .db-top { flex-direction: column; align-items: flex-start; padding: 18px 2px 14px; }
  .db-top-stat { width: 100%; }
  .db-stat-card { flex: 1; }
  .db-channel { flex-direction: column; align-items: stretch; }
  .db-channel-tabs { padding: 0 4px; overflow-x: auto; flex-wrap: nowrap; }
  .db-channel-tabs button { padding: 12px 10px; font-size: 12px; }
  .db-channel-search { padding: 8px 12px; }
  .db-channel-search input { flex: 1; width: auto; }
  .db-assoc-grid { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 6px; }
  .db-assoc-badge { height: 58px; }
  .db-assoc-badge img { max-width: 54px; max-height: 54px; }
  .db-assoc-name { font-size: 11px; }
  .db-assoc-meta { display: none; }
  .db-team-grid { grid-template-columns: repeat(auto-fill, minmax(88px, 1fr)); gap: 8px; }
  .db-tabs button { padding: 9px 12px; font-size: 12px; }
  .db-tabpane { padding: 14px 10px; }
}
@media (max-width: 520px) { .db-assoc-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
