/* ============================================================
   ao3 专题站 - 全站共享样式
   设计基调：档案纸本（米白纸张 + 陈年酒红 + 旧金）
   ============================================================ */

:root {
  --paper:      #F1EFF4;
  --paper-2:    #E7E4EC;
  --paper-3:    #DEDAE4;
  --card:       #FFFFFF;
  --ink:        #1D2A33;
  --ink-2:      #586873;
  --ink-3:      #8A93A0;
  --seal:       #2A4C63;
  --seal-2:     #1B3547;
  --seal-soft:  #5B93B5;
  --gold:       #3E7295;
  --sand:       #B9AE9C;
  --line:       #E0DCE6;
  --line-2:     #CFC9D8;
  --radius:     14px;
  --radius-lg:  22px;
  --shadow:     0 2px 4px rgba(30, 40, 55, .05), 0 12px 30px rgba(30, 40, 55, .07);
  --shadow-lg:  0 6px 16px rgba(30, 40, 55, .08), 0 26px 60px rgba(30, 40, 55, .12);
  --maxw:       1120px;
  --font: "Microsoft YaHei", "PingFang SC", "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }

[id] { scroll-margin-top: 86px; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.85;
  color: var(--ink);
  background-color: var(--paper);
  background-image:
    repeating-linear-gradient(135deg, rgba(42, 76, 99, .032) 0 2px, transparent 2px 13px),
    radial-gradient(circle at 86% 4%, rgba(91, 147, 181, .10), transparent 44%);
  background-attachment: fixed;
  background-repeat: repeat, no-repeat;
  -webkit-font-smoothing: antialiased;
}

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

a { color: var(--seal); text-decoration: none; }
a:hover { color: var(--seal-soft); text-decoration: underline; }

.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }

.skip {
  position: absolute; left: -9999px; top: 0;
  background: var(--seal); color: #fff; padding: 10px 16px; z-index: 99;
}
.skip:focus { left: 12px; top: 12px; }

/* ---------------- 顶部导航 ---------------- */
.site-head {
  position: sticky; top: 0; z-index: 50;
  background: rgba(250, 246, 239, .94);
  backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.site-head .wrap {
  display: flex; align-items: center; gap: 14px;
  min-height: 68px;
}
.brand { display: flex; align-items: center; gap: 11px; text-decoration: none; }
.brand:hover { text-decoration: none; }
.brand img { width: 40px; height: 40px; border-radius: 11px; box-shadow: 0 2px 8px rgba(27, 53, 71, .24); }
.brand-name {
  font-size: 25px; font-weight: 700; color: var(--seal);
  letter-spacing: .04em; line-height: 1;
}
.brand-sub {
  font-size: 11px; color: var(--ink-3); letter-spacing: .22em;
  display: block; margin-top: 3px; text-transform: uppercase;
}

.nav { margin-left: auto; display: flex; align-items: center; gap: 4px; }
.nav a {
  color: var(--ink-2); font-size: 15px; padding: 8px 14px; border-radius: 999px;
  text-decoration: none; transition: background .18s, color .18s;
}
.nav a:hover { background: var(--paper-2); color: var(--seal); text-decoration: none; }
.nav a.is-active { color: var(--seal); font-weight: 700; background: var(--paper-2); }

.head-cta { margin-left: 10px; }

.nav-toggle {
  display: none; margin-left: auto;
  width: 42px; height: 42px; border: 1px solid var(--line-2); border-radius: 11px;
  background: var(--card); cursor: pointer; padding: 0;
}
.nav-toggle span {
  display: block; width: 18px; height: 2px; background: var(--ink-2); margin: 4px auto;
  border-radius: 2px;
}

/* ---------------- 按钮 ---------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--font); font-size: 16px; font-weight: 700;
  padding: 13px 30px; border-radius: 999px; border: 1px solid transparent;
  cursor: pointer; transition: transform .16s, box-shadow .16s, background .16s, color .16s;
  text-decoration: none; white-space: nowrap;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn-primary {
  background: linear-gradient(180deg, var(--seal) 0%, var(--seal-2) 100%);
  color: #F4F9FC; box-shadow: 0 8px 20px rgba(27, 53, 71, .28);
}
.btn-primary:hover { color: #fff; box-shadow: 0 12px 26px rgba(27, 53, 71, .36); }
.btn-ghost { background: var(--card); color: var(--seal); border-color: var(--line-2); }
.btn-ghost:hover { color: var(--seal-2); border-color: var(--seal-soft); }
.btn-sm { padding: 10px 22px; font-size: 15px; }
.btn-lg { padding: 16px 40px; font-size: 17px; }

/* ---------------- 通用区块 ---------------- */
.sec { padding: 76px 0; }
.sec-alt {
  background: linear-gradient(180deg, rgba(231, 228, 236, .6), rgba(231, 228, 236, .2));
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.sec-head { max-width: 720px; margin-bottom: 40px; }
.sec-head.center { margin-left: auto; margin-right: auto; text-align: center; }

.eyebrow {
  display: inline-block; font-size: 12px; letter-spacing: .3em; color: var(--gold);
  text-transform: uppercase; margin-bottom: 12px; font-weight: 700;
}
h1, h2, h3, h4 { line-height: 1.42; margin: 0 0 12px; font-weight: 700; letter-spacing: .01em; }
h2 { font-size: 30px; color: var(--ink); }
h3 { font-size: 19px; color: var(--ink); }
p { margin: 0 0 14px; color: var(--ink-2); }
.lead { font-size: 17px; color: var(--ink-2); }

.rule {
  width: 54px; height: 3px; border-radius: 3px; background: var(--gold);
  margin: 0 0 22px;
}
.center .rule { margin-left: auto; margin-right: auto; }

/* ---------------- Hero ---------------- */
.hero { position: relative; padding: 66px 0 74px; overflow: hidden; }
.hero::after {
  content: ""; position: absolute; left: -70px; bottom: -90px; width: 430px; height: 330px;
  background: repeating-linear-gradient(135deg, rgba(42, 76, 99, .13) 0 2px, transparent 2px 11px);
  -webkit-mask-image: radial-gradient(circle at 6% 100%, #000 0%, transparent 74%);
  mask-image: radial-gradient(circle at 6% 100%, #000 0%, transparent 74%);
  pointer-events: none;
}
.hero .wrap {
  display: grid; grid-template-columns: 1.08fr .92fr; gap: 56px; align-items: center;
  position: relative; z-index: 1;
}
.hero h1 { font-size: 46px; letter-spacing: .02em; margin-bottom: 18px; }
.hero h1 .accent { color: var(--seal); }
.hero .lead { font-size: 17.5px; max-width: 520px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin: 26px 0 8px; }
.hero-note { font-size: 13px; color: var(--ink-3); }

.hero-figure { display: flex; justify-content: center; }

/* 手机框（按原图比例，width:auto，无拉伸） */
.phone {
  position: relative; background: var(--card);
  border: 1px solid var(--line-2); border-radius: 26px; padding: 12px;
  box-shadow: var(--shadow-lg);
}
.phone img { border-radius: 16px; width: auto; max-height: 520px; }
.phone::before {
  content: ""; position: absolute; left: 50%; top: 5px; transform: translateX(-50%);
  width: 46px; height: 4px; border-radius: 4px; background: var(--sand);
}

/* 数据条 */
.stats {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 0; margin-top: 42px; border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.stats div { padding: 20px 16px; border-right: 1px solid var(--line); }
.stats div:last-child { border-right: 0; }
.stats b { display: block; font-size: 25px; color: var(--seal); letter-spacing: .01em; }
.stats span { font-size: 13px; color: var(--ink-3); }

/* ---------------- 功能卡 ---------------- */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }

.card {
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius-lg); padding: 28px 26px;
  box-shadow: var(--shadow); transition: transform .18s, box-shadow .18s, border-color .18s;
  position: relative; overflow: hidden;
}
.card::after {
  content: ""; position: absolute; right: 0; top: 0; width: 4px; height: 100%;
  background: var(--seal); opacity: .85; transition: background .18s, width .18s;
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); border-color: var(--line-2); }
.card:hover::after { background: var(--seal-soft); width: 6px; }
.card h3 { margin-bottom: 8px; }
.card p { margin: 0; font-size: 15px; }

.chip {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 34px; height: 34px; padding: 0 10px; border-radius: 10px;
  background: var(--paper-2); border: 1px solid var(--line-2);
  color: var(--seal); font-size: 14px; font-weight: 700; letter-spacing: .04em;
  margin-bottom: 14px;
}

/* ---------------- 截图墙 ---------------- */
.gallery {
  display: flex; gap: 20px; overflow-x: auto; padding: 8px 4px 22px;
  scroll-snap-type: x proximity; scrollbar-width: thin;
}
.gallery::-webkit-scrollbar { height: 8px; }
.gallery::-webkit-scrollbar-thumb { background: var(--line-2); border-radius: 8px; }
.gallery::-webkit-scrollbar-track { background: var(--paper-2); border-radius: 8px; }

.shot {
  flex: 0 0 auto; width: 224px; scroll-snap-align: start;
  background: var(--card); border: 1px solid var(--line);
  border-radius: 20px; padding: 12px; box-shadow: var(--shadow);
  display: flex; flex-direction: column;
}
.shot .frame {
  height: 424px; display: flex; align-items: center; justify-content: center;
  background: var(--paper-2); border: 1px solid var(--line); border-radius: 13px;
  overflow: hidden;
}
.shot .frame img { width: auto; height: auto; max-width: 100%; max-height: 100%; border-radius: 8px; }
.shot figcaption {
  padding: 12px 4px 2px; font-size: 13.5px; color: var(--ink-2); text-align: center;
}
.shot figcaption b { display: block; color: var(--ink); font-size: 14px; margin-bottom: 2px; }
.shot-gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.shot-gallery .shot { width: auto; }

/* ---------------- 内页入口 ---------------- */
.entry { display: block; color: inherit; text-decoration: none; }
.entry:hover { text-decoration: none; }
.entry .card { height: 100%; }
.entry .card h3 { color: var(--seal); }
.entry .more { font-size: 14px; color: var(--gold); font-weight: 700; letter-spacing: .06em; }

/* ---------------- FAQ ---------------- */
.faq { border-top: 1px solid var(--line); }
.faq details {
  border-bottom: 1px solid var(--line); padding: 4px 0;
}
.faq summary {
  cursor: pointer; list-style: none; padding: 18px 40px 18px 0;
  font-weight: 700; color: var(--ink); font-size: 16.5px; position: relative;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; position: absolute; right: 8px; top: 50%; transform: translateY(-50%);
  color: var(--seal); font-size: 22px; font-weight: 400; line-height: 1;
}
.faq details[open] summary::after { content: "\2013"; }
.faq details[open] summary { color: var(--seal); }
.faq .ans { padding: 0 40px 20px 0; color: var(--ink-2); font-size: 15.5px; }
.faq .ans p:last-child { margin-bottom: 0; }

/* ---------------- CTA ---------------- */
.cta {
  background: linear-gradient(135deg, var(--seal) 0%, var(--seal-2) 62%, #151F27 100%);
  color: #F0F6FA; border-radius: var(--radius-lg); padding: 54px 44px; text-align: center;
  box-shadow: 0 24px 60px rgba(24, 40, 55, .30); position: relative; overflow: hidden;
}
.cta::before {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(circle at 82% 12%, rgba(255, 255, 255, .13), transparent 46%);
  pointer-events: none;
}
.cta h2 { color: #F7FBFD; margin-bottom: 10px; }
.cta p { color: rgba(240, 246, 250, .82); max-width: 620px; margin: 0 auto 26px; }
.cta .btn-primary {
  background: #F2F8FB; color: var(--seal-2); box-shadow: 0 10px 26px rgba(0, 0, 0, .22);
}
.cta .btn-primary:hover { background: #fff; color: var(--seal-2); }
.cta-sub { margin-top: 20px; font-size: 13px; color: rgba(240, 246, 250, .62); }

/* ---------------- 内页正文 ---------------- */
.page-hero {
  padding: 52px 0 44px; border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(231, 228, 236, .72), transparent);
}
.page-hero h1 { font-size: 38px; margin-bottom: 14px; }
.crumb { font-size: 13.5px; color: var(--ink-3); margin-bottom: 16px; }
.crumb a { color: var(--ink-3); }
.crumb a:hover { color: var(--seal); }

.article { padding: 56px 0 70px; }
.article .wrap { max-width: var(--maxw); }
.article .wrap > * { max-width: 860px; }
.article h2 { margin-top: 46px; }
.article h2:first-child { margin-top: 0; }
.article h3 { margin-top: 30px; }
.article ul, .article ol { padding-left: 22px; color: var(--ink-2); }
.article li { margin-bottom: 9px; }
.article li b, .article p b { color: var(--ink); }
.article .note {
  background: var(--paper-2); border-left: 3px solid var(--gold);
  border-radius: 0 12px 12px 0; padding: 18px 22px; margin: 24px 0;
}
.article .note p:last-child { margin-bottom: 0; }

.step {
  display: grid; grid-template-columns: 60px 1fr; gap: 20px;
  padding: 24px 0; border-bottom: 1px dashed var(--line-2);
}
.step:last-of-type { border-bottom: 0; }
.step .no {
  font-size: 15px; font-weight: 700; color: var(--seal);
  border: 1px solid var(--line-2); border-radius: 12px; height: 44px;
  display: flex; align-items: center; justify-content: center; background: var(--card);
}
.step h3 { margin: 2px 0 8px; }
.step p { margin: 0 0 8px; font-size: 15.5px; }
.step p:last-child { margin-bottom: 0; }

.tbl { width: 100%; border-collapse: collapse; margin: 22px 0; font-size: 15px; }
.tbl th, .tbl td { border: 1px solid var(--line); padding: 12px 14px; text-align: left; }
.tbl th { background: var(--paper-2); color: var(--ink); font-weight: 700; }
.tbl td { color: var(--ink-2); }

.pager {
  display: flex; flex-wrap: wrap; gap: 12px; justify-content: space-between;
  margin-top: 54px; padding-top: 26px; border-top: 1px solid var(--line);
}
.pager a { font-size: 15px; }

/* ---------------- 页脚 ---------------- */
.site-foot {
  background: #1B2731; color: #A9B9C4; padding: 56px 0 26px; font-size: 14.5px;
}
.site-foot .cols { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 40px; }
.site-foot h4 { color: #E6EEF3; font-size: 15px; margin-bottom: 14px; letter-spacing: .06em; }
.site-foot a { color: #A9B9C4; }
.site-foot a:hover { color: #E6EEF3; }
.site-foot ul { list-style: none; padding: 0; margin: 0; }
.site-foot li { margin-bottom: 9px; }
.site-foot .fbrand { display: flex; align-items: center; gap: 11px; margin-bottom: 14px; }
.site-foot .fbrand img { width: 36px; height: 36px; border-radius: 10px; }
.site-foot .fbrand b { color: #E6EEF3; font-size: 22px; letter-spacing: .04em; }
.disclaimer {
  margin-top: 36px; padding: 18px 20px; border-radius: 12px;
  background: rgba(255, 255, 255, .05); border: 1px solid rgba(255, 255, 255, .1);
  color: #93A5B1; font-size: 13.5px; line-height: 1.8;
}
.copy {
  margin-top: 22px; padding-top: 20px; border-top: 1px solid rgba(255, 255, 255, .1);
  text-align: center; font-size: 13px; color: #7B8C98;
}

/* 返回顶部 */
.to-top {
  position: fixed; right: 22px; bottom: 26px; z-index: 60;
  width: 46px; height: 46px; border-radius: 14px; border: 1px solid var(--line-2);
  background: var(--card); color: var(--seal); font-size: 18px; cursor: pointer;
  box-shadow: var(--shadow); opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s;
}
.to-top.show { opacity: 1; pointer-events: auto; }
.to-top:hover { transform: translateY(-2px); }

/* ---------------- 响应式 ---------------- */
@media (max-width: 980px) {
  .hero .wrap { grid-template-columns: 1fr; gap: 40px; }
  .hero h1 { font-size: 38px; }
  .hero-figure { order: -1; }
  .phone img { max-height: 420px; }
  .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .shot-gallery { grid-template-columns: repeat(2, 1fr); }
  .site-foot .cols { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 760px) {
  .nav {
    position: absolute; left: 16px; right: 16px; top: 68px;
    flex-direction: column; align-items: stretch; gap: 2px;
    background: var(--card); border: 1px solid var(--line-2); border-radius: 16px;
    padding: 10px; box-shadow: var(--shadow-lg); display: none;
  }
  .nav.open { display: flex; }
  .nav-toggle { display: block; }
  .head-cta { display: none; }
  .sec { padding: 56px 0; }
  h2 { font-size: 25px; }
  .hero h1 { font-size: 32px; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .stats div:nth-child(2) { border-right: 0; }
  .stats div:nth-child(1), .stats div:nth-child(2) { border-bottom: 1px solid var(--line); }
  .grid-3, .grid-4, .grid-2, .shot-gallery { grid-template-columns: 1fr; }
  .site-foot .cols { grid-template-columns: 1fr; gap: 26px; }
  .step { grid-template-columns: 46px 1fr; gap: 14px; }
  .cta { padding: 40px 24px; }
  .page-hero h1 { font-size: 28px; }
  .brand-name { font-size: 22px; }
}
