/* ========================================
   Site Kit — 球友会官网 China基地
   共享样式 /assets/site.css
   ======================================== */

/* ---------- 设计令牌 ---------- */
:root {
  --orange:       #FF6B00;
  --deep-blue:    #0A1E3F;
  --yellow:       #FFC400;
  --light-orange: #FFE0B2;
  --light-gray:   #F5F7FA;
  --dark:         #1D1D1F;
  --gray:         #6E7681;
  --white:        #FFFFFF;
  --deep-orange:  #E65100;
  --tech-blue:    #00A8E8;

  --font-body:   "PingFang SC", "Source Han Sans SC", "Microsoft YaHei", "Noto Sans CJK SC", system-ui, sans-serif;
  --font-title:  "PingFang SC", "Source Han Sans SC", "Microsoft YaHei", "Noto Sans CJK SC", system-ui, sans-serif;
  --font-index:  "SF Mono", "Roboto Mono", "Cascadia Mono", "Liberation Mono", "Consolas", monospace;

  --container-w: 1440px;
  --ease-out:    cubic-bezier(0.22, 1, 0.36, 1);
  --shadow-sm:   0 2px 12px rgba(10, 30, 63, 0.08);
  --shadow-md:   0 8px 28px rgba(10, 30, 63, 0.12);
  --shadow-lg:   0 18px 44px rgba(10, 30, 63, 0.16);
}

/* ---------- 重置与基础 ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.75;
  color: var(--dark);
  background: var(--light-gray);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  display: block;
  height: auto;
}

a {
  color: var(--tech-blue);
  text-decoration: none;
}

ul,
ol {
  list-style: none;
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-title);
  font-weight: 900;
  line-height: 1.25;
  color: var(--deep-blue);
}

:focus-visible {
  outline: 3px solid var(--yellow);
  outline-offset: 2px;
}

/* ---------- 通用容器与区块 ---------- */
.container {
  width: calc(100% - 64px);
  max-width: var(--container-w);
  margin-inline: auto;
}

.section {
  padding: 72px 0;
}

.section--tight {
  padding: 40px 0;
}

.section--tint {
  background: var(--light-orange);
}

.section--dark {
  background: var(--deep-blue);
  color: rgba(255, 255, 255, 0.78);
}

/* ---------- 索引与标签 ---------- */
.index-label {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-index);
  font-size: 13px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gray);
}

.index-label::before {
  content: "";
  width: 28px;
  height: 2px;
  background: var(--orange);
  flex: 0 0 28px;
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: var(--yellow);
  color: var(--deep-blue);
  font-family: var(--font-index);
  font-size: 12px;
  font-weight: 700;
  padding: 4px 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  line-height: 1.4;
}

/* ---------- 面包屑 ---------- */
.breadcrumb {
  max-width: var(--container-w);
  margin-inline: auto;
  width: calc(100% - 64px);
  padding: 28px 0 0;
  font-family: var(--font-index);
  font-size: 13px;
  color: var(--gray);
}

.breadcrumb a {
  color: var(--tech-blue);
  text-decoration: none;
  transition: color 0.2s;
}

.breadcrumb a:hover {
  color: var(--deep-orange);
}

.breadcrumb__sep {
  display: inline-block;
  margin: 0 10px;
  color: var(--gray);
}

/* ---------- 按钮 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-body);
  font-weight: 900;
  font-size: 15px;
  line-height: 1;
  padding: 13px 28px;
  background: var(--orange);
  color: var(--deep-blue);
  border: 0;
  cursor: pointer;
  text-decoration: none;
  position: relative;
  transition: background 0.25s ease, transform 0.25s var(--ease-out), box-shadow 0.25s ease;
}

.btn:hover {
  background: var(--deep-orange);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 12px 24px rgba(230, 81, 0, 0.24);
}

.btn:active {
  transform: translateY(0);
}

.btn--yellow {
  background: var(--yellow);
  color: var(--deep-blue);
}

.btn--yellow:hover {
  background: #FFD600;
  color: var(--deep-blue);
  box-shadow: 0 12px 24px rgba(255, 196, 0, 0.28);
}

.btn--ghost {
  background: transparent;
  border: 2px solid var(--deep-blue);
  color: var(--deep-blue);
  padding: 11px 26px;
}

.btn--ghost:hover {
  background: var(--deep-blue);
  color: #fff;
  box-shadow: none;
  transform: none;
}

.btn--sm {
  padding: 9px 18px;
  font-size: 13px;
}

/* ---------- 切角面板 ---------- */
.panel {
  position: relative;
  background: var(--white);
  box-shadow: var(--shadow-sm);
  padding: 32px;
}

.panel::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: 0;
  width: 28px;
  height: 28px;
  background: var(--yellow);
  clip-path: polygon(100% 100%, 0 100%, 100% 0);
  pointer-events: none;
}

/* ---------- 网格 ---------- */
.grid {
  display: grid;
  gap: 28px;
}

.grid--2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.grid--3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

/* ---------- 非对称编辑部布局 ---------- */
.layout-editorial {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: clamp(24px, 5vw, 64px);
  max-width: var(--container-w);
  margin-inline: auto;
  padding: 48px 32px 72px;
}

.layout-editorial__aside {
  border-left: 3px solid var(--orange);
  padding-left: 18px;
  font-family: var(--font-index);
  font-size: 14px;
  color: var(--gray);
}

.layout-editorial__content {
  min-width: 0;
}

/* ---------- 首屏与分屏 ---------- */
.hero {
  max-width: var(--container-w);
  margin-inline: auto;
  padding: 64px 32px 56px;
}

.hero__title {
  font-size: clamp(48px, 7vw, 96px);
  font-weight: 900;
  line-height: 1.05;
  letter-spacing: -0.02em;
  color: var(--deep-blue);
  margin-bottom: 16px;
}

.hero__title .accent {
  color: var(--orange);
}

.hero__lede {
  font-size: 18px;
  color: var(--gray);
  max-width: 36em;
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(32px, 6vw, 80px);
  align-items: center;
}

.split__art {
  position: relative;
  min-height: 320px;
  background: var(--light-orange);
  clip-path: polygon(0 0, 100% 0, 100% 84%, 84% 100%, 0 100%);
}

/* ---------- 跳转与焦点辅助 ---------- */
.skip-link {
  position: absolute;
  top: -120px;
  left: 16px;
  z-index: 2000;
  background: var(--yellow);
  color: var(--deep-blue);
  font-weight: 700;
  padding: 10px 20px;
  text-decoration: none;
  transition: top 0.3s var(--ease-out);
}

.skip-link:focus {
  top: 8px;
}

/* ========================================
   头部
   ======================================== */
.site-header {
  position: relative;
  background: var(--deep-blue);
  color: #fff;
  z-index: 100;
  font-family: var(--font-body);
}

.site-header::before {
  content: "";
  display: block;
  height: 6px;
  background: linear-gradient(90deg, var(--orange) 0%, var(--orange) 35%, var(--yellow) 35%, var(--yellow) 55%, rgba(255, 255, 255, 0.12) 55%);
}

.site-header::after {
  content: "";
  position: absolute;
  top: 0;
  right: 12%;
  width: 1px;
  height: 100%;
  background: linear-gradient(180deg, rgba(255, 107, 0, 0.7), rgba(255, 196, 0, 0) 70%);
  opacity: 0.35;
  pointer-events: none;
}

/* --- 顶部索引条 --- */
.header__meta {
  background: rgba(0, 0, 0, 0.2);
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  font-family: var(--font-index);
  font-size: 12px;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.6);
  position: relative;
  z-index: 1;
}

.header__meta-inner {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  column-gap: 28px;
  row-gap: 4px;
  padding-top: 8px;
  padding-bottom: 8px;
}

.header__meta-index {
  color: var(--yellow);
  font-weight: 700;
  text-transform: uppercase;
}

.header__meta-index::before {
  content: "";
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--orange);
  margin-right: 8px;
  vertical-align: baseline;
  animation: meta-pulse 2.2s infinite ease-in-out;
}

.header__meta-tag {
  color: rgba(255, 255, 255, 0.48);
}

.header__meta-version {
  margin-left: auto;
  color: rgba(255, 255, 255, 0.32);
  text-transform: uppercase;
}

@keyframes meta-pulse {
  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.4;
    transform: scale(0.8);
  }
}

/* --- 主头部 --- */
.header__main {
  position: relative;
  z-index: 2;
}

.header__main-inner {
  display: flex;
  align-items: center;
  padding-top: 16px;
  padding-bottom: 16px;
  position: relative;
}

.header__main::after {
  content: "";
  position: absolute;
  right: 14%;
  top: 50%;
  width: 90px;
  height: 3px;
  background: linear-gradient(90deg, var(--yellow) 0%, transparent 100%);
  transform: translateY(-50%) rotate(-18deg);
  opacity: 0.5;
  pointer-events: none;
}

/* --- 品牌 --- */
.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: #fff;
  text-decoration: none;
  flex-shrink: 0;
  transition: opacity 0.2s;
}

.brand:hover {
  opacity: 0.9;
}

.brand__mark {
  width: 46px;
  height: 46px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--orange);
  color: #fff;
  font-size: 23px;
  font-weight: 900;
  line-height: 1;
  clip-path: polygon(0 0, 100% 0, 100% 72%, 72% 100%, 0 100%);
}

.brand__text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.brand__text strong {
  font-size: 21px;
  font-weight: 900;
  letter-spacing: 0.02em;
  color: #fff;
}

.brand__text span {
  font-family: var(--font-index);
  font-size: 12px;
  letter-spacing: 0.16em;
  color: var(--yellow);
  margin-top: 2px;
}

/* --- 导航 --- */
.header__nav {
  margin-left: auto;
  display: flex;
  align-items: center;
}

.nav__list {
  display: flex;
  align-items: center;
}

.nav__item {
  position: relative;
}

.nav__link {
  display: block;
  padding: 10px 14px;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: rgba(255, 255, 255, 0.78);
  text-decoration: none;
  white-space: nowrap;
  transition: color 0.2s;
}

.nav__link::after {
  content: "";
  position: absolute;
  bottom: 4px;
  left: 14px;
  right: 14px;
  height: 3px;
  background: var(--orange);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s var(--ease-out);
}

.nav__link:hover,
.nav__link:focus-visible {
  color: #fff;
}

.nav__link:hover::after,
.nav__link:focus-visible::after,
.nav__link[aria-current="page"]::after {
  transform: scaleX(1);
}

.nav__link[aria-current="page"] {
  color: #fff;
  font-weight: 700;
}

/* --- 登录栏按钮 --- */
.btn--login {
  margin-left: 24px;
  flex: 0 0 auto;
  padding: 11px 20px 13px;
  font-size: 13px;
  background: var(--orange);
  color: var(--deep-blue);
  position: relative;
  transition: background 0.25s ease, color 0.25s ease;
}

.btn--login:hover {
  background: var(--deep-orange);
  color: #fff;
  box-shadow: none;
  transform: none;
}

.btn--login::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: 0;
  width: 18px;
  height: 18px;
  background: var(--deep-blue);
  clip-path: polygon(100% 100%, 0 100%, 100% 0);
  pointer-events: none;
}

/* --- 移动导航按钮 --- */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  margin-left: 12px;
  background: transparent;
  border: 0;
  cursor: pointer;
  border-radius: 0;
  z-index: 30;
}

.nav-toggle__line {
  display: block;
  width: 22px;
  height: 3px;
  background: #fff;
  transition: transform 0.3s var(--ease-out), opacity 0.2s;
}

.nav-toggle[aria-expanded="true"] .nav-toggle__line:nth-child(1) {
  transform: translateY(8px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] .nav-toggle__line:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] .nav-toggle__line:nth-child(3) {
  transform: translateY(-8px) rotate(-45deg);
}

/* ========================================
   页脚
   ======================================== */
.site-footer {
  background: var(--deep-blue);
  color: rgba(255, 255, 255, 0.75);
  position: relative;
  overflow: hidden;
}

.site-footer::before {
  content: "";
  display: block;
  height: 6px;
  background: linear-gradient(90deg, var(--orange) 0%, var(--orange) 30%, var(--yellow) 30%, var(--yellow) 46%, rgba(255, 255, 255, 0.1) 46%);
}

.site-footer::after {
  content: "";
  position: absolute;
  right: -100px;
  top: 10%;
  width: 280px;
  height: 280px;
  border: 2px dashed rgba(255, 196, 0, 0.18);
  border-radius: 50%;
  pointer-events: none;
}

.footer__main-inner {
  display: grid;
  grid-template-columns: 1.4fr 0.7fr 1.1fr;
  gap: 56px;
  padding-top: 64px;
  padding-bottom: 64px;
}

.footer__brand {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  max-width: 380px;
}

.brand__mark--footer {
  background: var(--yellow);
  color: var(--deep-blue);
  font-size: 28px;
  width: 56px;
  height: 56px;
}

.footer__brand-text {
  margin-top: 14px;
  display: flex;
  flex-direction: column;
}

.footer__brand-text strong {
  font-size: 22px;
  font-weight: 900;
  color: #fff;
}

.footer__brand-text span {
  font-family: var(--font-index);
  font-size: 12px;
  letter-spacing: 0.16em;
  color: var(--yellow);
  margin-top: 2px;
}

.footer__trust {
  margin-top: 14px;
  font-size: 13px;
  line-height: 1.8;
  color: rgba(255, 255, 255, 0.5);
}

.footer__links {
  display: flex;
  flex-direction: column;
}

.footer__title {
  font-family: var(--font-index);
  font-size: 13px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--yellow);
  margin-bottom: 18px;
  font-weight: 700;
}

.footer__link {
  display: block;
  padding: 5px 0;
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  font-size: 15px;
  transition: color 0.2s, padding-left 0.25s var(--ease-out);
}

.footer__link:hover {
  color: var(--orange);
  padding-left: 8px;
}

.footer__contact {
  display: flex;
  flex-direction: column;
}

.footer__contact-item {
  display: block;
  padding: 5px 0;
  color: rgba(255, 255, 255, 0.55);
  font-size: 14px;
  font-family: var(--font-index);
  word-break: break-all;
  line-height: 1.5;
}

.footer__bottom {
  background: rgba(0, 0, 0, 0.3);
}

.footer__bottom-inner {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  padding-top: 20px;
  padding-bottom: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  font-family: var(--font-index);
  font-size: 13px;
  color: rgba(255, 255, 255, 0.35);
}

/* ---------- 滚动显现 ---------- */
[data-reveal] {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
}

[data-reveal="visible"] {
  opacity: 1;
  transform: translateY(0);
}

/* ========================================
   响应式
   ======================================== */
@media (max-width: 1080px) {
  .nav__link {
    padding: 10px 8px;
    font-size: 14px;
  }
}

@media (max-width: 900px) {
  .layout-editorial {
    grid-template-columns: 1fr;
    padding: 32px 16px;
  }

  .layout-editorial__aside {
    border-left: none;
    border-bottom: 3px solid var(--orange);
    padding-bottom: 16px;
    padding-left: 0;
  }

  .grid--2,
  .grid--3 {
    grid-template-columns: 1fr;
  }

  .hero {
    padding: 40px 16px;
  }

  .split {
    grid-template-columns: 1fr;
  }

  .split__art {
    min-height: 220px;
  }
}

@media (max-width: 860px) {
  .header__meta-tag {
    display: none;
  }

  .header__meta-inner {
    column-gap: 16px;
  }

  .nav-toggle {
    display: flex;
    margin-left: 8px;
  }

  .btn--login {
    margin-left: auto;
    padding: 10px 14px 12px;
    font-size: 12px;
  }

  .btn--login::after {
    width: 14px;
    height: 14px;
  }

  .header__main-inner {
    padding-top: 12px;
    padding-bottom: 12px;
  }

  .header__main::after {
    display: none;
  }

  .header__nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    display: none;
    flex-direction: column;
    background: var(--deep-blue);
    margin-left: 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 14px 28px rgba(0, 0, 0, 0.3);
    z-index: 50;
    max-height: calc(100vh - 60px);
    overflow-y: auto;
  }

  .header__nav[data-open] {
    display: flex;
  }

  .nav__list {
    flex-direction: column;
    align-items: stretch;
    width: 100%;
  }

  .nav__item {
    width: 100%;
  }

  .nav__link {
    padding: 15px 16px;
    font-size: 17px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  }

  .nav__link::after {
    left: 16px;
    right: auto;
    width: 0;
    height: 2px;
    transform: none;
    background: var(--orange);
    transition: width 0.3s var(--ease-out);
  }

  .nav__link:hover::after,
  .nav__link[aria-current="page"]::after {
    width: 32px;
  }

  .footer__main-inner {
    grid-template-columns: 1fr;
    gap: 36px;
    padding-top: 44px;
    padding-bottom: 44px;
  }
}

@media (max-width: 640px) {
  .container {
    width: calc(100% - 32px);
  }

  .section {
    padding: 48px 0;
  }

  .breadcrumb {
    width: calc(100% - 32px);
  }
}

@media (max-width: 520px) {
  .brand__text span {
    display: none;
  }

  .brand__text strong {
    font-size: 18px;
  }

  .brand__mark {
    width: 40px;
    height: 40px;
    font-size: 20px;
  }

  .btn--login {
    padding: 9px 10px 11px;
    font-size: 11px;
  }

  .btn--login::after {
    width: 10px;
    height: 10px;
  }

  .header__meta-version {
    display: none;
  }

  .header__meta-inner {
    justify-content: space-between;
  }
}

/* ---------- 减少动态效果 ---------- */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  html {
    scroll-behavior: auto;
  }

  [data-reveal] {
    opacity: 1;
    transform: none;
    transition: none;
  }
}
