/* ═══════════════════════════════════════════
   瑞师傅官网 — 禅意美学设计系统 V2.0
   www.ruishifu.cc
   ═══════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Noto+Serif+SC:wght@300;400;600;700&family=Playfair+Display:ital,wght@0,400;0,600;1,400&display=swap');

/* ── Reset & Vars ── */
:root {
  --rice-paper: #FDFBF7;
  --ink: #1C1A17; /* 暖灰/深墨色，比纯黑更柔和 */
  --ink-light: #4A4843;
  --ink-faint: rgba(28, 26, 23, 0.04);
  --zen-green: #6B8F71;
  --zen-green-light: rgba(107, 143, 113, 0.05);
  --vermillion: #C7493A;
  --grey-400: #999;
  --grey-500: #777;
  
  --font-zh: 'Noto Serif SC', serif;
  --font-en: 'Playfair Display', serif;
  --font-sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  
  --max-width: 1080px; /* 收窄内容宽度，增加两侧留白 */
  --section-padding: 160px 32px; /* 进一步增加区块间距 */
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-zh);
  background: var(--rice-paper);
  color: var(--ink);
  line-height: 2.2; /* 增大行高 */
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  font-weight: 400;
}

/* ── Typography Enhancements ── */
h1, h2, h3, h4, .en-serif {
  font-family: var(--font-en);
}

.zh-title {
  font-family: var(--font-zh);
  font-weight: 600;
}

a {
  color: var(--zen-green);
  text-decoration: none;
  transition: color 0.4s ease;
}
a:hover {
  color: var(--vermillion);
}

img {
  max-width: 100%;
  height: auto;
}

/* ── Navigation ── */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 24px 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: transparent;
  transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.nav.scrolled {
  padding: 16px 40px;
  background: rgba(253, 251, 247, 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--ink-faint);
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 16px;
}

.nav-brand img {
  height: 32px;
  width: auto;
  border-radius: 6px;
}

.nav-brand span {
  font-size: 16px;
  font-weight: 600;
  color: var(--ink);
  letter-spacing: 4px;
}

.nav-links {
  display: flex;
  gap: 48px;
  list-style: none;
}

.nav-links a {
  font-size: 13px;
  color: var(--ink-light);
  letter-spacing: 2px;
  transition: all 0.4s ease;
  font-family: var(--font-sans);
  position: relative;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--ink);
  transition: width 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.nav-links a:hover {
  color: var(--ink);
}

.nav-links a:hover::after {
  width: 100%;
}

/* ── Hero Section ── */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 32px;
  background: url('../assets/ink-bg.png') center/cover no-repeat;
  background-attachment: fixed; /* 视差效果 */
  position: relative;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 200px;
  background: linear-gradient(transparent, var(--rice-paper));
  pointer-events: none;
}

.hero-content {
  max-width: var(--max-width);
  display: flex;
  align-items: center;
  gap: 120px; /* 增加图文间距 */
  position: relative;
  z-index: 1;
  padding-top: 80px;
}

.hero-text {
  flex: 1;
}

.hero-text h1 {
  font-size: clamp(40px, 5vw, 64px);
  line-height: 1.1;
  letter-spacing: 8px;
  margin-bottom: 24px;
  color: var(--ink);
}

.hero-text h1 span {
  display: block;
  font-size: 0.35em;
  font-weight: 400;
  letter-spacing: 4px;
  color: var(--ink-light);
  margin-top: 16px;
  font-style: italic;
  font-family: var(--font-en);
}

.hero-text p {
  font-size: 16px;
  color: var(--ink-light);
  margin-bottom: 56px;
  line-height: 2.2;
  max-width: 420px;
  font-weight: 300;
}

.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 18px 48px;
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--ink);
  border-radius: 0; /* 更加克制的方形按钮 */
  font-size: 13px;
  letter-spacing: 4px;
  transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: default;
  font-family: var(--font-sans);
  position: relative;
  overflow: hidden;
}

.hero-cta::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: var(--ink);
  transform: scaleY(0);
  transform-origin: bottom;
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: -1;
}

.hero-cta:hover {
  color: var(--rice-paper);
}

.hero-cta:hover::before {
  transform: scaleY(1);
}

.hero-image {
  flex: 0 0 400px;
  position: relative;
}

.hero-image::before {
  content: '';
  position: absolute;
  top: -20px; right: -20px; bottom: 20px; left: 20px;
  border: 1px solid var(--ink-faint);
  z-index: -1;
  transition: transform 0.8s ease;
}

.hero-image:hover::before {
  transform: translate(10px, -10px);
}

.hero-image img {
  width: 100%;
  border-radius: 0; /* 摒弃圆角，增加画册感 */
  box-shadow: 0 30px 80px rgba(28, 26, 23, 0.08);
  transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.hero-image img:hover {
  transform: scale(1.03);
}

/* ── Features Section (Asymmetric Layout) ── */
.features {
  padding: var(--section-padding);
  max-width: var(--max-width);
  margin: 0 auto;
}

.section-title {
  text-align: center;
  margin-bottom: 120px;
}

.section-title h2 {
  font-size: 32px;
  font-weight: 400;
  letter-spacing: 8px;
  margin-bottom: 16px;
}

.section-title p {
  font-size: 14px;
  color: var(--grey-400);
  letter-spacing: 4px;
  font-family: var(--font-en);
  font-style: italic;
}

.feature-block {
  display: flex;
  align-items: center;
  gap: 80px;
  margin-bottom: 160px;
}

.feature-block:last-child {
  margin-bottom: 0;
}

.feature-block.reverse {
  flex-direction: row-reverse;
}

.feature-content {
  flex: 1;
}

.feature-num {
  font-family: var(--font-en);
  font-size: 14px;
  color: var(--grey-400);
  letter-spacing: 2px;
  margin-bottom: 24px;
  display: block;
}

.feature-block h3 {
  font-size: 24px;
  font-weight: 400;
  margin-bottom: 24px;
  letter-spacing: 4px;
  position: relative;
  display: inline-block;
}

.feature-block h3::after {
  content: '';
  position: absolute;
  bottom: -8px;
  left: 0;
  width: 40px;
  height: 1px;
  background: var(--zen-green);
}

.feature-block p {
  font-size: 15px;
  color: var(--ink-light);
  font-weight: 300;
  max-width: 400px;
}

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

.feature-visual .visual-box {
  width: 320px;
  height: 420px;
  background: var(--zen-green-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 64px;
  position: relative;
}

.feature-visual .visual-box::after {
  content: '';
  position: absolute;
  top: 20px; left: 20px; right: -20px; bottom: -20px;
  border: 1px solid var(--ink-faint);
  z-index: -1;
}

/* ── Screenshots Section ── */
.screenshots {
  padding: var(--section-padding);
  background: linear-gradient(180deg, var(--rice-paper), var(--zen-green-light), var(--rice-paper));
  position: relative;
  overflow: hidden;
}

.screenshots-container {
  max-width: var(--max-width);
  margin: 0 auto;
  position: relative;
  z-index: 2;
}

.screenshots-grid {
  display: flex;
  justify-content: center;
  gap: 60px;
  align-items: center;
  margin-top: 80px;
}

.screenshot-item {
  flex: 0 0 280px;
  position: relative;
  transition: all 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

/* 错落布局 */
.screenshot-item:nth-child(1) { transform: translateY(40px); }
.screenshot-item:nth-child(2) { transform: translateY(-40px); z-index: 2; }
.screenshot-item:nth-child(3) { transform: translateY(60px); }

.screenshot-item img {
  width: 100%;
  display: block;
  box-shadow: 0 30px 60px rgba(0,0,0,0.06);
}

/* ── About Section ── */
.about {
  padding: 160px 32px 200px;
  max-width: 800px;
  margin: 0 auto;
  text-align: center;
}

.about-logo {
  width: 260px;
  margin-bottom: 48px;
  mix-blend-mode: multiply; /* 核心：让 logo 融入宣纸 */
  opacity: 0.85; /* 柔和化 */
  filter: grayscale(15%); /* 轻微降低饱和度 */
}

.about h3 {
  font-size: 20px;
  font-weight: 400;
  letter-spacing: 6px;
  margin-bottom: 12px;
}

.about .company-name-en {
  font-size: 12px;
  color: var(--grey-400);
  letter-spacing: 4px;
  margin-bottom: 48px;
  font-family: var(--font-en);
}

.about p.desc {
  font-size: 15px;
  color: var(--ink-light);
  margin-bottom: 16px;
  font-weight: 300;
  max-width: 560px;
  margin-left: auto;
  margin-right: auto;
}

.about-contact {
  display: flex;
  justify-content: center;
  gap: 64px;
  margin-top: 80px;
  flex-wrap: wrap;
}

.about-contact-item {
  font-size: 13px;
  color: var(--grey-500);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  letter-spacing: 2px;
  font-family: var(--font-sans);
}

.about-contact-item .icon {
  font-size: 20px;
  color: var(--ink);
}

/* ── Footer ── */
.footer {
  padding: 64px 24px 80px;
  text-align: center;
  position: relative;
}

.footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 1px;
  height: 40px;
  background: var(--ink-faint);
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 40px;
  margin-bottom: 40px;
  flex-wrap: wrap;
}

.footer-links a {
  font-size: 12px;
  color: var(--ink-light);
  letter-spacing: 2px;
  font-family: var(--font-sans);
  text-transform: uppercase;
}

.footer p {
  font-size: 12px;
  color: var(--grey-400);
  line-height: 2.5;
  font-family: var(--font-sans);
  letter-spacing: 1px;
}

.footer .icp {
  color: var(--grey-400);
  transition: color 0.3s;
}

.footer .icp:hover {
  color: var(--ink);
}

/* ── Subtle Animations ── */
.fade-in {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 1.2s cubic-bezier(0.16, 1, 0.3, 1), transform 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

.fade-in-delay-1 { transition-delay: 0.1s; }
.fade-in-delay-2 { transition-delay: 0.2s; }
.fade-in-delay-3 { transition-delay: 0.3s; }

/* ── Legal Pages (Like a Poetry Book) ── */
.legal-page {
  max-width: 680px; /* 极窄行宽，最佳阅读体验 */
  margin: 0 auto;
  padding: 160px 24px 120px;
}

.legal-page h1 {
  font-size: 32px;
  font-weight: 400;
  letter-spacing: 8px;
  margin-bottom: 16px;
  text-align: center;
}

.legal-page .subtitle {
  text-align: center;
  color: var(--grey-400);
  font-size: 13px;
  margin-bottom: 80px;
  letter-spacing: 2px;
  font-family: var(--font-sans);
  text-transform: uppercase;
}

.legal-page h2 {
  font-size: 18px;
  font-weight: 600;
  margin-top: 64px;
  margin-bottom: 24px;
  color: var(--ink);
  letter-spacing: 2px;
  display: flex;
  align-items: center;
  gap: 16px;
}

.legal-page h2::before {
  content: '';
  display: block;
  width: 24px;
  height: 1px;
  background: var(--zen-green);
}

.legal-page p, .legal-page li {
  font-size: 15px;
  color: var(--ink-light);
  line-height: 2.4;
  margin-bottom: 16px;
  font-weight: 300;
}

.legal-page ul {
  padding-left: 0;
  margin-bottom: 32px;
  list-style: none;
}

.legal-page li {
  position: relative;
  padding-left: 24px;
}

.legal-page li::before {
  content: '·';
  position: absolute;
  left: 0;
  color: var(--zen-green);
  font-weight: bold;
}

.legal-page .contact-box {
  margin-top: 80px;
  padding: 48px;
  background: transparent;
  border: 1px solid var(--ink-faint);
  text-align: center;
}

/* ── Responsive ── */
@media (max-width: 900px) {
  :root {
    --section-padding: 100px 24px;
  }

  .nav { padding: 16px 24px; }
  .nav-links { display: none; }

  .hero-content {
    flex-direction: column;
    text-align: center;
    gap: 60px;
  }

  .hero-text p {
    margin: 0 auto 40px;
  }

  .hero-image {
    flex: 0 0 auto;
    width: 280px;
  }

  .feature-block, .feature-block.reverse {
    flex-direction: column;
    gap: 48px;
    text-align: center;
    margin-bottom: 100px;
  }

  .feature-block h3::after {
    left: 50%;
    transform: translateX(-50%);
  }

  .feature-block p {
    margin: 0 auto;
  }

  .screenshots-grid {
    flex-direction: column;
    gap: 40px;
  }
  
  .screenshot-item:nth-child(n) {
    transform: none !important;
  }
}
