/* Timeline page ("Then. Now. Forever.｜WWE YYYY年") body. Loaded only on pages that use [rsm_event_archive view="year"].
   Every rule is scoped to .rsm-yp; the doubled class outranks Cocoon's ".article h2" style rules without !important. */
.rsm-yp {
  --yp-ink: #17120f;
  --yp-ink-soft: #5c5450;
  --yp-paper: #f3f1ee;
  --yp-sheet: #ffffff;
  --yp-line: #d9d4ce;
  --yp-red: #b5121b;
  --yp-gold: #c9a24a;
  --yp-display: "Barlow Condensed", "Arial Narrow", "Hiragino Sans", sans-serif;
  --yp-body: "Zen Kaku Gothic New", "Hiragino Sans", "Yu Gothic", "Noto Sans JP", system-ui, sans-serif;
  color: var(--yp-ink);
  font-family: var(--yp-body);
  font-size: 16px;
  line-height: 1.85;
}
.rsm-yp *, .rsm-yp *::before, .rsm-yp *::after { box-sizing: border-box; }
.rsm-yp.rsm-yp h1, .rsm-yp.rsm-yp h2, .rsm-yp.rsm-yp h3 { margin: 0; padding: 0; background: none; border: 0; border-radius: 0; color: inherit; }
.rsm-yp.rsm-yp p, .rsm-yp.rsm-yp ul, .rsm-yp.rsm-yp ol, .rsm-yp.rsm-yp dl, .rsm-yp.rsm-yp dd { margin: 0; padding: 0; }
.rsm-yp.rsm-yp ul, .rsm-yp.rsm-yp ol { list-style: none; }
.rsm-yp a { color: inherit; }
.rsm-yp :focus-visible { outline: 3px solid var(--yp-gold); outline-offset: 2px; }

/* Title band */
.rsm-yp-hero { background: var(--yp-ink); color: #fff; padding: 28px 24px 22px; border-radius: 4px; }
.rsm-yp-kicker { display: block; font-family: var(--yp-display); font-size: 15px; font-weight: 700; letter-spacing: .16em; color: var(--yp-gold); }
.rsm-yp.rsm-yp .rsm-yp-hero h1 { font-size: 34px; font-weight: 900; line-height: 1.3; margin: 2px 0 14px; }
.rsm-yp.rsm-yp .rsm-yp-hero p { color: #e9e4df; font-size: 15.5px; }
.rsm-yp.rsm-yp .rsm-yp-hero p + p { margin-top: 10px; }
.rsm-yp-jump { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 18px; }
.rsm-yp .rsm-yp-jump a { display: inline-flex; align-items: center; min-height: 36px; padding: 2px 12px; border: 1px solid #70675f; border-radius: 3px; font-size: 13.5px; text-decoration: none; color: #fff; }
.rsm-yp .rsm-yp-jump a:hover { background: #fff; color: var(--yp-ink); }
.rsm-yp .rsm-yp-jump a[href="#yp-review"] { border-color: var(--yp-red); }

/* Sections */
.rsm-yp-sec { margin-top: 44px; scroll-margin-top: 16px; }
.rsm-yp.rsm-yp .rsm-yp-sec > h2 { font-size: 24px; font-weight: 900; line-height: 1.35; padding-left: 12px; border-left: 5px solid var(--yp-red); }
.rsm-yp.rsm-yp .rsm-yp-lead { margin-top: 8px; color: var(--yp-ink-soft); font-size: 14.5px; }
.rsm-yp + .rsm-top.rsm-yearview, .rsm-top.rsm-yearview + .rsm-yp { margin-top: 0; }

/* Season blocks */
.rsm-yp-season { margin-top: 18px; padding: 18px 20px; background: var(--yp-sheet); border: 1px solid var(--yp-line); border-radius: 4px; }
.rsm-yp.rsm-yp .rsm-yp-season h3 { font-size: 19px; font-weight: 900; line-height: 1.4; margin-bottom: 8px; }
/* The period label sits outside the h3: Cocoon's table of contents rewrites what is inside headings. */
.rsm-yp.rsm-yp .rsm-yp-period { display: inline-block; margin-bottom: 4px; padding: 0 8px; font-family: var(--yp-display); font-size: 15px; font-weight: 700; letter-spacing: .04em; color: #fff; background: var(--yp-ink); border-radius: 2px; }
/* A period given as months: each month opens its rows in the year calendar above. */
.rsm-yp.rsm-yp .rsm-yp-months { display: flex; flex-wrap: wrap; gap: 6px; padding: 0; background: none; }
.rsm-yp .rsm-yp-months a { display: inline-flex; align-items: center; justify-content: center; min-width: 52px; min-height: 32px; padding: 0 10px; color: #fff; background: var(--yp-ink); border-radius: 2px; text-decoration: none; }
.rsm-yp .rsm-yp-months a:hover { background: var(--yp-red); }
.rsm-yp .rsm-yp-months a.is-empty { opacity: .35; pointer-events: none; }
.rsm-yp.rsm-yp .rsm-yp-season p + p { margin-top: 10px; }
.rsm-yp.rsm-yp .rsm-yp-events { font-size: 13.5px; color: var(--yp-ink-soft); }
.rsm-yp .rsm-yp-events a { color: var(--yp-red); }

/* NXT: a short lead, the faces to watch, then the big nights (each opens its row in the calendar). */
.rsm-yp.rsm-yp .rsm-yp-nxt-lead { margin-top: 12px; padding: 14px 18px; font-size: 15.5px; font-weight: 500; line-height: 1.9; color: #fff; background: var(--yp-ink); border-left: 5px solid var(--yp-gold); border-radius: 2px; }
.rsm-yp-stars { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; margin-top: 16px; }
.rsm-yp-star { padding: 14px 16px; background: var(--yp-sheet); border: 1px solid var(--yp-line); border-left: 4px solid var(--yp-gold); border-radius: 4px; }
/* The name is a paragraph, not a heading: Cocoon's TOC widget strips the tags inside headings, which would drop the
   link to the wrestler page. (h3 kept for pages written before 0.4.1.) */
.rsm-yp.rsm-yp .rsm-yp-star h3,
.rsm-yp.rsm-yp .rsm-yp-star-name { margin: 0; font-size: 17px; font-weight: 900; line-height: 1.4; }
.rsm-yp .rsm-yp-star h3 a,
.rsm-yp .rsm-yp-star-name a { text-decoration: underline; text-underline-offset: 4px; text-decoration-color: var(--yp-gold); }
.rsm-yp .rsm-yp-star h3 a:hover,
.rsm-yp .rsm-yp-star-name a:hover { color: var(--yp-red); }
.rsm-yp.rsm-yp .rsm-yp-star-tag { margin: 2px 0 6px; font-size: 12.5px; font-weight: 700; color: #8a6a1c; }
.rsm-yp.rsm-yp .rsm-yp-star p:not([class]) { font-size: 14px; line-height: 1.8; }
.rsm-yp.rsm-yp .rsm-yp-subhead { margin-top: 22px; font-size: 18px; font-weight: 900; }
.rsm-yp-stages { display: grid; gap: 8px; margin-top: 10px; }
.rsm-yp .rsm-yp-stages a { display: grid; grid-template-columns: 56px minmax(0, 1fr); column-gap: 12px; align-items: baseline; padding: 10px 14px; background: var(--yp-sheet); border: 1px solid var(--yp-line); border-radius: 4px; text-decoration: none; }
.rsm-yp .rsm-yp-stages a:hover { border-color: var(--yp-red); }
.rsm-yp .rsm-yp-stages .m { grid-row: span 2; align-self: center; text-align: center; padding: 2px 0; font-family: var(--yp-display); font-size: 17px; font-weight: 700; color: #fff; background: var(--yp-ink); border-radius: 2px; }
.rsm-yp .rsm-yp-stages b { font-size: 15.5px; color: var(--yp-red); text-decoration: underline; text-underline-offset: 3px; }
.rsm-yp .rsm-yp-stages .d { font-size: 13.5px; color: var(--yp-ink-soft); line-height: 1.7; }
.rsm-yp .rsm-yp-stages a.is-empty { pointer-events: none; opacity: .5; }

/* Feuds */
/* One feud per row: an opened ending must not leave the neighbouring card stranded. */
.rsm-yp-feuds { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; margin-top: 18px; }
.rsm-yp-feud { padding: 16px 18px; background: var(--yp-sheet); border: 1px solid var(--yp-line); border-top: 4px solid var(--yp-ink); border-radius: 4px; }
.rsm-yp.rsm-yp .rsm-yp-feud h3 { font-size: 17px; font-weight: 900; line-height: 1.45; margin-bottom: 6px; }
.rsm-yp.rsm-yp .rsm-yp-feud p { font-size: 14.5px; line-height: 1.8; }
/* A feud's matches open the event page at that match. Black outline = "opens another page", the same colour as the
   year buttons at the top and bottom; red stays for links that move within this page. */
.rsm-yp.rsm-yp .rsm-yp-matches { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 10px; }
.rsm-yp .rsm-yp-matches .lbl { margin-right: 2px; font-size: 12px; font-weight: 700; color: var(--yp-ink-soft); }
.rsm-yp .rsm-yp-matches a { display: inline-flex; align-items: center; gap: 4px; min-height: 30px; padding: 2px 10px; font-size: 12.5px; font-weight: 700; color: var(--yp-ink); text-decoration: none; background: var(--yp-sheet); border: 1.5px solid var(--yp-ink); border-radius: 2px; }
.rsm-yp .rsm-yp-matches a::after { content: "»" / ""; font-size: 1.15em; line-height: 1; }
.rsm-yp .rsm-yp-matches a:hover { background: var(--yp-ink); color: #fff; }

/* A feud's ending, folded so the card itself stays spoiler-free. No headings inside: the top page reads the h3s. */
.rsm-yp-ending { margin-top: 12px; border-top: 1px dashed var(--yp-line); padding-top: 8px; }
.rsm-yp-ending > summary { cursor: pointer; list-style: none; font-size: 13.5px; font-weight: 700; color: var(--yp-red); }
.rsm-yp-ending > summary::-webkit-details-marker { display: none; }
.rsm-yp-ending > summary::before { content: "▶"; display: inline-block; margin-right: 6px; font-size: 11px; transition: transform .15s; }
.rsm-yp-ending[open] > summary::before { transform: rotate(90deg); }
.rsm-yp.rsm-yp .rsm-yp-ending p { margin-top: 6px; padding: 8px 10px; font-size: 14px; background: #fbeeee; border-radius: 2px; }
.rsm-yp .rsm-yp-ending a { color: var(--yp-red); text-decoration: underline; text-underline-offset: 3px; }
.rsm-yp .rsm-yp-ending a.is-empty { color: var(--yp-ink-soft); text-decoration: none; pointer-events: none; }

/* Feud cards, NXT star cards and season blocks with a match video's thumbnail (archive.js picks one of their matches at random).
   The same shading as the 対戦カード list on event pages (.rsm-cardlist.has-cardlist-bg): white over the text side,
   the image showing through on the right; on a phone an even white veil. Text, buttons and colours stay as on the
   plain white card, which is also what shows without the script or an image. */
.rsm-yp-feud.has-bg,
.rsm-yp-star.has-bg,
.rsm-yp-season.has-bg {
  background:
    linear-gradient(90deg, rgba(255, 255, 255, .97) 0%, rgba(255, 255, 255, .92) 45%, rgba(255, 255, 255, .72) 70%, rgba(255, 255, 255, .55) 100%),
    var(--yp-card-bg) center top / cover no-repeat var(--yp-sheet);
}
@media (max-width: 600px) {
  .rsm-yp-feud.has-bg,
  .rsm-yp-star.has-bg,
  .rsm-yp-season.has-bg {
    background:
      linear-gradient(rgba(255, 255, 255, .88), rgba(255, 255, 255, .88)),
      var(--yp-card-bg) center / cover no-repeat var(--yp-sheet);
  }
}

/* Key wrestlers */
.rsm-yp-tablewrap { margin-top: 16px; overflow-x: auto; }
.rsm-yp.rsm-yp table.rsm-yp-players { width: 100%; margin: 0; border-collapse: collapse; background: var(--yp-sheet); border: 1px solid var(--yp-line); font-size: 14.5px; }
.rsm-yp.rsm-yp .rsm-yp-players th, .rsm-yp.rsm-yp .rsm-yp-players td { padding: 10px 12px; border: 0; border-bottom: 1px solid var(--yp-line); text-align: left; vertical-align: top; background: none; }
.rsm-yp.rsm-yp .rsm-yp-players thead th { background: var(--yp-ink); color: #fff; font-size: 13px; font-weight: 700; }
.rsm-yp .rsm-yp-players td:first-child { font-weight: 700; white-space: nowrap; }
.rsm-yp .rsm-yp-players td:last-child, .rsm-yp .rsm-yp-players th:last-child { text-align: center; width: 4.5em; font-family: var(--yp-display); font-size: 18px; font-weight: 700; }
.rsm-yp.rsm-yp .rsm-yp-players thead th:last-child { font-size: 15px; }

/* Best matches */
.rsm-yp-best { margin-top: 16px; counter-reset: best; display: grid; gap: 10px; }
.rsm-yp-best li { counter-increment: best; }
.rsm-yp .rsm-yp-best a { position: relative; display: block; padding: 14px 16px 14px 60px; background: var(--yp-sheet); border: 1px solid var(--yp-line); border-radius: 4px; text-decoration: none; }
.rsm-yp .rsm-yp-best a::before { content: counter(best); position: absolute; left: 16px; top: 12px; font-family: var(--yp-display); font-size: 30px; font-weight: 700; line-height: 1; color: var(--yp-red); }
.rsm-yp .rsm-yp-best a:hover { border-color: var(--yp-red); }
.rsm-yp-best strong { display: block; font-size: 16px; line-height: 1.5; }
.rsm-yp-best .ev { display: block; font-size: 13px; color: var(--yp-ink-soft); }
.rsm-yp-best .why { display: block; margin-top: 4px; font-size: 14px; line-height: 1.7; }

/* Spoiler area */
.rsm-yp.rsm-yp .rsm-yp-warn { margin-top: 10px; padding: 12px 14px; font-size: 14px; background: #fbeeee; border-left: 4px solid var(--yp-red); }
.rsm-yp-spoiler { margin-top: 14px; background: var(--yp-sheet); border: 1px solid var(--yp-line); border-radius: 4px; }
.rsm-yp-spoiler > summary { cursor: pointer; padding: 14px 18px; font-weight: 700; color: var(--yp-red); list-style: none; }
.rsm-yp-spoiler > summary::-webkit-details-marker { display: none; }
.rsm-yp-spoiler > summary::before { content: "▶"; display: inline-block; margin-right: 8px; font-size: 12px; transition: transform .15s; }
.rsm-yp-spoiler[open] > summary::before { transform: rotate(90deg); }
.rsm-yp-spoiler[open] { padding-bottom: 18px; }
.rsm-yp.rsm-yp .rsm-yp-spoiler h3 { margin: 18px 18px 8px; font-size: 18px; font-weight: 900; }
.rsm-yp-log { margin: 0 18px; display: grid; gap: 10px; }
.rsm-yp .rsm-yp-log li { padding-left: 14px; border-left: 3px solid var(--yp-line); font-size: 14.5px; line-height: 1.8; }
.rsm-yp-log b { color: var(--yp-red); }
/* Event names open their row in the year calendar above. */
.rsm-yp .rsm-yp-log b a { text-decoration: underline; text-underline-offset: 3px; }
.rsm-yp .rsm-yp-log b a:hover { text-decoration-thickness: 2px; }
.rsm-yp .rsm-yp-log b a.is-empty { color: var(--yp-ink-soft); text-decoration: none; pointer-events: none; }

/* Other years */
.rsm-yp-years { display: flex; justify-content: space-between; gap: 10px; margin-top: 44px; }
.rsm-yp .rsm-yp-years > * { display: inline-flex; align-items: center; min-height: 44px; padding: 4px 16px; background: var(--yp-ink); color: #fff; text-decoration: none; border-radius: 3px; font-weight: 700; }
.rsm-yp .rsm-yp-years > .is-pending { opacity: .35; }
/* The same move at the top of the page, so another year always opens at its own introduction. */
.rsm-yp-step { display: flex; justify-content: space-between; gap: 10px; margin: -8px -8px 14px; }
.rsm-yp .rsm-yp-step > * { display: inline-flex; align-items: center; min-height: 40px; padding: 2px 12px; font-family: var(--yp-display); font-size: 17px; font-weight: 600; color: #fff; text-decoration: none; border: 1px solid #70675f; border-radius: 3px; }
.rsm-yp .rsm-yp-step a:hover { background: #fff; color: var(--yp-ink); }
.rsm-yp .rsm-yp-step > .is-pending { opacity: .35; }

@media (max-width: 640px) {
  .rsm-yp-hero { padding: 20px 16px 16px; }
  .rsm-yp.rsm-yp .rsm-yp-hero h1 { font-size: 27px; }
  .rsm-yp-season { padding: 14px 14px; }
  .rsm-yp.rsm-yp .rsm-yp-sec > h2 { font-size: 21px; }
  .rsm-yp .rsm-yp-players td:first-child { white-space: normal; }
  .rsm-yp .rsm-yp-best a { padding-left: 48px; }
  .rsm-yp .rsm-yp-best a::before { left: 12px; font-size: 26px; }
}

/* Link kinds. Event names in the text move up to their row in the calendar (▲); only the calendar, the feud
   buttons and the best matches open another page. */
.rsm-yp a[href^="#rsm-e-"]::after { content: "▲"; display: inline-block; margin-left: 2px; font-size: .7em; vertical-align: 1px; text-decoration: none; }
.rsm-yp .rsm-yp-stages a[href^="#rsm-e-"]::after { content: none; }
.rsm-yp .rsm-yp-stages b::after { content: "▲"; display: inline-block; margin-left: 3px; font-size: .7em; vertical-align: 1px; }
