@import url("https://fonts.googleapis.com/css2?family=Nunito:wght@500;700;800&family=ZCOOL+XiaoWei&display=swap");

:root {
  --sky: #e8f6f4;
  --mist: #f4fbfa;
  --ink: #1f3b3a;
  --soft: #5f7d7b;
  --teal: #2aa89a;
  --teal-deep: #1d7f74;
  --peach: #ff8a65;
  --peach-deep: #ef6c4d;
  --card: #ffffff;
  --line: rgba(42, 168, 154, .14);
  --shadow: 0 14px 28px rgba(31, 59, 58, .08);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: "Nunito", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(900px 480px at 8% -8%, rgba(255, 138, 101, .18), transparent 55%),
    radial-gradient(760px 420px at 100% 0%, rgba(42, 168, 154, .16), transparent 50%),
    linear-gradient(180deg, #f7fcfb 0%, var(--sky) 48%, #dff3ef 100%);
  min-height: 100vh;
}
a { color: var(--teal-deep); text-decoration: none; }
a:hover { color: var(--peach-deep); }
img { max-width: 100%; }
.pitch { width: min(1180px, calc(100% - 32px)); margin: 0 auto; }
.pitch-lines {
  pointer-events: none;
  position: fixed;
  inset: 0;
  background:
    radial-gradient(circle at 20% 30%, rgba(255,255,255,.55) 0 2px, transparent 3px),
    radial-gradient(circle at 80% 70%, rgba(255,255,255,.4) 0 2px, transparent 3px);
  background-size: 48px 48px;
  opacity: .55;
  z-index: 0;
}
.topbar, .endbar, main { position: relative; z-index: 1; }
.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(12px);
  background: rgba(255, 255, 255, .82);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 8px 24px rgba(31, 59, 58, .05);
}
.header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 72px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-family: "ZCOOL XiaoWei", "Nunito", serif;
  font-weight: 700;
  letter-spacing: .02em;
  font-size: 24px;
}
.brand img {
  border-radius: 16px;
  box-shadow: 0 8px 16px rgba(42, 168, 154, .25);
}
.menu-btn {
  display: none;
  border: 0;
  background: var(--teal);
  color: #fff;
  border-radius: 999px;
  padding: 8px 14px;
  font-weight: 700;
}
.nav { display: flex; align-items: center; gap: 4px; }
.nav-drop { position: relative; }
.nav-drop > a {
  display: block;
  color: var(--ink);
  padding: 10px 14px;
  border-radius: 999px;
  font-weight: 700;
}
.nav-drop > a.current, .nav-drop > a:hover {
  background: rgba(42, 168, 154, .12);
  color: var(--teal-deep);
}
.nav-sub {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 168px;
  background: #fff;
  border-radius: 18px;
  padding: 8px;
  box-shadow: var(--shadow);
}
.nav-sub a { display: block; color: var(--ink); padding: 8px 10px; border-radius: 12px; }
.nav-sub a.current, .nav-sub a:hover { background: #e7f7f4; color: var(--teal-deep); }
.nav-drop:hover .nav-sub, .nav-drop:focus-within .nav-sub { display: block; }

.hero {
  margin: 28px 0 22px;
  padding: 38px 34px;
  border-radius: 32px;
  background:
    linear-gradient(135deg, rgba(42,168,154,.92), rgba(38,120,170,.78) 55%, rgba(255,138,101,.82)),
    radial-gradient(circle at 85% 20%, rgba(255,255,255,.28), transparent 35%);
  color: #fff;
  box-shadow: var(--shadow);
  overflow: hidden;
}
.hero-kicker {
  margin: 0 0 8px;
  color: rgba(255,255,255,.85);
  letter-spacing: .18em;
  font-size: 12px;
  font-weight: 800;
}
.hero-title {
  margin: 0;
  font-family: "ZCOOL XiaoWei", "Nunito", serif;
  font-size: clamp(36px, 6vw, 64px);
  line-height: 1.05;
}
.hero-sub { max-width: 720px; line-height: 1.75; color: rgba(255,255,255,.92); }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; margin: 18px 0 8px; }
.go {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #fff;
  color: var(--teal-deep);
  font-weight: 800;
  border-radius: 999px;
  padding: 11px 18px;
  box-shadow: 0 10px 18px rgba(0,0,0,.12);
}
.go:hover { color: var(--peach-deep); transform: translateY(-1px); }
.go.ghost {
  background: transparent;
  color: #fff;
  box-shadow: inset 0 0 0 2px rgba(255,255,255,.85);
}
.stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 22px 0 0;
}
.stats div {
  background: rgba(255,255,255,.16);
  border-radius: 18px;
  padding: 12px 14px;
}
.stats dt { margin: 0; font-size: 12px; color: rgba(255,255,255,.85); }
.stats dd { margin: 4px 0 0; font-size: 28px; font-weight: 800; color: #fff; }

.league-row {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}
.league-chip {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  background: var(--card);
  border-radius: 22px;
  padding: 14px 8px;
  box-shadow: var(--shadow);
  color: var(--ink);
  font-weight: 800;
}
.league-chip img {
  width: 48px;
  height: 48px;
  object-fit: contain;
}
.league-chip:hover { transform: translateY(-2px); }

.cols, .split { display: grid; grid-template-columns: 1.2fr .8fr; gap: 18px; }
.panel, .story, .faq, .about, .day {
  background: rgba(255,255,255,.78);
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 18px;
  margin-bottom: 18px;
  box-shadow: var(--shadow);
}
.panel-head, .end-box { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.panel-head h2, .headline, .story h1, .faq h2, .about h2 { margin: 0 0 12px; font-family: "ZCOOL XiaoWei", "Nunito", serif; }
.headline { font-size: 30px; }
.lead, .extra, .tiny, .crumb { color: var(--soft); }
.crumb { font-size: 13px; }
.board { display: grid; gap: 12px; }
.ticket {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  grid-template-areas: "home center away" "when when when" "lanes lanes lanes";
  gap: 8px 12px;
  background: var(--card);
  color: var(--ink);
  border-radius: 20px;
  padding: 14px;
  box-shadow: 0 10px 0 rgba(42, 168, 154, .08);
  border: 1px solid rgba(42,168,154,.1);
  position: relative;
}
.side { display: flex; align-items: center; gap: 8px; }
.side.home { grid-area: home; }
.side.away { grid-area: away; justify-content: flex-end; text-align: right; }
.side a { color: var(--ink); font-weight: 800; }
.side img {
  width: 42px;
  height: 42px;
  object-fit: contain;
  background: #f0faf8;
  border-radius: 50%;
  padding: 4px;
}
.center { grid-area: center; text-align: center; }
.score { display: block; font-size: 24px; letter-spacing: .04em; }
.tag {
  display: inline-block;
  margin-top: 4px;
  font-size: 12px;
  border-radius: 999px;
  padding: 2px 8px;
  font-weight: 700;
}
.tag-live { background: var(--peach); color: #fff; }
.tag-upcoming { background: #e7f7f4; color: var(--teal-deep); }
.tag-done { background: #eef2f1; color: #667; }
.when {
  grid-area: when;
  margin: 0;
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
  font-size: 13px;
  color: var(--soft);
}
.when em {
  font-style: normal;
  background: #fff1eb;
  color: var(--peach-deep);
  border-radius: 999px;
  padding: 1px 8px;
}
.lanes { grid-area: lanes; display: flex; gap: 8px; }
.lanes a {
  flex: 1;
  text-align: center;
  background: var(--teal);
  color: #fff;
  border-radius: 999px;
  padding: 7px 0;
  font-size: 13px;
  font-weight: 800;
}
.lanes a:hover { background: var(--teal-deep); color: #fff; }
.note-grid, .clip-grid { display: grid; gap: 12px; }
.note, .clip {
  display: grid;
  grid-template-columns: 88px 1fr;
  gap: 12px;
  background: var(--card);
  color: var(--ink);
  border-radius: 18px;
  padding: 10px;
  border: 1px solid rgba(42,168,154,.08);
}
.note img, .clip img {
  width: 88px;
  height: 62px;
  object-fit: contain;
  background: #f0faf8;
  border-radius: 12px;
}
.note h3, .clip h3 { margin: 0 0 6px; font-size: 16px; }
.note a, .clip a { color: var(--ink); }
.faq details {
  background: #f3fbf9;
  border-radius: 14px;
  padding: 10px 14px;
  margin-bottom: 8px;
}
.faq summary { cursor: pointer; font-weight: 800; }
.about p, .story p, .body p { line-height: 1.8; }
.meta-list { padding-left: 18px; color: var(--soft); }
.related { padding-left: 18px; }
.turn { display: flex; justify-content: space-between; gap: 12px; margin-top: 16px; flex-wrap: wrap; }
.endbar {
  margin-top: 24px;
  background: #1f3b3a;
  color: #dceae8;
  padding: 28px 0;
  border-top: 6px solid var(--peach);
}
.end-box { display: block; }
.friends { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
.friends span { color: #9ab5b2; }
.friends a { color: #e8f6f4; }
.blank { color: var(--soft); }
.side a, .note h3 a, .clip h3 a {
  overflow-wrap: anywhere;
  word-break: break-word;
}

@media (max-width: 900px) {
  .pitch {
    width: min(1180px, calc(100% - 24px));
  }
  .header-row {
    min-height: 60px;
    position: relative;
  }
  .brand {
    font-size: 20px;
    min-width: 0;
  }
  .brand span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: min(46vw, 180px);
  }
  .brand img {
    width: 36px;
    height: 36px;
    flex-shrink: 0;
  }
  .menu-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    min-width: 64px;
    padding: 8px 16px;
    -webkit-tap-highlight-color: transparent;
  }
  .nav {
    display: none;
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    background: #fff;
    padding: 10px;
    border-radius: 18px;
    width: min(300px, calc(100vw - 24px));
    max-height: min(70vh, 520px);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    box-shadow: var(--shadow);
    border: 1px solid var(--line);
    z-index: 30;
  }
  .nav.open { display: flex; }
  .nav-drop > a {
    padding: 12px 14px;
    min-height: 44px;
  }
  .nav-drop:has(.nav-sub) > a::after {
    content: "";
    float: right;
    width: 8px;
    height: 8px;
    margin-top: 6px;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(45deg);
    opacity: .55;
  }
  .nav-drop.open:has(.nav-sub) > a::after {
    transform: rotate(-135deg);
    margin-top: 10px;
  }
  .nav-drop:hover .nav-sub,
  .nav-drop:focus-within .nav-sub {
    display: none;
  }
  .nav-sub {
    position: static;
    display: none;
    min-width: 0;
    margin: 0 0 4px;
    background: #f3fbf9;
    box-shadow: none;
  }
  .nav-drop.open > .nav-sub { display: block; }
  .nav-sub a {
    padding: 11px 12px;
    min-height: 42px;
  }

  .hero {
    margin: 16px 0 14px;
    padding: 22px 18px;
    border-radius: 24px;
  }
  .hero-title {
    font-size: clamp(30px, 9vw, 44px);
  }
  .hero-sub {
    font-size: 14px;
    line-height: 1.65;
  }
  .hero-actions {
    margin-top: 14px;
  }
  .go {
    min-height: 42px;
    padding: 10px 16px;
  }
  .stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    margin-top: 16px;
  }
  .stats div { padding: 10px 8px; border-radius: 14px; }
  .stats dt { font-size: 11px; }
  .stats dd { font-size: 22px; }

  .league-row {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    margin-bottom: 14px;
  }
  .league-chip {
    padding: 12px 6px;
    border-radius: 16px;
    font-size: 13px;
    gap: 6px;
  }
  .league-chip img {
    width: 40px;
    height: 40px;
  }

  .cols,
  .split {
    grid-template-columns: 1fr;
    gap: 12px;
  }
  .panel,
  .story,
  .faq,
  .about,
  .day {
    padding: 14px;
    border-radius: 18px;
    margin-bottom: 12px;
  }
  .panel-head {
    align-items: flex-start;
    gap: 8px;
  }
  .panel-head h2,
  .headline,
  .story h1,
  .faq h2,
  .about h2 {
    font-size: 22px;
    line-height: 1.25;
  }
  .headline { font-size: 24px; }

  .ticket {
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    grid-template-areas: "home center away" "when when when" "lanes lanes lanes";
    gap: 6px 8px;
    padding: 12px;
    border-radius: 16px;
  }
  .side {
    min-width: 0;
    gap: 6px;
  }
  .side img {
    width: 34px;
    height: 34px;
    flex-shrink: 0;
  }
  .side a {
    font-size: 13px;
    line-height: 1.25;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }
  .score { font-size: 20px; }
  .tag { font-size: 11px; }
  .when { font-size: 12px; gap: 6px; }
  .lanes { gap: 6px; }
  .lanes a {
    min-height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 0;
    font-size: 12px;
  }

  .note,
  .clip {
    grid-template-columns: 72px 1fr;
    gap: 10px;
    padding: 10px;
  }
  .note img,
  .clip img {
    width: 72px;
    height: 54px;
  }
  .note h3,
  .clip h3 {
    font-size: 15px;
    line-height: 1.35;
  }

  .meta-list,
  .related {
    padding-left: 16px;
    font-size: 14px;
  }
  .turn {
    flex-direction: column;
  }
  .turn a {
    display: block;
    padding: 10px 0;
    min-height: 44px;
  }
  .endbar {
    padding: 22px 0 calc(22px + env(safe-area-inset-bottom, 0px));
  }
  .friends {
    gap: 10px 14px;
  }
}

@media (max-width: 560px) {
  .pitch {
    width: calc(100% - 16px);
  }
  .topbar {
    padding-left: env(safe-area-inset-left, 0px);
    padding-right: env(safe-area-inset-right, 0px);
  }
  .hero {
    margin: 12px 0;
    padding: 18px 14px;
    border-radius: 20px;
  }
  .hero-kicker {
    letter-spacing: .12em;
    font-size: 11px;
  }
  .hero-actions {
    flex-direction: column;
  }
  .hero-actions .go {
    width: 100%;
    justify-content: center;
  }
  .stats dd { font-size: 20px; }
  .league-row {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 6px;
  }
  .league-chip {
    font-size: 12px;
    padding: 10px 4px;
  }
  .league-chip img {
    width: 34px;
    height: 34px;
  }
  .side a {
    font-size: 12px;
  }
  .side img {
    width: 30px;
    height: 30px;
  }
  .score { font-size: 18px; }
  .lanes a {
    border-radius: 12px;
    font-size: 12px;
  }
  .note,
  .clip {
    grid-template-columns: 1fr;
  }
  .note img,
  .clip img {
    width: 100%;
    height: 84px;
  }
  .panel-head h2,
  .headline {
    font-size: 20px;
  }
}

@media (max-width: 380px) {
  .brand span { max-width: 38vw; }
  .stats {
    gap: 6px;
  }
  .stats div { padding: 8px 6px; }
  .stats dd { font-size: 18px; }
  .league-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (hover: none) and (pointer: coarse) {
  .go:hover,
  .league-chip:hover {
    transform: none;
  }
  a:hover { color: var(--teal-deep); }
  .friends a:hover { color: #e8f6f4; }
}
