/* API Manager 官网样式 —— 主题色 群青 #2E59A7 */
:root {
  --primary: #2E59A7;
  --primary-dark: #1e3f7d;
  --primary-light: #e8eefb;
  --bg: #f6f8fc;
  --text: #1f2937;
  --muted: #64748b;
  --border: #e2e8f0;
  --radius: 12px;
  --shadow: 0 6px 24px rgba(46, 89, 167, 0.08);
}

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

html { scroll-behavior: smooth; }

body {
  font-family: "Segoe UI", "PingFang SC", "Microsoft YaHei", system-ui, -apple-system, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
}

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

/* ---------- 导航栏 ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.nav-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 10px 24px;
  display: flex;
  align-items: center;
  gap: 16px;
}
.nav-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  color: var(--text);
  font-weight: 700;
  font-size: 18px;
  margin-right: auto;
}
.nav-logo { width: 30px; height: 30px; border-radius: 7px; }
.nav-links { display: flex; align-items: center; gap: 18px; }
.nav-links a { text-decoration: none; color: var(--muted); font-size: 14px; }
.nav-links a:hover { color: var(--primary); }
.nav-links .nav-dl {
  background: var(--primary);
  color: #fff;
  padding: 6px 14px;
  border-radius: 8px;
}
.nav-links .nav-dl:hover { background: var(--primary-dark); color: #fff; }
.lang-switch { display: flex; align-items: center; margin-left: 8px; }
.lang-select {
  border: 1px solid var(--border);
  background: #fff;
  color: var(--text);
  font-size: 14px;
  padding: 5px 10px;
  border-radius: 8px;
  cursor: pointer;
  outline: none;
  font-family: inherit;
}
.lang-select:hover { border-color: var(--primary); }
.lang-select:focus { border-color: var(--primary); box-shadow: 0 0 0 2px var(--primary-light); }

/* ---------- Hero ---------- */
.hero {
  background: linear-gradient(160deg, #16264d 0%, #2E59A7 60%, #3d6fc0 100%);
  color: #fff;
  padding: 72px 24px 0;
  text-align: center;
}
.hero-inner { max-width: 1100px; margin: 0 auto; }
.hero-logo {
  width: 96px;
  height: 96px;
  margin: 0 auto 20px;
  border-radius: 22px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.35);
}
.hero-title { font-size: 52px; font-weight: 800; letter-spacing: 1px; }
.hero-sub {
  font-size: 22px;
  margin: 14px 0 10px;
  font-weight: 500;
  opacity: 0.95;
}
.hero-desc {
  max-width: 640px;
  margin: 0 auto;
  font-size: 15px;
  opacity: 0.85;
}
.hero-actions { display: flex; gap: 14px; justify-content: center; margin: 30px 0 22px; }
.btn {
  display: inline-block;
  padding: 11px 28px;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
  transition: transform 0.15s, box-shadow 0.15s;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: #fff; color: var(--primary); box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25); }
.btn-primary:hover { box-shadow: 0 10px 28px rgba(0, 0, 0, 0.3); }
.btn-ghost { background: rgba(255, 255, 255, 0.14); color: #fff; border: 1px solid rgba(255, 255, 255, 0.4); }
.hero-badges { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; padding-bottom: 34px; }
.badge {
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.25);
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 13px;
}
.hero-shot {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 12px;
  transform: translateY(36px);
  position: relative;
  z-index: 5;
}
.shot-img { width: 100%; display: block; }

/* ---------- Hero 轮播 ---------- */
.carousel {
  position: relative;
  overflow: hidden;
  border-radius: 16px 16px 0 0;
  border: 6px solid rgba(255, 255, 255, 0.35);
  border-bottom: none;
  box-shadow: 0 -12px 50px rgba(0, 0, 0, 0.28);
  background: #fff;
}
.carousel-track { display: flex; transition: transform 0.5s ease; }
.carousel-slide { position: relative; min-width: 100%; }
.carousel-cap {
  position: absolute;
  left: 14px;
  bottom: 14px;
  max-width: 70%;
  background: rgba(15, 23, 42, 0.6);
  color: #fff;
  padding: 5px 12px;
  border-radius: 8px;
  font-size: 13px;
  line-height: 1.5;
  backdrop-filter: blur(4px);
}
.carousel-nav {
  position: absolute;
  top: 44%;
  transform: translateY(-50%);
  z-index: 10;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: rgba(15, 23, 42, 0.45);
  color: #fff;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}
.carousel-nav:hover { background: rgba(15, 23, 42, 0.7); }
.carousel-prev { left: 12px; }
.carousel-next { right: 12px; }
.carousel-dots {
  position: absolute;
  right: 14px;
  bottom: 16px;
  display: flex;
  gap: 8px;
  z-index: 10;
}
.carousel-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.45);
  cursor: pointer;
  padding: 0;
}
.carousel-dot.active { background: #fff; }

/* ---------- 通用分区 ---------- */
.sec-inner { max-width: 1100px; margin: 0 auto; padding: 64px 24px; }
.sec-title {
  font-size: 32px;
  font-weight: 800;
  text-align: center;
  color: var(--text);
}
.sec-desc { text-align: center; color: var(--muted); margin: 10px 0 40px; }

/* ---------- 功能卡片 ---------- */
.features { padding-top: 36px; }
.feat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(330px, 1fr));
  gap: 22px;
}
.feat-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform 0.18s, box-shadow 0.18s;
}
.feat-card:hover { transform: translateY(-4px); box-shadow: 0 14px 34px rgba(46, 89, 167, 0.14); }
.feat-shot {
  background: var(--primary-light);
  padding: 14px;
  border-bottom: 1px solid var(--border);
}
.feat-shot img { border-radius: 8px; border: 1px solid var(--border); }
.feat-card h3 { font-size: 17px; padding: 16px 18px 6px; }
.feat-card p { padding: 0 18px 18px; color: var(--muted); font-size: 14px; }

/* ---------- 目录结构 ---------- */
.structure { background: #fff; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.code-block {
  max-width: 780px;
  margin: 0 auto;
  background: #0f172a;
  color: #dbeafe;
  border-radius: var(--radius);
  padding: 26px 30px;
  font-size: 14px;
  overflow-x: auto;
  box-shadow: var(--shadow);
}
.code-block code { font-family: "Cascadia Code", Consolas, monospace; }
.code-block span { color: #94a3b8; }
.code-note { text-align: center; color: var(--muted); font-size: 14px; margin-top: 18px; }

/* ---------- 技术栈 ---------- */
.stack-list {
  display: flex;
  flex-wrap: nowrap;
  gap: 14px;
  justify-content: center;
}
.stack-row {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 14px;
  box-shadow: var(--shadow);
  text-decoration: none;
  color: var(--text);
  text-align: center;
  transition: transform 0.18s, box-shadow 0.18s, border-color 0.18s;
}
.stack-row:hover {
  transform: translateY(-2px);
  border-color: var(--primary);
  box-shadow: 0 14px 34px rgba(46, 89, 167, 0.14);
}
.stack-row .stack-icon { font-size: 30px; }
.stack-info h3 { font-size: 15px; }
.stack-info p {
  color: var(--muted);
  font-size: 12px;
  margin-top: 6px;
  line-height: 1.5;
}

/* ---------- CTA ---------- */
.cta {
  background: linear-gradient(160deg, #2E59A7, #16264d);
  color: #fff;
  text-align: center;
  padding: 70px 24px;
}
.cta h2 { font-size: 30px; }
.cta p { opacity: 0.85; margin: 12px 0 26px; }

/* ---------- Footer ---------- */
.footer { background: #0f172a; color: #94a3b8; padding: 34px 24px; text-align: center; }
.footer-brand {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: #e2e8f0;
  font-weight: 700;
  margin-bottom: 8px;
}
.footer-brand img { width: 26px; height: 26px; border-radius: 6px; }
.footer p { font-size: 13px; margin: 4px 0; }
.footer-links a { color: #94a3b8; text-decoration: none; }
.footer-links a:hover { color: #fff; }

/* ---------- 响应式 ---------- */
@media (max-width: 720px) {
  .nav-inner { flex-wrap: wrap; }
  .nav-links { order: 3; width: 100%; justify-content: center; gap: 14px; }
  .hero-title { font-size: 36px; }
  .hero-sub { font-size: 18px; }
  .feat-grid { grid-template-columns: 1fr; }
  .hero-shot { transform: translateY(24px); }
  /* 窄屏允许技术栈换行，避免内容过挤 */
  .stack-list { flex-wrap: wrap; }
  .stack-row { flex: 1 1 45%; }
}
