/* ==========================================================================
   pages.css — 首页 hero、内页页头、长文排版、404
   ========================================================================== */

/* ================================================================ 首页 hero */

.hero {
  padding-top: clamp(10px, 1.6vw, 22px);
  padding-bottom: clamp(28px, 3.4vw, 48px);
}

.hero__in {
  display: grid;
  grid-template-columns: minmax(0, 1.06fr) minmax(0, .94fr);
  gap: clamp(12px, 1.2vw, 18px);
  align-items: stretch;
}

/* 左：薄荷绿文案卡 */
.hero__copy {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: clamp(16px, 1.6vw, 22px);
  padding: clamp(28px, 3.6vw, 56px);
  background: var(--mint);
  border-radius: var(--radius);
  min-height: clamp(420px, 42vw, 560px);
  overflow: hidden;
}

/* 卡内一角的大圆装饰，让色块更有呼吸 */
.hero__copy::after {
  content: "";
  position: absolute;
  right: -70px;
  bottom: -90px;
  width: 260px;
  height: 260px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .34);
  pointer-events: none;
}

.hero__copy > * { position: relative; z-index: 1; }

.hero__copy .eyebrow {
  margin-bottom: 0;
  color: rgba(27, 69, 45, .62);
}

.hero__copy .eyebrow::before { background: var(--accent); }

.hero__copy .h-hero { max-width: 14em; }

.hero__copy .h-hero em { display: block; }

.hero__copy .lede {
  max-width: 44ch;
  color: var(--ink-2);
  font-size: clamp(15px, 1.14vw, 16.5px);
}

.hero__copy .btn-row { margin-top: 4px; }

.hero__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 18px;
  margin-top: 6px;
  font-size: 12.5px;
  color: rgba(27, 69, 45, .62);
}

.hero__meta span {
  display: inline-flex;
  align-items: baseline;
  gap: 4px;
  position: relative;
}

.hero__meta span + span::before {
  content: "";
  position: absolute;
  left: -10px;
  top: 50%;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: rgba(27, 69, 45, .3);
  transform: translateY(-50%);
}

.hero__meta b {
  font-family: "Manrope", var(--font-sans);
  font-weight: 800;
  color: var(--ink-deep);
}

/* 右：奶油黄角色卡 */
.hero__visual {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: clamp(18px, 2vw, 26px);
  background: var(--butter);
  border-radius: var(--radius);
  overflow: hidden;
  min-height: clamp(420px, 42vw, 560px);
}

.hero__art-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: rgba(74, 63, 12, .55);
  z-index: 2;
}

.hero__art-head svg {
  width: 22px;
  height: 22px;
  color: rgba(74, 63, 12, .5);
}

.hero__art {
  flex: 1;
  min-height: 0;
  margin: clamp(-16px, -1.6vw, -8px) 0 0;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

.hero__art img {
  width: auto;
  height: 100%;
  max-width: 100%;
  object-fit: contain;
  object-position: center bottom;
  filter: drop-shadow(0 18px 26px rgba(122, 107, 24, .18));
}

.hero__art-foot {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  padding-top: 12px;
  z-index: 2;
}

.hero__art-foot p {
  font-size: 13.5px;
  line-height: 1.65;
  color: rgba(74, 63, 12, .72);
  max-width: 18ch;
}

.hero__art-btn {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .68);
  color: #6B5B14;
  flex: none;
  transition: background-color var(--t-fast), transform 260ms cubic-bezier(.34, 1.5, .64, 1);
}

.hero__art-btn svg { width: 20px; height: 20px; }

.hero__art-btn:hover { background: #fff; transform: translate(2px, -2px); }
/* ================================================================ 展示区（截图） */

.showcase {
  display: grid;
  grid-template-columns: minmax(0, .82fr) minmax(0, 1.18fr);
  gap: clamp(28px, 4vw, 64px);
  align-items: center;
}

.showcase__media {
  display: flex;
  gap: 18px;
  align-items: flex-start;
  justify-content: center;
}

.showcase__media .phone { width: min(48%, 220px); }
.showcase__media .phone:nth-child(2) { margin-top: 40px; }

/* ================================================================ 内页页头 */

.page-head {
  padding-top: clamp(24px, 3vw, 40px);
  padding-bottom: clamp(16px, 2vw, 28px);
}

.page-head .wrap:has(> .lede) {
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(0, .88fr);
  column-gap: clamp(32px, 5vw, 80px);
  align-items: end;
}

.page-head .wrap > * { grid-column: 1; }

.page-head .wrap > .lede {
  grid-column: 2;
  grid-row: 1 / span 8;
  align-self: end;
  justify-self: end;
  text-align: right;
  max-width: 38ch;
  font-size: 14.5px;
  line-height: 1.8;
  color: var(--ink-3);
  padding-bottom: 6px;
}

.page-head .wrap > .breadcrumb { margin-bottom: clamp(18px, 2vw, 26px); }

.page-head .wrap > .ver-bar {
  grid-column: 1 / -1;
  margin-top: 24px;
}

.page-head .wrap > .tiny { grid-column: 1 / -1; }

.page-head .h-1 { margin-bottom: 0; }

.page-head .wrap > .page-head__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: clamp(16px, 1.8vw, 22px);
}

/* ================================================================ 长文排版 */

.doc-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 264px;
  gap: clamp(28px, 4vw, 56px);
  align-items: start;
}

.prose {
  font-size: 15.5px;
  line-height: 1.85;
  color: var(--ink-2);
  max-width: 74ch;
}

.prose > * + * { margin-top: 18px; }

.prose h2 {
  font-size: clamp(21px, 2vw, 26px);
  color: var(--ink-deep);
  margin-top: clamp(34px, 4vw, 48px);
  scroll-margin-top: 110px;
}

.prose h2:first-child { margin-top: 0; }

.prose h3 {
  font-size: 17px;
  font-weight: 600;
  color: var(--ink-deep);
  margin-top: 28px;
  scroll-margin-top: 110px;
}

.prose p { line-height: 1.85; }

.prose ul,
.prose ol {
  display: grid;
  gap: 8px;
  padding-left: 0;
}

.prose ul > li {
  position: relative;
  padding-left: 20px;
}

.prose ul > li::before {
  content: "";
  position: absolute;
  left: 3px;
  top: .74em;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--mint-3);
}

.prose ol { counter-reset: n; }
.prose ol > li {
  position: relative;
  padding-left: 30px;
  counter-increment: n;
}

.prose ol > li::before {
  content: counter(n);
  position: absolute;
  left: 0;
  top: .12em;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--mint);
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: 10.5px;
  font-weight: 700;
}

.prose a {
  color: var(--accent);
  border-bottom: 1px solid var(--accent-line);
}

.prose a:hover { border-bottom-color: var(--accent); }

.prose strong { color: var(--ink); }

.prose code {
  font-family: var(--font-mono);
  font-size: .88em;
  background: var(--paper-3);
  padding: 2px 6px;
  border-radius: 6px;
  color: var(--ink-deep);
}

.prose .table-wrap,
.prose .code,
.prose .note { margin-top: 22px; }

.prose .table-wrap { max-width: 100%; }

.prose blockquote {
  padding: 16px 20px;
  border-left: 3px solid var(--mint-3);
  background: var(--paper-3);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  color: var(--ink-2);
}

/* 侧栏里的卡片 */
.doc-aside + .doc-aside { margin-top: 16px; }

/* ================================================================ 404 */

.error-page {
  padding-block: clamp(60px, 10vw, 140px);
  text-align: center;
}

.error-page__code {
  font-family: "Manrope", var(--font-sans);
  font-size: clamp(76px, 15vw, 168px);
  font-weight: 800;
  letter-spacing: -.05em;
  line-height: .9;
  color: var(--mint);
  margin-bottom: 18px;
}

/* ================================================================ 响应式 */

@media (max-width: 1080px) {
  .doc-layout { grid-template-columns: minmax(0, 1fr); }
  .doc-layout > .doc-aside { order: 2; }
}

@media (max-width: 960px) {
  .hero__in { grid-template-columns: minmax(0, 1fr); }

  .hero__copy {
    min-height: 0;
    padding: clamp(26px, 5vw, 40px) clamp(22px, 5vw, 36px);
  }

  .hero__visual { min-height: clamp(360px, 62vw, 460px); }

  .hero__art img { max-height: clamp(260px, 46vw, 360px); }

  .showcase { grid-template-columns: minmax(0, 1fr); }
  .showcase__media { order: -1; }

  .page-head .wrap:has(> .lede) {
    grid-template-columns: minmax(0, 1fr);
    row-gap: 14px;
  }

  .page-head .wrap > .lede {
    grid-column: 1;
    grid-row: auto;
    justify-self: start;
    text-align: left;
    max-width: 56ch;
    padding-bottom: 0;
  }
}

@media (max-width: 560px) {
  .hero__art-foot p { font-size: 12.5px; }
  .hero__meta { font-size: 12px; gap: 6px 16px; }
  .error-page__code { font-size: 92px; }
}
