/*
 * 研究員コメント ブロック
 *
 * 表側とブロックエディタの両方で読み込まれる。
 * 見た目はトピックス調査の研究員コメント（assets/css/layouts/single-topics.css の .researcher）と同じ。
 * エディタではサイトのリセットCSS・rem の基準（62.5%）・.pc/.sp が効かないので、px と自前の切り替えで書く。
 */

.kodomo-comment {
  display: flex;
  align-items: flex-start;
  color: #222;
  font-family: 'MFW-PA1GothicStd-Medium', var(--font-yugothic);

  .icon {
    flex: none;
    width: 82px;
    img {
      display: block;
      width: 100%;
      height: auto;
    }
  }

  .type {
    margin: 0;
    color: #919191;
    font-size: 14px;
    line-height: 1;
  }
  .type.is-sp {
    display: none;
  }

  .comment {
    flex: 1;
    min-width: 0; /* テキストが長いときに横幅があふれるのを防ぐ */
    margin-top: -8px;
    padding-left: 22px;
  }

  /* p にすると本文側の p のスタイルが効いてしまうので div にしている */
  .text {
    margin: 8px 0 0;
    font-size: 18px;
    line-height: calc(32 / 18);
  }

  @media only screen and (max-width: 767px) {
    .icon {
      width: 45px;
    }
    .type.is-pc {
      display: none;
    }
    .type.is-sp {
      display: block;
      margin-top: 9px;
      padding: 0 4px;
      font-size: 12px;
      line-height: calc(16 / 12);
      text-align: center;
    }
    .comment {
      margin-top: -6px;
      padding-left: 15px;
    }
    .text {
      margin-top: 0;
      font-size: 14px;
      line-height: 2;
    }
  }
}
