
/*
 * 课本库 · 网站首页 —— 静态还原
 * 设计源：Ardot「课本库 · 网站首页设计」/ 画布 1440 × 2716 / 根帧 2:1
 * 所有颜色、字号、行高、圆角、gap、padding 均取自设计文件的节点读取结果。
 * 设计标注 AUTO 的行高，按该文本节点在设计稿中的实际盒高落地（可追溯到 absoluteBoundingBox）。
 */
@font-face {
  font-family: 'Noto Sans SC';
  src: url('./assets/fonts/noto-sans-sc-variable.woff2') format('woff2');
  font-style: normal;
  font-weight: 100 900; /* 设计用 Regular / Medium / SemiBold → 400 / 500 / 600 */
  font-display: swap;
}
@font-face {
  font-family: 'Noto Serif SC';
  src: url('./assets/fonts/noto-serif-sc-700.woff2') format('woff2');
  font-style: normal;
  font-weight: 700;
  font-display: swap;
}
@font-face {
  font-family: 'Geist Mono';
  src: url('./assets/fonts/geist-mono-500.woff2') format('woff2');
  font-style: normal;
  font-weight: 500;
  font-display: swap;
}

:root {
  /* 纸底 / 墨色 / 朱红：来自各节点的 fills[0].color */
  --paper:        #F7F4EC;
  --paper-alt:    #FBF8F1;
  --paper-footer: #F2EEE4;
  --ink:          #1C1B19;
  --ink-2:        #6B675E;
  --ink-3:        #8C8578;
  --red:          #B4462F;
  --red-light:    #D9785F;
  --btn-ink:      #FFFDF8;
  --cta-muted:    #A9A397;
  --cta-ghost:    #D8D2C4;
  --line:         #E3DDD0;
  --line-soft:    #D9D2C4;
  --line-footer:  #DDD6C7;

  --font-sans:  'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  --font-serif: 'Noto Serif SC', 'Songti SC', 'SimSun', serif;
  --font-mono:  'Geist Mono', 'SFMono-Regular', Menlo, monospace;
}

/* ---- reset：显式重设，避免浏览器默认样式覆盖设计值 ---- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-sans);
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, p { margin: 0; font-weight: inherit; font-size: inherit; }
img { display: block; }
a { color: inherit; text-decoration: none; }
a:focus-visible { outline: 2px solid var(--red); outline-offset: 3px; }
.page { width: 100%; max-width: 1440px; margin: 0 auto; }

/* ---- 2:2 顶部导航（88px / padding 0 120 / space-between） ---- */
.site-header {
  height: 88px;
  padding: 0 120px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--paper);
}
.brand { display: flex; align-items: center; gap: 12px; }
.brand-icon { width: 26px; height: 26px; flex: none; }
.brand-name {
  font-family: var(--font-serif); font-weight: 700; font-size: 22px; line-height: 32px;
  color: var(--ink); white-space: nowrap;
}
.brand-en {
  font-family: var(--font-mono); font-weight: 500; font-size: 9px; line-height: 12px;
  color: var(--ink-3); white-space: nowrap;
}
.nav-links { display: flex; align-items: center; gap: 36px; }
.nav-links a { font-size: 14px; line-height: 20px; font-weight: 400; color: var(--ink); white-space: nowrap; }
.header-actions { display: flex; align-items: center; gap: 24px; }
.header-actions .login { font-size: 14px; line-height: 20px; color: var(--ink); white-space: nowrap; }

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  border: 0; border-radius: 3px; background: var(--red); color: var(--btn-ink);
  font-weight: 500; white-space: nowrap; cursor: pointer;
  transition: opacity .18s ease;
}
.btn:hover { opacity: .9; }
.btn-header  { height: 44px; padding: 0 22px; font-size: 14px; line-height: 20px; }
.btn-primary { height: 54px; padding: 0 30px; font-size: 16px; line-height: 23px; }
.btn-cta     { height: 52px; padding: 0 28px; font-size: 16px; line-height: 23px; }

.header-divider { height: 1px; background: var(--line); }

/* ---- 2:19 主视觉 Hero（padding 96/120/88/120 · gap 80 · center） ---- */
.hero {
  display: flex; align-items: center; gap: 80px;
  padding: 96px 120px 88px; background: var(--paper);
}
.hero-copy { flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: flex-start; gap: 28px; }
.eyebrow { display: flex; align-items: center; gap: 12px; }
.eyebrow-line { width: 28px; height: 2px; background: var(--red); flex: none; }
.eyebrow-text {
  font-size: 12px; line-height: 17px; font-weight: 500; color: var(--red); white-space: pre-wrap;
}
.hero-title {
  font-family: var(--font-serif); font-weight: 700; font-size: 60px; line-height: 82px;
  color: var(--ink);
}
.hero-sub { width: 460px; max-width: 100%; font-size: 17px; line-height: 30px; color: var(--ink-2); }
.hero-actions { display: flex; align-items: center; gap: 28px; }
.text-link { display: inline-flex; align-items: center; gap: 8px; font-size: 15px; line-height: 22px; color: var(--ink); }
.text-link .arrow { width: 16px; height: 16px; flex: none; }
.trust-row { display: flex; align-items: center; gap: 16px; }
.trust-row span { font-size: 13px; line-height: 19px; color: var(--ink-3); }
.trust-sep { width: 1px; height: 14px; background: var(--line-soft); flex: none; }

.hero-visual { flex: 0 0 520px; display: flex; flex-direction: column; gap: 16px; }
.hero-image { width: 520px; height: 520px; border-radius: 2px; object-fit: cover; }
.caption { display: flex; align-items: center; gap: 12px; }
.caption-line { width: 20px; height: 1px; background: var(--red); flex: none; }
.caption-text { font-size: 12px; line-height: 17px; color: var(--ink-3); white-space: pre-wrap; }

/* ---- 2:44 常见问题 FAQ（padding 104/120 · gap 100） ---- */
.faq {
  display: flex; align-items: flex-start; gap: 100px;
  padding: 104px 120px; background: var(--paper-alt);
}
.faq-intro { flex: 0 0 360px; display: flex; flex-direction: column; gap: 24px; }
.faq-kicker { font-size: 12px; line-height: 17px; font-weight: 500; color: var(--red); }
.faq-title {
  font-family: var(--font-serif); font-weight: 700; font-size: 38px; line-height: 56px;
  color: var(--ink);
}
.faq-desc { font-size: 14px; line-height: 24px; color: var(--ink-3); }
.faq-list { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 0; }
.faq-item { display: flex; flex-direction: column; gap: 12px; padding: 26px 0; }
.faq-q { font-size: 18px; line-height: 26px; font-weight: 600; color: var(--ink); }
.faq-a { font-size: 15px; line-height: 28px; color: var(--ink-2); }
.faq-divider { height: 1px; background: var(--line); }

/* ---- 2:69 结尾行动号召（padding 88/120 · gap 60 · center） ---- */
.cta {
  display: flex; align-items: center; gap: 60px;
  padding: 88px 120px; background: var(--ink);
}
.cta-copy { flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: flex-start; gap: 26px; }
.cta-kicker { font-size: 12px; line-height: 17px; font-weight: 500; color: var(--red-light); }
.cta-title {
  font-family: var(--font-serif); font-weight: 700; font-size: 44px; line-height: 62px;
  color: var(--paper);
}
.cta-desc { font-size: 15px; line-height: 22px; color: var(--cta-muted); }
.cta-actions { display: flex; align-items: center; gap: 28px; }
.cta-ghost { font-size: 15px; line-height: 22px; color: var(--cta-ghost); }
.cta-decor {
  flex: 0 0 340px; text-align: center;
  font-family: var(--font-serif); font-weight: 700; font-size: 148px; line-height: 213px;
  color: rgba(247, 245, 237, .09); /* 设计 fills[0] #F7F5ED @ opacity .09 */
  pointer-events: none; user-select: none;
}

/* ---- 2:79 页脚（padding 64/120/32 · gap 40） ---- */
.site-footer {
  display: flex; flex-direction: column; gap: 40px;
  padding: 64px 120px 32px; background: var(--paper-footer);
}
.footer-top { display: flex; align-items: flex-start; gap: 80px; }
.footer-brand { flex: 0 0 360px; display: flex; flex-direction: column; gap: 14px; }
.footer-brand-name {
  font-family: var(--font-serif); font-weight: 700; font-size: 26px; line-height: 37px; color: var(--ink);
}
.footer-tagline { font-size: 14px; line-height: 24px; color: var(--ink-2); }
.footer-col { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 14px; }
.footer-col .col-title { font-size: 12px; line-height: 17px; font-weight: 500; color: var(--ink-3); }
.footer-col a { font-size: 14px; line-height: 20px; color: var(--ink); white-space: nowrap; }
.footer-watermark {
  text-align: center; font-family: var(--font-serif); font-weight: 700;
  font-size: 132px; line-height: 190px;
  color: rgba(28, 28, 26, .06); /* 设计 fills[0] #1C1C1A @ opacity .06 */
  pointer-events: none; user-select: none;
}
.footer-divider { height: 1px; background: var(--line-footer); }
.footer-bottom { display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.footer-bottom span { font-size: 12px; line-height: 17px; color: var(--ink-3); white-space: pre-wrap; }

/* 交互态：设计稿未定义 hover，采用已有 token 或透明度，不引入新色值 */
.nav-links a:hover, .header-actions .login:hover,
.text-link:hover, .cta-ghost:hover, .footer-col a:hover { color: var(--red); }
.cta-ghost:hover { color: var(--red-light); }

/* ---- 响应式重排：用户确认的窄屏策略，桌面 1440 保持设计稿 1:1 ---- */
@media (max-width: 1439px) {
  .site-header { padding: 0 64px; }
  .hero { padding: 80px 64px 72px; gap: 48px; }
  .hero-visual { flex: 0 0 min(42vw, 520px); }
  .hero-image { width: 100%; height: auto; aspect-ratio: 1 / 1; }
  .faq { padding: 88px 64px; gap: 60px; }
  .cta { padding: 80px 64px; gap: 40px; }
  .site-footer { padding: 56px 64px 32px; }
  .footer-top { gap: 48px; }
}
@media (max-width: 1023px) {
  .site-header { height: auto; min-height: 88px; flex-wrap: wrap; gap: 16px 32px; padding: 20px 32px; }
  .hero { flex-direction: column; align-items: flex-start; gap: 48px; padding: 64px 32px; }
  .hero-copy { width: 100%; }
  .hero-visual { flex: none; width: 100%; max-width: 520px; }
  .faq { flex-direction: column; gap: 48px; padding: 72px 32px; }
  .faq-intro, .faq-list { flex: none; width: 100%; }
  .cta { flex-direction: column; align-items: flex-start; gap: 32px; padding: 72px 32px; }
  .cta-decor { flex: none; width: 100%; max-width: 340px; align-self: flex-end; font-size: 96px; line-height: 1.44; }
  .site-footer { padding: 56px 32px 32px; }
  .footer-top { flex-wrap: wrap; gap: 40px 48px; }
  .footer-brand { flex: 0 0 100%; }
  .footer-col { flex: 0 0 calc(33.333% - 32px); }
  .footer-watermark { font-size: clamp(64px, 12vw, 132px); line-height: 1.44; }
}
@media (max-width: 767px) {
  .site-header { padding: 20px 24px; }
  .hero { padding: 48px 24px; gap: 36px; }
  .hero-title { font-size: clamp(34px, 9vw, 60px); line-height: 1.37; }
  .hero-sub { width: 100%; font-size: 16px; line-height: 28px; }
  .hero-actions { flex-wrap: wrap; gap: 20px; }
  .trust-row { flex-wrap: wrap; gap: 12px; }
  .trust-row .trust-sep { display: none; } /* 窄屏换行后避免分隔符落在行尾 */
  .faq { padding: 56px 24px; gap: 36px; }
  .faq-title { font-size: 32px; line-height: 46px; }
  .faq-item { padding: 22px 0; }
  .cta { padding: 56px 24px; }
  .cta-title { font-size: clamp(32px, 8vw, 44px); line-height: 1.41; }
  .cta-decor { font-size: 72px; }
  .site-footer { padding: 48px 24px 28px; gap: 32px; }
  .footer-top { gap: 32px 24px; }
  .footer-col { flex: 0 0 calc(50% - 12px); }
  .footer-watermark { font-size: clamp(52px, 14vw, 132px); }
  .footer-bottom { flex-direction: column; align-items: flex-start; gap: 8px; }
}
@media (max-width: 480px) {
  .nav-links { gap: 20px; }
  .nav-links a { font-size: 13px; }
  .header-actions { gap: 16px; }
  .footer-col { flex: 0 0 100%; }
}
