@import url('https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,300;0,400;0,500;0,700;1,400&display=swap');

:root {
  --ink: #171f26;
  --ink-soft: #3d4b58;
  --sky: #c8e0f4;
  --rose: #f5e0e8;
  --surface: #e9f0f8;
  --line: rgba(23, 31, 38, .16);
  --up: -6px -6px 14px rgba(255, 255, 255, .86), 6px 6px 16px rgba(23, 31, 38, .16);
  --up-sm: -3px -3px 8px rgba(255, 255, 255, .86), 3px 3px 8px rgba(23, 31, 38, .14);
  --down: inset -3px -3px 8px rgba(255, 255, 255, .9), inset 3px 3px 8px rgba(23, 31, 38, .14);
  --radius: 14px;
}

*, *::before, *::after { box-sizing: border-box; }

html {
  font-size: 17px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: 'Roboto', system-ui, -apple-system, 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
  font-size: 1rem;
  line-height: 1.72;
  color: var(--ink);
  background:
    radial-gradient(900px 520px at 12% -8%, #f9eff3 0%, rgba(249, 239, 243, 0) 62%),
    radial-gradient(900px 520px at 92% 8%, #e3eef9 0%, rgba(227, 238, 249, 0) 60%),
    linear-gradient(168deg, #eef4fa 0%, #e6eef7 52%, #f6eef2 100%);
  background-attachment: fixed;
  overflow-wrap: break-word;
}

a { color: inherit; }
a:focus-visible, button:focus-visible, input:focus-visible {
  outline: 2px solid #1c5b8c;
  outline-offset: 3px;
}

h1, h2, h3 { font-weight: 700; letter-spacing: .01em; color: var(--ink); }

/* 顶栏 */
.topbar {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px clamp(12px, 3vw, 26px);
  background: linear-gradient(160deg, rgba(249, 240, 244, .93), rgba(232, 242, 251, .93));
  -webkit-backdrop-filter: blur(9px);
  backdrop-filter: blur(9px);
  box-shadow: 0 10px 22px rgba(23, 31, 38, .09);
}

.brand {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  display: inline-flex;
  align-items: center;
  padding: 12px 14px;
  border-radius: 12px;
  font-weight: 700;
  letter-spacing: .05em;
  text-decoration: none;
  color: var(--ink);
  white-space: nowrap;
}
.brand-logo { display: block; max-height: 28px; width: auto; }

.site-nav { display: none; }
.site-nav ol {
  display: flex;
  align-items: center;
  gap: 2px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.site-nav li:nth-child(4) { margin-left: auto; }
.site-nav a {
  display: inline-block;
  padding: 12px 10px;
  border-radius: 10px;
  font-size: 1rem;
  color: var(--ink-soft);
  text-decoration: none;
  transition: color .15s ease, box-shadow .15s ease, transform .15s ease;
}
.site-nav a:hover { color: var(--ink); box-shadow: var(--up-sm); }
.site-nav a:active { transform: scale(.97); box-shadow: var(--down); }

.burger {
  margin-left: auto;
  position: relative;
  z-index: 70;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 11px 18px;
  font: inherit;
  font-size: 1rem;
  color: var(--ink);
  background: var(--surface);
  border: 0;
  border-radius: 12px;
  box-shadow: var(--up);
  cursor: pointer;
  transition: transform .15s ease, box-shadow .15s ease;
}
.burger:active { transform: scale(.97); box-shadow: var(--down); }

/* 主区 */
main { padding: 0 clamp(13px, 4vw, 30px); }

.hero {
  position: relative;
  min-height: 70vh;
  display: grid;
  place-items: center;
  overflow: hidden;
  padding: clamp(26px, 7vw, 72px) clamp(14px, 4vw, 30px);
  margin-bottom: clamp(16px, 3vw, 28px);
  scroll-margin-top: 80px;
}

.collage { position: absolute; inset: 0; margin: 0; pointer-events: none; }
.collage-img {
  position: absolute;
  display: block;
  width: clamp(118px, 17vw, 212px);
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 16px;
  background: linear-gradient(145deg, var(--sky), var(--rose));
  box-shadow: var(--up);
}
.shot-1 { top: 7%; left: 5%; transform: rotate(-6deg); }
.shot-2 { bottom: 7%; right: 5%; transform: rotate(6deg); }

.hero-copy {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 15px;
  max-width: min(560px, 92vw);
  padding: clamp(20px, 4vw, 32px);
  text-align: center;
  border-radius: 16px;
  background: linear-gradient(150deg, rgba(255, 255, 255, .8), rgba(245, 224, 232, .64));
  box-shadow: var(--up);
}
.hero-copy h1 {
  margin: 0;
  font-size: clamp(1.7rem, 5.4vw, 2.8rem);
  line-height: 1.3;
}
.badge {
  margin: 0;
  padding: 7px 16px;
  border-radius: 999px;
  font-size: 1rem;
  background: var(--rose);
  box-shadow: var(--down);
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 11px; justify-content: center; }

.pill {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 11px 22px;
  border-radius: 12px;
  font-size: 1rem;
  text-decoration: none;
  color: var(--ink);
  background: var(--surface);
  box-shadow: var(--up);
  transition: transform .15s ease, box-shadow .15s ease;
}
.pill:active { transform: scale(.97); box-shadow: var(--down); }
.pill.ghost { background: transparent; color: var(--ink-soft); box-shadow: var(--down); }

.shell {
  max-width: 1120px;
  margin: 0 auto;
  display: grid;
  gap: clamp(16px, 3vw, 28px);
  padding-bottom: clamp(28px, 6vw, 56px);
}
.shell > * { min-width: 0; }

/* 侧栏 */
.rail {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 16px 18px;
  background: rgba(255, 255, 255, .56);
  box-shadow: var(--up-sm);
}
.rail small {
  display: block;
  font-size: 1rem;
  letter-spacing: .16em;
  color: var(--ink-soft);
}
.rail h2 { margin: 2px 0 10px; font-size: 1.15rem; }
.rail-list { display: grid; gap: 4px; margin: 0; padding: 0; list-style: none; }
.rail-list a {
  display: block;
  padding: 10px 12px;
  min-height: 44px;
  border-radius: 10px;
  font-size: 1rem;
  color: var(--ink-soft);
  text-decoration: none;
  transition: background .15s ease, color .15s ease;
}
.rail-list a:hover { background: rgba(255, 255, 255, .85); color: var(--ink); }

/* 正文 */
.content > div {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: clamp(18px, 3.4vw, 32px);
  margin-bottom: clamp(14px, 2.4vw, 20px);
  background: rgba(255, 255, 255, .55);
  scroll-margin-top: 92px;
}
.content > div > *:first-child { margin-top: 0; }
.content > div > *:last-child { margin-bottom: 0; }
.content h2 { margin: 0 0 .6em; font-size: clamp(1.22rem, 2.8vw, 1.55rem); line-height: 1.36; }
.content h3 { margin: 1.3em 0 .5em; font-size: 1.14rem; line-height: 1.4; }
.content p { margin: 0 0 1em; }
.content ul, .content ol { margin: 0 0 1em; padding-left: 1.35em; }
.content li { margin: .35em 0; }
.content small {
  display: block;
  margin-bottom: 6px;
  font-size: 1rem;
  letter-spacing: .14em;
  color: var(--ink-soft);
}
.content a { color: #1c5b8c; text-underline-offset: 3px; }
.content img { max-width: 100%; height: auto; border-radius: 12px; }
.content blockquote {
  margin: 1em 0;
  padding: 13px 18px;
  border-left: 3px solid var(--sky);
  border-radius: 0 12px 12px 0;
  background: rgba(200, 224, 244, .38);
}
.content table { display: block; overflow-x: auto; border-collapse: collapse; }
.content th, .content td { border: 1px solid var(--line); padding: 8px 10px; text-align: left; }
.content time { color: var(--ink-soft); }

/* 页脚 */
.foot {
  display: grid;
  gap: clamp(18px, 4vw, 34px);
  padding: clamp(26px, 5vw, 46px) clamp(16px, 4vw, 32px) 22px;
  margin-top: clamp(20px, 4vw, 38px);
  border-top: 1px solid var(--line);
  background: linear-gradient(165deg, #eef4fb, #f8f0f4);
}
.foot-col small {
  display: block;
  font-size: 1rem;
  letter-spacing: .16em;
  color: var(--ink-soft);
}
.foot-col h2 { margin: 3px 0 10px; font-size: 1.1rem; }
.foot-nav { display: grid; gap: 2px; grid-template-columns: 1fr 1fr; margin: 0; padding: 0; list-style: none; }
.foot-nav a {
  display: block;
  padding: 10px 8px;
  min-height: 44px;
  font-size: 1rem;
  color: var(--ink-soft);
  text-decoration: none;
  border-radius: 10px;
}
.foot-nav a:hover { color: var(--ink); background: rgba(255, 255, 255, .7); }

.sub { display: grid; gap: 9px; max-width: 330px; }
.sub label { font-size: 1rem; color: var(--ink-soft); }
.sub input {
  width: 100%;
  min-height: 46px;
  padding: 11px 14px;
  font: inherit;
  font-size: 1rem;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: var(--down);
}
.sub button {
  min-height: 46px;
  padding: 11px 20px;
  font: inherit;
  font-size: 1rem;
  color: var(--ink);
  background: var(--rose);
  border: 0;
  border-radius: 12px;
  box-shadow: var(--up);
  cursor: pointer;
  transition: transform .15s ease, box-shadow .15s ease;
}
.sub button:active { transform: scale(.97); box-shadow: var(--down); }

.foot-base { display: grid; gap: 3px; align-content: start; text-align: center; }
.copy { margin: 0; font-weight: 500; }
.host { margin: 0; font-size: 1rem; color: var(--ink-soft); }

.totop {
  position: fixed;
  right: 14px;
  bottom: 14px;
  z-index: 35;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 11px 16px;
  font-size: 1rem;
  color: var(--ink);
  text-decoration: none;
  background: var(--surface);
  border-radius: 12px;
  box-shadow: var(--up);
}
.totop:active { box-shadow: var(--down); transform: scale(.97); }

/* 渐进动效 */
html.has-js .content > div {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity .5s ease, transform .5s ease;
}
html.has-js .content > div.in { opacity: 1; transform: none; }

/* 断点 */
@media (max-width: 720px) {
  .collage-img { width: 96px; opacity: .82; }
  .shot-1 { top: 4%; left: 3%; }
  .shot-2 { bottom: 4%; right: 3%; }
  .hero { padding-top: 34px; padding-bottom: 34px; }
}

@media (min-width: 760px) {
  .foot { grid-template-columns: 1.25fr 1fr 1fr; align-items: start; max-width: 1120px; margin-left: auto; margin-right: auto; border-top: 0; }
  .foot-nav { grid-template-columns: 1fr; }
  .foot-base { align-self: center; }
}

@media (min-width: 960px) {
  .site-nav { display: block; flex: 1; }
  .burger { margin-left: 0; }
  .shell { grid-template-columns: 250px minmax(0, 1fr); align-items: start; }
  .rail { position: sticky; top: 84px; }
}

/* 全屏遮罩菜单 */
body.menu-open { overflow: hidden; }
body.menu-open .site-nav {
  display: block;
  position: fixed;
  inset: 0;
  z-index: 60;
  padding: 96px 20px 44px;
  overflow: auto;
  background: linear-gradient(165deg, #f9f0f4 0%, #e6eff9 60%, #dfeaf6 100%);
}
body.menu-open .site-nav ol { flex-direction: column; align-items: stretch; gap: 8px; max-width: 460px; margin: 0 auto; }
body.menu-open .site-nav li:nth-child(4) { margin-left: 0; }
body.menu-open .site-nav a {
  display: block;
  padding: 15px 18px;
  text-align: center;
  font-size: 1.05rem;
  box-shadow: var(--up-sm);
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  html.has-js .content > div { opacity: 1; transform: none; transition: none; }
  * { transition-duration: .01ms !important; animation-duration: .01ms !important; }
}

button[aria-expanded]{min-width:44px;min-height:44px}
