/* slider */
.slider {
  max-width: 100%;
  width: 1000px;
  aspect-ratio: 5/2;
  margin-inline: auto;

  @media screen and (min-width: 1000px) {
    margin-bottom: 24px;
    overflow: hidden;
  }

  .bx-wrapper {
    margin-bottom: 0;
    z-index: 0;

    .bx-viewport {
      left: 0;
      border: none;
      box-shadow: none;
    }

    .bx-caption {
      display: inline-flex;
      align-items: center;
      height: 24px;
      background: var(--sub_key_color);

      @media screen and (max-width: 999px) {
        position: relative;
        justify-content: center;
        background: #edeae4;
      }

      @media screen and (min-width: 1000px) {
        height: 30px;
        background: rgb(237 234 228 / 80%);
      }

      span {
        padding: 0 8px;
        color: var(--color-neutral-900);
        font-size: 13px;
        line-height: 1;

        @media screen and (min-width: 1000px) {
          padding: 0 8px;
        }
      }
    }

    .bx-pager {
      bottom: 30px;
      padding: 0;

      @media screen and (max-width: 999px) {
        font-size: 0;
        line-height: 1;
      }

      @media screen and (min-width: 1000px) {
        bottom: 0;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        height: 30px;
      }

      &.bx-default-pager a {
        width: 6px;
        height: 6px;
        margin: 0 6px;
        background: var(--bordercolor_secondary);
      }
    }
  }

  @media screen and (max-width: 999px) {
    #slider > div:not(:first-child) {
      display: none;
    }
  }
}

.products {
  padding-top: 20px;
  padding-bottom: 20px;

  h3 {
    margin: 20px 0;
    font-size: 16px;
    line-height: 1.25;

    @media screen and (min-width: 1000px) {
      font-size: 18px;
    }

    span {
      display: block;
      margin-top: 8px;
      color: #505050;
      font-size: 14px;
      font-weight: normal;
      line-height: 1.21;

      @media screen and (min-width: 1000px) {
        font-size: 16px;
      }
    }

    img {
      display: none !important;
    }
  }

  ul {
    list-style: none;

    @media screen and (max-width: 999px) {
      display: grid;
      grid-template-columns: 1fr 1fr;
      grid-template-rows: auto;
      grid-gap: 24px;
    }
  }

  li {
    @media screen and (max-width: 999px) {
      &:first-child {
        grid-column: 1/3;

        h3 {
          font-size: 18px;
        }

        span {
          display: block;
          margin-top: 6px;
          color: #505050;
          font-size: 16px;
          line-height: 1.1875;
        }
      }
    }

    .product-list__price {
      font-weight: 700;

      @media screen and (min-width: 1000px) {
        font-size: 18px;
      }
    }

    @media screen and (max-width: 999px) {
      a img {
        display: block;
        width: auto;
        margin-inline: auto;
      }
    }
  }
}

.products.specialty {
  @media screen and (min-width: 1000px) {
    border-top: 2px solid rgb(112, 112, 112);
  }

  h2 {
    margin: 12px 0;
    font-size: 24px;
    line-height: 1.38;

    @media screen and (min-width: 1000px) {
      font-size: 24px;
      line-height: 1;
    }

    &::before {
      content: "ąŁ";
      color: var(--key_color);
    }
  }

  h3 {
    margin-top: 16px;

    @media screen and (min-width: 1000px) {
      margin-top: 0;
    }
  }

  hgroup p {
    margin-bottom: 32px;
    line-height: 1.75;

    @media screen and (min-width: 1000px) {
      margin: 16px 0 32px;
      line-height: 1.875;
    }
  }

  ul {
    margin-top: 32px;
  }

  li {
    img {
      width: auto;
      height: auto;

      @media screen and (max-width: 999px) {
        aspect-ratio: 1/1;
        margin-inline: auto;
      }

      @media screen and (min-width: 1000px) {
        width: 320px;
        height: 240px;
        margin-right: 15px;
        -o-object-fit: cover;
        object-fit: cover;
        float: left;
      }
    }

    @media screen and (min-width: 1000px) {
      + li {
        margin-top: 1.5rem;
      }
    }

    a {
      display: block;
      width: 100%;

      @media screen and (min-width: 1000px) {
        height: 240px;
      }
    }

    &:first-child p.description {
      margin: 1rem 0;
    }
  }

  p.description {
    position: relative;
    margin-top: 0.8rem;
    padding-top: 0.8rem;
    line-height: 1.75;

    @media screen and (max-width: 999px) {
      border-top: 1px solid #b7b7b7;
    }

    @media screen and (min-width: 1000px) {
      font-size: 0.75rem;

      &::before {
        content: "";
        position: absolute;
        top: 0;
        left: 335px;
        display: block;
        width: 26px;
        height: 1px;
        background: #b7b7b7;
      }
    }
  }

  .more {
    margin-top: 32px;
    text-align: right;

    @media screen and (min-width: 1000px) {
      margin-top: 16px;
    }

    a {
      position: relative;
      font-size: 13px;

      &::before {
        content: "";
        position: absolute;
        top: 0;
        left: -1em;
        bottom: -1px;
        display: block;
        width: 0.5em;
        height: 0.5em;
        margin: auto;
        border-top: solid 1px #000;
        border-right: solid 1px #000;
        background: none;
        transform: rotate(45deg);
      }
    }
  }
}

.banner {
  margin: 2rem 0;

  img {
    display: block;
    margin: auto;

    &.is-square {
      width: 345px;
      height: auto;
    }
  }

  a + a {
    display: block;
    margin-top: 0.5rem;
  }
}

.products.recommend {
  h2 {
    margin-bottom: 24px;
    font-size: 26px;

    @media screen and (min-width: 1000px) {
      position: relative;
      display: block;
      margin-bottom: 32px;
      text-align: center;
      font-size: 22px;
    }

    &::before {
      content: "ąŁ";
      color: #ee4b13;

      @media screen and (min-width: 1000px) {
        content: "";
        position: absolute;
        top: 3px;
        bottom: 0;
        display: block;
        width: 100%;
        height: 3px;
        margin: auto;
        border-top: 1px solid #b7b7b7;
        border-bottom: 1px solid #b7b7b7;
        z-index: -1;
      }
    }

    @media screen and (min-width: 1000px) {
      span {
        background: #fff;
        padding: 1em;
      }
    }
  }

  h3 {
    margin-bottom: 0.8rem;
    font-size: 18px;
    line-height: 1.38;
  }

  @media screen and (max-width: 999px) {
    &::before {
      content: "";
      display: block;
      width: 100%;
      height: 1px;
      margin: 0 auto 40px;
      background-color: #707070;
    }
  }

  @media screen and (min-width: 1000px) {
    ul {
      display: flex;
      flex-direction: row;
      flex-wrap: nowrap;
      grid-gap: 32px;
    }
  }
}

aside.suggest {
  margin-top: 48px;

  .module.history {
    padding-top: 0;
    border: none;
  }
}

.products.ranking {
  margin-top: 44px;
  padding: 0;

  @media screen and (min-width: 1000px) {
    margin-top: 2.25rem;
    outline: 1px solid #fff;
    outline-offset: -4px;
  }

  h2 {
    font-size: 1.5rem;

    @media screen and (max-width: 999px) {
      position: relative;
      display: block;
      width: -webkit-fit-content;
      width: -moz-fit-content;
      width: fit-content;
      margin: 0 auto;
      padding: 1.25rem 2.5rem;
      background: #000;
      color: #fff;
      font-size: 1.5rem;
      line-height: 1;
      text-align: center;

      &::before,
      &::after {
        content: "";
        position: absolute;
        top: 0;
        display: block;
        width: 3px;
        height: 100%;
        background-image: url("https://www.tsuku-shin.jp/colorme/img/dashed.svg");
        background-repeat: no-repeat;
        background-size: cover;
      }

      &::before {
        left: 11px;
      }

      &::after {
        right: 11px;
      }

      .is-circle {
        border-radius: 50%;
        border: 1px solid #707070;
      }
    }
  }

  h3 {
    margin: 1em 0 0.6rem;
  }

  ul {
    display: grid;
    grid-template-columns: repeat(2, 160px);
    grid-template-rows: auto;
    justify-items: center;
    justify-content: center;
    grid-gap: 40px 20px;
    padding-top: 32px;
    padding-bottom: 56px;
    list-style: none;

    @media screen and (min-width: 1000px) {
      grid-template-columns: repeat(2, 216px);
      grid-gap: 60px 40px;
      padding-right: 40px;
      padding-left: 40px;
    }
  }

  li {
    position: relative;

    &:first-child {
      padding-bottom: 0.5rem;

      @media screen and (min-width: 1000px) {
        grid-column: 1/3;

        a {
          display: flex;
          flex-wrap: nowrap;
          justify-content: center;
          align-items: center;
          grid-gap: 24px;
        }

        h3 {
          width: -webkit-min-content;
          width: -moz-min-content;
          width: min-content;
          white-space: nowrap;

          span {
            width: inherit;
            white-space: pre-wrap;
          }
        }

        &:not(li:first-child) {
          border-top: 1px solid #fff;
        }
      }

      .img {
        width: 250px;
        height: auto;
        margin-inline: auto;

        @media screen and (min-width: 1000px) {
          margin: 0;
        }
      }
    }

    @media screen and (min-width: 1000px) {
      &:nth-child(even)::before {
        content: "";
        position: absolute;
        top: -30px;
        left: -48px;
        display: block;
        width: 557px;
        height: 1px;
        border-top: 1px solid #fff;
      }
    }
  }

  .img {
    position: relative;
    display: block;

    @media screen and (min-width: 1000px) {
      width: 190px;
      height: 190px;
    }
  }

  @media screen and (max-width: 999px) {
    span.rank-number {
      position: absolute;
      top: 0;
      left: 0;
    }
  }
}
