:root {
  --jn-ink: #2c2f2b;
  --jn-ink-soft: #5d615b;
  --jn-paper: #f5f3ee;
  --jn-card: #fbfaf7;
  --jn-line: #dedbd2;
  --jn-accent: #6d7f6b;
  --jn-accent-dark: #536450;
  --jn-danger: #9a5a4c;
  --jn-radius: 4px;
}

* { box-sizing: border-box; }

body.jn-h5-body,
.jn-h5 {
  margin: 0;
  padding: 0;
  background: var(--jn-paper);
  color: var(--jn-ink);
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  font-size: 16px;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
}

.jn-h5 { max-width: 760px; margin: 0 auto; min-height: 100vh; }
.jn-h5-body { padding: 0; }

.jn-h5-header {
  padding: 46px 22px 32px;
  text-align: center;
  border-bottom: 1px solid var(--jn-line);
}
.jn-portrait {
  width: 116px; height: 116px; margin: 0 auto 20px;
  border-radius: 50%; overflow: hidden;
  background: #e8e5dd; border: 1px solid var(--jn-line);
  display: flex; align-items: center; justify-content: center;
}
.jn-portrait img { width: 100%; height: 100%; object-fit: cover; display: block; }
.jn-portrait-empty { font-family: "Songti SC", "SimSun", serif; font-size: 36px; color: var(--jn-ink-soft); }
.jn-h5-header h1 {
  font-family: "Songti SC", "STSong", "SimSun", serif;
  font-size: 30px; font-weight: 500; letter-spacing: 4px; margin: 0 0 8px;
}
.jn-dates { color: var(--jn-ink-soft); font-size: 14px; letter-spacing: 1px; margin: 0; }
.jn-epitaph {
  margin: 22px auto 0; max-width: 520px;
  font-family: "Songti SC", "SimSun", serif;
  font-size: 17px; color: var(--jn-ink-soft);
  border-left: 2px solid var(--jn-accent); padding-left: 16px; text-align: left;
}
.jn-h5-section { padding: 30px 22px; border-bottom: 1px solid var(--jn-line); }
.jn-h5-section h2 {
  font-family: "Songti SC", "SimSun", serif;
  font-size: 19px; font-weight: 500; letter-spacing: 2px;
  margin: 0 0 18px; padding-left: 10px; border-left: 3px solid var(--jn-accent);
}
.jn-prose { white-space: normal; color: var(--jn-ink-soft); margin: 0 0 12px; }

.jn-timeline { position: relative; padding-left: 18px; }
.jn-timeline::before { content: ""; position: absolute; left: 3px; top: 6px; bottom: 6px; width: 1px; background: var(--jn-line); }
.jn-timeline-item { position: relative; padding: 0 0 26px 12px; }
.jn-timeline-item::before {
  content: ""; position: absolute; left: -19px; top: 9px;
  width: 7px; height: 7px; border-radius: 50%; background: var(--jn-accent);
}
.jn-year { font-size: 13px; color: var(--jn-accent-dark); letter-spacing: 2px; }
.jn-timeline-item h3 { font-size: 17px; font-weight: 600; margin: 2px 0 8px; }
.jn-media-strip { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 10px; margin-top: 12px; }
.jn-media-strip figure { margin: 0; }
.jn-media-strip img, .jn-media-strip video { width: 100%; display: block; border-radius: var(--jn-radius); border: 1px solid var(--jn-line); }
.jn-media-strip audio { width: 100%; }

.jn-family-tree, .jn-family-children { list-style: none; margin: 0; padding: 0; }
.jn-family-tree li { padding: 10px 0; border-bottom: 1px dashed var(--jn-line); }
.jn-family-children li { border-left: 1px solid var(--jn-line); padding-left: 12px; }
.jn-family-name { font-weight: 600; margin-right: 10px; }
.jn-family-relation { color: var(--jn-accent-dark); font-size: 14px; }
.jn-family-note { display: block; color: var(--jn-ink-soft); font-size: 14px; }

.jn-h5-message { padding: 14px 0; border-bottom: 1px dashed var(--jn-line); }
.jn-h5-message p { margin: 0 0 4px; }
.jn-h5-footer { padding: 28px 22px 50px; text-align: center; color: var(--jn-ink-soft); font-size: 13px; }
.jn-h5-footer a { color: var(--jn-accent-dark); }

.jn-h5-state { padding: 90px 24px; text-align: center; }
.jn-seal {
  width: 58px; height: 58px; margin: 0 auto 24px; border: 1px solid var(--jn-accent);
  color: var(--jn-accent-dark); display: flex; align-items: center; justify-content: center;
  font-family: "Songti SC", "SimSun", serif; font-size: 26px; border-radius: 2px;
}
.jn-h5-state h1 { font-family: "Songti SC", "SimSun", serif; font-weight: 500; font-size: 24px; letter-spacing: 3px; }
.jn-h5-state p { color: var(--jn-ink-soft); }

/* 通用表单 / 用户中心 */
.jn-form { display: block; }
.jn-form label { display: block; margin: 0 0 14px; font-size: 14px; color: var(--jn-ink-soft); }
.jn-form input:not([type=checkbox]):not([type=radio]):not([type=file]),
.jn-form textarea, .jn-form select {
  display: block; width: 100%; margin-top: 6px; padding: 10px 12px;
  border: 1px solid var(--jn-line); border-radius: var(--jn-radius);
  background: #fff; color: var(--jn-ink); font: inherit; font-size: 15px;
}
.jn-form textarea { resize: vertical; }
.jn-form input:focus, .jn-form textarea:focus, .jn-form select:focus { outline: none; border-color: var(--jn-accent); }
.jn-check { display: flex !important; gap: 8px; align-items: flex-start; font-size: 13px !important; }
.jn-check input { margin-top: 5px; }
.jn-inline { display: flex; gap: 8px; align-items: center; }
.jn-inline > input { flex: 1; }
.jn-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.jn-honeypot { position: absolute !important; left: -9999px !important; width: 1px !important; height: 1px !important; }

.jn-btn {
  display: inline-block; border: 1px solid var(--jn-accent); border-radius: var(--jn-radius);
  background: var(--jn-accent); color: #fff; padding: 9px 18px; font-size: 14px;
  cursor: pointer; text-decoration: none; line-height: 1.5; white-space: nowrap;
}
.jn-btn:hover { background: var(--jn-accent-dark); border-color: var(--jn-accent-dark); color: #fff; }
.jn-btn-ghost, .jn-btn-outline { background: transparent; color: var(--jn-accent-dark); }
.jn-btn-ghost:hover, .jn-btn-outline:hover { background: #ece9e1; color: var(--jn-accent-dark); border-color: var(--jn-accent); }
.jn-btn-primary { background: var(--jn-accent-dark); border-color: var(--jn-accent-dark); }
.jn-btn:disabled { opacity: .55; cursor: default; }

.jn-card, .jn-box {
  background: var(--jn-card); border: 1px solid var(--jn-line); border-radius: var(--jn-radius);
  padding: 20px; margin: 0 0 20px;
}
.jn-muted { color: var(--jn-ink-soft); font-size: 14px; }
.jn-hint { color: var(--jn-ink-soft); font-size: 13px; }
.jn-notice {
  background: #f0ece2; border-left: 3px solid var(--jn-accent); padding: 12px 16px;
  margin: 16px 0; font-size: 14px;
}
.jn-label { display: block; font-size: 13px; color: var(--jn-ink-soft); margin-bottom: 6px; }
.jn-form-message { margin-top: 12px; font-size: 14px; min-height: 20px; }
.jn-form-message.is-error { color: var(--jn-danger); }
.jn-form-message.is-success { color: var(--jn-accent-dark); }

.jn-auth { max-width: 420px; margin: 40px auto; padding: 0 20px; }
.jn-auth-tabs { display: flex; border-bottom: 1px solid var(--jn-line); margin-bottom: 24px; }
.jn-auth-tabs a { flex: 1; text-align: center; padding: 10px 0; color: var(--jn-ink-soft); text-decoration: none; }
.jn-auth-tabs a.active { color: var(--jn-accent-dark); border-bottom: 2px solid var(--jn-accent); }
.jn-auth-foot { text-align: right; font-size: 14px; }

.jn-dashboard, .jn-shop, .jn-public-messages { max-width: 960px; margin: 0 auto; padding: 28px 18px 60px; }
.jn-dash-header { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-bottom: 24px; }
.jn-dash-header h1, .jn-shop h1, .jn-public-messages h1 { font-family: "Songti SC", "SimSun", serif; font-weight: 500; letter-spacing: 2px; margin: 0 0 4px; }
.jn-dash-header p { margin: 0; }
.jn-permalink { display: flex; gap: 8px; align-items: center; margin-top: 12px; }
.jn-permalink input { flex: 1; padding: 9px 10px; border: 1px solid var(--jn-line); background: #fff; font-size: 13px; }
.jn-tabs { display: flex; flex-wrap: wrap; gap: 4px; border-bottom: 1px solid var(--jn-line); margin: 24px 0 20px; }
.jn-tabs button { border: 0; background: none; padding: 10px 14px; color: var(--jn-ink-soft); cursor: pointer; font-size: 14px; }
.jn-tabs button.active { color: var(--jn-accent-dark); border-bottom: 2px solid var(--jn-accent); }
.jn-panel { display: none; }
.jn-panel.active { display: block; }
.jn-list { margin-top: 16px; }
.jn-list-item { background: var(--jn-card); border: 1px solid var(--jn-line); padding: 14px 16px; margin-bottom: 10px; }
.jn-list-item h3 { margin: 0 0 6px; font-size: 16px; }
.jn-list-item p { margin: 0 0 6px; font-size: 14px; color: var(--jn-ink-soft); }
.jn-list-item .jn-actions { margin-top: 8px; display: flex; gap: 8px; flex-wrap: wrap; }
.jn-link-btn { border: 0; background: none; color: var(--jn-accent-dark); cursor: pointer; padding: 0; font-size: 13px; text-decoration: underline; }
.jn-link-btn.danger { color: var(--jn-danger); }
.jn-media-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; margin-top: 16px; }
.jn-media-item { background: var(--jn-card); border: 1px solid var(--jn-line); padding: 8px; }
.jn-media-item img, .jn-media-item video { width: 100%; display: block; }
.jn-media-item p { font-size: 12px; word-break: break-all; margin: 6px 0; }
.jn-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0; }
.jn-chip { background: #ece9e1; padding: 4px 10px; font-size: 13px; display: inline-flex; gap: 8px; align-items: center; }
.jn-chip button { border: 0; background: none; cursor: pointer; color: var(--jn-danger); }
.jn-product-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; margin: 24px 0; }
.jn-product h2 { margin: 0 0 8px; font-size: 18px; }
.jn-price { font-size: 24px; color: var(--jn-accent-dark); margin: 0 0 10px; }
.jn-table-wrap { overflow-x: auto; }
.jn-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.jn-table th, .jn-table td { border: 1px solid var(--jn-line); padding: 8px 10px; text-align: left; }
.jn-message-card h2 { font-size: 16px; margin: 0 0 8px; }
.jn-message-card blockquote { margin: 0 0 8px; color: var(--jn-ink); }

/* 官网首页 */
.jn-home { max-width: 1040px; margin: 0 auto; padding: 0 20px 60px; }
.jn-hero { text-align: center; padding: 80px 16px 60px; border-bottom: 1px solid var(--jn-line); }
.jn-hero h1 { font-family: "Songti SC", "SimSun", serif; font-weight: 500; font-size: 34px; letter-spacing: 5px; margin: 0 0 18px; }
.jn-hero p { color: var(--jn-ink-soft); font-size: 15px; line-height: 2; }
.jn-hero-actions { display: flex; gap: 12px; justify-content: center; margin-top: 26px; flex-wrap: wrap; }
.jn-home-section { padding: 44px 0; border-bottom: 1px solid var(--jn-line); }
.jn-home-section h2 { font-family: "Songti SC", "SimSun", serif; font-weight: 500; font-size: 22px; letter-spacing: 3px; margin: 0 0 24px; }
.jn-home-section h3 { font-size: 17px; margin: 28px 0 12px; }
.jn-steps { padding-left: 20px; color: var(--jn-ink-soft); }
.jn-steps li { margin: 8px 0; }
.jn-case-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 14px; }
.jn-case { display: flex; flex-direction: column; gap: 6px; text-decoration: none; color: var(--jn-ink); }
.jn-home-cta { text-align: center; }
.jn-home-footer { display: flex; gap: 18px; justify-content: center; padding-top: 24px; font-size: 13px; }

@media (max-width: 600px) {
  .jn-grid-2 { grid-template-columns: 1fr; }
  .jn-inline { flex-wrap: wrap; }
  .jn-inline .jn-btn { width: 100%; }
  .jn-tabs button { padding: 9px 10px; }
  .jn-h5-header { padding-top: 34px; }
  .jn-h5-header h1 { font-size: 26px; }
}

/* ------------------------------------------------------------
   H5 纪念档案 · 阅读节奏与交互细节
   ------------------------------------------------------------ */
.jn-h5 {
  --h5-bg: #f7f4ee;
  --h5-paper: #ffffff;
  --h5-ink: #3a3430;
  --h5-muted: #8a7f74;
  --h5-accent: #b58a54;
  --h5-line: #e6e1d8;
  --h5-track: #d8cfbf;
  width: 100%;
  max-width: 640px;
  margin: 0 auto;
  background: var(--h5-bg);
  color: var(--h5-ink);
}

.jn-h5-body,
.jn-luxury.jn-h5-body {
  background: var(--h5-bg) !important;
  color: var(--h5-ink) !important;
}

.jn-h5-topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  justify-content: space-between;
  padding: 12px 18px;
  background: rgba(247,244,238,.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(230,225,216,.8);
}
.jn-h5-tool {
  border: 0;
  background: transparent;
  color: var(--h5-muted);
  font-size: 13px;
  padding: 6px 4px;
  cursor: pointer;
}

.jn-h5 .jn-reveal,
.jn-h5 .jn-reveal-item {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 600ms ease-out, transform 600ms ease-out;
  transition-delay: var(--jn-delay, 0ms);
}
.jn-h5 .jn-reveal.is-visible,
.jn-h5 .jn-reveal-item.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.jn-h5 .jn-fade-media img {
  opacity: 0;
  transition: opacity 600ms ease-out, filter 600ms ease-out;
}
.jn-h5 .jn-fade-media img.is-loaded {
  opacity: 1;
}

.jn-h5 .jn-h5-header {
  padding: 42px 24px 46px;
  text-align: center;
  border-bottom: 1px solid var(--h5-line);
  background: linear-gradient(180deg, #fbf9f4 0%, var(--h5-bg) 100%);
}
.jn-h5 .jn-portrait {
  width: 108px;
  height: 108px;
  border: 1px solid rgba(181,138,84,.55);
  background: #efe9dd;
  box-shadow: 0 12px 30px rgba(80,60,35,.08);
}
.jn-h5 .jn-portrait img { width: 100%; height: 100%; object-fit: cover; }
.jn-h5 .jn-portrait-empty { color: #a89b8a; }
.jn-h5 .jn-h5-header h1 {
  margin: 22px 0 8px;
  font-size: 30px;
  font-weight: 600;
  letter-spacing: 4px;
  color: var(--h5-ink);
  line-height: 1.5;
}
.jn-h5 .jn-dates { font-size: 13px; letter-spacing: 1px; color: var(--h5-muted); }
.jn-h5 .jn-epitaph-card {
  margin: 24px auto 0;
  max-width: 460px;
  padding: 18px 20px;
  background: var(--h5-paper);
  border-radius: 16px;
  border: 1px solid var(--h5-line);
  color: #6d6055;
  font-size: 15px;
  line-height: 1.9;
  box-shadow: 0 10px 26px rgba(80,60,35,.05);
}

.jn-h5 .jn-h5-section {
  padding: 34px 24px;
  border-bottom: 1px solid var(--h5-line);
}
.jn-h5 .jn-h5-section h2 {
  margin: 0 0 8px;
  color: var(--h5-ink);
  font-family: "Songti SC", "STSong", "SimSun", serif;
  font-size: 21px;
  font-weight: 600;
  letter-spacing: 3px;
}
.jn-h5 .jn-section-sub {
  margin: 0 0 24px;
  color: var(--h5-muted);
  font-size: 13px;
  line-height: 1.8;
}
.jn-h5 .jn-prose {
  color: #5c524a;
  font-size: 15px;
  line-height: 2;
  letter-spacing: .3px;
}

/* 人生时光线 */
.jn-h5 .jn-timeline { position: relative; padding-left: 26px; }
.jn-h5 .jn-timeline::before {
  content: "";
  position: absolute;
  left: 7px;
  top: 8px;
  bottom: 18px;
  width: 1px;
  background: var(--h5-track);
}
.jn-h5 .jn-timeline-item { position: relative; margin-bottom: 22px; }
.jn-h5 .jn-timeline-track {
  position: absolute;
  left: -26px;
  top: 24px;
  width: 15px;
  height: 15px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.jn-h5 .jn-timeline-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--h5-accent);
  box-shadow: 0 0 0 4px rgba(181,138,84,.12);
  transition: box-shadow 300ms ease-out, background 300ms ease-out;
}
.jn-h5 .jn-timeline-item.is-active .jn-timeline-dot {
  box-shadow: 0 0 0 7px rgba(181,138,84,.2);
}
.jn-h5 .jn-story-card {
  background: var(--h5-paper);
  border-radius: 16px;
  padding: 20px 20px 18px;
  box-shadow: 0 12px 30px rgba(80,60,35,.06);
  transition: box-shadow 300ms ease-out, background 300ms ease-out, opacity 220ms ease-out, transform 220ms ease-out;
}
.jn-h5 .jn-timeline-item.is-active .jn-story-card {
  background: #fffdf8;
  box-shadow: 0 16px 38px rgba(80,60,35,.1);
}
.jn-h5 .jn-story-card.is-switching { opacity: 0; transform: translateY(-6px); }
.jn-h5 .jn-year {
  color: var(--h5-accent);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 2px;
}
.jn-h5 .jn-story-card h3 {
  margin: 6px 0 10px;
  font-size: 17px;
  font-weight: 600;
  color: var(--h5-ink);
}
.jn-h5 .jn-story-content {
  color: #5c524a;
  font-size: 14px;
  line-height: 1.95;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.jn-h5 .jn-story-card.is-expanded .jn-story-content { -webkit-line-clamp: unset; }
.jn-h5 .jn-story-toggle {
  margin-top: 8px;
  border: 0;
  background: transparent;
  color: var(--h5-accent);
  font-size: 12px;
  padding: 4px 0;
  cursor: pointer;
}
.jn-h5 .jn-timeline-nav {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 18px;
  margin-top: 18px;
}
.jn-h5 .jn-timeline-nav button {
  border: 1px solid var(--h5-line);
  background: var(--h5-paper);
  border-radius: 999px;
  padding: 8px 16px;
  color: var(--h5-muted);
  font-size: 12px;
  cursor: pointer;
}
.jn-h5 .jn-timeline-nav span { font-size: 12px; color: var(--h5-muted); }

/* 影像珍藏 */
.jn-h5 .jn-gallery {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding: 4px 0 14px;
  -webkit-overflow-scrolling: touch;
}
.jn-h5 .jn-gallery::-webkit-scrollbar { display: none; }
.jn-h5 .jn-gallery-item {
  flex: 0 0 76%;
  margin: 0;
  scroll-snap-align: center;
  background: var(--h5-paper);
  border-radius: 16px;
  padding: 8px;
  box-shadow: 0 12px 30px rgba(80,60,35,.06);
  cursor: pointer;
}
.jn-h5 .jn-gallery-item:nth-child(2n) { flex-basis: 68%; }
.jn-h5 .jn-gallery-item img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 12px;
  filter: saturate(.82) sepia(.08) contrast(.96);
}
.jn-h5 .jn-gallery-item figcaption {
  margin-top: 8px;
  color: var(--h5-muted);
  font-size: 12px;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.jn-h5 .jn-gallery-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
}
.jn-h5 .jn-gallery-dots span {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--h5-line);
  transition: background 200ms ease-out, width 200ms ease-out;
}
.jn-h5 .jn-gallery-dots span.is-active { width: 14px; border-radius: 4px; background: var(--h5-accent); }

/* 家族谱系 */
.jn-h5 .jn-family-viewport {
  overflow: hidden;
  min-height: 320px;
  border-radius: 16px;
  background: #fffdf8;
  border: 1px solid var(--h5-line);
  touch-action: none;
}
.jn-h5 .jn-family-canvas {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 30px;
  padding: 30px 20px;
  transform-origin: center center;
  will-change: transform;
}
.jn-h5 .jn-family-row {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  position: relative;
}
.jn-h5 .jn-family-row--parents::after,
.jn-h5 .jn-family-row--children::before {
  content: "";
  position: absolute;
  left: 50%;
  width: 1px;
  height: 18px;
  background: var(--h5-track);
}
.jn-h5 .jn-family-row--parents::after { bottom: -18px; }
.jn-h5 .jn-family-row--children::before { top: -18px; }
.jn-h5 .jn-family-node {
  width: 96px;
  min-height: 92px;
  border: 1px solid var(--h5-line);
  border-radius: 14px;
  background: #fff;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 10px 6px;
  cursor: pointer;
  color: var(--h5-ink);
}
.jn-h5 .jn-family-node--self { border-color: var(--h5-accent); box-shadow: 0 8px 22px rgba(181,138,84,.14); }
.jn-h5 .jn-family-avatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: #f1ece3;
  color: var(--h5-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
}
.jn-h5 .jn-family-name { font-size: 13px; font-weight: 600; }
.jn-h5 .jn-family-relation { font-size: 11px; color: var(--h5-muted); }
.jn-h5 .jn-family-hint { margin: 10px 0 0; text-align: center; font-size: 11px; color: var(--h5-muted); }

/* 留言 */
.jn-h5 .jn-message-form { margin-bottom: 22px; background: #fffdf8; }
.jn-h5 .jn-h5-message {
  background: var(--h5-paper);
  border-radius: 16px;
  padding: 16px 18px;
  margin-bottom: 12px;
  box-shadow: 0 10px 26px rgba(80,60,35,.05);
}

/* 页脚 */
.jn-h5 .jn-h5-footer {
  padding: 34px 24px 52px;
  text-align: center;
  background: #f1ece3;
  color: var(--h5-muted);
  font-size: 12px;
  line-height: 2;
}
.jn-h5 .jn-footer-actions {
  display: flex;
  justify-content: center;
  gap: 18px;
  margin-top: 12px;
}
.jn-h5 .jn-footer-actions button,
.jn-h5 .jn-footer-actions a {
  border: 0;
  background: transparent;
  color: var(--h5-accent);
  font-size: 12px;
  text-decoration: none;
  cursor: pointer;
}

/* 灯箱 / 节点详情 / 轻提示 */
.jn-lightbox,
.jn-family-modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(28,24,20,.88);
  padding: 20px;
}
.jn-lightbox[hidden],
.jn-family-modal[hidden] { display: none; }
.jn-lightbox img { max-width: 100%; max-height: 76vh; border-radius: 10px; }
.jn-lightbox-close,
.jn-family-modal-close {
  position: absolute;
  top: 18px;
  right: 20px;
  border: 0;
  background: transparent;
  color: #fff;
  font-size: 28px;
  cursor: pointer;
}
.jn-lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  border: 0;
  background: rgba(255,255,255,.12);
  color: #fff;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  font-size: 26px;
  cursor: pointer;
}
.jn-lightbox-prev { left: 12px; }
.jn-lightbox-next { right: 12px; }
.jn-lightbox-caption {
  position: absolute;
  bottom: 24px;
  color: #e8ded0;
  font-size: 12px;
}
.jn-family-modal-card {
  position: relative;
  width: min(340px, 90vw);
  background: #fffdf8;
  border-radius: 16px;
  padding: 28px 24px;
  color: var(--h5-ink);
}
.jn-family-modal-card h3 { margin: 0 0 10px; font-size: 19px; }
.jn-family-modal-card p { margin: 4px 0; font-size: 13px; color: var(--h5-muted); line-height: 1.8; }
.jn-family-modal-close { color: var(--h5-muted); top: 10px; right: 14px; font-size: 22px; }
.jn-toast {
  position: fixed;
  left: 50%;
  bottom: 32px;
  transform: translate(-50%, 12px);
  background: rgba(58,52,48,.92);
  color: #fff;
  padding: 10px 18px;
  border-radius: 999px;
  font-size: 12px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 250ms ease-out, transform 250ms ease-out;
  z-index: 120;
}
.jn-toast.is-visible { opacity: 1; transform: translate(-50%, 0); }

@media (prefers-reduced-motion: reduce) {
  .jn-h5 .jn-reveal,
  .jn-h5 .jn-reveal-item,
  .jn-h5 .jn-fade-media img { opacity: 1 !important; transform: none !important; transition: none !important; }
}

/* H5 访问验证、详情页与空状态 */
.jn-access-gate { max-width: 420px; margin: 0 auto; padding-top: 62px; }
.jn-access-icon { width: 76px; height: 76px; margin: 0 auto 22px; border: 1px solid rgba(181,138,84,.5); border-radius: 50%; display: flex; align-items: center; justify-content: center; color: #b58a54; background: #fffdf8; }
.jn-access-eyebrow { color: #9b8b79; font-size: 12px; letter-spacing: 1px; }
.jn-access-boxes { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; max-width: 300px; margin: 28px auto; }
.jn-access-boxes input { height: 60px; text-align: center; border: 1px solid #e3d9cb; border-radius: 12px; background: #fffdf8; color: #3a3430; font-size: 22px; outline: none; transition: border-color 300ms ease-out, box-shadow 300ms ease-out; }
.jn-access-boxes input:focus { border-color: #b58a54; box-shadow: 0 8px 20px rgba(181,138,84,.12); }
.jn-access-help { margin-top: 20px; color: #8a7c6c; font-size: 12px; }
.jn-access-note { margin-top: 18px; padding: 14px 18px; border-radius: 12px; background: #f1ece3; color: #8a7c6c; font-size: 12px; line-height: 1.8; }
.jn-empty-card { padding: 26px; text-align: center; border-radius: 16px; background: #fffdf8; border: 1px solid var(--h5-line); color: #9b8b79; font-size: 13px; line-height: 1.8; }
.jn-video-poster { position: relative; min-height: 180px; border-radius: 12px; background: linear-gradient(135deg, #d8c6ad, #efe6da); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; cursor: pointer; }
.jn-video-play { width: 48px; height: 48px; border: 1px solid rgba(181,138,84,.7); border-radius: 50%; color: #b58a54; display: flex; align-items: center; justify-content: center; font-size: 16px; }

.jn-story-modal,
.jn-family-modal,
.jn-lightbox { animation: jn-fade-in 300ms ease-out; }
@keyframes jn-fade-in { from { opacity: 0; } to { opacity: 1; } }
.jn-story-modal { position: fixed; inset: 0; z-index: 90; display: flex; align-items: center; justify-content: center; padding: 18px; background: rgba(36,30,25,.78); }
.jn-story-modal[hidden] { display: none; }
.jn-story-modal-card { position: relative; width: min(560px, 94vw); max-height: 88vh; overflow-y: auto; border-radius: 18px; background: #fffdf8; padding: 30px 24px 24px; box-shadow: 0 30px 80px rgba(0,0,0,.25); }
.jn-story-modal-close { position: absolute; right: 16px; top: 12px; border: 0; background: transparent; color: #8a7c6c; font-size: 24px; cursor: pointer; }
.jn-story-modal-card h2 { margin: 8px 0 16px; font-family: "Songti SC", serif; font-size: 22px; color: #3a3430; }
.jn-story-modal-card .jn-story-content { display: block; color: #5c524a; font-size: 14px; line-height: 2; }
.jn-story-modal-media { margin-top: 18px; }
.jn-story-modal-media img { width: 100%; border-radius: 12px; filter: saturate(.82) sepia(.08); }
.jn-story-modal-nav { display: flex; justify-content: center; align-items: center; gap: 18px; margin-top: 24px; }
.jn-story-modal-nav button { border: 1px solid #e6e1d8; border-radius: 999px; background: #fff; color: #8a7c6c; padding: 9px 18px; font-size: 12px; cursor: pointer; }
.jn-story-modal-nav button:disabled { opacity: .4; cursor: default; }
.jn-story-modal-nav span { color: #9b8b79; font-size: 12px; }
.jn-video-modal { position: fixed; inset: 0; z-index: 110; display: flex; align-items: center; justify-content: center; background: rgba(26,22,19,.9); padding: 18px; animation: jn-fade-in 300ms ease-out; }
.jn-video-modal video { width: min(720px, 96vw); max-height: 82vh; border-radius: 12px; }

/* ------------------------------------------------------------
   官网叙事首页与我的记忆馆
   ------------------------------------------------------------ */
/* 覆盖旧版子主题中的深色 Hero，确保首页回到米白叙事基调 */
.jn-luxury .jn-home .jn-hero {
  background: #f7f4ee !important;
  color: #4a392b !important;
  text-align: left;
  box-shadow: none !important;
}
.jn-luxury .jn-home .jn-hero::before { display: none !important; }
.jn-luxury .jn-home .jn-hero h1 { color: #4a392b !important; text-shadow: none !important; }
.jn-luxury .jn-home .jn-hero p { color: #75685c !important; }
.jn-luxury .jn-home .jn-seal { display: none; }

.jn-site-nav {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 14px 28px;
  background: rgba(247,244,238,.72);
  border-bottom: 1px solid rgba(230,225,216,.8);
  backdrop-filter: blur(14px);
}
.jn-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #4a3a2b;
  font-family: "Songti SC", "SimSun", serif;
  font-size: 18px;
  font-weight: 600;
  letter-spacing: 2px;
  text-decoration: none;
}
.jn-brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border: 1px solid rgba(181,138,84,.6);
  border-radius: 50%;
  font-size: 13px;
  color: #9c7444;
}
.jn-nav-links { display: flex; align-items: center; gap: 24px; flex-wrap: wrap; }
.jn-nav-links a { color: #6a5d50; font-size: 13px; text-decoration: none; transition: color .3s ease; }
.jn-nav-links a:hover { color: #b58a54; }
.jn-nav-toggle { display: none; border: 0; background: transparent; color: #6a5d50; font-size: 22px; cursor: pointer; }

.jn-hero--split {
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  align-items: center;
  gap: 40px;
  min-height: 70vh;
  text-align: left;
  padding: 90px 28px 80px;
  border-bottom: 1px solid var(--jn-line);
}
.jn-hero-copy h1 {
  font-family: "Songti SC", "STSong", "SimSun", serif;
  font-size: clamp(38px, 5vw, 62px);
  font-weight: 600;
  line-height: 1.38;
  letter-spacing: 3px;
  color: #4a392b;
}
.jn-hero-copy p { max-width: 560px; margin: 22px 0 0; font-size: 15px; line-height: 2.05; color: #75685c; }
.jn-hero--split .jn-hero-actions { justify-content: flex-start; margin-top: 32px; }
.jn-hero-visual { position: relative; min-height: 380px; }
.jn-hero-halo {
  position: absolute;
  inset: 10% 4%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(214,184,138,.3), transparent 62%);
  filter: blur(6px);
}
.jn-hero-card {
  position: absolute;
  left: 4%;
  top: 22%;
  width: 220px;
  height: 142px;
  border-radius: 18px;
  background: linear-gradient(135deg, #d9b988, #b88b55);
  box-shadow: 0 30px 60px rgba(120,85,45,.22);
  transform: rotate(-8deg);
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 22px;
  color: rgba(255,255,255,.86);
  font-family: "Songti SC", serif;
  letter-spacing: 4px;
}
.jn-hero-card i { display: block; width: 34px; height: 34px; border: 1px solid rgba(255,255,255,.5); border-radius: 50%; opacity: .7; }
.jn-hero-card--large { position: relative; left: auto; top: auto; width: min(360px, 80vw); height: 230px; transform: rotate(-6deg); }
.jn-hero-phone {
  position: absolute;
  right: 8%;
  top: 10%;
  width: 220px;
  height: 390px;
  border: 8px solid #2a2724;
  border-radius: 38px;
  background: #fffdf8;
  box-shadow: 0 38px 70px rgba(50,40,30,.22);
  transform: rotate(6deg);
  overflow: hidden;
}
.jn-hero-phone--large { position: relative; right: auto; top: auto; margin: 0 auto; transform: rotate(5deg); }
.jn-phone-notch { width: 74px; height: 14px; margin: 8px auto; border-radius: 0 0 12px 12px; background: #2a2724; }
.jn-phone-screen { padding: 26px 22px; }
.jn-phone-avatar { width: 72px; height: 72px; border-radius: 50%; background: #e8ddce; margin: 0 auto 16px; border: 1px solid #cdb897; }
.jn-phone-line { height: 8px; border-radius: 4px; background: #e6ded3; margin: 10px 0; }
.jn-phone-line--title { width: 62%; height: 14px; margin-left: auto; margin-right: auto; background: #cdb897; }
.jn-phone-line--short { width: 55%; }
.jn-phone-photo { margin-top: 22px; height: 100px; border-radius: 12px; background: linear-gradient(135deg, #d8c6ad, #efe6da); }

.jn-section-sub { color: #8a7c6c; font-size: 14px; line-height: 1.9; }
.jn-card-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  margin-bottom: 16px;
  border-radius: 50%;
  background: #f4eee3;
  color: #a87f4f;
  font-family: "Songti SC", serif;
  font-size: 18px;
}
.jn-home-steps { list-style: none; display: grid; grid-template-columns: repeat(5, 1fr); gap: 14px; margin: 30px 0 0; padding: 0; counter-reset: step; }
.jn-home-steps li { position: relative; padding: 22px 16px; background: #fffdf8; border-radius: 14px; border: 1px solid #eadfd0; }
.jn-home-steps li span { display: block; font-family: Georgia, serif; color: #b58a54; font-size: 22px; margin-bottom: 10px; }
.jn-home-steps li strong { display: block; font-size: 14px; margin-bottom: 6px; }
.jn-home-steps li p { margin: 0; color: #8a7c6c; font-size: 12px; line-height: 1.8; }
.jn-plan-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.jn-plan { position: relative; padding: 30px 24px; }
.jn-plan--featured { border-color: rgba(181,138,84,.55); box-shadow: 0 18px 44px rgba(120,85,45,.12); }
.jn-plan-badge { position: absolute; top: 16px; right: 18px; color: #b58a54; font-size: 12px; }
.jn-plan ul { list-style: none; padding: 0; margin: 18px 0 26px; color: #6f6458; font-size: 13px; line-height: 2; }
.jn-case-avatar { display: block; width: 60px; height: 60px; border-radius: 50%; background: #eee5d8; color: #b58a54; line-height: 60px; text-align: center; margin-bottom: 12px; }
.jn-faq details { padding: 0 20px; margin-bottom: 10px; }
.jn-faq summary { padding: 18px 0; cursor: pointer; color: #4a3a2b; font-size: 14px; }
.jn-faq details p { margin: 0 0 18px; color: #7d7063; font-size: 13px; line-height: 1.9; }
.jn-split-section { display: grid; grid-template-columns: 1fr 1fr; gap: 42px; align-items: center; }
.jn-split-section--reverse .jn-split-visual { order: -1; }
.jn-split-visual { min-height: 300px; display: flex; align-items: center; justify-content: center; }
.jn-soft-list { list-style: none; padding: 0; color: #6f6458; line-height: 2.2; }

.jn-global-toast {
  position: fixed;
  left: 50%;
  bottom: 32px;
  z-index: 200;
  transform: translate(-50%, 12px);
  background: rgba(58,52,48,.94);
  color: #fff;
  padding: 10px 18px;
  border-radius: 999px;
  font-size: 12px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 250ms ease-out, transform 250ms ease-out;
}
.jn-global-toast.is-visible { opacity: 1; transform: translate(-50%, 0); }

/* 我的记忆馆 */
.jn-memorial-hall { display: grid; grid-template-columns: 220px 1fr; gap: 0; max-width: none; padding: 0; }
.jn-hall-sidebar { position: sticky; top: 0; height: 100vh; padding: 28px 18px; background: #292520; color: #e8ddcc; }
.jn-hall-user { display: flex; align-items: center; gap: 10px; margin-bottom: 30px; font-size: 13px; }
.jn-hall-avatar { width: 34px; height: 34px; border-radius: 50%; background: #d8b98c; color: #292520; display: flex; align-items: center; justify-content: center; }
.jn-hall-nav button { display: block; width: 100%; text-align: left; border: 0; border-radius: 10px; background: transparent; color: #c9bba8; padding: 11px 12px; margin-bottom: 6px; cursor: pointer; font-size: 13px; transition: background .25s ease, color .25s ease; }
.jn-hall-nav button:hover, .jn-hall-nav button.active { background: rgba(216,185,140,.12); color: #f2e4ce; }
.jn-hall-logout { margin-top: 24px; border: 1px solid rgba(232,221,204,.3); background: transparent; color: #d8c9b5; border-radius: 999px; padding: 8px 16px; cursor: pointer; }
.jn-hall-main { padding: 34px 36px 70px; min-width: 0; }
.jn-hall-eyebrow { margin: 0; color: #b58a54; font-size: 12px; letter-spacing: 2px; }
.jn-hall-header h1 { margin: 6px 0 4px; font-family: "Songti SC", serif; font-size: 28px; font-weight: 500; }
.jn-hall-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin: 24px 0; }
.jn-hall-stats .jn-card { padding: 22px; background: linear-gradient(135deg, #fffdf8, #f6efe4); }
.jn-hall-stats span { display: block; color: #8a7c6c; font-size: 12px; margin-bottom: 8px; }
.jn-hall-stats strong { font-family: Georgia, "Songti SC", serif; color: #6a543f; font-size: 24px; }
.jn-hall-section-head { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; }
.jn-archive-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; margin: 18px 0; }
.jn-archive-card { padding: 22px; text-align: center; }
.jn-archive-avatar { width: 64px; height: 64px; margin: 0 auto 14px; border-radius: 50%; background: #eee5d8; color: #b58a54; line-height: 64px; font-family: "Songti SC", serif; }
.jn-archive-card h3 { margin: 0 0 6px; font-size: 16px; }
.jn-archive-actions { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; margin-top: 16px; }

@media (max-width: 900px) {
  .jn-nav-links { display: none; position: absolute; top: 64px; left: 0; right: 0; padding: 18px 24px; background: rgba(247,244,238,.96); border-bottom: 1px solid var(--jn-line); }
  .jn-nav-links.is-open { display: flex; }
  .jn-nav-toggle { display: block; }
  .jn-hero--split, .jn-split-section { grid-template-columns: 1fr; }
  .jn-hero-visual { min-height: 320px; }
  .jn-split-section--reverse .jn-split-visual { order: 0; }
  .jn-home-steps, .jn-plan-grid { grid-template-columns: 1fr; }
  .jn-memorial-hall { grid-template-columns: 1fr; }
  .jn-hall-sidebar { position: relative; height: auto; }
  .jn-hall-nav { display: grid; grid-template-columns: repeat(2, 1fr); gap: 6px; }
  .jn-hall-main { padding: 24px 18px 60px; }
  .jn-hall-stats { grid-template-columns: 1fr; }
}

/* ------------------------------------------------------------
   微信内置浏览器兼容：手势、字体、表单、弹窗
   ------------------------------------------------------------ */
.jn-h5,
.jn-h5-body {
  font-family: "Alibaba PuHuiTi", "Source Han Sans SC", "PingFang SC", "Microsoft YaHei", -apple-system, BlinkMacSystemFont, sans-serif;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}
.jn-h5 input,
.jn-h5 textarea,
.jn-h5 select,
.jn-form input,
.jn-form textarea,
.jn-form select {
  -webkit-appearance: none;
  appearance: none;
  border-radius: 0;
  box-shadow: none;
  touch-action: manipulation;
}
.jn-h5 button,
.jn-btn {
  touch-action: manipulation;
}
.jn-h5 .jn-fade-media img.is-fallback { filter: grayscale(.15); }
.jn-overlay-open { overflow: hidden !important; }
.jn-horizontal-scroll { overflow-y: hidden !important; }
.jn-h5 .jn-gallery { touch-action: pan-x; -webkit-overflow-scrolling: touch; }
.jn-h5 .jn-family-viewport { touch-action: none; -webkit-overflow-scrolling: touch; }
.jn-h5 .jn-timeline,
.jn-h5 .jn-message-list { -webkit-overflow-scrolling: touch; }
.jn-video-close {
  position: absolute;
  top: 18px;
  right: 20px;
  z-index: 2;
  border: 0;
  background: rgba(255,255,255,.16);
  color: #fff;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  font-size: 24px;
  cursor: pointer;
}
.jn-access-remember {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin: 18px 0 4px;
  color: #8a7c6c;
  font-size: 12px;
}
.jn-access-remember input {
  width: 14px;
  height: 14px;
  accent-color: #b58a54;
}
@media (max-width: 600px) {
  .jn-h5 .jn-lightbox-nav { width: 34px; height: 34px; }
}
