:root {
  --ink: #171f26;
  --ink-2: #3d4b56;
  --blue: #c8e0f4;
  --pink: #f5e0e8;
  --surf: #f1f6fb;
  --raise: -6px -6px 16px rgba(255, 255, 255, 0.95), 8px 8px 22px rgba(23, 31, 38, 0.14);
  --raise-sm: -3px -3px 8px rgba(255, 255, 255, 0.9), 4px 4px 12px rgba(23, 31, 38, 0.14);
  --sink: inset -4px -4px 10px rgba(255, 255, 255, 0.95), inset 5px 5px 14px rgba(23, 31, 38, 0.13);
  --r-lg: 28px;
  --r-md: 18px;
  --r-sm: 13px;
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  overflow-x: hidden;
}

body {
  margin: 0;
  max-width: 100%;
  overflow-x: hidden;
  font-family: "Be Vietnam Pro", "Noto Sans", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.78;
  color: var(--ink);
  background: linear-gradient(165deg, #eef4fa 0%, #dde9f6 34%, var(--blue) 64%, var(--pink) 100%);
  background-attachment: fixed;
}

img,
svg,
video,
iframe {
  max-width: 100%;
}

img { height: auto; }

a { color: inherit; }

:focus-visible {
  outline: 2px solid #2f6f9e;
  outline-offset: 3px;
}

:where(main [id]) { scroll-margin-top: 104px; }

.skip {
  position: absolute;
  left: 14px;
  top: -70px;
  z-index: 80;
  padding: 12px 20px;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  border-radius: var(--r-sm);
  background: var(--surf);
  color: var(--ink);
  text-decoration: none;
  box-shadow: var(--raise-sm);
  transition: top 0.2s ease;
}
.skip:focus { top: 14px; }

.bar {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 12px clamp(14px, 4vw, 42px);
  background: rgba(238, 244, 250, 0.86);
  backdrop-filter: blur(12px) saturate(1.1);
  box-shadow: 0 8px 22px rgba(23, 31, 38, 0.1);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  min-height: 44px;
  padding: 5px 16px 5px 5px;
  border-radius: 999px;
  background: var(--surf);
  box-shadow: var(--raise-sm);
  color: var(--ink);
  text-decoration: none;
  font-weight: 700;
  letter-spacing: 0.02em;
}
.brand:active { box-shadow: var(--sink); }
.logo { display: block; border-radius: 50%; object-fit: cover; flex: none; }
.brand-txt {
  font-size: 1.05rem;
  min-width: 0;
  overflow-wrap: anywhere;
}

.menu { position: relative; flex: none; }

.menu summary {
  list-style: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-height: 44px;
  padding: 0 18px;
  border-radius: 999px;
  background: var(--surf);
  box-shadow: var(--raise-sm);
  font-weight: 600;
  font-size: 1rem;
  transition: box-shadow 0.15s ease, transform 0.15s ease;
}
.menu summary::-webkit-details-marker { display: none; }
.menu summary::after {
  content: "";
  width: 9px;
  height: 9px;
  border-right: 2px solid var(--ink-2);
  border-bottom: 2px solid var(--ink-2);
  transform: translateY(-2px) rotate(45deg);
  transition: transform 0.18s ease;
}
.menu[open] summary::after { transform: translateY(2px) rotate(-135deg); }
.menu summary:active { box-shadow: var(--sink); transform: scale(0.98); }

.menu menu {
  list-style: none;
  margin: 0;
  padding: 10px;
  display: grid;
  gap: 7px;
  position: absolute;
  right: 0;
  top: calc(100% + 10px);
  width: min(78vw, 268px);
  max-width: calc(100vw - 28px);
  border-radius: var(--r-md);
  background: var(--surf);
  box-shadow: var(--raise);
}

.menu menu a {
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: 8px 14px;
  border-radius: 12px;
  text-decoration: none;
  color: var(--ink);
  font-size: 1rem;
  overflow-wrap: anywhere;
  background: linear-gradient(145deg, #f7fbfe, #e6eef7);
  box-shadow: var(--raise-sm);
}
.menu menu a:hover { box-shadow: var(--sink); }

.hero {
  position: relative;
  overflow: hidden;
  min-height: 78svh;
  display: flex;
  align-items: flex-end;
  justify-content: flex-end;
  padding: clamp(22px, 6vw, 64px) clamp(16px, 5vw, 64px) clamp(38px, 7vw, 82px);
  border-radius: 0 0 36px 36px;
  background: linear-gradient(140deg, #b9d4ee, #e3ecf7 46%, #f3dde6);
}

.hero-media { position: absolute; inset: 0; }

.hero-img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.05);
  will-change: transform;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(262deg, rgba(23, 31, 38, 0.84), rgba(23, 31, 38, 0.3) 56%, rgba(23, 31, 38, 0.56));
}

.hero-copy {
  position: relative;
  z-index: 2;
  min-width: 0;
  max-width: min(44ch, 100%);
  text-align: right;
  color: #fff;
  overflow-wrap: anywhere;
}

.hero-copy h1 {
  margin: 0 0 14px;
  font-size: clamp(1.85rem, 7vw, 3.6rem);
  line-height: 1.2;
  letter-spacing: -0.01em;
  overflow-wrap: anywhere;
  text-shadow: 0 4px 22px rgba(23, 31, 38, 0.45);
}

.hero-copy p {
  margin: 0;
  font-size: clamp(1rem, 2.4vw, 1.12rem);
  color: rgba(255, 255, 255, 0.93);
  text-shadow: 0 2px 14px rgba(23, 31, 38, 0.5);
}

.sheet {
  max-width: 1180px;
  margin: clamp(28px, 5vw, 64px) auto 0;
  padding: 0 clamp(14px, 4vw, 36px);
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: clamp(18px, 3vw, 36px);
}

.rail {
  min-width: 0;
  padding: 20px 18px;
  border-radius: 24px;
  background: var(--surf);
  box-shadow: var(--sink);
}

.rail small {
  display: block;
  font-size: 0.78rem;
  letter-spacing: 0.2em;
  color: var(--ink-2);
  opacity: 0.8;
}

.rail h2 {
  margin: 2px 0 14px;
  font-size: 1.15rem;
  letter-spacing: 0.05em;
}

.rail ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
}

.rail a {
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: 6px 12px;
  border-radius: 12px;
  color: var(--ink);
  text-decoration: none;
  font-size: 0.96rem;
  overflow-wrap: anywhere;
  background: linear-gradient(145deg, #f7fbfe, #e8f0f8);
  box-shadow: var(--raise-sm);
}
.rail a:hover { box-shadow: var(--sink); background: #edf4fa; }

.prose {
  min-width: 0;
  max-width: 100%;
  overflow-x: auto;
  overflow-wrap: anywhere;
  word-break: break-word;
  padding: clamp(20px, 4vw, 46px);
  border-radius: var(--r-lg);
  background: var(--surf);
  box-shadow: var(--raise);
}

.prose > :first-child { margin-top: 0; }
.prose > :last-child { margin-bottom: 0; }
.prose > * { max-width: 100%; }

.prose section + section {
  margin-top: 2.1rem;
  padding-top: 2rem;
  border-top: 1px solid rgba(23, 31, 38, 0.08);
}

.prose h2 {
  margin: 0 0 0.7em;
  font-size: clamp(1.34rem, 3.4vw, 1.8rem);
  line-height: 1.4;
  letter-spacing: -0.01em;
}

.prose h3 {
  margin: 1.7em 0 0.5em;
  font-size: 1.14rem;
  line-height: 1.5;
}

.prose small {
  display: block;
  margin-bottom: 0.35rem;
  font-size: 0.8rem;
  letter-spacing: 0.16em;
  color: var(--ink-2);
  opacity: 0.85;
}

.prose p { margin: 0 0 1.1em; }
.prose ul, .prose ol { margin: 0 0 1.2em; padding-left: 1.3em; }
.prose li { margin: 0.4em 0; }

.prose a {
  color: #1b4b6f;
  text-underline-offset: 3px;
  text-decoration-color: rgba(27, 75, 111, 0.42);
}

.prose strong { font-weight: 600; }

.prose blockquote {
  margin: 1.5em 0;
  padding: 16px 20px;
  border-radius: 16px;
  background: #edf4fa;
  box-shadow: var(--sink);
}

.prose img {
  display: block;
  margin: 1.3em 0;
  max-width: 100%;
  height: auto;
  border-radius: 16px;
  box-shadow: var(--raise-sm);
}

.prose pre,
.prose code {
  overflow-wrap: anywhere;
}

.prose pre {
  display: block;
  max-width: 100%;
  overflow-x: auto;
  padding: 14px 16px;
  border-radius: 14px;
  background: #e9f1f8;
  box-shadow: var(--sink);
}

.prose table {
  display: block;
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  border-collapse: collapse;
  font-size: 0.96rem;
}

.prose th,
.prose td {
  padding: 8px 12px;
  border-bottom: 1px solid rgba(23, 31, 38, 0.1);
  text-align: left;
}

footer {
  max-width: 1180px;
  margin: clamp(36px, 6vw, 72px) auto clamp(20px, 4vw, 48px);
  padding: clamp(26px, 5vw, 54px) clamp(14px, 4vw, 36px);
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px 26px;
  align-items: end;
}

footer p { margin: 0; }

.f-brand {
  font-size: clamp(2.2rem, 11vw, 5.4rem);
  font-weight: 700;
  line-height: 0.94;
  letter-spacing: -0.03em;
  overflow-wrap: anywhere;
  color: rgba(23, 31, 38, 0.9);
}

.f-link {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
  min-width: 0;
}

.f-link a,
.f-top a {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 6px 15px;
  border-radius: 999px;
  text-decoration: none;
  color: var(--ink);
  font-size: 0.95rem;
  background: var(--surf);
  box-shadow: var(--raise-sm);
}
.f-link a:hover,
.f-top a:hover { box-shadow: var(--sink); }

.f-copy { font-size: 0.85rem; color: var(--ink-2); }
.f-top { justify-self: end; }

@media (max-width: 640px) {
  footer { grid-template-columns: minmax(0, 1fr); }
  .f-link { justify-content: flex-start; }
  .f-top { justify-self: start; }
}

@media (min-width: 880px) {
  .menu > summary { display: none; }
  .menu::details-content { display: block; }
  .menu menu {
    position: static;
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 4px;
    padding: 0;
    width: auto;
    max-width: none;
    background: none;
    box-shadow: none;
    border-radius: 0;
  }
  .menu menu a {
    background: none;
    box-shadow: none;
    padding: 6px 13px;
    font-weight: 500;
    color: var(--ink-2);
  }
  .menu menu a:hover {
    background: var(--surf);
    box-shadow: var(--raise-sm);
    color: var(--ink);
  }

  .hero { min-height: 86svh; }
  .sheet { grid-template-columns: 248px minmax(0, 1fr); }
  .rail { position: sticky; top: 100px; }
  .rail ul { grid-template-columns: minmax(0, 1fr); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition-duration: 0.01ms !important; animation: none !important; }
  .hero-img { transform: none !important; }
}

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