/* ========== 全局重置与变量 ========== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  /* 主色 - 沿用产品 UI 的红色品牌色 */
  --color-primary: #ec4141;
  --color-primary-dark: #d63434;
  --color-primary-light: #ff5757;

  /* 中性色 */
  --color-bg: #ffffff;
  --color-bg-soft: #f7f7f7;
  --color-bg-elev: #fafafa;
  --color-text: #1a1a1a;
  --color-text-soft: #666666;
  --color-text-mute: #999999;
  --color-border: #ececec;
  --color-border-dark: #d0d0d0;

  /* 暗色（局部使用） */
  --color-dark: #0d0d0d;
  --color-dark-soft: #1a1a1a;

  /* 阴影 */
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.04);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.06);
  --shadow-lg: 0 12px 40px rgba(0,0,0,0.10);
  --shadow-primary: 0 8px 24px rgba(236,65,65,0.32);

  /* 圆角 */
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-xl: 24px;

  /* 间距 */
  --gap-xs: 8px;
  --gap-sm: 12px;
  --gap-md: 20px;
  --gap-lg: 32px;
  --gap-xl: 64px;
  --gap-2xl: 96px;

  /* 排版 */
  --font: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Helvetica, Arial, sans-serif;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

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

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ========== 导航栏 ========== */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255,255,255,0.85);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--color-border);
}

.nav__inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 14px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav__logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 18px;
  color: var(--color-text);
}

.nav__logo-icon {
  display: inline-block;
  width: 32px;
  height: 32px;
  background: var(--color-primary);
  border-radius: 50%;
  position: relative;
  box-shadow: var(--shadow-primary);
}

.nav__logo-icon::after {
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 10px; height: 10px;
  background: #fff;
  border-radius: 50%;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 28px;
}

.nav__links a:not(.nav__github) {
  font-size: 14px;
  color: var(--color-text-soft);
  font-weight: 500;
  transition: color .2s;
}

.nav__links a:not(.nav__github):hover {
  color: var(--color-primary);
}

.nav__github {
  color: var(--color-text-soft);
  transition: color .2s;
  display: inline-flex;
}

.nav__github:hover {
  color: var(--color-primary);
}

/* ========== Hero ========== */
.hero {
  position: relative;
  padding: 80px 0 100px;
  overflow: hidden;
}

.hero__bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 80% 0%, rgba(236,65,65,0.10), transparent 50%),
    radial-gradient(ellipse at 0% 100%, rgba(236,65,65,0.06), transparent 50%);
  z-index: -1;
}

.hero__inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: var(--gap-xl);
  align-items: center;
}

.hero__badge {
  display: inline-block;
  padding: 6px 14px;
  background: rgba(236,65,65,0.10);
  color: var(--color-primary);
  font-size: 12px;
  font-weight: 600;
  border-radius: 999px;
  margin-bottom: 20px;
  letter-spacing: 0.5px;
}

.hero__title {
  font-size: 60px;
  line-height: 1.15;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 24px;
  background: linear-gradient(180deg, #1a1a1a 0%, #4a4a4a 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero__title br + * { display: inline; }

.hero__subtitle {
  font-size: 18px;
  color: var(--color-text-soft);
  line-height: 1.7;
  margin-bottom: 36px;
  max-width: 520px;
}

.hero__actions {
  display: flex;
  gap: 14px;
  margin-bottom: 32px;
}

.hero__meta {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
  font-size: 13px;
  color: var(--color-text-mute);
}

.hero__meta span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

/* Hero 窗口模拟 */
.hero__window {
  background: #fff;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg), 0 0 0 1px rgba(0,0,0,0.04);
  transform: perspective(2000px) rotateY(-3deg) rotateX(2deg);
  transition: transform .6s ease;
}

.hero__window:hover {
  transform: perspective(2000px) rotateY(0) rotateX(0);
}

.hero__titlebar {
  height: 36px;
  background: #f5f5f5;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 14px;
  border-bottom: 1px solid var(--color-border);
}

.dot {
  width: 11px; height: 11px;
  border-radius: 50%;
  display: inline-block;
}

.dot--r { background: #ff5f57; }
.dot--y { background: #febc2e; }
.dot--g { background: #28c840; }

.hero__titlebar-name {
  margin-left: 12px;
  font-size: 12px;
  color: var(--color-text-mute);
  font-weight: 500;
}

.hero__window img {
  display: block;
  width: 100%;
  height: auto;
}

/* Hero 轮播 */
.hero__carousel {
  position: relative;
  overflow: hidden;
  background: #fff;
}

.hero__slides {
  display: flex;
  transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: transform;
}

.hero__slide {
  flex: 0 0 100%;
}

.hero__slide img {
  width: 100%;
  height: auto;
  display: block;
}

.hero__prev, .hero__next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: none;
  background: rgba(0,0,0,0.5);
  color: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity .2s, background .2s;
  z-index: 2;
}

.hero__window:hover .hero__prev,
.hero__window:hover .hero__next {
  opacity: 1;
}

.hero__prev:hover, .hero__next:hover {
  background: rgba(0,0,0,0.7);
}

.hero__prev { left: 12px; }
.hero__next { right: 12px; }

.hero__dots {
  position: absolute;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  padding: 6px 12px;
  background: rgba(0,0,0,0.5);
  border-radius: 999px;
}

.hero__dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  border: none;
  background: rgba(255,255,255,0.5);
  cursor: pointer;
  transition: background .25s, transform .25s;
  padding: 0;
}

.hero__dot--active {
  background: #fff;
  transform: scale(1.4);
}

/* ========== 通用按钮 ========== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: transform .2s, box-shadow .2s, background .2s;
  text-decoration: none;
}

.btn--primary {
  background: var(--color-primary);
  color: #fff;
  box-shadow: var(--shadow-primary);
}

.btn--primary:hover {
  background: var(--color-primary-dark);
  transform: translateY(-2px);
  box-shadow: 0 12px 32px rgba(236,65,65,0.42);
}

.btn--ghost {
  background: transparent;
  color: var(--color-text);
  border: 1.5px solid var(--color-border-dark);
}

.btn--ghost:hover {
  background: var(--color-bg-soft);
  border-color: var(--color-text-soft);
}

/* ========== 章节标题 ========== */
.section__title {
  font-size: 40px;
  font-weight: 800;
  text-align: center;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
}

.section__title--light { color: #fff; }

.section__subtitle {
  font-size: 16px;
  color: var(--color-text-soft);
  text-align: center;
  margin-bottom: 60px;
}

.section__subtitle--light { color: rgba(255,255,255,0.7); }

/* ========== 功能特性 ========== */
.features {
  padding: var(--gap-2xl) 0;
  background: var(--color-bg-soft);
}

.features__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.feature-card {
  background: #fff;
  padding: 32px 28px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border);
  transition: transform .3s, box-shadow .3s, border-color .3s;
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: rgba(236,65,65,0.20);
}

.feature-card__icon {
  font-size: 36px;
  margin-bottom: 16px;
  display: inline-block;
}

.feature-card h3 {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 10px;
  color: var(--color-text);
}

.feature-card p {
  font-size: 14px;
  color: var(--color-text-soft);
  line-height: 1.65;
}

/* ========== 界面截图（轮播） ========== */
.screenshots {
  padding: var(--gap-2xl) 0;
}

.carousel {
  position: relative;
}

.carousel__track-wrap {
  position: relative;
  display: flex;
  align-items: center;
  gap: 16px;
}

.carousel__track {
  flex: 1;
  overflow: hidden;
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-md);
  background: #fff;
}

.carousel__slides {
  display: flex;
  transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: transform;
}

.carousel__slide {
  flex: 0 0 100%;
  display: flex;
  flex-direction: column;
}

.carousel__slide img {
  width: 100%;
  height: auto;
  display: block;
  border-bottom: 1px solid var(--color-border);
  user-select: none;
  -webkit-user-drag: none;
}

.carousel__btn {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 1px solid var(--color-border);
  background: #fff;
  color: var(--color-text);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: background .2s, border-color .2s, color .2s, box-shadow .2s;
  box-shadow: var(--shadow-sm);
  z-index: 2;
}

.carousel__btn:hover {
  background: var(--color-primary);
  color: #fff;
  border-color: var(--color-primary);
  box-shadow: var(--shadow-primary);
}

.carousel__btn:active {
  transform: scale(0.95);
}

.carousel__dots {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 24px;
}

.carousel__dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: none;
  background: var(--color-border-dark);
  cursor: pointer;
  transition: background .25s, transform .25s;
  padding: 0;
}

.carousel__dot:hover {
  background: var(--color-text-mute);
}

.carousel__dot--active {
  background: var(--color-primary);
  transform: scale(1.3);
}

.carousel__counter {
  text-align: center;
  margin-top: 12px;
  font-size: 13px;
  color: var(--color-text-mute);
  font-weight: 500;
  letter-spacing: 1px;
}

.carousel__counter .carousel__cur {
  color: var(--color-primary);
  font-weight: 700;
}

.carousel__caption {
  text-align: center;
  margin-top: 16px;
  font-size: 15px;
  color: var(--color-text-soft);
  font-weight: 500;
  min-height: 24px;
}

/* ========== 精简模式预览 ========== */
.mini-mode {
  padding: var(--gap-2xl) 0;
  background: var(--color-bg-soft);
}

.mini-mode__carousel {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
}

.mini-mode__track {
  max-width: 560px;
  width: 100%;
  aspect-ratio: 16/9;
  overflow: hidden;
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-md);
  background: #1a1a1a;
  display: flex;
  align-items: center;
  justify-content: center;
}

.mini-mode__slides {
  display: flex;
  width: 100%;
  height: 100%;
  transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: transform;
}

.mini-mode__slide {
  flex: 0 0 100%;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.mini-mode__slide img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  display: block;
  border-radius: 8px;
}

.mini-mode__btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid var(--color-border);
  background: #fff;
  color: var(--color-text);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: background .2s, border-color .2s, color .2s;
  box-shadow: var(--shadow-sm);
}

.mini-mode__btn:hover {
  background: var(--color-primary);
  color: #fff;
  border-color: var(--color-primary);
}

.mini-mode__dots {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 24px;
}

.mini-mode__dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: none;
  background: var(--color-border-dark);
  cursor: pointer;
  transition: background .25s, transform .25s;
  padding: 0;
}

.mini-mode__dot:hover {
  background: var(--color-text-mute);
}

.mini-mode__dot--active {
  background: var(--color-primary);
  transform: scale(1.3);
}

.mini-mode__caption {
  text-align: center;
  margin-top: 16px;
  font-size: 15px;
  color: var(--color-text-soft);
  font-weight: 500;
}

/* ========== 下载区 ========== */
.download {
  padding: var(--gap-2xl) 0;
  background: var(--color-bg-soft);
}

.download__card {
  background: linear-gradient(135deg, #1a1a1a 0%, #0d0d0d 100%);
  color: #fff;
  padding: 64px 48px;
  border-radius: var(--radius-xl);
  text-align: center;
  box-shadow: var(--shadow-lg);
  position: relative;
  overflow: hidden;
}

.download__card::before {
  content: '';
  position: absolute;
  top: -50%; left: -10%;
  width: 400px; height: 400px;
  background: radial-gradient(circle, rgba(236,65,65,0.25), transparent 70%);
  filter: blur(40px);
  pointer-events: none;
}

.download__card::after {
  content: '';
  position: absolute;
  bottom: -50%; right: -10%;
  width: 400px; height: 400px;
  background: radial-gradient(circle, rgba(236,65,65,0.18), transparent 70%);
  filter: blur(40px);
  pointer-events: none;
}

.download__card > * {
  position: relative;
  z-index: 1;
}

.download__card .section__title { margin-bottom: 8px; }
.download__card .section__subtitle { margin-bottom: 40px; }

.download__platforms {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin-bottom: 40px;
  flex-wrap: wrap;
}

.download-btn {
  display: inline-flex;
  align-items: center;
  gap: 16px;
  padding: 18px 32px;
  background: var(--color-primary);
  color: #fff;
  border-radius: var(--radius-md);
  font-size: 15px;
  font-weight: 600;
  transition: transform .2s, box-shadow .2s, background .2s;
  cursor: pointer;
  text-decoration: none;
}

.download-btn:hover {
  background: var(--color-primary-light);
  transform: translateY(-2px);
  box-shadow: var(--shadow-primary);
}

.download-btn__text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  line-height: 1.2;
}

.download-btn__text small {
  font-size: 11px;
  font-weight: 500;
  opacity: 0.85;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.download-btn__text strong {
  font-size: 16px;
  font-weight: 700;
  margin-top: 2px;
}

.download__meta {
  list-style: none;
  display: inline-flex;
  flex-direction: column;
  gap: 10px;
  font-size: 14px;
  color: rgba(255,255,255,0.75);
  margin: 0 auto 32px;
  text-align: left;
}

.download__meta code {
  background: rgba(255,255,255,0.10);
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 13px;
  color: rgba(255,255,255,0.95);
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, monospace;
}

.download__alt {
  font-size: 14px;
  color: rgba(255,255,255,0.6);
  display: flex;
  justify-content: center;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}

.download__alt a {
  color: rgba(255,255,255,0.85);
  text-decoration: underline;
  text-decoration-color: rgba(236,65,65,0.4);
  text-underline-offset: 4px;
  transition: color .2s;
}

.download__alt a:hover {
  color: var(--color-primary-light);
}

/* ========== 页脚 ========== */
.footer {
  background: #fff;
  padding: 60px 0 40px;
  border-top: 1px solid var(--color-border);
}

.footer__inner {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 40px;
  align-items: start;
}

.footer__brand p {
  color: var(--color-text-soft);
  font-size: 14px;
  margin-top: 12px;
}

.footer__links {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer__links a {
  color: var(--color-text-soft);
  font-size: 14px;
  transition: color .2s;
}

.footer__links a:hover {
  color: var(--color-primary);
}

.footer__copy p {
  color: var(--color-text-mute);
  font-size: 13px;
  text-align: right;
}

/* ========== 响应式 ========== */
@media (max-width: 900px) {
  .hero__inner {
    grid-template-columns: 1fr;
    gap: var(--gap-lg);
  }

  .hero__title { font-size: 44px; }

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

  .carousel__track-wrap { gap: 8px; }
  .carousel__btn { width: 40px; height: 40px; }

  .footer__inner {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .footer__links { flex-direction: row; justify-content: center; }
  .footer__copy p { text-align: center; }
}

@media (max-width: 600px) {
  .hero { padding: 50px 0 60px; }
  .hero__title { font-size: 36px; }
  .hero__subtitle { font-size: 15px; }
  .section__title { font-size: 30px; }
  .features__grid { grid-template-columns: 1fr; }
  .download__card { padding: 40px 24px; }
  .nav__links { gap: 16px; }
  .nav__links a:not(.nav__github) { display: none; }
}
