/* ============================================================
   W49 完整预览包 · shared
   参照 Resend+Wise；自有 token；未照抄品牌识别
   基线：W49-click-home.v-style-motion.preview.html
   禁 Google Fonts／易墙 CDN／第三方动效库
   ============================================================ */
:root {
  --bg: #EEECE6;
  --surface: #F7F6F2;
  --ink: #141413;
  --muted: #5C5A54;
  --accent: #2541B2;
  --accent-on: #FFFFFF;
  --border: #D4D1C8;
  --focus: #2541B2;
  --rule: #141413;

  --font: "PingFang SC", "Hiragino Sans GB", "Noto Sans SC", "Microsoft YaHei",
          system-ui, -apple-system, sans-serif;

  --fs-caption: 0.75rem;
  --fs-sm: 0.875rem;
  --fs-base: 1rem;
  --fs-md: 1.125rem;
  --fs-lg: 1.375rem;
  --fs-slogan: clamp(1.4rem, 3.4vw, 2rem);
  --fs-hero: clamp(4rem, 13vw, 7.5rem);
  --fs-page: clamp(1.75rem, 4vw, 2.5rem);

  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 24px;
  --space-6: 32px;
  --space-7: 48px;
  --space-8: 72px;
  --space-9: 96px;

  --radius: 8px;
  --rule-w: 3px;
  --max: 960px;
  --pad-x: clamp(1.25rem, 4.5vw, 3.25rem);

  --enter-dur: 0.55s;
  --enter-ease: cubic-bezier(0.22, 1, 0.36, 1);
  --reveal-dur: 0.5s;
  --hover-dur: 0.18s;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: var(--fs-base);
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  position: relative;
}

body::before {
  content: "";
  position: fixed;
  left: 0;
  top: 0;
  width: var(--rule-w);
  height: 100%;
  background: var(--rule);
  transform-origin: top center;
  transform: scaleY(0);
  animation: rule-draw 0.7s var(--enter-ease) 0.05s forwards;
  pointer-events: none;
  z-index: 50;
}

@keyframes rule-draw {
  from { transform: scaleY(0); }
  to   { transform: scaleY(1); }
}

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}
a:hover { text-decoration-thickness: 2px; }
:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 3px;
}
.skip {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--ink);
  color: var(--surface);
  padding: var(--space-2) var(--space-4);
  z-index: 100;
  font-size: var(--fs-sm);
}
.skip:focus { left: var(--pad-x); top: var(--space-2); }

.preview-banner {
  background: var(--ink);
  color: var(--surface);
  font-size: var(--fs-caption);
  letter-spacing: 0.04em;
  text-align: center;
  padding: 0.55rem var(--pad-x);
  line-height: 1.45;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  padding: var(--space-5) var(--pad-x);
  border-bottom: 1px solid var(--border);
  background: var(--surface);
  flex-wrap: wrap;
}
.brand {
  font-weight: 700;
  font-size: var(--fs-md);
  letter-spacing: 0.04em;
  color: var(--ink);
  text-decoration: none;
  transition: color var(--hover-dur) ease;
}
.brand:hover { color: var(--accent); text-decoration: none; }
.brand span {
  font-weight: 400;
  color: var(--muted);
  margin-left: 0.45em;
  font-size: var(--fs-sm);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.nav {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav a {
  color: var(--ink);
  text-decoration: none;
  font-size: var(--fs-sm);
  letter-spacing: 0.02em;
  transition: color var(--hover-dur) ease;
}
.nav a:hover { color: var(--accent); }
.nav a[aria-current="page"] {
  color: var(--accent);
  font-weight: 600;
}
.nav a:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 3px;
  border-radius: 2px;
}

main {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--pad-x) var(--space-8);
}

/* —— Hero —— */
.hero {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: var(--space-7);
  align-items: end;
  padding: var(--space-9) 0 var(--space-8);
  border-bottom: 1px solid var(--ink);
}
.hero-name {
  margin: 0;
  font-size: var(--fs-hero);
  font-weight: 800;
  line-height: 0.92;
  letter-spacing: -0.04em;
  color: var(--ink);
}
.hero-en {
  display: block;
  margin-top: var(--space-4);
  font-size: var(--fs-md);
  font-weight: 400;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
}
.hero-slogan {
  margin-top: var(--space-7);
  max-width: 20em;
}
.slogan-main {
  margin: 0;
  font-size: var(--fs-slogan);
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: 0.01em;
  color: var(--ink);
}
.slogan-en {
  display: block;
  margin-top: var(--space-3);
  font-size: var(--fs-caption);
  font-weight: 400;
  letter-spacing: 0.08em;
  line-height: 1.45;
  color: var(--muted);
  font-style: normal;
}
.slogan-sub {
  margin: var(--space-5) 0 0;
  font-size: var(--fs-sm);
  font-weight: 400;
  line-height: 1.55;
  color: var(--muted);
}
.hero-side {
  display: flex;
  flex-direction: column;
  gap: var(--space-5);
  padding-bottom: 0.4em;
}
.hero-tag {
  margin: 0;
  font-size: var(--fs-md);
  line-height: 1.5;
  color: var(--ink);
  max-width: 22em;
}
.hero-tag strong { font-weight: 700; }
.hero-geo {
  margin: 0;
  font-size: var(--fs-base);
  line-height: 1.55;
  color: var(--muted);
  max-width: 24em;
}

.enter {
  opacity: 0;
  transform: translateY(12px);
  animation: enter-up var(--enter-dur) var(--enter-ease) forwards;
  animation-delay: var(--d, 0ms);
}
@keyframes enter-up {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  min-height: 48px;
  padding: 0.85em 1.75em;
  font-family: inherit;
  font-size: var(--fs-base);
  font-weight: 600;
  letter-spacing: 0.04em;
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  text-decoration: none;
  background: var(--accent);
  color: var(--accent-on);
  width: fit-content;
  transition: filter var(--hover-dur) ease, transform var(--hover-dur) ease,
              box-shadow var(--hover-dur) ease;
}
.btn:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
  text-decoration: none;
  color: var(--accent-on);
  box-shadow: 0 4px 12px rgba(37, 65, 178, 0.18);
}
.btn:active {
  transform: translateY(0);
  filter: brightness(1.02);
  box-shadow: none;
}
.btn:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
}

section.content {
  padding: var(--space-8) 0;
  border-bottom: 1px solid var(--border);
}
section.content:last-of-type { border-bottom: none; }

.reveal {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity var(--reveal-dur) var(--enter-ease),
              transform var(--reveal-dur) var(--enter-ease);
  transition-delay: var(--d, 0ms);
}
.reveal.is-in {
  opacity: 1;
  transform: translateY(0);
}

h2.sec-label {
  margin: 0 0 var(--space-5);
  font-size: var(--fs-caption);
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
  line-height: 1.4;
}

.about-body {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  max-width: 40em;
}
.about-body p {
  margin: 0;
  font-size: var(--fs-md);
  line-height: 1.7;
  color: var(--ink);
}
.about-body p.muted-line {
  color: var(--muted);
  font-size: var(--fs-base);
}

.dirs {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-4);
}
.dirs li {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: var(--space-5) var(--space-5);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  transition: border-color var(--hover-dur) ease;
}
.dirs li:hover { border-color: #B8B4A8; }
.dirs .name {
  font-weight: 700;
  font-size: var(--fs-md);
  letter-spacing: 0.02em;
  color: var(--ink);
}
.dirs .desc {
  margin: 0;
  font-size: var(--fs-sm);
  line-height: 1.65;
  color: var(--muted);
  flex: 1;
}
.dirs .deep {
  font-size: var(--fs-sm);
  font-weight: 500;
  text-decoration: none;
  color: var(--accent);
  width: fit-content;
  border-bottom: 1px solid transparent;
  padding-bottom: 1px;
  transition: border-color var(--hover-dur) ease, color var(--hover-dur) ease;
}
.dirs .deep:hover {
  text-decoration: none;
  border-bottom-color: var(--accent);
}
.dirs .deep:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 3px;
  border-radius: 2px;
}
.fake-note {
  display: inline-block;
  margin-left: 0.35em;
  font-size: 0.7em;
  font-weight: 400;
  color: var(--muted);
  letter-spacing: 0;
  vertical-align: middle;
}

.contact-block {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}
.contact-block a.mail {
  font-size: var(--fs-lg);
  font-weight: 600;
  color: var(--ink);
  text-decoration: none;
  border-bottom: 2px solid var(--accent);
  padding-bottom: 3px;
  width: fit-content;
  transition: color var(--hover-dur) ease, border-color var(--hover-dur) ease;
}
.contact-block a.mail:hover { color: var(--accent); }
.contact-block a.mail:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 4px;
  border-radius: 2px;
}
.contact-note {
  margin: 0;
  font-size: var(--fs-sm);
  color: var(--muted);
  max-width: 36em;
}

.preview-foot-note {
  margin-top: var(--space-6);
  padding: var(--space-3) var(--space-4);
  background: var(--surface);
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  font-size: var(--fs-caption);
  color: var(--muted);
  line-height: 1.55;
}

.site-footer {
  max-width: var(--max);
  margin: 0 auto;
  padding: var(--space-6) var(--pad-x) var(--space-8);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: var(--space-3);
  font-size: var(--fs-caption);
  color: var(--muted);
  border-top: 1px solid var(--border);
}
.site-footer a {
  color: var(--muted);
  text-decoration: none;
  transition: color var(--hover-dur) ease;
}
.site-footer a:hover { color: var(--accent); }

/* —— 子页：页头／正文／相关 —— */
.page-hero {
  padding: var(--space-8) 0 var(--space-6);
  border-bottom: 1px solid var(--ink);
}
.page-kicker {
  margin: 0 0 var(--space-3);
  font-size: var(--fs-caption);
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
}
.page-title {
  margin: 0;
  font-size: var(--fs-page);
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--ink);
}
.page-lead {
  margin: var(--space-5) 0 0;
  max-width: 40em;
  font-size: var(--fs-md);
  line-height: 1.7;
  color: var(--ink);
}

.prose {
  display: flex;
  flex-direction: column;
  gap: var(--space-5);
  max-width: 40em;
}
.prose p {
  margin: 0;
  font-size: var(--fs-md);
  line-height: 1.7;
  color: var(--ink);
}
.prose p.muted-line {
  color: var(--muted);
  font-size: var(--fs-base);
}
.prose h3 {
  margin: var(--space-2) 0 0;
  font-size: var(--fs-base);
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--ink);
}
.prose ul {
  margin: 0;
  padding: 0 0 0 1.25em;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}
.prose li {
  font-size: var(--fs-base);
  line-height: 1.65;
  color: var(--ink);
}
.prose li strong { font-weight: 700; }

.surface-block {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: var(--space-5);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}
.surface-block p {
  margin: 0;
  font-size: var(--fs-base);
  line-height: 1.65;
  color: var(--ink);
}
.surface-block .label {
  font-size: var(--fs-caption);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}

.related {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}
.related a {
  font-size: var(--fs-sm);
  font-weight: 500;
  text-decoration: none;
  color: var(--accent);
  width: fit-content;
  border-bottom: 1px solid transparent;
  padding-bottom: 1px;
  transition: border-color var(--hover-dur) ease;
}
.related a:hover {
  text-decoration: none;
  border-bottom-color: var(--accent);
}

.matrix {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}
.matrix li {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: var(--space-5);
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}
.matrix .name {
  font-weight: 700;
  font-size: var(--fs-md);
  color: var(--ink);
}
.matrix .meta {
  font-size: var(--fs-caption);
  letter-spacing: 0.06em;
  color: var(--muted);
}
.matrix .desc {
  margin: 0;
  font-size: var(--fs-sm);
  line-height: 1.65;
  color: var(--muted);
}

@media (max-width: 720px) {
  .hero {
    grid-template-columns: 1fr;
    gap: var(--space-6);
    align-items: start;
    padding: var(--space-7) 0 var(--space-6);
  }
  .hero-slogan { max-width: none; margin-top: var(--space-5); }
  .dirs { grid-template-columns: 1fr; }
  .nav { gap: var(--space-3); }
  .site-header { padding: var(--space-4) var(--pad-x); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  body::before {
    animation: none !important;
    transform: none !important;
  }
  .enter {
    opacity: 1 !important;
    transform: none !important;
    animation: none !important;
  }
  .reveal,
  .reveal.is-in {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
  .btn { transition: filter var(--hover-dur) ease; }
  .btn:hover,
  .btn:active {
    transform: none;
    box-shadow: none;
  }
}
