/* ============================================================
   久伴良缘 官网样式
   纯静态 · 零外部依赖 · 响应式
   ============================================================ */

/* ---------- 变量 ---------- */
:root {
  --c-primary: #C8503C;
  --c-primary-dark: #A83E2C;
  --c-primary-soft: #F3DCD5;
  --c-accent: #E8A87C;
  --c-cream: #FAF7F5;
  --c-white: #FFFFFF;

  --c-ink: #2B211E;
  --c-ink-2: #574944;
  --c-ink-3: #8C7B75;
  --c-line: #EDE4DF;

  --c-dark: #2B211E;
  --c-dark-2: #362A26;

  --radius-card: 20px;
  --radius-pill: 999px;

  --shadow-sm: 0 4px 24px rgba(90, 60, 50, .06);
  --shadow-md: 0 14px 40px rgba(90, 60, 50, .10);

  --nav-h: 68px;
  --ease: cubic-bezier(.22, .61, .36, 1);

  --font: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB",
          "Microsoft YaHei", "Source Han Sans SC", "Noto Sans CJK SC", system-ui, sans-serif;
}

/* ---------- 基础 ---------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.75;
  color: var(--c-ink-2);
  background: var(--c-white);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3 { color: var(--c-ink); margin: 0; font-weight: 600; letter-spacing: -.01em; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
a { color: inherit; text-decoration: none; }

img, svg { display: block; max-width: 100%; }

:focus-visible {
  outline: 2px solid var(--c-primary);
  outline-offset: 3px;
  border-radius: 4px;
}

.container {
  width: 100%;
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- 导航 ---------- */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  height: var(--nav-h);
  background: transparent;
  transition: background .35s var(--ease), box-shadow .35s var(--ease),
              backdrop-filter .35s var(--ease);
}

.nav.is-scrolled {
  background: rgba(255, 255, 255, .88);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  box-shadow: 0 1px 0 rgba(43, 33, 30, .07), 0 6px 24px rgba(90, 60, 50, .05);
}

.nav-inner {
  height: 100%;
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  flex-shrink: 0;
}

.brand-mark {
  width: 30px; height: 30px;
  display: grid;
  place-items: center;
  color: var(--c-primary);
  background: linear-gradient(140deg, var(--c-primary-soft), #FBEDE7);
  border-radius: 9px;
  flex-shrink: 0;
}

.brand-mark svg { width: 19px; height: 19px; }

.brand-text {
  font-size: 18px;
  font-weight: 600;
  color: var(--c-ink);
  letter-spacing: .04em;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 6px;
}

.nav-links a {
  position: relative;
  padding: 8px 14px;
  font-size: 15px;
  color: var(--c-ink-2);
  border-radius: var(--radius-pill);
  transition: color .25s var(--ease), background .25s var(--ease);
  white-space: nowrap;
}

.nav-links a:hover { color: var(--c-primary); background: rgba(200, 80, 60, .06); }

.nav-links a.is-active { color: var(--c-primary); font-weight: 500; }

.nav-links a.nav-cta {
  margin-left: 8px;
  padding: 9px 20px;
  color: #fff;
  background: var(--c-primary);
  font-weight: 500;
  box-shadow: 0 6px 18px rgba(200, 80, 60, .22);
}

.nav-links a.nav-cta:hover {
  background: var(--c-primary-dark);
  color: #fff;
  transform: translateY(-1px);
}

.nav-toggle {
  display: none;
  width: 40px; height: 40px;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
}

.nav-toggle span {
  display: block;
  width: 20px; height: 2px;
  background: var(--c-ink);
  border-radius: 2px;
  transition: transform .3s var(--ease), opacity .2s var(--ease);
}

.nav-toggle.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.is-open span:nth-child(2) { opacity: 0; }
.nav-toggle.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  padding: calc(var(--nav-h) + 84px) 0 100px;
  background: linear-gradient(160deg, #FFFCFA 0%, #FDF2ED 46%, #FAE7DF 100%);
  isolation: isolate;
}

.hero-glow {
  position: absolute;
  width: 720px; height: 720px;
  top: -320px; right: -180px;
  background: radial-gradient(circle, rgba(200, 80, 60, .16), transparent 68%);
  border-radius: 50%;
  pointer-events: none;
  z-index: -1;
}

.hero-glow--2 {
  width: 560px; height: 560px;
  top: auto; right: auto;
  bottom: -260px; left: -200px;
  background: radial-gradient(circle, rgba(232, 168, 124, .22), transparent 68%);
}

.hero-inner { max-width: 900px; }

.hero-eyebrow {
  display: inline-block;
  margin-bottom: 22px;
  padding: 7px 18px;
  font-size: 13px;
  letter-spacing: .06em;
  color: var(--c-primary-dark);
  background: rgba(255, 255, 255, .72);
  border: 1px solid rgba(200, 80, 60, .16);
  border-radius: var(--radius-pill);
}

.hero-title {
  font-size: clamp(30px, 5.1vw, 56px);
  line-height: 1.28;
  font-weight: 600;
  letter-spacing: -.02em;
  color: var(--c-ink);
}

.hero-sub {
  margin-top: 24px;
  max-width: 620px;
  font-size: clamp(15px, 1.6vw, 18px);
  line-height: 1.85;
  color: var(--c-ink-2);
}

.hero-actions {
  margin-top: 38px;
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 32px;
  font-size: 16px;
  font-weight: 500;
  border-radius: var(--radius-pill);
  transition: transform .25s var(--ease), box-shadow .25s var(--ease),
              background .25s var(--ease), color .25s var(--ease);
  cursor: pointer;
  border: 1px solid transparent;
}

.btn-primary {
  color: #fff;
  background: var(--c-primary);
  box-shadow: 0 10px 28px rgba(200, 80, 60, .26);
}

.btn-primary:hover {
  background: var(--c-primary-dark);
  transform: translateY(-2px);
  box-shadow: 0 14px 34px rgba(200, 80, 60, .3);
}

.btn-ghost {
  color: var(--c-ink);
  background: rgba(255, 255, 255, .78);
  border-color: rgba(43, 33, 30, .1);
}

.btn-ghost:hover {
  background: #fff;
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

.hero-stats {
  margin-top: 64px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: rgba(43, 33, 30, .08);
  border-radius: 16px;
  overflow: hidden;
}

.hero-stats li {
  padding: 24px 26px;
  background: rgba(255, 255, 255, .7);
}

.hero-stats strong {
  display: block;
  font-size: 17px;
  font-weight: 600;
  color: var(--c-primary-dark);
  letter-spacing: .01em;
}

.hero-stats span {
  display: block;
  margin-top: 6px;
  font-size: 13.5px;
  line-height: 1.7;
  color: var(--c-ink-3);
}

/* ---------- 通用区块 ---------- */
.section { padding: clamp(68px, 9vw, 118px) 0; }

.section-head {
  max-width: 680px;
  margin-bottom: clamp(44px, 5.5vw, 68px);
}

.section-eyebrow {
  margin-bottom: 14px;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--c-primary);
}

.section-title {
  font-size: clamp(26px, 3.4vw, 40px);
  line-height: 1.34;
  letter-spacing: -.02em;
}

.section-desc {
  margin-top: 18px;
  font-size: 16px;
  line-height: 1.9;
  color: var(--c-ink-2);
}

/* ---------- 卡片 ---------- */
.cards {
  display: grid;
  gap: 22px;
}

.cards--3 { grid-template-columns: repeat(3, 1fr); }

.card {
  padding: 34px 30px 36px;
  background: var(--c-white);
  border: 1px solid var(--c-line);
  border-radius: var(--radius-card);
  transition: transform .38s var(--ease), box-shadow .38s var(--ease),
              border-color .38s var(--ease);
}

.card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-md);
  border-color: rgba(200, 80, 60, .2);
}

.card-icon {
  width: 52px; height: 52px;
  display: grid;
  place-items: center;
  margin-bottom: 24px;
  color: var(--c-primary);
  background: linear-gradient(145deg, #FDF2ED, #F8E3DA);
  border-radius: 15px;
}

.card-icon svg { width: 26px; height: 26px; }

.card h3 {
  font-size: 19px;
  font-weight: 600;
  margin-bottom: 12px;
}

.card p {
  font-size: 15px;
  line-height: 1.85;
  color: var(--c-ink-2);
}

/* ---------- 安全核验（深色） ---------- */
.security {
  position: relative;
  background: var(--c-dark);
  overflow: hidden;
}

.security::before {
  content: "";
  position: absolute;
  width: 800px; height: 800px;
  top: -420px; left: 50%;
  transform: translateX(-50%);
  background: radial-gradient(circle, rgba(200, 80, 60, .22), transparent 66%);
  pointer-events: none;
}

.security .container { position: relative; }

.section-head--light .section-eyebrow { color: var(--c-accent); }
.section-head--light .section-title { color: #fff; }
.section-head--light .section-desc { color: rgba(255, 255, 255, .68); }

.card--dark {
  background: var(--c-dark-2);
  border-color: rgba(255, 255, 255, .08);
}

.card--dark:hover {
  border-color: rgba(232, 168, 124, .34);
  box-shadow: 0 18px 46px rgba(0, 0, 0, .3);
}

.card--dark h3 { color: #fff; }
.card--dark p { color: rgba(255, 255, 255, .66); }

.card-icon--light {
  color: var(--c-accent);
  background: rgba(232, 168, 124, .1);
  border: 1px solid rgba(232, 168, 124, .18);
}

/* 流程条 */
.flow {
  margin-top: clamp(40px, 5vw, 60px);
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: rgba(255, 255, 255, .08);
  border-radius: 14px;
  overflow: hidden;
}

.flow li {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 22px 24px;
  background: rgba(255, 255, 255, .03);
}

.flow-num {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .08em;
  color: var(--c-accent);
  font-variant-numeric: tabular-nums;
}

.flow-text {
  font-size: 15px;
  color: rgba(255, 255, 255, .82);
  white-space: nowrap;
}

/* ---------- 合规声明 ---------- */
.compliance { background: var(--c-cream); }

.compliance-box {
  max-width: 880px;
  padding: clamp(32px, 4.5vw, 52px);
  background: var(--c-white);
  border: 1px solid var(--c-line);
  border-radius: var(--radius-card);
}

.compliance-title {
  font-size: clamp(20px, 2.2vw, 25px);
  margin-bottom: 24px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--c-line);
}

.compliance-list { display: grid; gap: 14px; }

.compliance-list li {
  position: relative;
  padding-left: 20px;
  font-size: 14.5px;
  line-height: 1.9;
  color: var(--c-ink-2);
}

.compliance-list li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: .74em;
  width: 6px; height: 6px;
  background: var(--c-primary);
  border-radius: 50%;
  opacity: .55;
}

.compliance-note {
  margin-top: 22px;
  font-size: 14px;
  color: var(--c-ink-3);
}

/* ---------- 页脚 ---------- */
.footer {
  background: var(--c-dark);
  padding-top: clamp(52px, 6vw, 76px);
}

.footer-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  padding-bottom: clamp(44px, 5vw, 64px);
}

.footer-brand .brand-text {
  font-size: 20px;
  color: #fff;
  letter-spacing: .05em;
}

.footer-slogan {
  margin-top: 12px;
  font-size: 14.5px;
  color: rgba(255, 255, 255, .5);
}

.footer-info { display: grid; gap: 14px; }

.footer-row {
  display: flex;
  gap: 16px;
  font-size: 14.5px;
  line-height: 1.8;
}

.footer-label {
  flex-shrink: 0;
  width: 76px;
  color: rgba(255, 255, 255, .42);
}

.footer-value { color: rgba(255, 255, 255, .86); }

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, .08);
}

.footer-bottom-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 22px 24px;
  font-size: 13px;
  color: rgba(255, 255, 255, .45);
}

.footer-bottom-inner a {
  color: rgba(255, 255, 255, .55);
  transition: color .25s var(--ease);
}

.footer-bottom-inner a:hover { color: var(--c-accent); }

/* ---------- 入场动效 ---------- */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .78s var(--ease), transform .78s var(--ease);
}

.reveal.is-in {
  opacity: 1;
  transform: none;
}

.br-m { display: none; }

/* ============================================================
   响应式
   ============================================================ */

/* 平板 */
@media (max-width: 1080px) {
  .hero { padding: calc(var(--nav-h) + 64px) 0 84px; }
  .cards--3 { gap: 18px; }
  .card { padding: 30px 26px 32px; }
}

/* 手机 / 微信内置浏览器 */
@media (max-width: 820px) {
  :root { --nav-h: 60px; }

  .nav-toggle { display: flex; }

  .nav-links {
    position: fixed;
    top: var(--nav-h);
    left: 0; right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    padding: 12px 16px 22px;
    background: rgba(255, 255, 255, .97);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--c-line);
    box-shadow: 0 18px 40px rgba(90, 60, 50, .1);
    transform: translateY(-12px);
    opacity: 0;
    pointer-events: none;
    transition: opacity .28s var(--ease), transform .28s var(--ease);
  }

  .nav-links.is-open {
    transform: none;
    opacity: 1;
    pointer-events: auto;
  }

  .nav-links a {
    padding: 13px 16px;
    font-size: 16px;
    border-radius: 12px;
  }

  .nav-links a.nav-cta {
    margin: 8px 0 0;
    padding: 14px 16px;
    text-align: center;
    border-radius: 12px;
  }

  .hero { padding: calc(var(--nav-h) + 52px) 0 72px; }

  .hero-glow { width: 460px; height: 460px; top: -200px; right: -160px; }
  .hero-glow--2 { width: 360px; height: 360px; bottom: -180px; left: -140px; }

  .hero-title { font-size: clamp(27px, 7.4vw, 38px); line-height: 1.36; }
  .br-m { display: block; }

  .hero-sub { margin-top: 20px; font-size: 15.5px; }

  .hero-actions { margin-top: 32px; gap: 12px; }

  .btn {
    flex: 1 1 auto;
    min-width: 148px;
    padding: 13px 24px;
    font-size: 15.5px;
  }

  .hero-stats {
    margin-top: 48px;
    grid-template-columns: 1fr;
  }

  .hero-stats li {
    display: flex;
    align-items: baseline;
    gap: 12px;
    padding: 18px 22px;
  }

  .hero-stats strong { flex-shrink: 0; font-size: 16px; }

  .hero-stats span { margin-top: 0; font-size: 13px; }

  .cards--3 { grid-template-columns: 1fr; }

  .card { padding: 26px 22px 28px; }

  .card:hover { transform: none; }

  .flow { grid-template-columns: repeat(2, 1fr); }

  .flow li { padding: 18px 20px; }

  .footer-inner {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .footer-bottom-inner {
    justify-content: flex-start;
    padding: 20px 24px calc(20px + env(safe-area-inset-bottom));
  }
}

/* 小屏 */
@media (max-width: 480px) {
  .container { padding: 0 20px; }

  .hero-title { font-size: 26px; }

  .hero-actions { flex-direction: column; }

  .btn { width: 100%; }

  .section-head { margin-bottom: 38px; }

  .card-icon { width: 46px; height: 46px; margin-bottom: 20px; }
  .card-icon svg { width: 23px; height: 23px; }

  .flow { grid-template-columns: 1fr; }

  .compliance-box { padding: 26px 22px; }

  .footer-row { flex-direction: column; gap: 2px; }
  .footer-label { width: auto; font-size: 13px; }
}

/* 减少动效偏好 */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001ms !important;
    transition-duration: .001ms !important;
  }
  .reveal { opacity: 1; transform: none; }
}
