/* Homepage layout built on the shared design tokens in /subscription/app.css.
   官网首页布局，复用 /subscription/app.css 中的设计令牌与组件。
   Every row (navigation, hero, sections, call to action, footer) shares one content width (--wrap)
   and side gutter, so left and right edges line up down the whole page.
   导航、首屏、各区块、行动区与页脚共用同一内容宽度（--wrap）与左右留白，整页左右边缘对齐。 */
.home-site { --wrap: 1120px; --gutter: clamp(16px, 4vw, 40px); --band: clamp(48px, 6vw, 80px); background: var(--bg); }
.home-site main#top { position: relative; z-index: 1; }
.site-nav-in, .hero, .band, .final-cta, .site-foot-in { width: min(var(--wrap), calc(100% - 2 * var(--gutter))); margin-inline: auto; }
.band > *, .hero > * { min-width: 0; }

/* ---------- Navigation ---------- */
.site-nav { position: sticky; top: 0; z-index: 40; border-bottom: 1px solid transparent; transition: background .25s, border-color .25s; }
.site-nav.scrolled { background: color-mix(in srgb, var(--bg) 80%, transparent); backdrop-filter: saturate(1.5) blur(16px); border-bottom-color: var(--line); }
.site-nav-in { display: flex; align-items: center; gap: 20px; min-height: 64px; }
.site-nav .brand-text b { font-size: 16px; }
.site-links { display: flex; gap: 2px; margin: 0 auto; }
.site-links a { padding: 7px 12px; border-radius: 9px; color: var(--ink-2); font-weight: 550; font-size: 14px; text-decoration: none; white-space: nowrap; }
.site-links a:hover { background: var(--surface-2); color: var(--ink); text-decoration: none; }
.site-actions { display: flex; align-items: center; gap: 4px; }
.site-actions .btn { min-height: 36px; padding: 6px 12px; font-size: 14px; border-radius: 10px; }
.site-actions .btn.icon-only { width: 36px; padding: 0; }
.site-actions .site-register { margin-left: 4px; padding-inline: 16px; }
.site-menu { display: none !important; }

/* ---------- Hero ---------- */
.hero { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, .92fr); gap: clamp(28px, 5vw, 64px); align-items: center; padding: clamp(36px, 6vw, 80px) 0 clamp(28px, 4vw, 48px); }
.hero-copy { display: grid; gap: 20px; justify-items: start; }
.pill { display: inline-flex; align-items: center; gap: 8px; padding: 5px 12px; border-radius: 99px; border: 1px solid var(--line-2); background: var(--surface); font-size: 12.5px; color: var(--ink-2); text-decoration: none !important; max-width: 100%; }
.pill-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 4px color-mix(in srgb, var(--ok) 20%, transparent); flex: none; }
.hero h1 { font-size: clamp(32px, 4.6vw, 54px); line-height: 1.14; letter-spacing: -.025em; text-wrap: balance; }
.grad-text { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.lead { font-size: clamp(15.5px, 1.4vw, 17.5px); line-height: 1.7; color: var(--ink-2); max-width: 34em; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 10px; }
.hero-cta .btn { min-height: 46px; padding-inline: 22px; font-size: 15px; }
.hero-proof { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 6px 18px; color: var(--muted); font-size: 13px; }
.hero-proof li::before { content: "✓"; color: var(--ok); font-weight: 700; margin-right: 6px; }

.demo { border-radius: var(--r-xl); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-lg); overflow: hidden; min-height: 320px; display: flex; flex-direction: column; }
.demo-bar { display: flex; align-items: center; gap: 6px; padding: 11px 16px; border-bottom: 1px solid var(--line); background: var(--surface-2); font-size: 12.5px; color: var(--muted); }
.demo-bar i { width: 10px; height: 10px; border-radius: 50%; background: var(--line-2); } .demo-bar i:nth-child(1) { background: #ff5f57; } .demo-bar i:nth-child(2) { background: #febc2e; } .demo-bar i:nth-child(3) { background: #28c840; }
.demo-bar span { margin-left: 8px; font-weight: 600; }
.demo-body { flex: 1; display: grid; align-content: start; gap: 14px; padding: 20px; }
.msg { max-width: 92%; padding: 11px 14px; border-radius: 16px; font-size: 14px; line-height: 1.6; min-height: 44px; }
.msg.me { justify-self: end; background: var(--grad); color: #fff; border-bottom-right-radius: 6px; }
.msg.ai { display: flex; gap: 10px; background: var(--surface-2); border: 1px solid var(--line); border-bottom-left-radius: 6px; }
.msg.ai > div { min-width: 0; display: grid; gap: 10px; }
.ai-badge { width: 26px; height: 26px; border-radius: 9px; background: var(--grad); flex: none; }
.demo-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.demo-chip { font-size: 12px; font-weight: 600; padding: 4px 10px; border-radius: 99px; background: var(--surface); border: 1px solid var(--line-2); animation: pop .3s var(--ease); }

/* ---------- Sections ---------- */
.band { display: grid; gap: clamp(22px, 3vw, 36px); padding: var(--band) 0 0; scroll-margin-top: 72px; }
.band-head { display: grid; gap: 8px; text-align: center; justify-items: center; max-width: 680px; margin: 0 auto; }
.band-head h2 { font-size: clamp(24px, 3vw, 34px); line-height: 1.25; letter-spacing: -.02em; text-wrap: balance; }
.band-head p { color: var(--muted); font-size: 15px; }
.eyebrow-dark { font-size: 12px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--brand); }

.feature-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.feature { display: grid; grid-template-columns: 40px minmax(0, 1fr); column-gap: 14px; row-gap: 4px; align-content: start; padding: 20px; border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); transition: transform .25s var(--ease), border-color .25s; }
.feature:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--brand) 40%, var(--line)); }
.feature > .f-icon { grid-row: 1 / span 2; }
.feature h3 { font-size: 16px; line-height: 1.4; }
.feature p { color: var(--muted); font-size: 14px; line-height: 1.6; }
.f-icon { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--grad-soft); color: var(--brand); }
.f-icon .ic { width: 20px; height: 20px; }

/* Steps read as one connected sequence. 步骤以连线串成一组。 */
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.steps li { position: relative; display: grid; grid-template-columns: 36px minmax(0, 1fr); column-gap: 14px; row-gap: 4px; align-content: start; padding: 20px; border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--line); }
.steps li:not(:last-child)::after { content: ""; position: absolute; top: 38px; right: -17px; width: 18px; height: 2px; background: var(--grad); opacity: .5; }
.steps b { grid-row: 1 / span 2; width: 36px; height: 36px; border-radius: 11px; background: var(--grad); color: #fff; display: grid; place-items: center; font-size: 15px; }
.steps h3 { font-size: 16px; line-height: 1.4; }
.steps p { color: var(--muted); font-size: 14px; line-height: 1.6; }

/* Plans and hour packs. 套餐与小时包。 */
.home-plans { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); gap: 16px; }
.home-plan { display: grid; gap: 14px; align-content: start; padding: 24px; border-radius: var(--r-xl); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); }
.home-plan.featured { border: 1.5px solid transparent; background: linear-gradient(var(--surface), var(--surface)) padding-box, var(--grad) border-box; box-shadow: var(--shadow-lg); }
.home-plan .plan-top { min-height: 28px; align-items: center; }
.home-plan .plan-top h3 { font-size: 16px; }
.home-plan .btn { margin-top: auto; }
.storefront-price-note { text-align: center; font-size: 13px; color: var(--muted); margin-top: -8px; }
.storefront-pack-list { display: grid; gap: 14px; margin-top: 8px; padding: 22px; border-radius: var(--r-xl); background: color-mix(in srgb, var(--surface) 60%, transparent); border: 1px dashed var(--line-2); }
.storefront-pack-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 16px; }
.storefront-pack-head h3 { font-size: 17px; }
.storefront-pack-head p { font-size: 13.5px; color: var(--muted); }
.home-packs { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.home-pack { display: grid; gap: 6px; align-content: start; padding: 14px 16px; border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--line); }
.home-pack h4 { font-size: 13px; font-weight: 650; color: var(--muted); }
.home-pack .plan-price { flex-wrap: nowrap; gap: 8px; }
.home-pack .plan-price .price { font-size: clamp(19px, 2vw, 22px); white-space: nowrap; }
.home-pack .plan-price s { white-space: nowrap; }

/* FAQ: heading on the left, questions on the right on wide screens. 常见问题：宽屏左侧标题，右侧问题列表。 */
.faq { display: grid; gap: 10px; width: 100%; }
.faq details { padding: 0 18px; border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--line); }
.faq summary { cursor: pointer; padding: 15px 0; font-weight: 650; font-size: 15px; list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.faq summary::after { content: "+"; font-size: 20px; line-height: 1; color: var(--muted); transition: transform .2s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq summary::-webkit-details-marker { display: none; }
.faq p { padding: 0 0 16px; color: var(--ink-2); font-size: 14.5px; line-height: 1.7; }
@media (min-width: 900px) {
  .band-split { grid-template-columns: minmax(0, 1fr) minmax(0, 1.9fr); align-items: start; gap: 48px; }
  .band-split .band-head { text-align: left; justify-items: start; margin: 0; position: sticky; top: 96px; }
}

/* ---------- Call to action ---------- */
.final-cta { margin-top: var(--band); padding: clamp(32px, 5vw, 52px) clamp(20px, 4vw, 48px); border-radius: var(--r-xl); text-align: center; display: grid; gap: 20px; justify-items: center; color: #fff; background: radial-gradient(120% 140% at 100% 0%, #19c3e6, transparent 46%), radial-gradient(120% 120% at 0% 100%, #7c5cff, transparent 55%), #1b1f4b; box-shadow: var(--shadow-lg); }
.final-cta h2 { font-size: clamp(22px, 2.8vw, 30px); text-wrap: balance; }
.final-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.final-actions .btn { min-height: 46px; padding-inline: 24px; font-size: 15px; }
.final-primary { background: #fff; color: #1b1f4b; border-color: transparent; }
.final-primary:hover { background: #eef1ff; border-color: transparent; }

/* ---------- Footer ---------- */
.site-foot { position: relative; z-index: 1; margin-top: var(--band); border-top: 1px solid var(--line); background: color-mix(in srgb, var(--surface) 55%, transparent); }
.site-foot-in { display: grid; grid-template-columns: minmax(0, 1.4fr) repeat(2, minmax(0, .7fr)) minmax(0, 1.2fr); gap: 28px 32px; padding: 36px 0 28px; }
.foot-brand { display: grid; gap: 12px; align-content: start; }
.foot-brand p { max-width: 26em; font-size: 12.5px; line-height: 1.6; color: var(--faint); }
.foot-col { display: grid; gap: 8px; align-content: start; font-size: 13.5px; }
.foot-col h4 { margin: 0 0 4px; font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.foot-col a { color: var(--ink-2); text-decoration: none; }
.foot-col a:hover { color: var(--brand); text-decoration: none; }
.foot-bottom { grid-column: 1 / -1; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 24px; padding-top: 20px; border-top: 1px solid var(--line); font-size: 12.5px; color: var(--faint); }

[data-reveal] { opacity: 0; transform: translateY(14px); transition: opacity .6s var(--ease) var(--d, 0ms), transform .6s var(--ease) var(--d, 0ms); }
[data-reveal].shown { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .site-links a { padding-inline: 9px; font-size: 13.5px; }
  .site-foot-in { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .foot-brand { grid-column: 1 / -1; }
}
@media (max-width: 980px) {
  .hero { grid-template-columns: minmax(0, 1fr); }
  .feature-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .steps { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .steps li:not(:last-child)::after { top: auto; bottom: -13px; right: auto; left: 37px; width: 2px; height: 14px; }
}
@media (max-width: 860px) {
  .site-nav { background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(14px); }
  .site-nav-in { flex-wrap: wrap; gap: 8px; min-height: 56px; }
  .site-links { display: none; order: 3; width: 100%; flex-direction: column; margin: 0; padding: 4px 0 10px; }
  .site-nav.open .site-links { display: flex; }
  .site-links a { padding: 11px 12px; font-size: 15px; }
  .site-actions { margin-left: auto; }
  .site-menu { display: inline-flex !important; }
  .site-login { display: none; }
  .site-actions .lang-btn .lang-name { display: none; }
}
@media (max-width: 640px) {
  .home-site { --band: 44px; }
  .hero { padding-top: 24px; }
  .hero-cta { justify-self: stretch; }
  .hero-cta .btn { flex: 1 1 0; padding-inline: 12px; white-space: nowrap; }
  .demo { min-height: 260px; }
  .feature-grid, .feature-grid.three { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .feature { padding: 16px; }
  .feature:hover { transform: none; }
  .home-packs { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .storefront-pack-list { padding: 16px; }
  .site-foot-in { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px 16px; padding-top: 28px; }
  .foot-policies { grid-column: 1 / -1; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 16px; }
  .foot-policies h4 { grid-column: 1 / -1; }
  .foot-bottom { flex-direction: column; }
}
