:root {
  --bg: #fffaf6;
  --surface: rgba(255, 255, 255, 0.74);
  --surface-strong: #ffffff;
  --text: #1d2433;
  --muted: #647089;
  --line: rgba(40, 53, 80, 0.12);
  --primary: #ff6d8a;
  --primary-strong: #ec4f72;
  --secondary: #6d7cff;
  --accent: #ffd7df;
  --shadow: 0 20px 60px rgba(33, 37, 60, 0.12);
  --radius-xl: 28px;
  --radius-lg: 20px;
  --radius-md: 14px;
  --container: min(1120px, calc(100% - 32px));
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Inter", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(255, 109, 138, 0.12), transparent 30%),
    radial-gradient(circle at top right, rgba(109, 124, 255, 0.16), transparent 28%),
    var(--bg);
}

body.modal-open {
  overflow: hidden;
}

body.is-loading {
  overflow: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
select,
input {
  font: inherit;
}

button {
  cursor: pointer;
  border: 0;
}

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

.loading-screen {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  padding: 20px;
  background:
    radial-gradient(circle at top left, rgba(255, 109, 138, 0.18), transparent 32%),
    radial-gradient(circle at top right, rgba(109, 124, 255, 0.22), transparent 28%),
    rgba(255, 250, 246, 0.96);
  backdrop-filter: blur(10px);
}

.skip-loading .loading-screen {
  display: none !important;
}

.loading-card {
  width: min(520px, 100%);
  padding: 32px;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.86);
  border: 1px solid rgba(255, 255, 255, 0.7);
  box-shadow: var(--shadow);
  text-align: center;
}

.loading-label {
  margin-bottom: 12px;
  color: var(--secondary);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.loading-card h2 {
  margin-bottom: 12px;
}

.loading-copy {
  margin-bottom: 20px;
}

.loading-progress {
  height: 14px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(40, 53, 80, 0.12);
}

.loading-bar {
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  transition: width 180ms linear;
}

.loading-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 14px;
  color: var(--muted);
}

.loading-meta strong {
  color: var(--primary-strong);
  font-size: 24px;
}

.section {
  padding: 88px 0;
}

.eyebrow {
  margin: 0 0 12px;
  font-size: 14px;
  font-weight: 700;
  color: var(--secondary);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 20px;
  font-size: clamp(40px, 6vw, 72px);
  line-height: 1.02;
  letter-spacing: -0.04em;
}

h2 {
  margin-bottom: 0;
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.1;
}

p {
  color: var(--muted);
  line-height: 1.7;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  backdrop-filter: blur(18px);
  background: rgba(255, 250, 246, 0.78);
  border-bottom: 1px solid rgba(40, 53, 80, 0.06);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 78px;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
}

.brand-mark {
  display: inline-grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
}

.desktop-nav,
.header-actions {
  display: flex;
  align-items: center;
  gap: 20px;
}

.desktop-nav a {
  color: var(--muted);
  font-weight: 600;
}

.primary-btn,
.ghost-btn,
.icon-btn {
  transition: transform 160ms ease, background-color 160ms ease, box-shadow 160ms ease;
}

.primary-btn {
  padding: 14px 22px;
  border-radius: 999px;
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--primary-strong));
  box-shadow: 0 14px 28px rgba(236, 79, 114, 0.24);
}

.ghost-btn {
  padding: 13px 20px;
  border-radius: 999px;
  color: var(--text);
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid rgba(40, 53, 80, 0.08);
}

.icon-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  color: var(--text);
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid var(--line);
}

.primary-btn:hover,
.ghost-btn:hover,
.icon-btn:hover {
  transform: translateY(-1px);
}

.wide {
  width: 100%;
}

.menu-toggle {
  display: none;
  width: 46px;
  height: 46px;
  padding: 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.84);
  border: 1px solid var(--line);
}

.menu-toggle span {
  display: block;
  width: 100%;
  height: 2px;
  margin: 4px 0;
  background: var(--text);
}

.mobile-menu {
  display: grid;
  gap: 14px;
  padding: 0 16px 18px;
}

.mobile-menu a {
  padding: 8px 2px;
  color: var(--muted);
  font-weight: 600;
}

.mobile-cta {
  margin-top: 8px;
}

.hero {
  padding: 72px 0 52px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 40px;
  align-items: center;
}

.hero-text {
  max-width: 60ch;
  font-size: 18px;
}

.hero-actions {
  display: flex;
  gap: 14px;
  margin: 30px 0 36px;
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  padding: 0;
  list-style: none;
}

.hero-stats li,
.form-card,
.profile-card,
.trust-card,
.story-card,
.cta-box {
  background: var(--surface);
  border: 1px solid rgba(255, 255, 255, 0.7);
  box-shadow: var(--shadow);
  backdrop-filter: blur(10px);
}

.hero-stats li {
  padding: 18px;
  border-radius: var(--radius-lg);
}

.hero-stats strong {
  display: block;
  margin-bottom: 6px;
  font-size: 26px;
}

.hero-panel {
  position: relative;
}

.hero-panel::before {
  content: "";
  position: absolute;
  inset: 24px -20px -24px 24px;
  border-radius: 32px;
  background: linear-gradient(135deg, rgba(255, 109, 138, 0.2), rgba(109, 124, 255, 0.18));
  filter: blur(18px);
  z-index: -1;
}

.form-card {
  padding: 28px;
  border-radius: var(--radius-xl);
}

.matcher-form {
  display: grid;
  gap: 18px;
}

.field-group {
  display: grid;
  gap: 8px;
}

.field-group label {
  font-weight: 700;
}

select,
input[type="range"] {
  width: 100%;
}

select {
  height: 52px;
  padding: 0 16px;
  color: var(--text);
  border-radius: 16px;
  border: 1px solid var(--line);
  background: var(--surface-strong);
}

input[type="range"] {
  accent-color: var(--primary);
}

.range-output {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.range-output strong {
  color: var(--primary-strong);
}

.chip-group,
.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.chip,
.tag-row span {
  padding: 10px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.92);
  color: var(--muted);
}

.chip.is-active {
  color: #fff;
  background: linear-gradient(135deg, var(--secondary), var(--primary));
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 28px;
}

.section-head.narrow,
.faq-grid > div:first-child {
  max-width: 720px;
}

.card-track {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.profile-card,
.trust-card,
.story-card {
  padding: 24px;
  border-radius: var(--radius-lg);
}

.profile-card h3 {
  margin-bottom: 10px;
}

.profile-card p {
  min-height: 54px;
}

.profile-card.is-hidden {
  display: none;
}

.card-btn {
  margin-top: 18px;
}

.avatar {
  display: block;
  width: 96px;
  height: 96px;
  margin-bottom: 16px;
  border-radius: 50%;
  object-fit: cover;
  background: #f3f5fa;
  border: 1px solid rgba(255, 255, 255, 0.8);
  box-shadow: 0 10px 24px rgba(33, 37, 60, 0.12);
}

.result-note {
  margin-top: 18px;
  color: var(--muted);
  font-weight: 600;
}

.trust-grid,
.story-grid {
  display: grid;
  gap: 18px;
}

.trust-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

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

.process-grid {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 32px;
  align-items: start;
}

.steps {
  display: grid;
  gap: 16px;
  margin: 0;
  padding-left: 22px;
}

.steps li {
  padding: 18px 20px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.74);
  border: 1px solid var(--line);
}

.steps strong {
  display: block;
  margin-bottom: 6px;
}

.faq-grid {
  display: grid;
  grid-template-columns: 0.75fr 1.25fr;
  gap: 32px;
}

.accordion {
  display: grid;
  gap: 14px;
}

details {
  padding: 22px 24px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.84);
  border: 1px solid var(--line);
}

summary {
  cursor: pointer;
  font-weight: 700;
  list-style: none;
}

summary::-webkit-details-marker {
  display: none;
}

details p {
  margin: 14px 0 0;
}

.cta {
  padding-top: 24px;
}

.cta-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 32px;
  border-radius: var(--radius-xl);
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 40;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(17, 24, 39, 0.52);
}

.modal-dialog {
  position: relative;
  width: min(520px, calc(100% - 24px));
  margin: 8vh auto 0;
  padding: 28px;
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 24px 70px rgba(16, 24, 40, 0.24);
}

.modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #f3f5fa;
}

.modal-form {
  display: grid;
  gap: 14px;
  margin-top: 20px;
}

.modal-form label {
  display: grid;
  gap: 8px;
  font-weight: 600;
}

.modal-form input {
  height: 52px;
  padding: 0 14px;
  border-radius: 14px;
  border: 1px solid var(--line);
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%);
  z-index: 50;
  padding: 14px 18px;
  border-radius: 999px;
  color: #fff;
  background: rgba(29, 36, 51, 0.92);
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.22);
}

[hidden] {
  display: none !important;
}

@media (max-width: 1024px) {
  .hero-grid,
  .process-grid,
  .faq-grid,
  .trust-grid,
  .story-grid {
    grid-template-columns: 1fr;
  }

  .card-track {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 768px) {
  .section {
    padding: 72px 0;
  }

  .desktop-nav,
  .header-actions .ghost-btn,
  .header-actions .primary-btn {
    display: none;
  }

  .menu-toggle {
    display: block;
  }

  .hero {
    padding-top: 48px;
  }

  .hero-actions,
  .hero-stats,
  .cta-box,
  .section-head {
    grid-template-columns: 1fr;
    flex-direction: column;
    align-items: stretch;
  }

  .hero-stats {
    display: grid;
  }

  .card-track {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: 78%;
    overflow-x: auto;
    padding-bottom: 6px;
    scroll-snap-type: x mandatory;
  }

  .profile-card {
    scroll-snap-align: start;
  }

  .carousel-actions {
    display: none;
  }

  .cta-box {
    text-align: left;
  }
}

@media (max-width: 520px) {
  .container {
    width: min(100% - 20px, 100%);
  }

  .form-card,
  .profile-card,
  .trust-card,
  .story-card,
  .cta-box,
  .modal-dialog {
    padding: 20px;
  }

  .hero-actions {
    gap: 10px;
  }

  .hero-actions .primary-btn,
  .hero-actions .ghost-btn {
    width: 100%;
  }

  .loading-card {
    padding: 24px;
  }

  .loading-meta {
    flex-direction: column;
    align-items: flex-start;
  }
}
