/* Glint landing — 视觉与 tauri/ui/style.css 同源（CSS 变量 + prefers-color-scheme 自动深浅色） */

:root {
  --bg: #f5f5f7;
  --card: rgba(0, 0, 0, 0.05);
  --text: #1d1d1f;
  --text-2: #6e6e73;
  --text-3: #aeaeb2;
  --border: rgba(0, 0, 0, 0.1);
  --green: #1db954;
  --red: #e5484d;
  --orange: #f59300;
  --purple: #8e64d8;
  --gray: #8e8e93;
  --nav-bg: rgba(245, 245, 247, 0.82);
  --danger-bg: rgba(229, 72, 77, 0.08);
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1e1e20;
    --card: rgba(255, 255, 255, 0.06);
    --text: #f2f2f5;
    --text-2: #a1a1a8;
    --text-3: #6e6e76;
    --border: rgba(255, 255, 255, 0.12);
    --green: #2fc466;
    --red: #ff5f57;
    --orange: #ffa416;
    --purple: #a27aea;
    --gray: #98989f;
    --nav-bg: rgba(30, 30, 32, 0.82);
    --danger-bg: rgba(255, 95, 87, 0.12);
  }
}

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

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

.container { max-width: 1080px; margin: 0 auto; padding: 0 24px; }
.mono { font-family: ui-monospace, Menlo, monospace; }

/* ======= 导航 ======= */
.nav {
  position: sticky; top: 0; z-index: 100;
  background: var(--nav-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 60px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text); }
.brand-icon { width: 28px; height: 28px; border-radius: 7px; }
.brand-name { font-size: 17px; font-weight: 700; letter-spacing: -0.2px; }
.nav-links { display: flex; align-items: center; gap: 22px; }
.nav-links a {
  color: var(--text-2); text-decoration: none; font-size: 14px; font-weight: 500;
  transition: color 0.15s;
}
.nav-links a:hover { color: var(--text); }
.nav-github { display: inline-flex; align-items: center; }
.lang-btn {
  border: 1px solid var(--border); background: var(--card); color: var(--text);
  font-size: 13px; font-weight: 600; padding: 5px 12px; border-radius: 999px;
  cursor: pointer; transition: background 0.15s;
}
.lang-btn:hover { background: var(--border); }

/* ======= Hero ======= */
.hero { position: relative; padding: 96px 0 72px; overflow: hidden; }
.hero::before {
  content: ""; position: absolute; top: -120px; left: 50%; transform: translateX(-50%);
  width: 900px; height: 560px; pointer-events: none;
  background: radial-gradient(closest-side, rgba(29, 185, 84, 0.13), transparent 70%);
}
@media (prefers-color-scheme: dark) {
  .hero::before { background: radial-gradient(closest-side, rgba(47, 196, 102, 0.16), transparent 70%); }
}
.hero-inner { position: relative; display: flex; flex-direction: column; align-items: center; text-align: center; }
.hero-icon {
  width: 108px; height: 108px; border-radius: 26px;
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.28);
}
.hero-title { font-size: 56px; font-weight: 800; letter-spacing: -1.5px; margin-top: 28px; }
.hero-tagline {
  font-size: 22px; font-weight: 600; color: var(--green); margin-top: 6px;
}
.hero-sub { max-width: 640px; color: var(--text-2); font-size: 17px; margin-top: 18px; }
.hero-quote {
  margin-top: 16px; color: var(--text-3); font-size: 14px; font-style: italic;
}
.hero-actions { display: flex; gap: 14px; margin-top: 32px; flex-wrap: wrap; justify-content: center; }
.hero-meta { color: var(--text-3); font-size: 13px; margin-top: 16px; }
.hero-install { color: var(--text-3); font-size: 12.5px; margin-top: 6px; }

/* 按钮 */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 24px; border-radius: 999px;
  font-size: 15px; font-weight: 600; text-decoration: none;
  transition: transform 0.12s, filter 0.12s, background 0.12s;
}
.btn:active { transform: scale(0.98); }
.btn-primary { background: var(--green); color: #fff; }
.btn-primary:hover { filter: brightness(1.06); }
.btn-ghost { background: var(--card); color: var(--text); border: 1px solid var(--border); }
.btn-ghost:hover { background: var(--border); }

/* ======= 状态点 / 徽章（与 app 同源） ======= */
.dot { width: 9px; height: 9px; border-radius: 50%; display: inline-block; flex-shrink: 0; }
.dot.green { background: #28cd41; }
.dot.red { background: #ff3b30; }
.dot.orange { background: #ff9500; }
.dot.gray { background: #8e8e93; }
.dot.purple { background: #af52de; }
.dot.lg { width: 14px; height: 14px; }
.dot.hollow { background: transparent; border: 2.5px solid #af52de; width: 12px; height: 12px; }
.dot.pulse { animation: pulse 1.6s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: 0.45; } }

.pill {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 3px 10px; border-radius: 999px;
  font-size: 12px; font-weight: 600; line-height: 1.4;
}
.pill.green { color: var(--green); background: rgba(29, 185, 84, 0.15); }
.pill.red { color: var(--red); background: rgba(255, 59, 48, 0.15); }
.pill.gray { color: var(--gray); background: rgba(142, 142, 147, 0.15); }

/* ======= 面板窗口 mockup（固定深色，拟真截图） ======= */
.mockup {
  width: 100%; max-width: 520px; margin-top: 56px;
  border-radius: 14px; overflow: hidden; text-align: left;
  background: #1e1e20;
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.35), 0 4px 16px rgba(0, 0, 0, 0.22);
  user-select: none;
}
.mock-titlebar {
  display: flex; align-items: center; gap: 7px;
  padding: 11px 14px;
  background: rgba(255, 255, 255, 0.04);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.tl { width: 11px; height: 11px; border-radius: 50%; }
.tl-r { background: #ff5f57; } .tl-y { background: #febc2e; } .tl-g { background: #28c840; }
.mock-title {
  flex: 1; text-align: center; margin-right: 48px;
  color: rgba(255, 255, 255, 0.55); font-size: 12px; font-weight: 600;
}
.mock-body { display: flex; flex-direction: column; gap: 8px; padding: 12px; }
.mock-card {
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 9px; padding: 10px 12px;
  color: #f2f2f5; font-size: 13px;
}
.mock-row { display: flex; align-items: center; gap: 8px; }
.mock-repo { font-weight: 600; }
.mock-status, .mock-time { color: #a1a1a8; font-size: 12px; }
.mock-time { margin-left: auto; }
.chev { color: #6e6e76; flex-shrink: 0; }
.chev.up { transform: rotate(180deg); }
.mock-detail { margin-top: 9px; padding-top: 9px; border-top: 1px solid rgba(255, 255, 255, 0.08); }
.mock-commit { color: #a1a1a8; font-size: 12px; font-family: ui-monospace, Menlo, monospace; }
.mock-checks { margin-top: 5px; font-size: 12px; color: #a1a1a8; }
.ck.red { color: #ff5f57; } .ck.green { color: #2fc466; } .ck.gray { color: #98989f; }
.mock-failbox {
  margin-top: 8px; padding: 9px 10px; border-radius: 8px;
  background: rgba(255, 95, 87, 0.1);
  border: 1px solid rgba(255, 95, 87, 0.18);
}
.mock-job { font-family: ui-monospace, Menlo, monospace; font-size: 12px; color: #ff5f57; font-weight: 600; }
.mock-dur { font-size: 11.5px; color: #a1a1a8; margin-top: 2px; }
.mock-actions { display: flex; gap: 8px; margin-top: 8px; }
.mock-link {
  display: inline-flex; align-items: center; gap: 4px;
  color: #2fc466; font-size: 11.5px; font-weight: 600;
}
.mock-btn {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 2px 9px; border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: #f2f2f5; font-size: 11.5px; font-weight: 600;
}

/* ======= 五态托盘图例 ======= */
.tray-legend {
  display: flex; gap: 28px; flex-wrap: wrap; justify-content: center;
  margin-top: 36px; font-size: 13.5px; color: var(--text-2);
}
.tray-item { display: flex; align-items: center; gap: 8px; }
.tray-caption { color: var(--text-3); font-size: 13px; margin-top: 14px; }

/* ======= Sections ======= */
.section { padding: 84px 0 8px; }
.section h2 { font-size: 32px; font-weight: 700; letter-spacing: -0.6px; text-align: center; }
.section-sub { text-align: center; color: var(--text-2); margin-top: 10px; font-size: 16px; }

.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 44px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin-top: 44px; }

.card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: 14px; padding: 24px;
}
.card h3 { font-size: 16px; font-weight: 700; }
.card p { color: var(--text-2); font-size: 14px; margin-top: 8px; }

.feature { transition: transform 0.15s, background 0.15s; }
.feature:hover { transform: translateY(-3px); background: var(--border); }
.f-icon {
  width: 42px; height: 42px; border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  background: rgba(29, 185, 84, 0.13); color: var(--green);
  margin-bottom: 16px;
}
.f-icon svg { width: 20px; height: 20px; }

.step { position: relative; text-align: left; }
.step-n {
  display: inline-flex; align-items: center; justify-content: center;
  width: 28px; height: 28px; border-radius: 50%;
  background: var(--green); color: #fff;
  font-size: 14px; font-weight: 700; margin-bottom: 12px;
}

.platform { text-align: left; }
.platform .pill { margin-top: 8px; }
.platform p { margin-top: 12px; }

/* ======= Footer ======= */
.footer { margin-top: 96px; padding: 72px 0 40px; border-top: 1px solid var(--border); text-align: center; }
.footer-cta { font-size: 26px; font-weight: 700; letter-spacing: -0.4px; }
.footer .btn-primary { margin-top: 24px; }
.footer-meta { margin-top: 40px; color: var(--text-3); font-size: 13px; }
.footer-meta a { color: var(--text-2); }
.footer-note { margin-top: 6px; font-size: 12px; }

/* ======= 响应式 ======= */
@media (max-width: 880px) {
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .hero-title { font-size: 44px; }
}
@media (max-width: 600px) {
  .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .nav-links a:not(.nav-github) { display: none; }
  .hero { padding-top: 64px; }
  .hero-title { font-size: 38px; }
  .hero-icon { width: 88px; height: 88px; border-radius: 21px; }
  .hero-actions .btn { padding: 11px 18px; font-size: 14px; }
  .tray-legend { gap: 16px; }
  .section { padding-top: 64px; }
}
