/* ============================================================
   潮心者 chaoxinzhe.com · Design System
   美学方向: Editorial + Cinematic
   核心: 作家的字句 × 导演的画面
   ============================================================ */

/* ---------- Fonts ---------- */
@import url('https://fonts.googleapis.com/css2?family=Fraunces:ital,opsz,wght@0,9..144,300;0,9..144,400;0,9..144,500;0,9..144,600;0,9..144,700;1,9..144,400;1,9..144,500&family=Inter:wght@400;500;600&display=swap');

/* ---------- Design Tokens ---------- */
:root {
  /* Color · 取自旧书与电影海报 */
  --ink:        #1B1F3B;    /* 深墨蓝 - 主色 */
  --ink-soft:   #2A2F52;
  --ember:      #C75D2D;    /* 暖橙红 - 强调 */
  --ember-soft: #E07A4A;
  --moss:       #4A6741;    /* 深绿 - 自然平静 */
  --gold:       #B8893A;    /* 古铜金 - 章节强调 */

  --paper:      #FAF8F3;    /* 旧纸暖白 */
  --cream:      #F5F1E8;    /* 米白 */
  --linen:      #EBE5D5;    /* 亚麻 */
  --char:       #2A2A2A;    /* 炭灰文字 */
  --mist:       #8A8478;    /* 暖灰次文字 */
  --whisper:    #C9C2B2;    /* 极浅边线 */

  /* Type */
  --font-display: 'Fraunces', 'Songti SC', 'Source Han Serif SC', 'Noto Serif CJK SC', 'STSong', serif;
  --font-body: 'Inter', -apple-system, 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
  --font-mono: 'Fraunces', 'Songti SC', serif;

  /* Sizes */
  --text-xs:   0.75rem;   /* 12px */
  --text-sm:   0.875rem;  /* 14px */
  --text-base: 1rem;      /* 16px */
  --text-lg:   1.125rem;  /* 18px */
  --text-xl:   1.375rem;  /* 22px */
  --text-2xl:  1.75rem;   /* 28px */
  --text-3xl:  2.5rem;    /* 40px */
  --text-4xl:  3.5rem;    /* 56px */
  --text-5xl:  5rem;      /* 80px */
  --text-6xl:  7rem;      /* 112px */

  /* Spacing */
  --s-1: 0.25rem;
  --s-2: 0.5rem;
  --s-3: 0.75rem;
  --s-4: 1rem;
  --s-5: 1.5rem;
  --s-6: 2rem;
  --s-7: 3rem;
  --s-8: 4rem;
  --s-9: 6rem;
  --s-10: 8rem;
  --s-11: 12rem;

  /* Layout */
  --max-width: 1280px;
  --content-width: 920px;
  --reading-width: 680px;

  /* Misc */
  --hairline: 1px solid var(--whisper);
  --bold-line: 2px solid var(--ink);
  --transition: 400ms cubic-bezier(0.2, 0, 0, 1);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-body);
  font-size: var(--text-base);
  font-weight: 400;
  line-height: 1.6;
  color: var(--char);
  background: var(--paper);
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img, svg, video { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; transition: var(--transition); }
button { font: inherit; cursor: pointer; border: none; background: none; }

/* ---------- Typography ---------- */
.font-display { font-family: var(--font-display); font-weight: 400; letter-spacing: -0.02em; }
.font-italic { font-family: var(--font-display); font-style: italic; }
.font-body { font-family: var(--font-body); }

h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 500; letter-spacing: -0.02em; line-height: 1.1; color: var(--ink); }
h1 { font-size: var(--text-5xl); }
h2 { font-size: var(--text-4xl); }
h3 { font-size: var(--text-2xl); }

p { max-width: var(--reading-width); }

.eyebrow {
  font-family: var(--font-display);
  font-style: italic;
  font-size: var(--text-sm);
  color: var(--ember);
  letter-spacing: 0.05em;
}

.serial {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 400;
  font-size: var(--text-lg);
  color: var(--mist);
  letter-spacing: 0.05em;
}

.kicker {
  display: inline-block;
  font-family: var(--font-body);
  font-size: var(--text-xs);
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink);
  padding-bottom: var(--s-2);
  border-bottom: var(--bold-line);
}

.lede {
  font-family: var(--font-display);
  font-size: var(--text-xl);
  line-height: 1.5;
  color: var(--ink);
  font-weight: 400;
}

.lede em, .lede i {
  color: var(--ember);
  font-style: italic;
}

.dropcap::first-letter {
  font-family: var(--font-display);
  float: left;
  font-size: 5.5em;
  line-height: 0.8;
  margin: 0.05em 0.08em 0 -0.05em;
  font-weight: 600;
  color: var(--ember);
}

/* ---------- Layout ---------- */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--s-6);
}

.content-narrow {
  max-width: var(--content-width);
  margin: 0 auto;
}

.reading {
  max-width: var(--reading-width);
  margin: 0 auto;
}

section { padding: var(--s-10) 0; }

/* ---------- Navigation ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(250, 248, 243, 0.92);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: var(--hairline);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--s-6);
}

.brand {
  display: flex;
  align-items: baseline;
  gap: var(--s-3);
  font-family: var(--font-display);
  color: var(--ink);
}
.brand-mark {
  font-size: var(--text-2xl);
  font-weight: 600;
  letter-spacing: -0.02em;
}
.brand-tag {
  font-size: var(--text-xs);
  font-style: italic;
  color: var(--mist);
  letter-spacing: 0.1em;
}

.nav-menu {
  display: flex;
  gap: var(--s-7);
  align-items: center;
}
.nav-menu a {
  font-size: var(--text-sm);
  color: var(--char);
  position: relative;
  padding: var(--s-2) 0;
  letter-spacing: 0.02em;
}
.nav-menu a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--ink);
  transition: var(--transition);
}
.nav-menu a:hover::after { width: 100%; }
.nav-menu a.active { color: var(--ember); font-style: italic; font-family: var(--font-display); }

.nav-cta {
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--paper);
  background: var(--ink);
  padding: var(--s-3) var(--s-5);
  border-radius: 999px;
  transition: var(--transition);
}
.nav-cta:hover { background: var(--ember); }

.nav-mobile-toggle { display: none; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 90vh;
  display: flex;
  align-items: center;
  padding: var(--s-11) 0 var(--s-10);
  overflow: hidden;
}

.hero-grain {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.4;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
  mix-blend-mode: multiply;
}

.hero-content {
  position: relative;
  z-index: 1;
}

.hero h1 {
  font-size: clamp(2.5rem, 7vw, 6rem);
  line-height: 0.95;
  font-weight: 400;
  letter-spacing: -0.03em;
  margin-bottom: var(--s-6);
}

.hero h1 .em {
  font-style: italic;
  color: var(--ember);
  font-weight: 400;
}

.hero h1 .underline {
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 0.12em;
  text-decoration-color: var(--gold);
}

.hero-meta {
  display: flex;
  align-items: center;
  gap: var(--s-5);
  margin-bottom: var(--s-7);
  font-family: var(--font-display);
  font-style: italic;
  font-size: var(--text-sm);
  color: var(--mist);
}
.hero-meta span:not(:last-child)::after {
  content: '·';
  margin-left: var(--s-5);
  color: var(--whisper);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--s-3);
  padding: var(--s-4) var(--s-6);
  font-family: var(--font-body);
  font-size: var(--text-base);
  font-weight: 500;
  letter-spacing: 0.02em;
  border-radius: 999px;
  transition: var(--transition);
  cursor: pointer;
}
.btn-primary {
  background: var(--ink);
  color: var(--paper);
}
.btn-primary:hover {
  background: var(--ember);
  transform: translateY(-2px);
}
.btn-outline {
  background: transparent;
  color: var(--ink);
  box-shadow: inset 0 0 0 1px var(--ink);
}
.btn-outline:hover {
  background: var(--ink);
  color: var(--paper);
}
.btn-arrow {
  display: inline-flex;
  align-items: center;
  gap: var(--s-3);
  font-family: var(--font-display);
  font-style: italic;
  font-size: var(--text-base);
  color: var(--ink);
  padding-bottom: 2px;
  border-bottom: 1px solid var(--ink);
  transition: var(--transition);
}
.btn-arrow:hover { color: var(--ember); border-color: var(--ember); transform: translateX(4px); }
.btn-arrow::after { content: '→'; transition: var(--transition); }
.btn-arrow:hover::after { transform: translateX(4px); }

/* ---------- Section Headers ---------- */
.section-header {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: var(--s-7);
  align-items: baseline;
  margin-bottom: var(--s-8);
  padding-bottom: var(--s-5);
  border-bottom: var(--hairline);
}

.section-number {
  font-family: var(--font-display);
  font-style: italic;
  font-size: var(--text-3xl);
  color: var(--ember);
  font-weight: 300;
  letter-spacing: -0.02em;
}

.section-title h2 { margin-bottom: var(--s-3); }

.section-title .sub {
  font-family: var(--font-display);
  font-style: italic;
  color: var(--mist);
  font-size: var(--text-lg);
}

/* ---------- Cards ---------- */
.card {
  background: var(--paper);
  padding: var(--s-7);
  border: 1px solid var(--whisper);
  transition: var(--transition);
  position: relative;
}
.card:hover {
  border-color: var(--ink);
  transform: translateY(-4px);
}
.card-num {
  font-family: var(--font-display);
  font-style: italic;
  color: var(--ember);
  font-size: var(--text-2xl);
  font-weight: 400;
  margin-bottom: var(--s-5);
  display: block;
}
.card h3 {
  font-size: var(--text-xl);
  margin-bottom: var(--s-4);
}

/* ---------- Stats ---------- */
.stat {
  border-top: var(--bold-line);
  padding-top: var(--s-5);
}
.stat-num {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 400;
  line-height: 1;
  color: var(--ink);
  letter-spacing: -0.03em;
  font-feature-settings: "tnum" on;
}
.stat-num .em { font-style: italic; color: var(--ember); }
.stat-label {
  font-family: var(--font-display);
  font-style: italic;
  font-size: var(--text-sm);
  color: var(--mist);
  margin-top: var(--s-3);
}

/* ---------- Audience Cards (Homepage) ---------- */
.audience-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  border-top: var(--bold-line);
  border-bottom: var(--bold-line);
}
.audience-card {
  padding: var(--s-7) var(--s-5);
  border-right: var(--hairline);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  position: relative;
  cursor: pointer;
  color: inherit;
}
.audience-card:last-child { border-right: none; }
.audience-card:hover { background: var(--cream); }
.audience-card:hover .audience-arrow { transform: translateX(8px); color: var(--ember); }
.audience-icon {
  font-family: var(--font-display);
  font-style: italic;
  color: var(--ember);
  font-size: var(--text-xl);
}
.audience-card h3 {
  font-size: var(--text-xl);
  margin-bottom: 0;
}
.audience-card p {
  font-size: var(--text-sm);
  color: var(--mist);
  margin-bottom: var(--s-5);
}
.audience-arrow {
  font-family: var(--font-display);
  font-style: italic;
  color: var(--ink);
  margin-top: auto;
  transition: var(--transition);
}

/* ---------- Quote ---------- */
.quote {
  position: relative;
  font-family: var(--font-display);
  font-size: var(--text-2xl);
  line-height: 1.4;
  color: var(--ink);
  font-style: italic;
  font-weight: 400;
  padding-left: var(--s-7);
  max-width: 720px;
}
.quote::before {
  content: '"';
  position: absolute;
  left: 0;
  top: -0.2em;
  font-family: var(--font-display);
  font-size: 4em;
  line-height: 1;
  color: var(--ember);
  font-style: normal;
  font-weight: 300;
}
.quote-author {
  display: block;
  margin-top: var(--s-5);
  font-family: var(--font-body);
  font-style: normal;
  font-size: var(--text-sm);
  color: var(--mist);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

/* ---------- Filmstrip ---------- */
.filmstrip {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: var(--s-3);
  margin-top: var(--s-7);
}
.filmstrip-step {
  text-align: center;
  position: relative;
}
.filmstrip-step::after {
  content: '';
  position: absolute;
  top: 28px;
  right: -20%;
  width: 40%;
  height: 1px;
  background: var(--whisper);
}
.filmstrip-step:last-child::after { display: none; }
.filmstrip-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--paper);
  border: 1px solid var(--ink);
  font-family: var(--font-display);
  font-style: italic;
  font-size: var(--text-xl);
  color: var(--ink);
  margin-bottom: var(--s-4);
  position: relative;
  z-index: 1;
}
.filmstrip-step h4 {
  font-family: var(--font-display);
  font-size: var(--text-lg);
  margin-bottom: var(--s-2);
}
.filmstrip-step p {
  font-size: var(--text-sm);
  color: var(--mist);
  margin: 0 auto;
}

/* ---------- Comparison Table ---------- */
.compare-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: var(--s-6);
  font-size: var(--text-sm);
}
.compare-table th, .compare-table td {
  padding: var(--s-4) var(--s-5);
  text-align: left;
  border-bottom: var(--hairline);
}
.compare-table th {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: var(--text-base);
  color: var(--ink);
  background: var(--cream);
}
.compare-table th.highlight { color: var(--ember); }
.compare-table td.highlight {
  color: var(--ink);
  font-weight: 500;
  background: rgba(199, 93, 45, 0.05);
}
.compare-table tr:hover td { background: var(--cream); }

/* ---------- Tabs ---------- */
.tabs {
  display: flex;
  gap: 0;
  border-bottom: var(--hairline);
  margin-bottom: var(--s-8);
  overflow-x: auto;
}
.tab {
  padding: var(--s-5) var(--s-6);
  font-family: var(--font-display);
  font-size: var(--text-lg);
  color: var(--mist);
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  transition: var(--transition);
  white-space: nowrap;
  cursor: pointer;
  background: none;
}
.tab .num {
  font-style: italic;
  color: var(--ember);
  margin-right: var(--s-3);
  font-size: var(--text-base);
}
.tab:hover { color: var(--ink); }
.tab.active {
  color: var(--ink);
  border-bottom-color: var(--ink);
  font-weight: 500;
}
.tab-panel { display: none; }
.tab-panel.active { display: block; animation: fadeIn 600ms cubic-bezier(0.2, 0, 0, 1); }

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ---------- Footer ---------- */
.footer {
  background: var(--ink);
  color: var(--cream);
  padding: var(--s-9) 0 var(--s-6);
  margin-top: var(--s-10);
}
.footer a { color: var(--cream); opacity: 0.7; }
.footer a:hover { opacity: 1; color: var(--ember-soft); }

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: var(--s-7);
  padding-bottom: var(--s-7);
  border-bottom: 1px solid rgba(245, 241, 232, 0.15);
}
.footer-brand {
  font-family: var(--font-display);
}
.footer-brand .mark {
  font-size: var(--text-3xl);
  font-weight: 600;
  letter-spacing: -0.02em;
  display: block;
  margin-bottom: var(--s-3);
}
.footer-brand .tag {
  font-style: italic;
  color: var(--ember-soft);
  font-size: var(--text-base);
  margin-bottom: var(--s-5);
  display: block;
}
.footer-brand p {
  font-size: var(--text-sm);
  opacity: 0.7;
  line-height: 1.7;
  max-width: 380px;
}
.footer-col h5 {
  font-family: var(--font-display);
  font-style: italic;
  font-size: var(--text-base);
  font-weight: 400;
  color: var(--ember-soft);
  margin-bottom: var(--s-5);
}
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: var(--s-3); }
.footer-col a { font-size: var(--text-sm); }

.footer-bottom {
  padding-top: var(--s-5);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--s-4);
  font-size: var(--text-xs);
  opacity: 0.6;
  font-family: var(--font-body);
  letter-spacing: 0.05em;
}
.footer-bottom .icp { color: var(--ember-soft); opacity: 1; display: flex; align-items: center; flex-wrap: wrap; gap: var(--s-4); }
.footer-bottom .icp a { color: var(--ember-soft); }
.footer-bottom .icp a:hover { opacity: 0.75; }
.footer-bottom .icp .gongan { display: inline-flex; align-items: center; gap: 6px; }
.footer-bottom .icp .gongan img { width: 14px; height: 16px; display: block; }

/* ---------- Decorative ---------- */
.divider {
  display: flex;
  align-items: center;
  gap: var(--s-5);
  color: var(--whisper);
  margin: var(--s-9) auto;
  max-width: 200px;
  font-family: var(--font-display);
  font-style: italic;
}
.divider::before, .divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--whisper);
}

/* ---------- Page-specific helpers ---------- */
.bg-cream { background: var(--cream); }
.bg-paper { background: var(--paper); }
.bg-ink { background: var(--ink); color: var(--cream); }
.bg-ink h1, .bg-ink h2, .bg-ink h3 { color: var(--cream); }
.bg-ink .eyebrow, .bg-ink .section-number { color: var(--ember-soft); }
.bg-ink .kicker { color: var(--cream); border-bottom-color: var(--cream); }
.bg-ink .section-header { border-bottom-color: rgba(245, 241, 232, 0.2); }

/* ---------- Reveal Animation ---------- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 1000ms cubic-bezier(0.2, 0, 0, 1), transform 1000ms cubic-bezier(0.2, 0, 0, 1);
}
.reveal.in {
  opacity: 1;
  transform: translateY(0);
}

/* ---------- Responsive ---------- */
@media (max-width: 768px) {
  :root {
    --s-10: 5rem;
    --s-9: 4rem;
    --s-8: 3rem;
  }
  .container { padding: 0 var(--s-5); }
  h1 { font-size: var(--text-4xl); }
  h2 { font-size: var(--text-3xl); }

  .nav-menu { display: none; }
  .nav-mobile-toggle {
    display: flex;
    align-items: center;
    gap: var(--s-2);
    font-family: var(--font-display);
    font-style: italic;
    color: var(--ink);
  }
  .nav-menu.open {
    display: flex;
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    flex-direction: column;
    background: var(--paper);
    padding: var(--s-6);
    border-bottom: var(--hairline);
    gap: var(--s-4);
  }

  .hero { min-height: auto; padding: var(--s-9) 0; }

  .section-header {
    grid-template-columns: 1fr;
    gap: var(--s-4);
  }

  .audience-grid {
    grid-template-columns: 1fr;
  }
  .audience-card {
    border-right: none;
    border-bottom: var(--hairline);
  }
  .audience-card:last-child { border-bottom: none; }

  .filmstrip {
    grid-template-columns: 1fr;
    gap: var(--s-6);
  }
  .filmstrip-step::after { display: none; }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: var(--s-6);
  }
  .footer-bottom {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* ---------- Selection ---------- */
::selection { background: var(--ember); color: var(--paper); }


/* ---------- Hero Two-Column Layout ---------- */
.hero-layout {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: var(--s-9);
  align-items: center;
}

.hero-text {
  position: relative;
  z-index: 1;
}

.hero-visual {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: flex-end;
}

.hero-visual img {
  width: 100%;
  max-width: 540px;
  height: auto;
  border-radius: 20px;
  box-shadow: 0 28px 72px rgba(27, 31, 59, 0.14);
  transition: var(--transition);
}

.hero-visual img:hover {
  transform: translateY(-6px) scale(1.01);
  box-shadow: 0 36px 88px rgba(27, 31, 59, 0.18);
}

/* 中等屏幕适配 */
@media (max-width: 1024px) {
  .hero-layout {
    grid-template-columns: 1fr 1fr;
    gap: var(--s-7);
  }
  .hero-visual img {
    max-width: 420px;
    border-radius: 16px;
  }
}

/* 平板及以下：图片移到上方 */
@media (max-width: 900px) {
  .hero-layout {
    grid-template-columns: 1fr;
    gap: var(--s-8);
  }
  .hero-visual {
    order: -1;
    justify-content: center;
    max-width: 480px;
    margin: 0 auto;
  }
  .hero-visual img {
    max-width: 100%;
    border-radius: 16px;
  }
  .hero {
    padding: var(--s-9) 0 var(--s-10);
  }
  .hero-text {
    text-align: center;
  }
  .hero-text p.lede {
    margin-left: auto;
    margin-right: auto;
  }
  .hero-text div[style*="display: flex"] {
    justify-content: center;
  }
}

/* 手机端微调 */
@media (max-width: 768px) {
  .hero-layout {
    gap: var(--s-6);
  }
  .hero-visual img {
    border-radius: 12px;
    box-shadow: 0 16px 40px rgba(27, 31, 59, 0.12);
  }
}

header.hero {
    padding-top: 30px;
}
