/* ===== 2026湘超联赛 - 共享样式 ===== */
:root {
  --primary: #0d5c2e;
  --primary-light: #178a45;
  --accent: #f7b500;
  --accent-light: #ffd84d;
  --bg: #f0f5f1;
  --card-bg: #ffffff;
  --text: #1a1a2e;
  --text-muted: #6b7280;
  --border: #e2e8f0;
  --win: #dc2626;
  --draw: #6b7280;
  --lose: #16a34a;
  --shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
  --radius: 12px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
}

/* ===== 导航栏 ===== */
.navbar {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  padding: 0 24px;
  box-shadow: 0 2px 16px rgba(13, 92, 46, 0.3);
  position: sticky;
  top: 0;
  z-index: 100;
}

.navbar-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.navbar-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #fff;
  font-size: 20px;
  font-weight: 700;
  text-decoration: none;
}

.navbar-logo .ball {
  font-size: 28px;
}

.navbar-links {
  display: flex;
  gap: 4px;
  list-style: none;
}

.navbar-links a {
  color: rgba(255, 255, 255, 0.85);
  text-decoration: none;
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 500;
  transition: all 0.2s;
}

.navbar-links a:hover {
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
}

.navbar-links a.active {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
}

/* 汉堡菜单按钮（仅移动端显示） */
.hamburger {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  flex-direction: column;
  gap: 5px;
  z-index: 101;
}

.hamburger span {
  display: block;
  width: 26px;
  height: 3px;
  background: #fff;
  border-radius: 2px;
  transition: all 0.3s ease;
}

.hamburger.active span:nth-child(1) {
  transform: translateY(8px) rotate(45deg);
}

.hamburger.active span:nth-child(2) {
  opacity: 0;
}

.hamburger.active span:nth-child(3) {
  transform: translateY(-8px) rotate(-45deg);
}

/* ===== 容器 ===== */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 32px 24px;
}

.page-header {
  text-align: center;
  margin-bottom: 36px;
}

.page-header h1 {
  font-size: 32px;
  color: var(--primary);
  margin-bottom: 8px;
}

.page-header .subtitle {
  font-size: 15px;
  color: var(--text-muted);
}

/* ===== 卡片 ===== */
.card {
  background: var(--card-bg);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 24px;
  margin-bottom: 24px;
}

.card-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 3px solid var(--accent);
  display: inline-block;
}

/* ===== 表格 ===== */
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

table th {
  background: var(--primary);
  color: #fff;
  padding: 12px 8px;
  text-align: center;
  font-weight: 600;
  white-space: nowrap;
}

table th:first-child {
  border-top-left-radius: 8px;
}

table th:last-child {
  border-top-right-radius: 8px;
}

table td {
  padding: 10px 8px;
  text-align: center;
  border-bottom: 1px solid var(--border);
}

table tbody tr:hover {
  background: #f7fdf9;
}

table tbody tr:nth-child(even) {
  background: #fafdfa;
}

table tbody tr:nth-child(even):hover {
  background: #f0f9f3;
}

/* 积分榜特殊样式 */
.standings-table td:nth-child(1) {
  font-weight: 700;
  font-size: 16px;
  width: 50px;
}

.standings-table .team-name {
  text-align: left;
  padding-left: 12px;
  font-weight: 600;
}

.standings-table .points {
  font-weight: 700;
  font-size: 18px;
  color: var(--primary);
}

.standings-table .win { color: var(--win); font-weight: 600; }
.standings-table .draw { color: var(--draw); }
.standings-table .lose { color: var(--lose); font-weight: 600; }

.standings-table tr.top-8 td {
  background: #fffbeb;
}

.standings-table tr.top-8 td:nth-child(1) {
  color: var(--accent);
}

.standings-table tr.bottom td {
  color: var(--text-muted);
}

/* ===== 赛程卡片 ===== */
.round-section {
  margin-bottom: 32px;
}

.round-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.round-badge {
  background: var(--primary);
  color: #fff;
  padding: 6px 16px;
  border-radius: 20px;
  font-size: 15px;
  font-weight: 700;
}

.round-date {
  color: var(--text-muted);
  font-size: 14px;
}

.round-status {
  margin-left: auto;
  font-size: 13px;
  padding: 4px 12px;
  border-radius: 12px;
  font-weight: 600;
}

.round-status.done { background: #dcfce7; color: #16a34a; }
.round-status.upcoming { background: #fef3c7; color: #d97706; }
.round-status.future { background: #e0e7ff; color: #4f46e5; }

.match-row {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
  transition: background 0.2s;
}

.match-row:hover {
  background: #f7fdf9;
}

.match-team {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 15px;
  font-weight: 600;
}

.match-team.home {
  justify-content: flex-end;
}

.match-team.away {
  justify-content: flex-start;
}

.match-team-icon {
  font-size: 24px;
}

.match-score {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 18px;
  font-weight: 700;
  min-width: 80px;
  justify-content: center;
}

.match-score .vs {
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 400;
}

.match-score .score-num {
  background: var(--primary);
  color: #fff;
  padding: 2px 10px;
  border-radius: 6px;
}

.match-score .score-num.win {
  background: var(--win);
}

.match-score .score-num.lose {
  background: var(--lose);
}

.match-info {
  text-align: center;
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 4px;
}

/* ===== 射手榜 ===== */
.scorer-row {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
  transition: background 0.2s;
}

.scorer-row:hover {
  background: #f7fdf9;
}

.scorer-rank {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 16px;
  flex-shrink: 0;
}

.scorer-rank.gold { background: linear-gradient(135deg, #f7b500, #ffd84d); color: #fff; }
.scorer-rank.silver { background: linear-gradient(135deg, #9ca3af, #d1d5db); color: #fff; }
.scorer-rank.bronze { background: linear-gradient(135deg, #b45309, #d97706); color: #fff; }
.scorer-rank.normal { background: #e0e7ff; color: #4f46e5; }

.scorer-info {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 12px;
}

.scorer-name {
  font-size: 16px;
  font-weight: 600;
}

.scorer-team {
  font-size: 13px;
  color: var(--text-muted);
  background: #f0f5f1;
  padding: 2px 10px;
  border-radius: 10px;
}

.scorer-goals {
  font-size: 22px;
  font-weight: 800;
  color: var(--primary);
  min-width: 50px;
  text-align: right;
}

.scorer-goals .unit {
  font-size: 13px;
  font-weight: 400;
  color: var(--text-muted);
}

/* ===== 比赛结果详情 ===== */
.result-card {
  background: var(--card-bg);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  margin-bottom: 20px;
  overflow: hidden;
}

.result-card-header {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  color: #fff;
  padding: 12px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 14px;
}

.result-card-body {
  padding: 24px;
}

.result-match {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 20px;
  margin-bottom: 20px;
}

.result-team {
  text-align: center;
}

.result-team .team-icon {
  font-size: 40px;
  margin-bottom: 8px;
}

.result-team .team-name {
  font-size: 18px;
  font-weight: 700;
}

.result-score {
  font-size: 36px;
  font-weight: 800;
  color: var(--primary);
}

.result-score .separator {
  color: var(--text-muted);
  margin: 0 8px;
}

.goal-list {
  background: #f9fafb;
  border-radius: 8px;
  padding: 16px;
  margin-top: 16px;
}

.goal-list-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.goal-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 0;
  font-size: 14px;
  border-bottom: 1px solid #f0f0f0;
}

.goal-item:last-child {
  border-bottom: none;
}

.goal-item .goal-icon {
  font-size: 16px;
}

.goal-item .goal-min {
  font-weight: 700;
  color: var(--primary);
  min-width: 45px;
}

.goal-item .goal-scorer {
  font-weight: 600;
}

.goal-item .goal-team {
  font-size: 12px;
  color: var(--text-muted);
  margin-left: auto;
}

.goal-item.own-goal .goal-icon {
  color: var(--lose);
}

/* ===== 首页特殊样式 ===== */
.hero {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 50%, #1a8f4a 100%);
  border-radius: 20px;
  padding: 48px 40px;
  color: #fff;
  text-align: center;
  margin-bottom: 32px;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  top: -50%;
  right: -20%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
  border-radius: 50%;
}

.hero h1 {
  font-size: 40px;
  margin-bottom: 12px;
  position: relative;
}

.hero .hero-sub {
  font-size: 18px;
  opacity: 0.9;
  margin-bottom: 24px;
  position: relative;
}

.hero .hero-info {
  display: flex;
  justify-content: center;
  gap: 32px;
  flex-wrap: wrap;
  position: relative;
}

.hero-info-item {
  text-align: center;
}

.hero-info-item .num {
  font-size: 32px;
  font-weight: 800;
  color: var(--accent-light);
}

.hero-info-item .label {
  font-size: 13px;
  opacity: 0.85;
}

.quick-nav {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  margin-bottom: 32px;
}

.quick-nav-card {
  background: var(--card-bg);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 28px 24px;
  text-decoration: none;
  color: var(--text);
  transition: transform 0.2s, box-shadow 0.2s;
  display: block;
  border-left: 4px solid var(--primary);
}

.quick-nav-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.quick-nav-card .icon {
  font-size: 36px;
  margin-bottom: 12px;
}

.quick-nav-card .title {
  font-size: 18px;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 6px;
}

.quick-nav-card .desc {
  font-size: 14px;
  color: var(--text-muted);
}

/* ===== 统计卡片 ===== */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 32px;
}

.stat-card {
  background: var(--card-bg);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 20px;
  text-align: center;
}

.stat-card .stat-value {
  font-size: 28px;
  font-weight: 800;
  color: var(--primary);
}

.stat-card .stat-label {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 4px;
}

/* ===== 页脚 ===== */
.footer {
  text-align: center;
  padding: 32px 24px;
  color: var(--text-muted);
  font-size: 13px;
  border-top: 1px solid var(--border);
  margin-top: 40px;
}

.footer a {
  color: var(--primary);
  text-decoration: none;
}

/* ===== 球队LOGO ===== */
.team-logo {
  display: inline-block;
  vertical-align: middle;
  border-radius: 50%;
  object-fit: cover;
  background: #fff;
}

.team-logo-sm {
  width: 28px;
  height: 28px;
}

.team-logo-md {
  width: 36px;
  height: 36px;
}

.team-logo-lg {
  width: 56px;
  height: 56px;
}

/* 赛程页 - 对阵双方LOGO */
.match-team .team-logo-sm {
  flex-shrink: 0;
}

/* 积分榜表格 - 队名前LOGO */
.standings-table .team-logo-sm {
  margin-right: 8px;
}

/* 比赛结果页 - 大LOGO */
.result-team .team-logo-lg {
  margin-bottom: 8px;
}

/* 首页 - 参赛队伍卡片LOGO */
.team-card-logo {
  width: 48px;
  height: 48px;
  margin: 0 auto 8px;
  display: block;
  border-radius: 50%;
  object-fit: cover;
  background: #fff;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

/* 射手榜 - 球队进球榜LOGO */
table .team-logo-sm {
  vertical-align: middle;
  margin-right: 6px;
}

/* ===== 响应式 - 手机端适配 ===== */
@media (max-width: 768px) {
  /* 汉堡菜单按钮显示 */
  .hamburger {
    display: flex;
  }

  /* 导航菜单 - 默认隐藏，点击展开 */
  .navbar-links {
    display: none;
    flex-direction: column;
    position: fixed;
    top: 64px;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    padding: 12px 16px 20px;
    gap: 2px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
    z-index: 99;
    max-height: calc(100vh - 64px);
    overflow-y: auto;
  }

  .navbar-links.show {
    display: flex;
  }

  .navbar-links li {
    width: 100%;
  }

  .navbar-links a {
    display: block;
    padding: 14px 16px;
    font-size: 16px;
    border-radius: 10px;
    text-align: center;
  }

  /* 导航栏Logo缩小 */
  .navbar-logo {
    font-size: 17px;
  }

  .navbar-logo .ball {
    font-size: 24px;
  }

  .navbar {
    padding: 0 16px;
  }

  .navbar-inner {
    height: 56px;
  }

  .navbar-links {
    top: 56px;
  }

  /* 容器 */
  .container {
    padding: 16px 12px;
  }

  /* 页面标题 */
  .page-header {
    margin-bottom: 24px;
  }

  .page-header h1 {
    font-size: 22px;
  }

  .page-header .subtitle {
    font-size: 13px;
  }

  /* Hero区域 */
  .hero {
    padding: 28px 18px;
    border-radius: 14px;
  }

  .hero h1 {
    font-size: 24px;
  }

  .hero .hero-sub {
    font-size: 14px;
  }

  .hero-info {
    gap: 12px;
  }

  .hero-info-item .num {
    font-size: 24px;
  }

  .hero-info-item .label {
    font-size: 11px;
  }

  /* 卡片 */
  .card {
    padding: 16px 14px;
    margin-bottom: 16px;
    border-radius: 10px;
  }

  .card-title {
    font-size: 17px;
  }

  /* 统计卡片 */
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }

  .stat-card {
    padding: 14px 8px;
  }

  .stat-card .stat-value {
    font-size: 20px;
  }

  .stat-card .stat-label {
    font-size: 11px;
  }

  /* 快捷导航卡片 */
  .quick-nav {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .quick-nav-card {
    padding: 20px 16px;
  }

  .quick-nav-card .icon {
    font-size: 30px;
  }

  .quick-nav-card .title {
    font-size: 16px;
  }

  /* 表格 - 可横向滚动 */
  table {
    font-size: 12px;
  }

  table th {
    padding: 8px 4px;
    font-size: 12px;
  }

  table td {
    padding: 8px 4px;
    font-size: 12px;
  }

  /* 积分榜表格 */
  .standings-table td:nth-child(1) {
    font-size: 14px;
    width: 32px;
  }

  .standings-table .points {
    font-size: 15px;
  }

  .standings-table .team-logo-sm {
    width: 22px;
    height: 22px;
    margin-right: 4px;
  }

  /* 参赛队伍网格 */
  .card > div[style*="grid-template-columns: repeat(auto-fit"] {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 8px !important;
  }

  .team-card-logo {
    width: 40px;
    height: 40px;
  }

  /* 赛程 - 对阵行 */
  .match-row {
    grid-template-columns: 1fr;
    gap: 6px;
    padding: 10px 12px;
    text-align: center;
  }

  .match-team.home,
  .match-team.away {
    justify-content: center;
  }

  .match-team {
    font-size: 14px;
    gap: 8px;
  }

  .match-team .team-logo-sm {
    width: 24px;
    height: 24px;
  }

  .match-score {
    font-size: 16px;
    min-width: 60px;
  }

  .match-info {
    font-size: 11px;
  }

  /* 轮次标签 */
  .round-header {
    flex-wrap: wrap;
    gap: 8px;
  }

  .round-badge {
    font-size: 13px;
    padding: 4px 12px;
  }

  .round-date {
    font-size: 12px;
  }

  .round-status {
    font-size: 11px;
    padding: 3px 8px;
  }

  /* 比赛结果卡片 */
  .result-card-body {
    padding: 16px 12px;
  }

  .result-match {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .result-team .team-logo-lg {
    width: 44px;
    height: 44px;
  }

  .result-team .team-name {
    font-size: 15px;
  }

  .result-score {
    font-size: 28px;
  }

  .result-card-header {
    padding: 10px 14px;
    font-size: 12px;
    flex-wrap: wrap;
    gap: 4px;
  }

  /* 进球记录 */
  .goal-list {
    padding: 12px 10px;
  }

  .goal-item {
    font-size: 13px;
    gap: 6px;
    flex-wrap: wrap;
  }

  .goal-item .goal-min {
    min-width: 38px;
    font-size: 13px;
  }

  /* 射手榜 */
  .scorer-row {
    gap: 10px;
    padding: 10px 12px;
  }

  .scorer-rank {
    width: 32px;
    height: 32px;
    font-size: 14px;
  }

  .scorer-info {
    gap: 8px;
    flex-wrap: wrap;
  }

  .scorer-name {
    font-size: 15px;
  }

  .scorer-team {
    font-size: 12px;
    padding: 2px 8px;
  }

  .scorer-team .team-logo-sm {
    width: 18px;
    height: 18px;
  }

  .scorer-goals {
    font-size: 18px;
    min-width: 40px;
  }

  /* TOP 3 射手卡片 */
  .card > div[style*="grid-template-columns: repeat(auto-fit, minmax(200px"] {
    grid-template-columns: 1fr !important;
    gap: 12px !important;
  }

  /* 帽子戏法记录网格 */
  .card > div[style*="grid-template-columns: repeat(auto-fit, minmax(280px"] {
    grid-template-columns: 1fr !important;
    gap: 12px !important;
  }

  /* 页脚 */
  .footer {
    padding: 20px 16px;
    font-size: 11px;
  }

  .footer p {
    line-height: 1.5;
  }
}

/* 超小屏幕（<380px）额外优化 */
@media (max-width: 380px) {
  .stats-grid {
    grid-template-columns: 1fr;
  }

  .hero h1 {
    font-size: 20px;
  }

  .hero-info {
    gap: 8px;
  }

  .hero-info-item .num {
    font-size: 20px;
  }

  .navbar-logo span:last-child {
    font-size: 15px;
  }
}
