/* 吃瓜网 17 — 浅底渐变条 + 卡片河流，响应式 */
:root {
  --ml-bg: #f2f0f7;
  --ml-card: #ffffff;
  --ml-ink: #16131c;
  --ml-muted: #6b6578;
  --ml-line: #e0dbe8;
  --ml-violet: #5b21b6;
  --ml-violet-d: #4c1d95;
  --ml-rose: #e11d48;
  --ml-soft: #ede9fe;
  --ml-max: 1080px;
  --ml-read: 720px;
  --ml-r: 16px;
  --ml-font: "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--ml-font);
  font-size: 16px;
  line-height: 1.65;
  color: var(--ml-ink);
  background: var(--ml-bg);
}

a {
  color: var(--ml-violet-d);
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
  border-radius: 12px;
}

.ml-box {
  width: min(100% - 28px, var(--ml-max));
  margin-inline: auto;
}

.ml-read {
  max-width: var(--ml-read);
}

/* 顶区：渐变带 + 单行滚动标签（移动端可折行） */
.ml-banner {
  background: linear-gradient(110deg, #5b21b6 0%, #7c3aed 38%, #db2777 100%);
  color: #fff;
  padding: 18px 0 22px;
}

.ml-banner-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 14px;
}

.ml-site {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.ml-site h1 {
  margin: 0;
  font-size: clamp(1.25rem, 4vw, 1.65rem);
  font-weight: 800;
  letter-spacing: 0.02em;
}

.ml-site p {
  margin: 0;
  font-size: 0.82rem;
  opacity: 0.92;
  max-width: 36ch;
}

.ml-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.ml-tabs a {
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 600;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.35);
  color: #fff;
  text-decoration: none;
}
.ml-tabs a:hover {
  background: rgba(255, 255, 255, 0.28);
  text-decoration: none;
}
.ml-tabs a.on {
  background: #fff;
  color: var(--ml-violet-d);
  border-color: #fff;
}

/* 二级白顶栏 */
.ml-subbar {
  background: var(--ml-card);
  border-bottom: 1px solid var(--ml-line);
  box-shadow: 0 4px 20px rgba(91, 33, 182, 0.06);
}

.ml-subbar-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 12px 0;
  align-items: center;
  justify-content: space-between;
}

.ml-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.ml-pills a {
  font-size: 0.8rem;
  padding: 6px 12px;
  border-radius: 8px;
  background: var(--ml-soft);
  color: var(--ml-violet-d);
  font-weight: 600;
  text-decoration: none;
}
.ml-pills a:hover {
  background: #ddd6fe;
  text-decoration: none;
}

.ml-tip {
  font-size: 0.78rem;
  color: var(--ml-muted);
}

/* 三枚能力徽标 */
.ml-strip {
  padding: 22px 0;
}

.ml-trio {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

@media (min-width: 640px) {
  .ml-trio {
    grid-template-columns: repeat(3, 1fr);
  }
}

.ml-cap {
  background: var(--ml-card);
  border: 1px solid var(--ml-line);
  border-radius: var(--ml-r);
  padding: 16px;
  display: flex;
  gap: 14px;
  align-items: flex-start;
}

.ml-ico {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: linear-gradient(145deg, #ede9fe, #fce7f3);
  flex-shrink: 0;
  display: grid;
  place-items: center;
  font-weight: 900;
  font-size: 0.85rem;
  color: var(--ml-violet);
}

.ml-cap h2 {
  margin: 0 0 4px;
  font-size: 0.95rem;
}

.ml-cap p {
  margin: 0;
  font-size: 0.82rem;
  color: var(--ml-muted);
}

/* 主阅读柱 + 全宽卡片河 */
.ml-main {
  padding-bottom: 40px;
}

.ml-hero-img {
  border-radius: var(--ml-r);
  overflow: hidden;
  border: 1px solid var(--ml-line);
  margin: 0 auto 20px;
  max-width: var(--ml-read);
  background: var(--ml-card);
}

.ml-hero-img img {
  border-radius: 0;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.ml-hero-img figcaption {
  padding: 10px 14px;
  font-size: 0.78rem;
  color: var(--ml-muted);
  border-top: 1px solid var(--ml-line);
}

.ml-k {
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ml-rose);
  margin-bottom: 8px;
}

.ml-main h2 {
  margin: 0 0 12px;
  font-size: clamp(1.2rem, 3vw, 1.5rem);
  line-height: 1.3;
}

.ml-lead {
  margin: 0 0 18px;
  color: var(--ml-muted);
  font-size: 0.94rem;
}

.ml-article {
  background: var(--ml-card);
  border: 1px solid var(--ml-line);
  border-radius: var(--ml-r);
  padding: 22px 20px 24px;
  font-size: 0.95rem;
  color: #2f2a38;
  margin: 0 auto 28px;
  max-width: var(--ml-read);
}

.ml-article p {
  margin: 0 0 1em;
  text-align: justify;
  text-justify: inter-ideograph;
}

.ml-article p:last-of-type {
  margin-bottom: 0;
}

.ml-loz {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.ml-loz span {
  font-size: 0.74rem;
  padding: 5px 10px;
  border-radius: 999px;
  background: var(--ml-soft);
  border: 1px solid var(--ml-line);
  color: var(--ml-muted);
}

/* 卡片河流 */
.ml-sec-title {
  font-size: 1.1rem;
  margin: 0 0 8px;
}

.ml-sec-sub {
  margin: 0 0 14px;
  font-size: 0.88rem;
  color: var(--ml-muted);
}

.ml-river {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

@media (min-width: 560px) {
  .ml-river.r2 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 880px) {
  .ml-river.r3 {
    grid-template-columns: repeat(3, 1fr);
  }
}

.ml-tile {
  background: var(--ml-card);
  border: 1px solid var(--ml-line);
  border-radius: var(--ml-r);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  height: 100%;
  transition: transform 0.2s, box-shadow 0.2s;
}
.ml-tile:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(91, 33, 182, 0.1);
}

.ml-tile a {
  color: inherit;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.ml-tile a:hover h3 {
  color: var(--ml-violet);
}

.ml-tile img {
  border-radius: 0;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  width: 100%;
}

.ml-tile .in {
  padding: 14px 16px 18px;
  flex: 1;
}

.ml-badge {
  display: inline-block;
  font-size: 0.65rem;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: 6px;
  background: #ffe4e6;
  color: var(--ml-rose);
  margin-bottom: 6px;
}

.ml-tile h3 {
  margin: 0 0 6px;
  font-size: 1rem;
}

.ml-tile p {
  margin: 0;
  font-size: 0.84rem;
  color: var(--ml-muted);
}

/* 内页 */
.ml-crumb {
  font-size: 0.85rem;
  color: var(--ml-muted);
  padding: 18px 0 6px;
}

.ml-page-h1 {
  margin: 0 0 10px;
  font-size: clamp(1.2rem, 3vw, 1.55rem);
}

.ml-sum {
  color: var(--ml-muted);
  font-size: 0.92rem;
  margin: 0 0 18px;
}

.ml-fig {
  border-radius: var(--ml-r);
  overflow: hidden;
  border: 1px solid var(--ml-line);
  margin-bottom: 20px;
  background: var(--ml-card);
}

.ml-fig img {
  border-radius: 0;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.ml-fig figcaption {
  padding: 8px 12px;
  font-size: 0.78rem;
  color: var(--ml-muted);
}

.ml-board {
  border: 1px solid var(--ml-line);
  border-radius: var(--ml-r);
  overflow: hidden;
  background: var(--ml-card);
}

.ml-line {
  display: grid;
  grid-template-columns: 1fr;
  gap: 6px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--ml-line);
}

@media (min-width: 600px) {
  .ml-line {
    grid-template-columns: 1fr auto auto;
    align-items: center;
  }
}

.ml-line:last-child {
  border-bottom: 0;
}

.ml-line a.n {
  font-weight: 700;
  color: var(--ml-ink);
  text-decoration: none;
}
.ml-line a.n:hover {
  color: var(--ml-violet);
}

.ml-line .d {
  font-size: 0.82rem;
  color: var(--ml-muted);
}

.ml-line .f {
  font-size: 0.76rem;
  color: var(--ml-rose);
  font-weight: 700;
  white-space: nowrap;
}

.ml-prose {
  font-size: 0.94rem;
  color: #2f2a38;
  max-width: var(--ml-read);
}

.ml-prose p {
  margin: 0 0 1em;
}

.ml-split {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
  padding-bottom: 36px;
}

@media (min-width: 760px) {
  .ml-split.s2 {
    grid-template-columns: 280px 1fr;
  }
}

.ml-sidebox {
  background: var(--ml-soft);
  border: 1px solid var(--ml-line);
  border-radius: var(--ml-r);
  padding: 16px;
  font-size: 0.88rem;
  color: var(--ml-muted);
}

.ml-sidebox h2 {
  margin: 0 0 8px;
  font-size: 0.9rem;
  color: var(--ml-violet-d);
}

.ml-foot {
  border-top: 1px solid var(--ml-line);
  padding: 24px 0;
  background: #eae6f2;
}

.ml-foot p {
  margin: 0;
  text-align: center;
  font-size: 0.82rem;
  color: var(--ml-muted);
}

.ml-skip {
  position: absolute;
  left: -9999px;
  background: var(--ml-violet);
  color: #fff;
  padding: 8px 14px;
  z-index: 99;
}
.ml-skip:focus {
  left: 8px;
  top: 8px;
}
