.pokemon-visual {
  margin-bottom: 35px;
}

.pokemon-visual .visual {
  position: relative;
  z-index: 1;
}

.pokemon-visual .before {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.pokemon-visual .before .frame {
  position: relative;
  width: 42.2535211268%;
  margin-inline: auto;
  aspect-ratio: 1;
  background: url("../img/common/frame.png") center/contain no-repeat;
}

.pokemon-visual .before .frame::after {
  content: "";
  position: absolute;
  background: url("../img/pokemon/arrow4.png") center/contain no-repeat;
  aspect-ratio: 142/208;
  top: 52.6666666667%;
  left: 106.6666666667%;
  width: 47.3333333333%;
}

.pokemon-visual .before .text-m {
  margin-top: 5px;
}

.pokemon-visual .before .text-m .trim {
  position: relative;
}

.pokemon-visual .before .text-m .trim::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 2px;
  border-radius: 100px;
  background: linear-gradient(90deg, var(--color-lightblue), #8e8ed8 35%, #c97bdf 80%, var(--color-purple));
}

.pokemon-visual .before img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  max-width: initial;
}

.pokemon-visual .before .chirean {
  top: 17.3333333333%;
  left: 34.6666666667%;
  width: 30%;
}

.pokemon-visual .before .seglaive {
  top: 17.3333333333%;
  left: 26.3333333333%;
  width: 46.3333333333%;
}

.pokemon-visual .after {
  position: relative;
  width: 66.0563380282%;
  z-index: 1;
  margin-inline: auto;
}

.pokemon-visual .after .inner {
  width: 100%;
  padding-top: 29.8507462687%;
  padding-bottom: 26.012793177%;
}

.pokemon-visual .after .symbol {
  position: relative;
  width: 100%;
  aspect-ratio: 469/561;
  background: url("../img/common/symbol.png") center/cover no-repeat;
}

.pokemon-visual .after .symbol img {
  position: absolute;
  top: 0;
  left: 0;
  width: 142.2174840085%;
  margin-top: -9.381663113%;
  margin-left: -17.2707889126%;
  height: auto;
  max-width: initial;
}

.pokemon-visual .data {
  width: 100%;
  max-width: 640px;
  margin: 0 auto;
}

.pokemon-visual .data .cardbox-inner {
  padding: 20px 30px 25px;
}

.pokemon-visual .data h1 {
  text-align: center;
  margin-bottom: 20px;
}

.pokemon-visual .data .info {
  display: grid;
  gap: 5px;
}

.pokemon-visual .data .info dl {
  display: flex;
  align-items: center;
  gap: 20px;
  color: var(--color-white);
  font-size: 18px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0.05em;
}

.pokemon-visual .data .info dt {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 65px;
  height: 35px;
  background: var(--color-purple);
  border-radius: 5px;
}

#gallery {
  margin-bottom: 60px;
}

#gallery .grid {
  --row-gap: 40px;
  --col-gap: 0px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  flex-direction: column;
  gap: var(--row-gap) var(--col-gap);
}

#gallery .grid .cardbox .cardbox-background .cardbox-frame::after {
  background: rgba(66, 60, 60, 0.85);
}

#gallery .grid .caption {
  padding: 15px;
  background: rgba(66, 60, 60, 0.85);
  border-radius: 6px;
  margin-top: 10px;
}

#flow .flow-fig {
  max-width: 640px;
  margin: 0 auto;
}

#flow .flow-fig .cardbox-inner {
  aspect-ratio: 658/980;
}

#flow .flow-fig picture {
  position: relative;
  display: block;
  aspect-ratio: 658/980;
}

#flow .flow-fig picture img {
  object-fit: cover;
  width: 100%;
  height: 100%;
}

.button-link {
  --border-width: 2px;
  --border-radius: 8px;
  position: relative;
  border: solid var(--border-width) var(--color-white);
  border-radius: var(--border-radius);
  width: 100%;
  max-width: 572px;
  overflow: hidden;
  margin-top: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  filter: drop-shadow(0px 6px 0px rgba(0, 0, 0, 0.3));
}

.button-link::before {
  content: "";
  background: linear-gradient(90deg, var(--color-lightblue) 0%, var(--color-lightblue) 50%, #8e8ed8 68%, #c97bdf 90%, var(--color-purple) 100%);
  position: absolute;
  top: 0;
  left: 0;
  width: 200%;
  height: 100%;
  transition: transform 400ms ease;
  transform: translate3d(-50%, 0, 0);
}

.button-link .text {
  position: relative;
  color: var(--color-white);
  font-size: 18px;
  font-weight: 700;
  line-height: 1.5;
  letter-spacing: 0.05em;
  text-align: center;
  padding: 17px 2em;
}

@media screen and (min-width: 540px) {
  .button-link .text br.sp_only {
    display: none;
  }
}

@media screen and (min-width: 768px) {
  .pokemon-visual .before .frame {
    width: 50%;
    max-width: 360px;
  }

  .pokemon-visual .after {
    width: 75%;
    max-width: 600px;
  }

  .pokemon-visual .data .info {
    gap: 10px 4px;
    grid-template-rows: auto auto;
    grid-template-columns: 1fr 1fr;
  }

  .pokemon-visual .data .info dl {
    gap: 10px;
  }

  .pokemon-visual .data .info dt {
    width: 90px;
    height: 40px;
    border-radius: 10px;
  }

  #gallery {
    margin-bottom: 80px;
  }

  .button-link {
    --border-width: 3px;
    --border-radius: 10px;
    margin-top: 45px;
  }

  .button-link .text {
    padding: 20px 2em;
  }
}

@media screen and (min-width: 1024px) {
  .pokemon-visual {
    display: grid;
    grid-template-rows: auto auto;
    grid-template-columns: 1fr 440px;
    gap: 50px 0;
    margin-right: -36px;
    margin-bottom: 80px;
  }

  .pokemon-visual .data {
    grid-row: 1/2;
    grid-column: 1/2;
  }

  .pokemon-visual .before {
    grid-row: 2/3;
    grid-column: 1/2;
  }

  .pokemon-visual .after {
    grid-row: 1/3;
    grid-column: 2/3;
  }

  .pokemon-visual .before .frame {
    width: 300px;
    max-width: initial;
  }

  .pokemon-visual .before .frame::after {
    background: url("../img/pokemon/arrow2.png") center/contain no-repeat;
    aspect-ratio: 102/52;
    top: 77.3333333333%;
    left: 89%;
    width: 34%;
  }

  .pokemon-visual .before .chirean {
    top: 11.3333333333%;
    left: 35%;
    width: 30%;
  }

  .pokemon-visual .before .seglaive {
    top: 11.3333333333%;
    left: 27%;
    width: 46.3333333333%;
  }

  .pokemon-visual .after {
    width: 100%;
    max-width: initial;
  }

  .pokemon-visual .after .inner {
    padding: 0;
  }

  .pokemon-visual .after .symbol {
    margin-top: -5.7569296375%;
  }

  .pokemon-visual .after .symbol img {
    width: 142.2174840085%;
    margin-top: -13.6460554371%;
    margin-left: -21.3219616205%;
  }

  .pokemon-visual .data .cardbox-inner {
    padding: 40px;
  }

  .pokemon-visual .data h1 {
    text-align: left;
    margin-bottom: 40px;
  }

  #gallery {
    margin-bottom: 100px;
  }

  #gallery .grid {
    --row-gap: 60px;
    --col-gap: 32px;
    flex-direction: row;
  }

  #gallery .grid > div {
    width: calc(50% - var(--col-gap) * 0.5);
  }

  #gallery .grid > div.full {
    margin: 0 var(--col-gap);
  }

  #gallery .grid .caption {
    padding: 20px;
    border-radius: 12px;
    margin-top: 20px;
  }

  #flow .flow-fig {
    max-width: 764px;
  }

  #flow .flow-fig .cardbox-inner {
    aspect-ratio: 712/418;
  }

  #flow .flow-fig picture {
    aspect-ratio: 712/418;
  }

  .button-link {
    --border-width: 4px;
    --border-radius: 12px;
    filter: drop-shadow(5px 8px 0px rgba(0, 0, 0, 0.3));
    margin-top: 60px;
  }

  .button-link .text {
    padding: 24px 2em;
  }
}

@media screen and (min-width: 1280px) {
  .pokemon-visual {
    grid-template-columns: 1fr 469px;
    margin-right: -72px;
  }
}

@media screen and (min-width: 1280px) and (max-width: 1380px) {
  .pokemon-visual .before .frame::after {
    margin-top: 36px;
  }
}

@media (hover: hover) {
  .button-link:hover::before {
    transform: none;
  }
}

@media screen and (-ms-high-contrast: active), screen and (-ms-high-contrast: none) {
  .button-link:hover::before {
    transform: none;
  }
}