/* ==========================================================
   学历荟 大屏版式(1121 用户令「学历荟 知省学 和我们样板都改了」,学阿里云首页)
   只改版式,不动文案/链接/SEO 标记。挂在 main.css 之后。
   · 内容区 = 屏幕宽 − 两边各 80,最宽 1760;769–1439 两边 40;手机(≤768)不动
   · 1680 以上字号大一档(大标题 52 / 板块标题 40 / 卡片标题 18–20 / 正文 16)
   · 详情页正文栏封顶 860,宽屏把「本文目录」放到正文左边;列表页宽屏改两列卡片
   ========================================================== */

/* ---------- 内容区宽度 ---------- */
@media (min-width: 769px) {
  .container { max-width: none; padding-left: 40px !important; padding-right: 40px !important; } /* !important:页脚有一处行内 padding:8px 0 */
}
@media (min-width: 1440px) {
  .container { max-width: 1920px; padding-left: 80px !important; padding-right: 80px !important; }

  /* 首页首屏:原来两列自动铺,变宽后表单卡会被拉到 800+,改成左文字右固定宽卡片 */
  .hero-inner { grid-template-columns: minmax(0, 1fr) 460px !important; gap: 80px !important; }
  .hero-section { padding: 88px 0; }

  /* 首页六大类入口:保持 3×2,不让它自动挤成 5+1 */
  .cat-cards { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
  .articles-grid { gap: 24px; }

  /* 列表 / 详情:侧栏放宽 */
  .list-layout,
  .detail-layout { grid-template-columns: minmax(0, 1fr) 340px; gap: 32px; }

  /* 详情页:正文类内容封顶 860,在白卡片里居中,保证一行不超过约 50 字 */
  .detail-main > .detail-header > *,
  .detail-main > .article-toc,
  .detail-main > .article-content,
  .detail-main > .article-tags-row,
  .detail-main > .article-note,
  .detail-main > .article-related,
  .detail-main > .article-cta-box,
  .detail-main > .article-nav { max-width: 860px; margin-left: auto; margin-right: auto; }
  .detail-main > .article-content { box-sizing: content-box; }
}

/* ---------- 1680 以上:字号大一档 + 版面铺开 ---------- */
@media (min-width: 1680px) {
  /* 首页 */
  .hero-text h1 { font-size: 52px; line-height: 1.25; }
  .hero-subtitle { font-size: 18px; }
  .section-header h2 { font-size: 40px; }
  .section-header p { font-size: 16px; }
  .section-header-row h2, .articles-section h2 { font-size: 36px; }
  .article-card h3 { font-size: 18px; }
  .article-summary { font-size: 14px; }
  .cat-card-header h3 { font-size: 20px; }
  .cat-card-header h3 small, .cat-highlights li { font-size: 14px; }
  .why-item h3 { font-size: 20px; }
  .why-item p { font-size: 15px; }
  .nav-menu a { font-size: 16px; }

  /* 列表页:两列卡片 */
  .list-header h1 { font-size: 32px; }
  .article-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
  .article-list .list-article-card { margin-bottom: 0; }
  .article-list .empty-state { grid-column: 1 / -1; }
  .list-article-info h2 { font-size: 18px; }
  .list-summary { font-size: 14px; }
  .sidebar-card h3 { font-size: 17px; }
  .hot-articles a, .related-list a { font-size: 15px; }

  /* 详情页:目录放到正文左侧,正文栏 860 */
  .detail-layout { grid-template-columns: minmax(0, 1fr) 360px; gap: 40px; }
  .detail-main { display: grid; grid-template-columns: 240px minmax(0, 860px); column-gap: 48px;
                 justify-content: center; align-items: start; padding-bottom: 8px; }
  .detail-main > * { grid-column: 2; min-width: 0; }
  .detail-main > .detail-header { grid-column: 1 / -1; padding-left: 0; padding-right: 0; }
  .detail-main > .detail-header > * { max-width: none; margin-left: 0; margin-right: 0; }
  .detail-main > .detail-header { margin: 0 0 0 0; }
  .detail-main > .article-toc { grid-column: 1; grid-row: 2 / span 20; margin: 32px 0 0; }
  .detail-main > .article-toc,
  .detail-main > .article-content,
  .detail-main > .article-tags-row,
  .detail-main > .article-note,
  .detail-main > .article-related,
  .detail-main > .article-cta-box,
  .detail-main > .article-nav { max-width: none; margin-left: 0; margin-right: 0; }
  .detail-main > .article-content { padding-left: 0; padding-right: 0; }
  .detail-header h1 { font-size: 34px; }
  .article-content h2 { font-size: 24px; }
  .article-content h3 { font-size: 20px; }
}

/* ==========================================================
   进场动效(1121 用户「阿里云那种打开页面和往下滚的时候,内容从下往上淡入,速度适中,不拖沓」)
   html 上有 rv-on 才隐藏(由 head 里一小段脚本加;没 JS / 系统设了减少动态 / 4 秒内脚本没跑起来 → 不加或撤掉,内容照常显示)
   ========================================================== */
.rv-on :is(.hero-text, .hero-form-card, .section-header, .section-header-row, .article-card, .cat-card, .why-item,
  .list-header, .list-article-card, .sidebar-card, .detail-header, .article-toc, .article-content > *,
  .article-tags-row, .article-related, .article-cta-box, .article-nav, .pagination, .footer-inner):not(.rv-done) {
  opacity: 0; transform: translateY(28px);
  transition: opacity .55s ease-out, transform .55s cubic-bezier(.2,.7,.2,1);
  transition-delay: var(--rv-d, 0ms);
}
.rv-on :is(.hero-text, .hero-form-card, .section-header, .section-header-row, .article-card, .cat-card, .why-item,
  .list-header, .list-article-card, .sidebar-card, .detail-header, .article-toc, .article-content > *,
  .article-tags-row, .article-related, .article-cta-box, .article-nav, .pagination, .footer-inner).rv-in:not(.rv-done) {
  opacity: 1; transform: none;
}

/* 1122 第二轮(用户看完说「好」) */
/* 详情页:目录+正文+侧栏整块封顶 1600 居中(面包屑跟着对齐),白卡片里不再留两大块白 */
@media (min-width: 1680px) {
  .detail-page > .container, body:has(.detail-page) .breadcrumb-bar > .container { max-width: calc(1600px + 160px); }
}
/* 首页:六个栏目一个样太重复 → 第四个栏目(学历提升)做成深色带,打破节奏;只换底色,内容不动 */
@media (min-width: 769px) {
  .articles-section:nth-of-type(5) { background: linear-gradient(135deg, #0c1a3a 0%, #15306a 100%) !important; padding-top: 64px; padding-bottom: 64px; }
  .articles-section:nth-of-type(5) .section-header-row h2 { color: #fff; }
  .articles-section:nth-of-type(5) .more-link { color: #a9c8ff; }
  .articles-section:nth-of-type(5) .article-card { border-color: transparent; box-shadow: 0 10px 30px rgba(0,0,0,.25); }
}
