@charset "utf-8";

.wb-collect {
  position: relative;
  z-index: 0; /* ※1-重ね合わせの起点を作る。背景をmainより上の最後方 */
  background-image: url(../image/wb-top/collect-bg.jpg);
  background-size: auto 100%;
  background-position: top left;
  background-repeat: no-repeat;
  overflow: visible;

  /* ※2-クリックをmainに奪われないよう、スタックを隔離 */
  isolation: isolate;

  &::before {
    content: "";
    position: absolute;
    inset: 0; /*top: 0;,left: 0;,width: 100%;,height: 100%;を包括*/
    background: linear-gradient(to bottom, #950d0f 0%, rgb(195, 0, 25, 0.9) 20%, rgb(209, 186, 146, 0.6) 60%, #950d0f 100%);
    z-index: 1; /* ※3-背景(0)より上 */
    pointer-events: none;
  }
}

.wb-collect > div {
  width: 85vw;
  position: relative; /* ※4-スモーク(1)よりテキスト達を上にする */
  z-index: 2;
}

.wb-pro-collect,
.wb-fan-collect {
  width: 100%;
  max-width: 1640px;
  margin-bottom: clamp(140px, 16vw, 200px);
}

/* ===================================
 * Gallery archive page background
 * =================================== */
.post-type-archive-gallery_pro #content,
.post-type-archive-gallery_fan #content,
.post-type-archive-gallery_vam #content {
  background: radial-gradient(circle at 50% 30%, rgba(255, 150, 170, 0.25), transparent 45%), linear-gradient(135deg, #c91b2e 0%, #8a101a 20%, #7a0f1a 50%, #c91b2e 100%);
}

/* ==========================================
 * Gallery pagination
 * ========================================== */

.wb-gallery-archive__pagination,
.wb-gallery-vam-single__pagination {
  margin-top: clamp(70px, 10vw, 120px);
  text-align: center;
}

.wb-gallery-vam-single__pagination[hidden] {
  display: none;
}

.wb-gallery-archive__pagination .nav-links,
.wb-gallery-vam-single__pagination .nav-links {
  display: flex;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
}

.wb-gallery-archive__pagination .page-numbers,
.wb-gallery-vam-single__pagination .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 38px;
  min-height: 38px;
  padding: 0.45em 0.85em;
  color: var(--color-font);
  font-size: var(--fs-16);
  line-height: 1;
  white-space: nowrap;
  background-color: rgba(51, 51, 51, 0.72);
  border: 1px solid rgba(255, 192, 215, 0.5);
  border-radius: 3px;
  text-decoration: none;
  box-sizing: border-box;
  transition:
    background-color 0.25s,
    border-color 0.25s,
    color 0.25s;
}

.wb-gallery-vam-single__pagination button.page-numbers {
  font-family: inherit;
  font-size: var(--fs-16);
  cursor: pointer;
}

.wb-gallery-archive__pagination a.page-numbers:hover,
.wb-gallery-vam-single__pagination button.page-numbers:hover {
  background-color: var(--color-main);
  border-color: var(--color-accent);
}

.wb-gallery-archive__pagination .page-numbers.current,
.wb-gallery-vam-single__pagination .page-numbers.current {
  color: var(--color-base);
  background-color: var(--color-accent);
  border-color: var(--color-accent);
}

.wb-collect-list {
  display: grid;
  /* ★1-重要：minmax(0, 1fr)で最小値を0に固定します */
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 20px;
  row-gap: clamp(64px, 7vw, 96px);
  /* align-items: stretch; */
  padding: 0;
}

.wb-collect-list > li {
  display: flex;
  justify-content: center;
  font-family: "Noto Sans JP", sans-serif;
}

.wb-pro-collect .wb-collect-list > li,
.wb-pro-collect .wb-collect-item {
  align-items: flex-start;
}

.wb-pro-collect .wb-collect-card-stack {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  width: 100%;
  max-width: min(100%, 260px);
  min-width: 0;
}

.wb-pro-collect .wb-collect-title {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 260px;
  min-width: 0;
  height: auto;
  min-height: calc((1.35em * 3) + 0.5em);
  margin: 0 auto;
  padding: 0;
  box-sizing: border-box;
  color: #ffc0d7;
  font-family: "Kaisei Decol", "Zen Old Mincho", serif;
  font-size: var(--fs-16);
  font-weight: 400;
  line-height: 1.35;
  letter-spacing: 0;
  text-align: center;
  word-break: keep-all;
  word-break: auto-phrase;
  overflow-wrap: break-word;
  line-break: strict;
  text-wrap: balance;
  hyphens: auto;
  overflow: visible;
  -webkit-box-orient: initial;
  line-clamp: initial;
  -webkit-line-clamp: initial;
  -webkit-text-stroke: 0.15px rgba(255, 255, 255, 0.45);
  text-shadow:
    0 1px 0 rgba(255, 255, 255, 0.1),
    0 2px 2px rgba(45, 8, 38, 0.45);
}

.wb-pro-collect .wb-collect-title-text {
  display: block;
  max-width: 100%;
  padding: 0.25em clamp(0.5em, 2vw, 1.25em);
  box-sizing: border-box;
  overflow: visible;
  background-image:
    linear-gradient(90deg, transparent 0%, rgba(255, 192, 215, 0.35) 15%, rgba(255, 192, 215, 0.6) 50%, rgba(255, 192, 215, 0.35) 85%, transparent 100%), linear-gradient(90deg, transparent 0%, rgba(255, 192, 215, 0.25) 15%, rgba(255, 192, 215, 0.45) 50%, rgba(255, 192, 215, 0.25) 85%, transparent 100%),
    linear-gradient(90deg, transparent 0%, rgba(255, 192, 215, 0.05) 10%, rgba(255, 192, 215, 0.2) 50%, rgba(255, 192, 215, 0.05) 90%, transparent 100%);
  background-repeat: no-repeat;
  background-size:
    calc(100% - 1.2em) 1px,
    calc(100% - 1.2em) 1px,
    100% 100%;
  background-position:
    center top,
    center bottom,
    center center;
}

.wb-pro-collect .wb-collect-title--empty .wb-collect-title-text {
  visibility: hidden;
}

.wb-collect-container {
  flex-direction: column;
  width: fit-content;
  max-width: min(100%, 260px);

  /* gap: 5px; */
  /* padding: 5px 3px; /*外枠*/
  line-height: 1.2;
  border-radius: 3px;
  box-sizing: border-box;

  border: 2px solid rgb(150, 40, 42);
}

.wb-pro-collect .wb-collect-container {
  background: radial-gradient(circle at 18% 12%, rgba(255, 192, 215, 0.2), transparent 32%), linear-gradient(135deg, rgba(50, 22, 190, 0.82) 0%, rgba(34, 34, 34, 0.9) 48%, rgba(149, 13, 15, 0.78) 100%);
  border-color: rgba(255, 192, 215, 0.3);
  box-shadow:
    0 10px 24px rgba(0, 0, 0, 0.18),
    inset 0 0 18px rgba(255, 192, 215, 0.08);
}

.wb-pro-collect .wb-collect-info {
  color: rgba(255, 239, 247, 0.94);
  opacity: 0.9;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.32);
}

.wb-pro-collect .wb-info-x a {
  color: rgba(226, 218, 255, 0.88);
  opacity: 0.88;
}

.wb-pro-collect .wb-info-name--credit {
  display: grid;
  gap: 0.25em;
  font-size: 11px;
  line-height: 1.35;
  letter-spacing: 0;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

.wb-pro-collect .wb-credit-line {
  display: grid;
  gap: 0.05em;
  min-width: 0;
}

.wb-pro-collect .wb-credit-value {
  display: block;
}

.wb-pro-collect .wb-credit-label {
  display: block;
  color: rgba(255, 192, 215, 0.8);
  font-size: 10px;
  line-height: 1.2;
  letter-spacing: 0;
}

.wb-pro-collect .wb-credit-value {
  color: rgba(255, 239, 247, 0.95);
  font-size: 12px;
  line-height: 1.3;
}

.wb-pro-collect .wb-collect-info.text-top {
  background: linear-gradient(90deg, rgba(50, 22, 190, 0.34), rgba(70, 24, 62, 0.5), rgba(149, 13, 15, 0.34));
  border-bottom: 1px solid rgba(255, 192, 215, 0.16);
}

.wb-fan-collect .wb-collect-container {
  background: radial-gradient(circle at 18% 88%, rgba(255, 207, 112, 0.22), transparent 36%), linear-gradient(120deg, rgba(216, 129, 0, 0.82) 10%, rgba(198, 142, 38, 0.86) 35%, rgba(156, 103, 32, 0.9) 100%);
  border-color: rgba(255, 206, 116, 0.38);
  box-shadow:
    0 10px 24px rgba(0, 0, 0, 0.18),
    inset 0 0 16px rgba(255, 206, 116, 0.12);
}

.wb-fan-collect .wb-collect-info {
  color: rgba(255, 248, 232, 0.92);
  opacity: 0.88;
}

.wb-fan-collect .wb-info-x a {
  color: rgba(255, 231, 183, 0.86);
  opacity: 0.86;
}

.wb-fan-collect .wb-collect-info.text-top {
  background: linear-gradient(90deg, rgba(216, 129, 0, 0.44), rgba(151, 102, 36, 0.56));
  border-bottom: 1px solid rgba(255, 219, 145, 0.18);
}

.wb-collect-image {
  /* ★3-画像のコンテナは幅を指定せず、中のimgに任せる */
  width: fit-content;
  margin: 0 auto;
  overflow: hidden;
}

.wb-collect-image img {
  display: block;
  /* ★4-width: 100%をやめ、高さ固定(20vw)による自然な幅を維持させる */
  width: auto;
  max-width: 100%;
  height: clamp(120px, 18vw, 260px);
  object-fit: cover;
  border-radius: 2px;
  background: radial-gradient(ellipse, #b0005e 0%, #b0005e 30%, #720c7a 100%);
}

.wb-collect-info {
  /* ★5-重要：親(container)がfit-contentなので、
     width: 0; min-width: 100%; とすることで「画像が作った幅」を上限にします */
  width: 0;
  min-width: 100%;
  box-sizing: border-box;

  padding: 5px 0.5em;
  font-size: var(--fs-14);
  opacity: 0.7;
  word-break: break-all;
}

.wb-info-name {
  color: rgba(255, 255, 255, 0.96);
  font-weight: 500;
  line-height: 1.3;
}

.wb-info-name-suffix {
  display: inline-block;
  margin-left: 0.15em;
  font-size: 0.78em;
  font-weight: 500;
  opacity: 0.78;
}
.wb-info-x a {
  opacity: 0.6;
  /* color: rgb(238, 238, 238, 0.7); */
  font-style: italic;
}

.wb-collect-info.text-top {
  order: -1;
}

.wb-collect-top {
  align-items: flex-start;
}

.wb-collect-mid {
  align-items: center;
}

.wb-collect-btm {
  align-items: flex-end;
}

.wb-collect-full {
  flex-grow: 1;

  & img {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }
}

@media (min-width: 1501px) {
  .wb-collect-list > li:nth-child(4n + 2),
  .wb-collect-list > li:nth-child(4n) {
    transform: translateY(22px);
  }
}

@media (max-width: 1500px) {
  .wb-collect-image img {
    height: clamp(120px, 20vw, 220px);
  }
}

@media (min-width: 901px) and (max-width: 1500px) {
  .wb-collect-list {
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 10px;
  }

  .wb-pro-collect .wb-collect-list {
    row-gap: 45px;
  }

  .wb-pro-collect .wb-collect-list > li {
    align-self: start;
  }

  .wb-fan-collect .wb-collect-list {
    row-gap: 75px;
  }

  .wb-collect-list > li {
    grid-column: span 2;
  }

  .wb-collect-list > li:nth-child(4),
  .wb-collect-list > li:nth-child(12) {
    grid-column: 2 / span 2;
  }

  .wb-collect-list > li:nth-child(5),
  .wb-collect-list > li:nth-child(13) {
    grid-column: 4 / span 2;
  }
}

@media (max-width: 900px) {
  .wb-collect .model-inner {
    padding-left: 15px;
    padding-right: 15px;
  }

  .wb-collect-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 15px;
  }

  .wb-pro-collect .wb-collect-list {
    row-gap: 60px;
  }

  .wb-fan-collect .wb-collect-list {
    row-gap: 90px;
  }

  .wb-collect-list > li:nth-child(even) {
    transform: translateY(22px);
  }

  .wb-collect-image img {
    height: 35vw;
  }

  .wb-collect-info {
    font-size: 13px;
  }
}

@media (max-width: 600px) {
  .wb-collect-list {
    grid-template-columns: minmax(0, 1fr);
  }

  .wb-pro-collect .wb-collect-list {
    row-gap: 50px;
  }

  .wb-collect-list > li:nth-child(even) {
    transform: none;
  }

  .wb-pro-collect .wb-collect-card-stack,
  .wb-collect-container,
  .wb-pro-collect .wb-collect-title {
    max-width: min(100%, 320px);
  }

  .wb-collect-info.text-top {
    order: unset;
  }

  .wb-collect-image img {
    height: auto;
    max-height: 420px;
  }
}
