/**
 * 19-river-ferry：River Ferry 全站壳层（:root、字标 rf-lockup、顶栏、页脚 rf-ft）
 * 首页仅加载本文件；内页另加 nv-inland.css（原 monolith 在 421 行后的部分）。
 *
 * 原 nv-inland 说明摘要：与 Meridian 分包叠加；内页/App/文章内容见 nv-inland.css。
 */
:root {
  --nv-amber: #fbbf24;
  --nv-amber-2: #ea580c;
  --nv-ink: #0f172a;
  --nv-ink2: #475569;
  --nv-line: #e2e8f0;
  --nv-dark: #0f172a;
  --nv-dark-2: #1e293b;
}

/* ========== 顶栏品牌锁区 rf-lockup（19 riverferry 全新字标 + 徽记） ========== */
body.layout-riverferry .rf-lockup {
  gap: 14px;
  align-items: center;
}

body.layout-riverferry .rf-lockup:focus-visible {
  outline: 2px solid rgba(253, 230, 138, 0.9);
  outline-offset: 4px;
  border-radius: 6px;
}

body.layout-riverferry .rf-lockup__badge {
  position: relative;
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  border-radius: 14px;
  padding: 2px;
  background: linear-gradient(
    145deg,
    rgba(251, 191, 36, 0.65) 0%,
    rgba(6, 182, 212, 0.45) 48%,
    rgba(99, 102, 241, 0.4) 100%
  );
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.12) inset,
    0 12px 32px rgba(0, 0, 0, 0.5);
  transition: filter 0.2s ease, box-shadow 0.2s ease;
}

body.layout-riverferry .rf-lockup:hover .rf-lockup__badge {
  filter: brightness(1.07);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.16) inset,
    0 14px 36px rgba(0, 0, 0, 0.55);
}

body.layout-riverferry .rf-lockup__badge-glow {
  position: absolute;
  inset: 2px;
  border-radius: 12px;
  background: radial-gradient(ellipse 90% 70% at 28% 8%, rgba(255, 255, 255, 0.28), transparent 52%);
  pointer-events: none;
}

body.layout-riverferry .rf-lockup__img {
  position: relative;
  z-index: 1;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: block;
  object-fit: cover;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.4);
}

body.layout-riverferry .rf-lockup__stack {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
  align-items: flex-start;
  text-align: left;
}

body.layout-riverferry .rf-lockup__name {
  margin: 0;
  padding: 0;
  font-size: clamp(1.08rem, 2.5vw, 1.38rem);
  font-weight: 900;
  letter-spacing: -0.035em;
  line-height: 1.12;
  color: #fffbeb;
  text-shadow:
    0 1px 0 rgba(0, 0, 0, 0.45),
    0 0 28px rgba(251, 191, 36, 0.22);
}

body.layout-riverferry .rf-lockup__track {
  display: block;
  max-width: min(20rem, 52vw);
  font-size: 10px;
  font-weight: 750;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(253, 230, 138, 0.58);
  line-height: 1.3;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (max-width: 380px) {
  body.layout-riverferry .rf-lockup__track {
    max-width: 42vw;
    letter-spacing: 0.1em;
  }
}

@media (prefers-reduced-motion: reduce) {
  body.layout-riverferry .rf-lockup .rf-lockup__badge {
    transition: none;
  }

  body.layout-riverferry .rf-lockup:hover .rf-lockup__badge {
    filter: none;
  }
}

/* ========== 顶栏底色（覆盖 agp-meridian.css 白底毛玻璃：须与 Meridian 同档选择器） ========== */
.river-ferry-html body.theme-agp-meridian.layout-riverferry .agp-masthead {
  background:
    radial-gradient(ellipse 120% 85% at 0% 0%, rgba(45, 212, 191, 0.16), transparent 52%),
    radial-gradient(ellipse 95% 75% at 100% 0%, rgba(56, 189, 248, 0.12), transparent 50%),
    linear-gradient(180deg, #0f172a 0%, #0c4a6e 48%, #082f49 100%);
  border-bottom: 1px solid rgba(45, 212, 191, 0.3);
  box-shadow: 0 10px 34px rgba(8, 47, 73, 0.52);
  backdrop-filter: none;
}

.river-ferry-html body.theme-agp-meridian.layout-riverferry .agp-masthead__nav-outer {
  border-top: 1px solid rgba(255, 255, 255, 0.09);
  background: linear-gradient(90deg, rgba(6, 182, 212, 0.11), transparent 44%, rgba(14, 116, 144, 0.14)),
    rgba(15, 23, 42, 0.97);
}

/* 深色顶栏下：Meridian 给字标/链接的深色需改浅（否则像「白底配深字」留在深底上） */
.river-ferry-html body.theme-agp-meridian.layout-riverferry .agp-masthead__brand {
  color: #fffbeb;
}

.river-ferry-html body.theme-agp-meridian.layout-riverferry .agp-masthead__link {
  color: rgba(226, 232, 240, 0.88);
}

.river-ferry-html body.theme-agp-meridian.layout-riverferry .agp-masthead__link:hover {
  color: #5eead4;
  background: rgba(45, 212, 191, 0.12);
}

.river-ferry-html body.theme-agp-meridian.layout-riverferry .agp-masthead__link.is-active {
  color: #5eead4;
  background: rgba(45, 212, 191, 0.16);
}

.river-ferry-html body.theme-agp-meridian.layout-riverferry .agp-masthead__btn--ghost {
  color: rgba(226, 232, 240, 0.92);
  border-color: rgba(255, 255, 255, 0.28);
  background: rgba(255, 255, 255, 0.06);
}

.river-ferry-html body.theme-agp-meridian.layout-riverferry .agp-masthead__btn--ghost:hover,
.river-ferry-html body.theme-agp-meridian.layout-riverferry .agp-masthead__btn--ghost.is-active {
  color: #ecfeff;
  border-color: rgba(45, 212, 191, 0.45);
  background: rgba(6, 182, 212, 0.14);
}

.river-ferry-html body.theme-agp-meridian.layout-riverferry .agp-masthead__burger {
  border-color: rgba(255, 255, 255, 0.28);
  background: rgba(255, 255, 255, 0.06);
}

.river-ferry-html body.theme-agp-meridian.layout-riverferry .agp-masthead__burger-box,
.river-ferry-html body.theme-agp-meridian.layout-riverferry .agp-masthead__burger-box::before,
.river-ferry-html body.theme-agp-meridian.layout-riverferry .agp-masthead__burger-box::after {
  background: #f8fafc;
}

.river-ferry-html body.theme-agp-meridian.layout-riverferry .agp-masthead__burger-box {
  box-shadow: 0 7px 0 #f8fafc, 0 -7px 0 #f8fafc;
}

/* ========== 页脚 rf-ft（River Ferry Footer，全新 DOM，替代 agp-footer） ========== */
body.layout-riverferry .rf-ft {
  --rf-ft-ink: #e2e8f0;
  --rf-ft-muted: #94a3b8;
  --rf-ft-line: rgba(148, 163, 184, 0.35);
  --rf-ft-accent: #2dd4bf;
  --rf-ft-accent2: #38bdf8;
  margin-top: auto;
}

body.layout-riverferry .rf-ft__deck {
  position: relative;
  overflow: hidden;
  padding: clamp(36px, 6vw, 56px) 0 clamp(28px, 4vw, 40px);
  background:
    radial-gradient(ellipse 90% 70% at 0% 0%, rgba(45, 212, 191, 0.12), transparent 55%),
    radial-gradient(ellipse 70% 50% at 100% 100%, rgba(56, 189, 248, 0.08), transparent 50%),
    linear-gradient(165deg, #0f172a 0%, #0c4a6e 38%, #082f49 100%);
  border-top: 1px solid rgba(45, 212, 191, 0.22);
}

body.layout-riverferry .rf-ft__deck::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 3px;
  background: linear-gradient(90deg, transparent, rgba(45, 212, 191, 0.55), rgba(251, 191, 36, 0.45), transparent);
  opacity: 0.85;
  pointer-events: none;
}

body.layout-riverferry .rf-ft__deck-inner {
  position: relative;
  z-index: 1;
  display: grid;
  gap: clamp(28px, 4vw, 40px);
  align-items: start;
}

@media (min-width: 900px) {
  body.layout-riverferry .rf-ft__deck-inner {
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 2fr);
    gap: clamp(32px, 4vw, 56px);
  }
}

body.layout-riverferry .rf-ft__identity {
  min-width: 0;
}

body.layout-riverferry .rf-ft__kicker {
  margin: 0 0 8px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(45, 212, 191, 0.85);
}

body.layout-riverferry .rf-ft__title {
  margin: 0 0 12px;
  font-size: clamp(1.25rem, 2.4vw, 1.55rem);
  font-weight: 900;
  letter-spacing: -0.03em;
  line-height: 1.2;
  color: #f8fafc;
}

body.layout-riverferry .rf-ft__blurb {
  margin: 0;
  max-width: 36rem;
  font-size: 14px;
  line-height: 1.65;
  color: var(--rf-ft-muted);
}

body.layout-riverferry .rf-ft__boards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 22px 20px;
}

@media (min-width: 520px) {
  body.layout-riverferry .rf-ft__boards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 720px) {
  body.layout-riverferry .rf-ft__boards {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px 24px;
  }
}

body.layout-riverferry .rf-ft__board {
  margin: 0;
  padding: 0 0 0 14px;
  border-left: 3px solid rgba(45, 212, 191, 0.45);
  border-radius: 0 2px 2px 0;
  background: rgba(15, 23, 42, 0.35);
  padding-top: 14px;
  padding-bottom: 14px;
  padding-right: 12px;
}

body.layout-riverferry .rf-ft__board-h {
  margin: 0 0 12px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(226, 232, 240, 0.92);
}

body.layout-riverferry .rf-ft__links {
  margin: 0;
  padding: 0;
  list-style: none;
}

body.layout-riverferry .rf-ft__li {
  margin: 0 0 8px;
}

body.layout-riverferry .rf-ft__li:last-child {
  margin-bottom: 0;
}

body.layout-riverferry .rf-ft__a {
  font-size: 13px;
  font-weight: 600;
  color: var(--rf-ft-muted);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color 0.15s ease, border-color 0.15s ease;
}

body.layout-riverferry .rf-ft__a:hover {
  color: var(--rf-ft-accent);
  border-bottom-color: rgba(45, 212, 191, 0.45);
}

body.layout-riverferry .rf-ft__a:focus-visible {
  outline: 2px solid var(--rf-ft-accent2);
  outline-offset: 3px;
  border-radius: 2px;
}

body.layout-riverferry .rf-ft__dock {
  padding: 16px 0 22px;
  background: #020617;
  border-top: 1px solid rgba(51, 65, 85, 0.85);
}

body.layout-riverferry .rf-ft__dock-inner {
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 12px;
  line-height: 1.55;
  color: var(--rf-ft-muted);
}

@media (min-width: 768px) {
  body.layout-riverferry .rf-ft__dock-inner {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px 24px;
  }
}

body.layout-riverferry .rf-ft__meta {
  margin: 0;
  max-width: 100%;
}

body.layout-riverferry .rf-ft__meta-line {
  display: inline;
}

body.layout-riverferry .rf-ft__meta-sep {
  margin: 0 0.35em;
  opacity: 0.55;
}

body.layout-riverferry .rf-ft__meta-mail {
  color: var(--rf-ft-accent);
  font-weight: 650;
  text-decoration: none;
}

body.layout-riverferry .rf-ft__meta-mail:hover {
  text-decoration: underline;
}

body.layout-riverferry .rf-ft__legal {
  margin: 0;
}

body.layout-riverferry .rf-ft__copy {
  display: inline;
}

body.layout-riverferry .rf-ft__legal-sep {
  margin: 0 0.35em;
  opacity: 0.55;
}

body.layout-riverferry .rf-ft__legal-a {
  color: var(--rf-ft-muted);
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1px solid rgba(148, 163, 184, 0.35);
}

body.layout-riverferry .rf-ft__legal-a:hover {
  color: var(--rf-ft-accent);
  border-bottom-color: rgba(45, 212, 191, 0.5);
}

@media (prefers-reduced-motion: reduce) {
  body.layout-riverferry .rf-ft__a {
    transition: none;
  }
}

