/* =========================================================
   Feature article (特集)
   Built from the Figma frame "特集" (1280px wide).
   Each chapter sets its own position with small variables
   in the HTML (style="--left:…; --width:…") so the zig-zag
   layout from Figma stays easy to tweak.
   ========================================================= */

.article { padding-bottom: 200px; }

/* ---------- Head ---------- */
.article-head { position: relative; margin-top: 32px; }

.article-title {
  height: 162px;
  margin-left: 73px;
  font-family: var(--font-jp-display);
  font-weight: 700;
  font-size: 107.2px;
}

.article-tags {
  position: absolute;
  left: calc(905 / 1280 * 100%);
  top: 0;
  display: flex;
  flex-direction: column;
  gap: 49.5px;
}
.article-tags .tag {
  width: 319px;
  height: 71.65px;
  border-width: 5.118px;
  border-radius: 18.77px;
  font-size: 34.118px;
}

.article-lead {
  margin-left: 40px;
  color: var(--red-dark);
  font-family: var(--font-latin);
  font-size: 40px;
}

.article-intro {
  position: relative;
  max-width: 1181px;
  margin: 23px 40px 0;
  font-family: var(--font-latin);
  font-size: 24px;
}
.article-intro p + p { margin-top: 32.8px; }

/* ---------- Chapters 01–06 ---------- */
.article .chapter {
  z-index: auto;               /* lets the big numbers sit behind all text */
  width: calc(var(--width) * 1px);
  max-width: calc(100% - var(--left) * 1px - 24px);
  margin: calc(var(--gap) * 1px) 0 0 calc(var(--left) * 1px);
  font-family: var(--font-latin);
}
.chapter h2,
.chapter p { position: relative; z-index: 1; }
.chapter h2 {
  color: var(--red-dark);
  font-weight: 700;
  font-size: 36px;
}
.chapter p { font-size: 24px; }
.chapter p + p { margin-top: 32.8px; }

.chapter-num {
  position: absolute;
  z-index: 0;
  left: calc((var(--num-x) - var(--left)) * 1px);
  top: calc(var(--num-y) * 1px);
  transform: translateX(-50%);
  color: rgba(66, 66, 66, 0.2);
  font-family: var(--font-latin);
  font-weight: 700;
  font-size: 476.545px;
  line-height: normal;
  pointer-events: none;
  user-select: none;
}

/* ---------- Photo bands ---------- */
.band {
  --bw: 1280;
  z-index: 2;
  position: relative;
  aspect-ratio: 1280 / 253;
  margin-top: 100px;
  overflow: hidden;
  background: #fff;
  border-radius: 27px;
  container-type: inline-size;
}
.band img {
  position: absolute;
  left: var(--img-x);
  top: var(--img-y);
  width: var(--img-w);
  height: auto;
}
.band figcaption {
  position: absolute;
  top: calc(76 / 253 * 100%);
  left: calc(var(--cx) / var(--bw) * 100%);
  transform: translateX(-50%);
  white-space: nowrap;
  color: #fff;
  font-size: calc(69.943 / var(--bw) * 100cqw);
}
.band-pair { position: relative; z-index: 2; display: flex; margin-top: 110px; }
.band--half { --bw: 640; flex: 1 1 50%; aspect-ratio: 640 / 253; margin-top: 0; }

/* ---------- Sources & related ---------- */
.article-h2 {
  height: 103px;
  margin: 100px 0 0 143px;
  font-weight: 300;
  font-size: 54.056px;
}
.article-sources {
  width: min(1195px, calc(100% - 84px));
  min-height: 122px;
  margin-left: 42px;
  padding: 24px 20px;
  border: 1.01px solid #000;
  border-radius: 26.27px;
  font-family: var(--font-latin);
  font-size: 20px;
}
.article-h2--related { height: 128px; margin-top: 98px; }
.article-related { display: flex; flex-wrap: wrap; gap: 16px 53px; margin-left: 113px; }

/* ---------- Tablets ---------- */
@media (max-width: 1100px) {
  .article-tags { position: static; flex-direction: row; flex-wrap: wrap; gap: 12px; margin: 0 40px 24px; }
  .article-tags .tag { width: auto; height: auto; padding: 6px 18px; font-size: 22px; border-width: 3px; }
  .article-title { height: auto; margin-bottom: 16px; }
  .article .chapter { --left: 40 !important; }
  .chapter-num { left: 50%; }
}

/* ---------- Phones ---------- */
@media (max-width: 760px) {
  .article { padding-bottom: 96px; }
  .article-head { margin-top: 20px; }
  .article-title { margin: 0 16px 12px; font-size: 56px; }
  .article-tags { margin: 0 16px 20px; gap: 8px; }
  .article-tags .tag { font-size: 15px; padding: 4px 12px; border-radius: 10px; }
  .article-lead { margin: 0 16px; font-size: 24px; line-height: 1.5; }
  .article-intro { margin: 20px 16px 0; font-size: 16px; line-height: 1.8; }
  .article-intro br,
  .chapter br { display: none; }
  .article-intro p + p,
  .chapter p + p { margin-top: 1.2em; }

  .article .chapter { width: auto; max-width: none; margin: 120px 16px 0 !important; }
  .chapter h2 { font-size: 22px; line-height: 1.5; margin-bottom: 12px; }
  .chapter p { font-size: 16px; line-height: 1.8; }
  .chapter-num { top: -150px; font-size: 220px; }

  .band { margin-top: 64px; border-radius: 16px; aspect-ratio: 1280 / 400; }
  .band img { top: calc(var(--img-y) * 0.632); }
  .band-pair { flex-direction: column; gap: 8px; margin-top: 64px; }
  .band--half { aspect-ratio: 640 / 253; }
  .band--half img { top: var(--img-y); }

  .article-h2 { height: auto; margin: 64px 16px 12px; font-size: 30px; }
  .article-sources { width: auto; margin: 0 16px; font-size: 14px; line-height: 1.7; border-radius: 16px; }
  .article-related { margin: 0 16px; gap: 12px; }
}
