/* ===== 基础重置 ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --brand: #29a3e8;
  --brand-dark: #1a86c8;
  --text: #1f2d3d;
  --text-soft: #5a6b7b;
  --nav-h: 68px;
}

html {
  scroll-behavior: smooth;
}

html,
body {
  height: 100%;
}

body {
  font-family: "PingFang SC", "Microsoft YaHei", "Segoe UI", -apple-system,
    BlinkMacSystemFont, sans-serif;
  color: var(--text);
  -webkit-font-smoothing: antialiased;
}

a {
  text-decoration: none;
  color: inherit;
}

/* ===== 顶部导航栏 ===== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-h);
  z-index: 100;
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(31, 45, 61, 0.06);
}

.navbar__inner {
  max-width: 1200px;
  height: 100%;
  margin: 0 auto;
  padding: 0 28px;
  display: flex;
  align-items: center;
  gap: 40px;
}

/* 桌面端：让子元素直接参与 navbar 布局，不改变现有排列 */
.nav-menu {
  display: contents;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* 公司 logo 完整展示：固定高度、宽度自适应，不裁切不变形 */
.brand__logo {
  display: block;
  height: 40px;
  width: auto;
  object-fit: contain;
}

.brand__name {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: 0.5px;
  color: var(--text);
}

.nav {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav--right {
  /* 靠右已由中间 .nav__site 的 auto 外边距抬出来，这里不再写 margin-left: auto */
  gap: 26px;
}

.nav__link {
  font-size: 15px;
  color: var(--text-soft);
  transition: color 0.2s ease;
  position: relative;
}

.nav__link:hover {
  color: var(--brand);
}

.nav__link--active {
  color: var(--brand);
  font-weight: 600;
}

.nav__link--active::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -24px;
  height: 3px;
  border-radius: 3px;
  background: var(--brand);
}

.nav__link--sub {
  font-size: 14px;
}

/* 顶栏正中的官网入口：左右 auto 边距把它夹在左侧菜单与右侧菜单中间，蓝字 */
.nav__site {
  margin: 0 auto;
  color: var(--brand);
  font-weight: 600;
}

.nav__site:hover {
  color: var(--brand-dark);
}

.nav-toggle {
  display: none;
  margin-left: auto;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: 0;
  cursor: pointer;
  padding: 6px;
}

.nav-toggle span {
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
}

/* ===== Hero ===== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: var(--nav-h) 24px 0;
  background: url("../static/img/bg.png") center / cover no-repeat;
  overflow: hidden;
}

/* 顶部轻微渐白，保证导航栏文字清晰 */
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.35) 0%,
    rgba(255, 255, 255, 0) 30%
  );
  pointer-events: none;
}

.hero__content {
  position: relative;
  z-index: 2;
  flex: 1 1 auto;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 32px 0;
  text-align: center;
  animation: fadeUp 0.7s ease both;
}

/* 软件图标（居中展示在标题上方） */
.hero__icon {
  display: block;
  width: 104px;
  height: 104px;
  margin: 0 auto 26px;
  border-radius: 24px;
  object-fit: cover;
  box-shadow: 0 16px 40px rgba(41, 163, 232, 0.35);
}

.hero__title {
  font-size: 56px;
  font-weight: 800;
  letter-spacing: 1px;
  color: var(--text);
  text-shadow: 0 2px 16px rgba(255, 255, 255, 0.6);
}

.hero__subtitle {
  margin-top: 18px;
  font-size: 22px;
  font-weight: 400;
  color: var(--text-soft);
}

.hero__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 30px;
  font-size: 17px;
  font-weight: 600;
  color: #fff;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--brand) 0%, var(--brand-dark) 100%);
  box-shadow: 0 12px 28px rgba(41, 163, 232, 0.4);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.hero__btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 36px rgba(41, 163, 232, 0.5);
}

.hero__btn:active {
  transform: translateY(-1px);
}

/* 下载按钮组 */
.hero__dl {
  margin-top: 40px;
}

.hero__choose {
  margin-bottom: 14px;
  font-size: 14px;
  color: var(--text-soft);
}

.hero__downloads {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
}

/* 次要下载项（描边） */
.hero__btn--ghost {
  color: var(--brand-dark);
  background: rgba(255, 255, 255, 0.72);
  border: 1.5px solid rgba(41, 163, 232, 0.5);
  box-shadow: none;
}

.hero__btn--ghost:hover {
  background: #fff;
  box-shadow: 0 10px 24px rgba(41, 163, 232, 0.18);
}

/* 开发中 / 敬请期待（禁用态）*/
.hero__btn--soon {
  color: #9aa7b4;
  background: rgba(255, 255, 255, 0.6);
  border: 1.5px dashed rgba(90, 107, 123, 0.4);
  box-shadow: none;
  cursor: default;
  pointer-events: none;
}

.hero__meta {
  margin-top: 20px;
  font-size: 14px;
  color: var(--text-soft);
  opacity: 0.85;
}

/* ===== 底部平台切换栏（流式布局，不再浮层遮挡下载按钮）===== */
.platforms {
  position: relative;
  width: 100%;
  z-index: 3;
  padding: 22px 24px 30px;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0) 0%,
    rgba(255, 255, 255, 0.55) 100%
  );
}

.platforms__inner {
  max-width: 760px;
  margin: 0 auto;
  display: flex;
  justify-content: center;
  gap: 20px;
  padding: 18px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.55);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.7);
  box-shadow: 0 10px 30px rgba(31, 45, 61, 0.08);
}

.platform {
  flex: 1;
  max-width: 160px;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 14px 10px;
  border: 0;
  border-radius: 12px;
  background: transparent;
  color: var(--text-soft);
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.platform:hover {
  color: var(--brand);
  transform: translateY(-2px);
}

.platform.is-active {
  background: rgba(41, 163, 232, 0.12);
  color: var(--brand);
}

.platform__icon {
  width: 30px;
  height: 30px;
  /* 图标取自 static/svg，用 mask 让形状跟随 currentColor：默认 --text-soft，悬停/激活变 --brand */
  background-color: currentColor;
  -webkit-mask: var(--icon) no-repeat center / contain;
  mask: var(--icon) no-repeat center / contain;
}

.platform__icon--win { --icon: url("../static/svg/windows.svg"); }
.platform__icon--mac { --icon: url("../static/svg/mac.svg"); }
.platform__icon--linux { --icon: url("../static/svg/linux.svg"); }
.platform__icon--android { --icon: url("../static/svg/android.svg"); }

.platform__name {
  font-size: 15px;
  font-weight: 500;
}

.platform__badge {
  position: absolute;
  top: 6px;
  right: 8px;
  font-size: 10px;
  line-height: 1;
  font-weight: 600;
  color: #b06a12;
  background: rgba(217, 130, 43, 0.16);
  padding: 3px 6px;
  border-radius: 999px;
}

/* ===== 动画 ===== */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero__content.switching {
  animation: fadeUp 0.45s ease both;
}

/* ===== 软件动态 / 更新日志 ===== */
.updates {
  scroll-margin-top: var(--nav-h);
  background: linear-gradient(180deg, #f4f9fd 0%, #eaf3fb 100%);
  padding: 88px 24px 96px;
}

.updates__inner {
  max-width: 860px;
  margin: 0 auto;
}

.updates__head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 44px;
}

.updates__title {
  font-size: 34px;
  font-weight: 800;
  color: var(--text);
}

.updates__desc {
  margin-top: 8px;
  font-size: 15px;
  color: var(--text-soft);
}

/* 语言切换 */
.lang-switch {
  display: inline-flex;
  padding: 4px;
  gap: 2px;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 4px 14px rgba(31, 45, 61, 0.08);
}

.lang {
  border: 0;
  background: transparent;
  padding: 8px 16px;
  font-size: 14px;
  color: var(--text-soft);
  border-radius: 999px;
  cursor: pointer;
  transition: color 0.2s ease, background 0.2s ease;
}

.lang:hover {
  color: var(--brand);
}

.lang.is-active {
  color: #fff;
  background: linear-gradient(135deg, var(--brand) 0%, var(--brand-dark) 100%);
}

/* 导航栏内的紧凑版 */
.lang-switch--nav {
  padding: 3px;
  flex: none;
  box-shadow: 0 2px 8px rgba(31, 45, 61, 0.08);
}

.lang-switch--nav .lang {
  padding: 6px 12px;
  font-size: 13px;
}

/* 时间线 */
.timeline {
  position: relative;
  padding-left: 34px;
}

.timeline::before {
  content: "";
  position: absolute;
  left: 7px;
  top: 6px;
  bottom: 6px;
  width: 2px;
  background: linear-gradient(180deg, var(--brand) 0%, rgba(41, 163, 232, 0.15) 100%);
}

.timeline__loading {
  color: var(--text-soft);
  font-size: 15px;
}

.tl-item {
  position: relative;
  padding: 0 0 40px 8px;
  animation: fadeUp 0.5s ease both;
}

.tl-item::before {
  content: "";
  position: absolute;
  left: -34px;
  top: 6px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  border: 3px solid var(--brand);
  box-shadow: 0 0 0 4px rgba(41, 163, 232, 0.12);
}

.tl-item__head {
  display: flex;
  align-items: baseline;
  gap: 14px;
  flex-wrap: wrap;
}

.tl-item__version {
  font-size: 22px;
  font-weight: 700;
  color: var(--text);
}

.tl-item__date {
  font-size: 14px;
  color: var(--text-soft);
}

.tl-item__latest {
  font-size: 12px;
  font-weight: 600;
  color: var(--brand);
  background: rgba(41, 163, 232, 0.12);
  padding: 2px 10px;
  border-radius: 999px;
}

.tl-group {
  margin-top: 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.tl-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.tl-tag {
  flex: none;
  font-size: 12px;
  font-weight: 600;
  line-height: 20px;
  height: 20px;
  padding: 0 8px;
  border-radius: 5px;
  white-space: nowrap;
}

.tl-tag--feature {
  color: #1a9c5b;
  background: rgba(26, 156, 91, 0.12);
}

.tl-tag--improve {
  color: var(--brand-dark);
  background: rgba(41, 163, 232, 0.14);
}

.tl-tag--fix {
  color: #d9822b;
  background: rgba(217, 130, 43, 0.14);
}

.tl-text {
  font-size: 15px;
  line-height: 20px;
  color: var(--text);
}

/* ===== 页脚 ===== */
.footer {
  background: #1f2d3d;
  color: rgba(255, 255, 255, 0.6);
  text-align: center;
  font-size: 13px;
  padding: 26px 24px;
}

/* ===== 响应式 ===== */
@media (max-width: 820px) {
  .navbar__inner {
    padding: 0 16px;
    gap: 12px;
  }

  .brand__logo {
    height: 32px;
  }

  /* 折叠栏只留 Logo + 汉堡按钮，菜单变成下拉面板 */
  .nav-menu {
    display: none;
    position: absolute;
    top: var(--nav-h);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    padding: 8px 16px 18px;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid rgba(31, 45, 61, 0.08);
    box-shadow: 0 14px 26px rgba(31, 45, 61, 0.12);
  }

  .navbar.open .nav-menu {
    display: flex;
  }

  .nav {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
  }

  .nav--right {
    margin-left: 0;
  }

  .nav__link {
    display: block;
    padding: 13px 6px;
    font-size: 16px;
  }

  .nav__link--sub {
    font-size: 16px;
  }

  /* 下拉面板里回到左对齐，与其他菜单项一致 */
  .nav__site {
    margin: 0;
  }

  .nav__link--active {
    color: var(--brand);
  }

  .nav__link--active::after {
    display: none;
  }

  .lang-switch--nav {
    margin-top: 12px;
    align-self: flex-start;
  }

  .nav-toggle {
    display: flex;
    margin-left: auto;
    min-width: 44px;
    min-height: 44px;
    align-items: center;
    justify-content: center;
  }

  .hero__title {
    font-size: 38px;
  }

  .hero__icon {
    width: 76px;
    height: 76px;
    margin-bottom: 18px;
    border-radius: 18px;
  }

  .hero__subtitle {
    font-size: 18px;
  }

  .hero__downloads {
    flex-direction: column;
    align-items: center;
  }

  .hero__btn {
    width: 100%;
    max-width: 320px;
    padding: 13px 24px;
    font-size: 16px;
  }

  .platforms__inner {
    gap: 8px;
    padding: 12px;
  }

  .platform__name {
    font-size: 13px;
  }

  /* 移动端窄按钮：角标改为内联排在名称下方，避免遮挡图标 */
  .platform__badge {
    position: static;
    order: 3;
    margin-top: 2px;
  }

  .updates {
    padding: 64px 18px 72px;
  }

  .updates__title {
    font-size: 26px;
  }

  .updates__head {
    align-items: flex-start;
    margin-bottom: 32px;
  }

  .lang {
    padding: 7px 12px;
    font-size: 13px;
  }

  .tl-item__version {
    font-size: 19px;
  }
}
