/*============================
#chart
============================*/
section#chart {
  display: flex;
  padding: var(--padding-block, 80px) var(--padding-inline, 20px);
  flex-direction: column;
  align-items: center;
  gap: var(--gap-row, 56px);
  align-self: stretch;
  background: var(--surface-variant, #f4eded);
}

/*title*/
section#chart .chart__heading {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--scale-24, 24px);
  align-self: stretch;
}

section#chart .chart__heading h2 {
  display: flex;
  padding: var(--scale-8, 8px) var(--scale-16, 16px);
  justify-content: center;
  align-items: center;
  border-radius: var(--scale-4, 4px);
  background: rgba(195, 126, 129, 0.9);
  color: var(--surface, #fff);
  text-align: center;
  font-family: "Noto Sans JP";
  font-size: min(40px, 100vw / 375 * 26);
  font-style: normal;
  font-weight: 700;
  line-height: 130%;
  /* 52px */
}

section#chart .chart__heading p {
  color: var(--on-surface, #4d4848);
  text-align: center;
  font-family: "Noto Sans JP";
  font-size: var(--scale-20, 20px);
  font-style: normal;
  font-weight: 500;
  line-height: 170%;
  /* 34px */
}

/*拡大して全体を見るポップアップ*/
section#chart .zoom__popup {
  z-index: 100;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.6);
  display: none;
  justify-content: center;
  align-items: center;
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

section#chart .zoom__popup-close {
  width: 30px;
  height: 30px;
  display: inline-block;
  background: url(../images/chart-close.svg) no-repeat;
  background-position: center;
  background-size: contain;
  cursor: pointer;
  position: absolute;
  top: 15px;
  right: 15px;
}

section#chart .zoom__popup__content {
  width: 100%;
  max-width: 90%;
  padding: 1em 0.5em;
  background: #fff;
  display: flex;
  flex-direction: column;
  gap: var(--scale-16, 16px);
  max-height: 90%;
  overflow-x: scroll;
}

section#chart .zoom__popup__content p {
  font-size: var(--scale-14, 14px);
  color: var(--on-surface, #1b1c1f);
}

section#chart button.zoom__button {
  display: flex;
  max-width: 280px;
  padding: var(--scale-16, 13px);
  justify-content: center;
  align-items: center;
  gap: var(--scale-8, 6px);
  flex: 1 0 0;
  border-radius: 1000px;
  background: var(--primary);
  box-shadow: var(--scale-2, 2px) var(--scale-4, 4px) 0 0 rgba(0, 0, 0, 0.2);
  color: var(--surface, #fff);
  text-align: center;
  font-family: "Noto Sans JP";
  font-size: var(--scale-20);
  font-style: normal;
  font-weight: 700;
  line-height: 130%;
  /* 27.3px */
  width: 100%;
}

section#chart button.chart__zoom figure.icon-zoom {
  width: 21px;
  flex-shrink: 0;
  aspect-ratio: 1/1;
}

section#chart button.chart__zoom figure.icon-zoom img {
  width: 100%;
}

section#chart button.chart__zoom figure.icon-arrow {
  width: 18px;
  flex-shrink: 0;
  aspect-ratio: 1/1;
}

section#chart button.chart__zoom figure.icon-arrow img {
  width: 100%;
}

/*チャート*/
section#chart div.chart__container {
  display: flex;
  width: 100%;
  margin-inline: auto;
  flex-direction: column;
  gap: var(--scale-20, 20px);
  max-width: 1280px;
}

section#chart div.chart__container .chart__body {
  /*max-width: 1280px;*/
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--scale-16, 16px);
  align-self: stretch;
}

section#chart .comparition-chart {
  max-width: 1280px;
  display: flex;
  flex-direction: column;
}

section#chart .row-group-container {
  display: flex;
  width: 100%;
}

section#chart .row-group {
  display: flex;
  width: 100%;
  flex-direction: column;
}

section#chart .row {
  display: flex;
  width: 100%;
  height: 100%;
}

section#chart .th.th--group {
  grid-column: span 1;
  justify-content: flex-start;
  display: flex;
  width: var(--chart-th-group-width);
  padding: var(--scale-8, 8px);
  flex-direction: column;
  align-items: center;
  gap: var(--scale-8, 8px);
  border-bottom: 1px solid var(--surface, #fff);
  background: var(--primary, #c37e81);
  line-height: 120%;
  /* 19.2px */
}

section#chart .th {
  display: flex;
  width: var(--chart-th-width, 200px);
  padding: var(--scale-8, 8px);
  flex-direction: column;
  justify-content: center;
  align-items: center;
  align-self: stretch;
  border-bottom: 1px solid var(--surface, #fff);
  background: var(--primary, #c37e81);
  color: var(--surface, #fff);
  text-align: center;
  font-family: "Noto Sans JP";
  font-size: var(--scale-16, 16px);
  font-style: normal;
  font-weight: 700;
  line-height: 150%;
  /* 24px */
  flex: 0 0 auto;
}

section#chart .th--sub {
  display: flex;
  width: var(--chart-th-sub-width, 160px);
  padding: var(--scale-8, 8px);
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: var(--scale-4, 4px);
  align-self: stretch;
  border-right: 1px solid var(--border, #c5b2b2);
  border-bottom: 1px solid var(--border, #c5b2b2);
  background: var(--surface-variant, #f4eded);
  color: var(--on-surface, #4d4848);
  text-align: center;
  font-family: "Noto Sans JP";
  font-size: 14px;
  font-style: normal;
  font-weight: 700;
  line-height: 130%;
  /* 18.2px */
  border-color: var(--border);
}

section#chart .th--sub .comment {
  display: flex;
  justify-content: center;
  align-items: flex-end;
  gap: var(--scale-4, 4px);
  align-self: stretch;
}

section#chart .th--sub .comment__text {
  display: flex;
  padding: var(--scale-4, 4px);
  justify-content: center;
  align-items: center;
  flex: 1 0 0;
  border-radius: var(--scale-8, 8px);
  background: var(--surface, #fff);
  color: var(--on-surface, #4d4848);
  font-family: "Noto Sans JP";
  font-size: var(--scale-12, 12px);
  font-style: normal;
  font-weight: 500;
  line-height: 130%;
  /* 15.6px */
}

section#chart .th--sub .comment figure img {
  width: var(--scale-40, 40px);
  aspect-ratio: 1/1;
}

section#chart .td-group {
  display: flex;
  width: 100%;
}

section#chart .td {
  display: flex;
  padding: var(--scale-8, 8px);
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: var(--scale-2, 2px);
  align-self: stretch;
  background: #fff;
  border-right: 1px solid var(--border, #c5b2b2);
  border-bottom: 1px solid var(--border, #c5b2b2);
  flex: 1 0 0;
}

section#chart .row-group-container:first-child .td {
  border-top: 1px solid var(--border, #c5b2b2);
}

section#chart .asterisk {
  font-size: 10px;
}

/*チェックアイコン*/
section#chart .th .c-check {
  display: flex;
  padding: var(--scale-2, 2px) var(--scale-4, 4px);
  justify-content: center;
  align-items: center;
  gap: var(--scale-2, 2px);
  border-radius: var(--scale-4, 4px);
  background: var(--tertiary, #05a29a);
  color: var(--surface, #fff);
  text-align: center;
  font-family: "Noto Sans JP";
  font-size: var(--scale-12, 12px);
  font-style: normal;
  font-weight: 700;
  line-height: 100%;
  /* 12px */
}

section#chart .th .c-check figure {
  width: var(--scale-16, 16px);
  aspect-ratio: 1/1;
}

section#chart .th .c-check span {
  flex: 0 0 auto;
}

section#chart .th--group .c-check {
  padding: var(--scale-4, 4px);
  flex-direction: column;
  font-size: var(--scale-12, 12px);
}

section#chart .th .c-check figure {
  width: var(--scale-14, 14px);
}

section#chart .th small {
  font-size: var(--scale-12, 12px);
  display: inline-block;
  line-height: 130%;
}

section#chart .c-td-rate {
  border-right: 1px solid var(--border, #b3b6d0);
  border-bottom: 1px solid var(--border, #b3b6d0);
  display: flex;
  padding: var(--scale-8, 8px);
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: var(--scale-2, 2px);
  align-self: stretch;
  background: var(--surface);
}

section#chart :is(.c-td-rate--great, .c-td-rate--check) {
  background: var(--rate-great-container, #fff8cf);
}

section#chart .c-td-rate--good {
  background: var(--rate-good-container, #e3ffe2);
}

section#chart .c-td-rate figure {
  width: var(--scale-32, 32px);
  aspect-ratio: 1/1;
}

section#chart .c-td-rate figure img {
  width: 100%;
}

section#chart .c-td-rate div.text {
  color: var(--on-surface, #4d4848);
  text-align: center;
  font-family: "Noto Sans JP";
  font-size: var(--scale-16, 16px);
  font-style: normal;
  font-weight: 700;
  line-height: 150%;
  /* 24px */
}

section#chart .c-td-rate div.subtext {
  color: var(--on-surface, #4d4848);
  text-align: center;
  font-family: "Noto Sans JP";
  font-size: var(--scale-14, 14px);
  font-style: normal;
  font-weight: 700;
  line-height: 150%;
  /* 21px */
}

/*トグルボタン*/

section#chart div.toggle-button {
  display: flex;
  padding: var(--scale-8, 8px);
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: var(--scale-8, 8px);
  align-self: stretch;
  grid-column: span 7;
  border-right: 1px solid var(--border, #b3b6d0);
  border-bottom: 1px solid var(--border, #b3b6d0);
  border-left: 1px solid var(--border, #b3b6d0);
  background: var(--primary-container, #ebf5ff);
}

.toggle-button2 {
  width: 100%;
  display: none;
}

@media screen and (max-width: 768px) {
  .toggle-button2 {
    display: flex;
  }
}

:is(div.toggle-button, div.toggle-button2) button {
  display: flex;
  padding: var(--scale-12, 12px) 0;
  justify-content: center;
  align-items: center;
  gap: var(--scale-4, 4px);
  align-self: stretch;
  border-radius: var(--scale-4, 4px);
  border: var(--scale-2, 2px) solid var(--primary, #4a64ba);
  background: var(--surface, #fff);
  color: var(--primary, #4a64ba);
  text-align: center;
  font-family: "Noto Sans JP";
  font-size: var(--scale-20, 20px);
  font-style: normal;
  font-weight: 700;
  line-height: 100%;
  /* 20px */
  position: relative;
  width: 100%;
}

:is(div.toggle-button, div.toggle-button2) button::after {
  content: "";
  display: inline-block;
  width: var(--scale-14);
  height: var(--scale-14);
  transition: 0.2s linear;

  background: linear-gradient(90deg,
      transparent 0%,
      transparent calc(50% - 1px),
      var(--primary) calc(50% - 1px),
      var(--primary) calc(50% + 1px),
      transparent calc(50% + 1px),
      transparent 100%),
    linear-gradient(0deg,
      transparent 0%,
      transparent calc(50% - 1px),
      var(--primary) calc(50% - 1px),
      var(--primary) calc(50% + 1px),
      transparent calc(50% + 1px),
      transparent 100%);
}

:is(div.toggle-button, div.toggle-button2) button[aria-expanded="true"]::after {
  rotate: 90deg;
  background: linear-gradient(90deg,
      transparent 0%,
      transparent calc(50% - 1px),
      var(--primary) calc(50% - 1px),
      var(--primary) calc(50% + 1px),
      transparent calc(50% + 1px),
      transparent 100%),
    linear-gradient(90deg,
      transparent 0%,
      transparent calc(50% - 1px),
      var(--primary) calc(50% - 1px),
      var(--primary) calc(50% + 1px),
      transparent calc(50% + 1px),
      transparent 100%);
}

/*サービス*/
section#chart .row-group-container:has(.row--service) {
  position: sticky;
  left: 0;
  top: 80px;
  /*ヘッダーの高さに合わせる*/
  z-index: 10;
}

section#chart .row--service .td .td__badge {
  display: flex;
  height: var(--scale-40, 40px);
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  aspect-ratio: 77.58/40;
}

section#chart .row--service .td .td__main-text {
  color: var(--on-surface, #4d4848);
  text-align: center;
  font-family: "Noto Sans JP";
  font-size: var(--scale-20, 20px);
  font-style: normal;
  font-weight: 700;
  line-height: 100%;
  /* 20px */
}

section#chart .row--service .td .td__main-text a {
  text-decoration: none !important;
}

section#chart .row--service figure.td__screenshot {
  width: 100%;
}

section#chart .row--service figure.td__screenshot img {
  width: 100%;
  border: 1px solid var(--border);
  aspect-ratio: 1366 / 768;
}

section#chart .row--service a.td__button {
  display: flex;
  padding: var(--scale-8, 8px);
  justify-content: center;
  align-items: center;
  gap: var(--scale-4, 4px);
  align-self: stretch;
  border-radius: 1000px;
  background: var(--secondary, #9174e6);
  box-shadow: 0 var(--scale-4, 4px) var(--scale-8, 8px) 0 #c7b4ff;
  color: var(--surface, #fff);
  text-align: center;
  font-family: "Noto Sans JP";
  font-size: var(--scale-18, 18px);
  font-style: normal;
  font-weight: 700;
  line-height: 100%;
  /* 18px */
  text-decoration: none;
}

/*ステップ*/
section#chart div.row-group div.row--step div.td {
  flex-direction: column;
  display: flex;
  padding: var(--scale-8, 8px);
  align-items: center;
  gap: var(--scale-8, 8px);
}

section#chart div.row-group div.row--step div.td div.feature {
  display: flex;
  padding: var(--scale-8, 8px) var(--scale-16, 16px);
  justify-content: center;
  align-items: center;
  align-self: stretch;
  border-radius: var(--scale-8, 8px);
  border: 1px solid var(--primary, #c37e81);
  color: var(--primary, #c37e81);
  text-align: center;
  font-family: "Noto Sans JP";
  font-size: var(--scale-16, 16px);
  font-style: normal;
  font-weight: 700;
  line-height: 130%;
  /* 20.8px */
  margin-bottom: var(--scale-4);
}

section#chart div.row-group div.row--step div.td div.step {
  display: grid;
  padding: var(--scale-8, 8px);
  justify-content: center;
  align-items: center;
  gap: var(--scale-4, 4px);
  align-self: stretch;
  border-radius: var(--scale-4, 4px);
  background: var(--surface-variant, #f4eded);
  grid-template-columns: auto 1fr auto;
}

section#chart div.row-group div.row--step div.td div.step--matching {
  background: var(--tertiary-container, #d4f6ec);
}

section#chart div.row-group div.row--step div.td div.step--message {
  background: #ffe2e5;
}

section#chart div.row-group div.row--step div.td div.step--date {
  background: var(--secondary-container, #e3dcf9);
  flex: 1 0 0;
}

section#chart div.row-group div.row--step div.td div.step:has(.sub-text, .feeling) figure.step__icon {
  grid-row: span 2;
}

section#chart div.row-group div.row--step div.td div.step figure.step__icon img {
  width: var(--scale-24, 24px);
  height: auto;
}

section#chart div.row-group div.row--step div.td div.step div.main-text {
  color: var(--on-surface, #4d4848);
  text-align: center;
  font-family: "Noto Sans JP";
  font-size: var(--scale-14, 14px);
  font-style: normal;
  font-weight: 700;
  line-height: 130%;
  /* 18.2px */
  flex: 1 0 0;
  grid-column: 2;
}

section#chart div.row-group div.row--step div.td div.step div.main-text img {
  display: inline-block;
  width: 1em;
}

section#chart div.row-group div.row--step div.td div.step div.sub-text {
  color: var(--on-surface, #4d4848);
  text-align: center;
  font-family: "Noto Sans JP";
  font-size: var(--scale-12, 12px);
  font-style: normal;
  font-weight: 700;
  line-height: 130%;
  /* 15.6px */
  grid-column: 2;
}

section#chart div.row-group div.row--step div.td div.step div.feeling {
  display: flex;
  padding: var(--scale-2, 2px) var(--scale-8, 8px);
  justify-content: center;
  align-items: center;
  align-self: stretch;
  border-radius: 10000px;
  background: var(--primary, #c37e81);
  color: var(--surface, #fff);
  text-align: center;
  font-family: "Noto Sans JP";
  font-size: var(--scale-12, 12px);
  font-style: normal;
  font-weight: 700;
  line-height: 130%;
  /* 15.6px */
  grid-column: 2;
}

section#chart div.row-group div.row--step div.td div.step .step__level {
  grid-row: 1 / span 2;
  grid-column: 3;
}

/*カテゴリ*/
section#chart div.cate {
  display: flex;
  padding: var(--scale-4, 4px) 0;
  justify-content: center;
  align-items: center;
  align-self: stretch;
  border-radius: 1000px;
  background: var(--surface, #fff);
  color: var(--tertiary, #05a29a);
  text-align: center;
  font-family: "Noto Sans JP";
  font-size: var(--scale-14, 14px);
  font-style: normal;
  font-weight: 700;
  line-height: 120%;
  /* 14px */
  flex-direction: column;
}

section#chart div.cate.cate--cate1 {
  border-radius: 1000px;
  background: var(--rate-great, #da7d4a);
  color: var(--surface, #fff);
}

/*料金*/
section#chart .text:has(div.women, div.men) {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
}

section#chart :is(div.women, div.men) {
  display: flex;
  align-items: flex-start;
  gap: var(--scale-8, 8px);
  color: var(--primary, #c37e81);
  text-align: center;
  font-family: "Noto Sans JP";
  font-size: var(--scale-16, 16px);
  font-style: normal;
  font-weight: 700;
  line-height: 150%;
  /* 24px */
  text-align: left;
}

section#chart :is(div.women, div.men) small {
  color: var(--on-surface, #4d4848);
  text-align: center;
  font-family: "Noto Sans JP";
  font-size: var(--scale-12, 12px);
  font-style: normal;
  font-weight: 700;
  line-height: 150%;
  /* 18px */
}

section#chart :is(div.women, div.men) label {
  display: flex;
  padding: 0 var(--scale-4, 4px);
  justify-content: center;
  align-items: center;
  border-radius: var(--scale-4, 4px);
  background: var(--primary, #c37e81);
  color: var(--surface, #fff);
  text-align: center;
  font-family: "Noto Sans JP";
  font-size: var(--scale-16, 16px);
  font-style: normal;
  font-weight: 700;
  line-height: 150%;
  /* 24px */
}

section#chart div.men {
  color: var(--tertiary, #05a29a);
}

section#chart div.men label {
  background: var(--tertiary, #05a29a);
}

section#chart .chart__note {
  color: var(--on-surface-variant, #888);
  font-family: "Noto Sans JP";
  font-size: var(--scale-12, 10px);
  font-style: normal;
  font-weight: 500;
  line-height: 130%;
  /* 13px */
}

@media screen and (max-width: 1024px) {
  /*=================================
  縦横変更
  ===================================*/

  section#chart .comparition-chart {
    flex-direction: row;
    max-width: none;
  }

  section#chart div.chart__container .chart__body {
    overflow-x: scroll;
  }

  section#chart .row-group-container {
    flex-direction: column;
    width: auto;
  }

  section#chart .row-group-container[data-width-sp] {
    width: attr(data-width-sp);
  }

  section#chart .row-group {
    flex-direction: row;
  }

  section#chart .th.th--group {
    flex-direction: row;
    width: 100%;
    height: var(--chart-th-group-height);
  }

  section#chart .row {
    flex-direction: column;
  }

  section#chart .td-group {
    flex-direction: column;
  }

  section#chart .th {
    border-right: 1px solid var(--surface, #fff);
    border-bottom: none;
    height: var(--chart-th-height);
  }

  section#chart .th--group .c-check {
    flex-direction: row;
  }

  section#chart .th.th--sub {
    height: var(--chart-th-sub-height);
    border-bottom: 1px solid;
    border-color: var(--border);
    width: auto;
  }

  section#chart .th.th--sub .comment img {
    display: none;
  }

  section#chart .td {
    height: var(--chart-td-height-short, 128px);
    flex: auto;
    padding: 6px;
  }

  section#chart .row-group-container:first-child .td {
    border-top: 0;
    border-left: 1px solid var(--border, #c5b2b2);
  }

  section#chart .td-group .td:first-child {
    height: var(--chart-td-height, 168px);
  }

  section#chart .row :is(.th, .td) {
    width: 120px;
  }

  section#chart .row.row--service :is(.th, .td) {
    width: 120px;
  }

  section#chart .row.row--bottom {
    display: none;
  }

  section#chart .row[data-attr="ステップ"] :is(.th, .td) {
    width: 387px;
  }

  section#chart .row[data-attr="気持ち確認"] :is(.th, .td) {
    width: 172px;
  }

  section#chart .row[data-attr="link2"] :is(.th, .td) {
    width: 148px;
  }

  section#chart .row[data-attr="対策"] :is(.th, .td) {
    width: min(150px, 100vw / 375 * 104);
  }

  section#chart .row[data-attr="プロフィール"] :is(.th, .td),
  section#chart .row[data-attr="顔写真"] :is(.th, .td) {
    width: 100px;
  }

  section#chart .row[data-attr="本人確認"] :is(.th, .td) {
    width: 80px;
  }

  section#chart .row--service .td figure.td__screenshot {
    width: 104px;
  }

  section#chart .row--service .td:nth-of-type(n + 2) figure.td__screenshot {
    display: none;
  }

  section#chart .row--service .td .td__badge {
    height: 28px;
  }

  section#chart .row--service .td:nth-of-type(n + 4) .td__badge {
    display: none;
  }

  section#chart .row--service a.td__button {
    font-size: 14px;
  }

  section#chart div.row-group div.row--step div.td {
    writing-mode: vertical-rl;
    flex-direction: column-reverse;
    gap: 3px;
  }

  section#chart div.row-group div.row--step div.td div.step {
    flex-direction: row;
    justify-content: flex-start;
    font-size: 13px;
    padding: 6px;
    grid-template-columns: auto;
    flex: 1 0 auto;
  }

  section#chart div.row-group div.row--step div.td div.step:has(.feeling) {
    grid-template-columns: auto;
  }

  section#chart div.row-group div.row--step div.td div.step figure.step__icon {
    grid-row: 1 / span 1 !important;
  }

  section#chart div.row-group div.row--step div.td div.step:has(.feeling) figure.step__icon {
    grid-row: span 2;
  }

  section#chart div.row-group div.row--step div.td div.step figure.step__icon img {
    height: 18px;
    width: auto;
  }

  section#chart div.row-group div.row--step div.td div.feature {
    text-align: left;
    font-size: 13px;
    padding: 6px;
    justify-content: flex-start;
  }

  section#chart div.row-group div.row--step div.td div.step div.main-text {
    grid-column: 2;
    white-space: nowrap;
    justify-self: flex-start;
    text-align: left;
    font-size: 14px;
  }

  section#chart div.row-group div.row--step div.td div.step:has(.feeling) div.main-text {
    grid-row: 2;
  }

  section#chart div.row-group div.row--step div.td div.step div.sub-text {
    display: none;
  }

  section#chart div.row-group div.row--step div.td div.step div.feeling {
    grid-row: 1;
    grid-column: 2 / span 2;
    padding: 6px 2px;
  }

  section#chart div.row-group div.row--step div.td div.step .step__level {
    grid-row: 2;
    grid-column: 3;
  }

  section#chart :is(div.women, div.men) {
    flex-direction: column;
    width: 100%;
    align-items: center;
    text-align: center;
  }
}