html {
  --font-YuMincho: '游明朝', 'Yu Mincho', '游明朝体', 'YuMincho', 'ＭＳ Ｐ明朝', 'MS PMincho', 'ヒラギノ明朝 Pro W3', 'Hiragino Mincho Pro', serif;
}

/* ---- mainWrap ---- */
#detail.tachiyomi .mainWrap {
  overflow: visible; /* ---- clipがサポートされていないブラウザのバージョン用 ---- */
  overflow: clip; /* ---- tachiyomi-book の position: sticky; を適用させるため ---- */
}
@media (max-width: 960px) {
  #detail.tachiyomi .mainWrap {
    overflow: hidden;
  }
}

/* ---- tachiyomi-wrap ---- */
.tachiyomi-wrap {
  display: grid;
  grid-template-columns: 1fr 2.1fr;
  grid-template-rows: repeat(2, auto);
  column-gap: 4px;
}
@media (max-width: 960px) {
  .tachiyomi-wrap {
    grid-template-columns: minmax(17px, 17fr) 370fr;
    grid-template-rows: repeat(3, auto);
    column-gap: 3px;
  }
}

/* ---- tachiyomi-parts ---- */
.tachiyomi-parts {
  position: relative;
  grid-column: 1 / 2;
  grid-row: 2 / 3;
  border-radius: 0 40px 40px 0;
  background-color: #fff;
}
@media (max-width: 960px) {
  .tachiyomi-parts {
    --min-width: 30px;
    min-width: var(--min-width);
    grid-column: 1 / 2;
    grid-row: 2 / 4;
    border-radius: 0 30px 30px 0;
    margin-left: calc(var(--min-width) * -1);
  }
}
.tachiyomi-parts::before {
  content: '';
  position: absolute;
  top: 0;
  right: 100%;
  width: 50vw;
  height: 100%;
  background-color: #fff;
}
@media (max-width: 960px) {
  .tachiyomi-parts::before {
    display: none;
  }
}

/* ---- parts/v2/article-head-tachiyomi.html ---- */
#detail.tachiyomi .ttlBox {
  display: grid;
  grid-template:
    'mainTtl mainTtl' auto
    'info variousTxt2' auto / 1fr auto;
  column-gap: 30px;
  row-gap: 14px;
  grid-column: 2 / 3;
  grid-row: 1 / 2;
  border: none;
  padding: 50px 15px 34px 34px;
}
@media (max-width: 960px) {
  #detail.tachiyomi .ttlBox {
    grid-column: 1 / 3;
    grid-row: 1 / 2;
    margin-bottom: 150px;
  }
}
@media (max-width: 650px) {
  #detail.tachiyomi .ttlBox {
    grid-template:
      'mainTtl' auto
      'variousTxt2' auto
      'info' auto / auto;
    gap: 0;
    margin-bottom: 128px;
    padding: 24px 20px;
  }
}
#detail.tachiyomi .ttlBox h1.mainTtl {
  grid-area: mainTtl;
  font-size: calc(24 / 16 * 1rem);
  line-height: calc(38.4 / 24);
  margin: 0;
}
@media (max-width: 650px) {
  #detail.tachiyomi .ttlBox h1.mainTtl {
    font-size: calc(20 / 16 * 1rem);
    line-height: calc(32 / 20);
  }
}
#detail.tachiyomi .ttlBox .info {
  grid-area: info;
}
@media (max-width: 650px) {
  #detail.tachiyomi .ttlBox .info {
    margin-top: 8px;
  }
}
#detail.tachiyomi .ttlBox .data {
  font-size: calc(15 / 16 * 1rem);
  color: #48403e;
}
#detail.tachiyomi .ttlBox .data::before {
  font-size: 17px;
  color: #48403e;
}
#detail.tachiyomi .ttlBox li span {
  font-size: calc(15 / 16 * 1rem);
  letter-spacing: normal;
  padding-left: 0.6em;
}
#detail.tachiyomi .ttlBox .variousTxt2 {
  grid-area: variousTxt2;
  text-align: right;
  align-self: start;
}
@media (max-width: 650px) {
  #detail.tachiyomi .ttlBox .variousTxt2 {
    text-align: left;
  }
}
#detail.tachiyomi .ttlBox .variousTxt2 a {
  color: #000;
}

/* ---- /parts/v2/article-keywords.html ---- */
#detail.tachiyomi .ttlBox .search {
  margin-top: 12px;
}
@media (max-width: 650px) {
  #detail.tachiyomi .ttlBox .search {
    margin-top: 6px;
  }
}
#detail.tachiyomi .ttlBox .search ul {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
#detail.tachiyomi .ttlBox .search li {
  display: block;
  line-height: 1;
}
#detail.tachiyomi .ttlBox .search a {
  display: inline-block;
  color: #48403e;
  font-size: calc(12 / 16 * 1rem);
  border: 1px solid #cccccc;
  border-radius: 9999px;
  padding: 0.4em 0.6em;
}
#detail.tachiyomi .ttlBox .search a::before {
  content: '#';
}

/* ---- tachiyomi-book ---- */
.tachiyomi-book {
  position: sticky;
  z-index: 1;
  top: 150px;
  align-self: start;
  justify-self: end;
  grid-column: 1 / 2;
  grid-row: 1 / 3;
  margin-top: 50px;
  padding: 0 30px 40px 15px;
}
@media (max-width: 960px) {
  .tachiyomi-book {
    position: static;
    grid-column: 2 / 3;
    grid-row: 2 / 3;
    align-self: auto;
    justify-self: auto;
    background-color: #fff;
    border-radius: 30px 0 0 0;
    margin-top: 0;
    padding: 0 30px 20px;
  }
}
@media (max-width: 650px) {
  .tachiyomi-book {
    padding: 0 21px 20px;
  }
}
.tachiyomi-book_img-link {
  display: block;
  width: 60.5%;
  margin: 0 auto;
  transition-property: opacity;
}
@media (max-width: 960px) {
  .tachiyomi-book_img-link {
    max-width: 250px;
    margin-top: -150px;
  }
}
@media (max-width: 650px) {
  .tachiyomi-book_img-link {
    max-width: 158px;
    margin-top: -122px;
  }
}
.tachiyomi-book_img {
  width: 100%;
  height: auto;
  box-shadow: 4px 4px 8px 0 rgb(0 0 0 / 0.4);
}
.tachiyomi-book_title {
  font-size: calc(20 / 16 * 1rem);
  font-family: var(--font-YuMincho);
  text-align: center;
  margin-top: 18px;
}
@media (max-width: 960px) {
  .tachiyomi-book_title {
    font-size: calc(18 / 16 * 1rem);
  }
}
@media (max-width: 650px) {
  .tachiyomi-book_title {
    margin-top: 15px;
  }
}
.tachiyomi-book_author {
  font-size: calc(18 / 16 * 1rem);
  font-family: var(--font-YuMincho);
  text-align: center;
  margin-top: 8px;
}
@media (max-width: 650px) {
  .tachiyomi-book_author {
    font-size: calc(14 / 16 * 1rem);
    margin-top: 4px;
  }
}
.tachiyomi-book_links {
  display: grid;
  gap: 10px;
  margin-top: 16px;
}
@media (max-width: 960px) {
  .tachiyomi-book_links {
    display: none;
  }
}
.tachiyomi-book_link {
  display: inline-block;
  text-align: center;
  background-color: #d07046;
  border-radius: 6px;
  padding: 0.8em 2em;
}
.tachiyomi-book_link span {
  position: relative;
  color: #fff;
  font-weight: bold;
}
.tachiyomi-book_link.-more span {
  padding-right: 28px;
}
.tachiyomi-book_link.-more span::before {
  content: '';
  position: absolute;
  right: 0;
  bottom: 0;
  width: 18px;
  min-width: 0;
  aspect-ratio: 1;
  background-image: url('/common/images/v2/icon_link.svg');
  background-size: contain;
  background-repeat: no-repeat;
  margin: auto;
}

/* ---- tachiyomi-toast ---- */
.tachiyomi-toast {
  display: none;
}
@media (max-width: 960px) {
  .tachiyomi-toast {
    --border-radius: 8px;
    position: fixed;
    z-index: 5;
    bottom: env(safe-area-inset-bottom, 0);
    left: 0;
    display: flex;
    max-width: 300px;
    background-color: #fff;
    box-shadow: 0 0 6px 0 rgb(0 0 0 / 0.4);
    border-radius: 0 var(--border-radius) 0 0;
    transition-property: opacity, visibility;
    transition-duration: 0.5s;
  }
}
@media (max-width: 960px) {
  .tachiyomi-toast[data-show='false'] {
    opacity: 0;
    visibility: hidden;
  }
}
@media (max-width: 960px) {
  .tachiyomi-toast[data-show='true'] {
    opacity: 1;
    visibility: visible;
  }
}
@media (max-width: 960px) {
  .tachiyomi-toast_img-link {
    display: block;
    width: 45px;
    flex-shrink: 0;
    margin: -11px 0 9px 7px;
  }
}
@media (max-width: 960px) {
  .tachiyomi-toast_img {
    width: 100%;
    height: auto;
    box-shadow: 2px 2px 3px 0 rgb(0 0 0 / 0.3);
  }
}
@media (max-width: 960px) {
  .tachiyomi-toast_info {
    align-self: center;
    padding: 10px 10px 6px;
  }
}
@media (max-width: 960px) {
  .tachiyomi-toast_title {
    font-size: calc(14 / 16 * 1rem);
    font-weight: bold;
    line-height: calc(18.2 / 14);
  }
}
@media (max-width: 960px) {
  .tachiyomi-toast_author {
    font-size: calc(12 / 16 * 1rem);
    line-height: 1.5;
  }
}
@media (max-width: 960px) {
  .tachiyomi-toast_link {
    display: grid;
    place-items: center;
    width: 58px;
    flex-shrink: 0;
    background-color: #d07046;
    border-radius: 0 var(--border-radius) 0 0;
  }
}
@media (max-width: 960px) {
  .tachiyomi-toast_link span {
    position: relative;
    color: #fff;
    font-size: calc(13 / 16 * 1rem);
    font-weight: bold;
    line-height: calc(15.6 / 13);
    text-align: center;
    padding-top: 30px;
  }
}
@media (max-width: 960px) {
  .tachiyomi-toast_link span::before {
    content: '';
    position: absolute;
    right: 0;
    left: 0;
    top: 9px;
    width: 18px;
    min-width: 0;
    aspect-ratio: 1;
    background-image: url(/common/images/v2/icon_link.svg);
    background-size: contain;
    background-repeat: no-repeat;
    margin: auto;
  }
}

/* ---- tachiyomi-body ---- */
#detail.tachiyomi .tachiyomi-body {
  position: relative;
  grid-column: 2 / 3;
  grid-row: 2 / 3;
}
@media (max-width: 960px) {
  #detail.tachiyomi .tachiyomi-body {
    grid-column: 2 / 3;
    grid-row: 3 / 4;
  }
}
#detail.tachiyomi .tachiyomi-body::before {
  content: '';
  position: absolute;
  top: 0;
  left: 100%;
  width: 50vw;
  height: 100%;
  background-color: #fff;
}
@media (max-width: 960px) {
  #detail.tachiyomi .tachiyomi-body::before {
    display: none;
  }
}
#detail.tachiyomi .tachiyomi-body .contentsBox {
  border-radius: 40px 0 0 40px;
  margin: 0;
}
@media (max-width: 960px) {
  #detail.tachiyomi .tachiyomi-body .contentsBox {
    border-radius: 0 0 0 30px;
  }
}
#detail.tachiyomi .tachiyomi-body .contentsBox .contents {
  margin-right: 13px;
  margin-left: 34px;
}
@media (max-width: 960px) {
  #detail.tachiyomi .tachiyomi-body .contentsBox .contents {
    margin-inline: 34px;
  }
}
@media (max-width: 650px) {
  #detail.tachiyomi .tachiyomi-body .contentsBox .contents {
    margin-inline: 21px;
  }
}

/* ---- /parts/v2/article-sns.html ---- */
#detail.tachiyomi .tachiyomi-body .contentsBox .snsBox {
  margin: 40px 13px 10px 34px;
}
@media (max-width: 650px) {
  #detail.tachiyomi .tachiyomi-body .contentsBox .snsBox {
    text-align: center;
    margin: 40px 20px 10px;
  }
}
