body {
  color: #333;
  background-color: #ffffff85;
  counter-reset: ranking;
}

header {
  top: 0;
  position: sticky;
  background-color: #ffffffc2;
  backdrop-filter: blur(5px);
  z-index: 10;
}

header h1 {
  cursor: pointer;
}

#autocomplete {
  width: 40%;
}

a {
  cursor: pointer;
}

input {
  color: #333;
  border-bottom: 1px solid #333;
}

svg {
  fill: #4444449f;
}

.title {
  font-size: 0.9rem;
  line-height: 1.4rem;
  font-weight: bold;
}

.maker,
.salesDate {
  font-size: 0.7rem;
  line-height: 1.4rem;
}

.rankingItems {
  display: flex;
  position: relative;
  align-items: flex-start;
}

.rankingItems > .contents {
  width: 100%;
  margin: 0.5rem;
  line-height: 1.2rem;
  font-size: 0.8rem;
}

article {
  display: flex;
  align-items: flex-start;
}

.ranking {
  padding-left: 1rem;
  width: 35%;
}

.results {
  width: 65%;
  display: flex;
  align-items: flex-start;
  flex-wrap: wrap;
}

.results .resLists {
  width: auto;
  flex-direction: column;
}

.resLists {
  width: 10rem;
  cursor: pointer;
}

.contents {
  width: 10.5rem;
}

.bookDetails {
  display: flex;
  align-items: flex-start;
  margin-top: 1rem;
  margin-left: 1rem;
}

.bookDetails > img {
  width: 10.5rem;
  height: auto;
}

.details,
.mDetails {
  width: 100%;
  margin: 1rem 2rem;
  display: flex;
  align-items: flex-start;
}

.details > div,
.mDetails > div {
  margin: 0 1rem;
}

.moreDetailsCont {
  border-top: dotted 1px #777777b9;
  border-bottom: dotted 1px #777777b9;
  padding: 1rem;
}

.moreDetailsCont > p:nth-child(1) {
  width: 100%;
  font-size: 0.8rem;
  font-weight: bold;
  line-height: 2rem;
}

.desc {
  width: 30%;
  display: inline-block;
  font-size: 0.8rem;
  line-height: 1.2rem;
}
.data {
  width: 70%;
  display: inline-block;
}

/* ranking */
.r-contents {
  height: 3rem;
  margin: 0 1rem 0 0.4rem;
  display: flex;
  align-items: center;
}

.r-contents p {
  line-height: 1.2rem;
  margin: 0.5rem 0 0.5rem 1rem;
  width: 85%;
  text-overflow: ellipsis;
  overflow: hidden;
  white-space: nowrap;
}

.ranking-item:nth-of-type(1) .order,
.ranking-item:nth-of-type(2) .order,
.ranking-item:nth-of-type(3) .order {
  border: none;
  color: #fff;
  font-weight: normal;
}

.ranking-item:nth-of-type(1) .order {
  background-color: #dab413;
}

.ranking-item:nth-of-type(2) .order {
  background-color: #6e7b84;
}

.ranking-item:nth-of-type(3) .order {
  background-color: #a0541a;
}

.ranking-item .order::before {
  content: counter(ranking);
  counter-increment: ranking;
  font-size: 1rem;
}

.detailsCont {
  width: 100%;
  height: 100%;
}

.review {
  position: relative;
  padding: 0.15rem;
  padding-left: 5rem;
  display: inline-block;
  width: 5rem;
  height: 1rem;
  font-size: 0.9rem;
}

.rate:before,
.rate:after {
  font-size: 1em;
  position: absolute;
  top: 50%;
  left: 0;
  transform: translateY(-50%);
  display: inline-block;
  height: 1em;
  line-height: 1em;
  content: '★★★★★';
}

.rate:before {
  color: #ddd;
}

.rate:after {
  color: #ffa500;
  overflow: hidden;
  white-space: nowrap;
}

.rate00:after {
  width: 0;
}
.rate05:after {
  width: 0.5em;
}
.rate10:after {
  width: 1em;
}
.rate15:after {
  width: 1.5em;
}
.rate20:after {
  width: 2em;
}
.rate25:after {
  width: 2.5em;
}
.rate30:after {
  width: 3em;
}
.rate35:after {
  width: 3.5em;
}
.rate40:after {
  width: 4em;
}
.rate45:after {
  width: 4.5em;
}
.rate5:after {
  width: 5em;
}

.category {
  margin-top: 0.4rem;
  font-size: 0.7rem;
  line-height: 1.4rem;
}

.status {
  font-size: 0.8rem;
  font-weight: bold;
  line-height: 3rem;
}

.rankLine0 {
  border-bottom: solid 0.5rem #a2d2ff;
}

.ranking .rankLine0 {
  border-bottom: solid 0.5rem #ffbc06d5;
}

.rankLine1 {
  border-bottom: solid 0.5rem #bdfefe;
}

.rankLine2 {
  border-bottom: solid 0.5rem #ffafcc;
}

.rankLine3 {
  border-bottom: solid 0.5rem #cdb4db;
}

.btn {
  color: #fff;
  background-color: #ff8b39;
  margin: 1rem 0;
  font-size: 0.8rem;
  font-weight: bold;
  padding: 0.5rem 1rem;
  text-decoration: none;
  border-radius: 0.2rem;
}

.btn:hover {
  color: #fff;
  background: #ffa361;
}

/* add CSS */
#ranking-container {
  width: 100%;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-around;
  margin: 0 auto;
}

.rankingTitle {
  width: 47%;
}

.ranking .rankingTitle {
  width: 100%;
}

.rankingTitle h2 {
  width: 100%;
  display: block;
  margin-top: 1rem;
  padding-left: 0.8rem;
  line-height: 0.6rem;
}

.rankingTitle > a {
  width: 100%;
  margin-top: 1rem;
  padding: 0.8rem 0 0.8rem 2rem;
  border: solid 0.1rem #6d687550;
}

.rankingTitle > a:nth-of-type(1)::before {
  content: '1';
  position: absolute;
  bottom: 1rem;
  left: 1rem;
  font-weight: bolder;
  font-size: 2.3rem;
  -webkit-text-stroke-width: 1px;
  -webkit-text-stroke-color: #f0ce0f;
  -webkit-text-fill-color: #ffff00;
}

.rankingTitle > a:nth-of-type(2)::before {
  content: '2';
  position: absolute;
  bottom: 1rem;
  left: 1rem;
  font-weight: bolder;
  font-size: 2.3rem;
  -webkit-text-stroke-width: 1px;
  -webkit-text-stroke-color: #fff;
  -webkit-text-fill-color: gray;
}

.rankingTitle > a:nth-of-type(3)::before {
  content: '3';
  position: absolute;
  bottom: 1rem;
  left: 1rem;
  font-weight: bolder;
  font-size: 2.3rem;
  -webkit-text-stroke-width: 1px;
  -webkit-text-stroke-color: #fff;
  -webkit-text-fill-color: brown;
}

.rankingItems {
  width: 100%;
  align-items: flex-start;
}

.order {
  width: 15%;
  height: 1.5rem;
  margin: 0 10px;
  color: #aaa;
  border: 1px solid #ccc;
  vertical-align: 20px;
  text-align: center;
  font-weight: bold;
  line-height: 1.5rem;
}

/* Normal */
@media (max-width: 1200px) {
  /* ranking */
  .r-contents p {
    font-size: 0.8rem;
    line-height: 1.2rem;
    margin: 0.5rem 0 0.5rem 1rem;
    width: 100%;
    text-overflow: ellipsis;
    overflow: hidden;
    white-space: nowrap;
  }
}

@media (max-width: 900px) {
  .rankingTitle {
    width: 95%;
  }
}

/* Tablet */
@media (max-width: 890px) {
  .results {
    width: 90%;
    /* margin: 0rem 2rem; */
  }

  .mDetails {
    margin: 0;
  }

  .resLists > img {
    display: block;
    margin-left: auto;
    margin-right: auto;
    /* width: 50%; */
  }

  .results .resLists {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    width: 100%;
    margin: 1rem;
  }

  .moreDetailsCont {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    align-content: flex-start;
    line-height: 1.4rem;
  }

  .results .contents {
    width: 50%;
    padding: 0.2rem 0;
  }
}

/* Smartphone */
@media (max-width: 600px) {
  .ranking {
    display: none !important;
  }

  .mDetails {
    margin: 0;
  }

  .resLists > img {
    display: block;
    margin-left: auto;
    margin-right: auto;
    /* width: 50%; */
  }

  .results .resLists {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    width: 100%;
  }

  .moreDetailsCont {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    align-content: flex-start;
    line-height: 1.4rem;
  }

  .results .contents {
    width: 50%;
    padding: 0.2rem 0;
  }
}

/* Smartphone */
@media (max-width: 500px) {
  .rankingTitle {
    width: 95%;
  }
  /* .results {
    justify-content: center;
  } */
}
