@charset "UTF-8";
/* キャラクター紹介の本文用の丸ゴシック(このページだけで読み込む) */
@import url('https://fonts.googleapis.com/css2?family=M+PLUS+Rounded+1c:wght@500;800&display=swap');

/**
 * ページ専用: /character/(自社IPキャラクター紹介)
 *
 * このページでだけ読み込む(functions.php がスラッグから自動で読み込む)。
 * HTML: docs/pages/character.html(固定ページのカスタムHTMLブロックに貼る)
 * 画像: assets/img/character/
 *
 * 配置の考え方(PC):
 *   キャラクターごとの <section class="rj-chara"> をコンテナにし、
 *   フィギュア・ロゴ・リード文の位置をカード幅に対する割合(cqw)で指定する。
 *   カード幅 932px のときにデザインどおりになり、画面が狭くなっても比率を保つ。
 */

/* --- ページタイトル・本文上の余白 --- */
h1 {
  display: none;
}
.l-mainContent__inner > .post_content {
  margin: 0 !important;
}

/* ==========================================================
   全体
   ========================================================== */
.rj-charas {
  padding: 80px 0 120px;
  font-family: 'M PLUS Rounded 1c', sans-serif;
}

.rj-chara {
  /* キャラクターごとに下で上書きする値 */
  --c-card: #ffe2ed;      /* カード背景 */
  --c-accent: #d963a8;    /* 見出し・ボタン・リード文 */
  --c-text: #aa8ba2;      /* 本文 */
  --gap: 0px;             /* 前のキャラクターのカードとの間隔 */
  --card-top: 0cqw;       /* セクション上端(フィギュア上端)からカード上端まで */
  --content-top: 0cqw;    /* カード上端から本文(雲・枠)まで */

  container-type: inline-size;
  position: relative;
  width: min(932px, 100% - 32px);
  margin: var(--gap) auto 0;
}
.rj-charas > .rj-chara:first-child {
  margin-top: 0;
}

/* 見出し・段落は SWELL の装飾を外す */
.post_content .rj-chara h2,
.post_content .rj-chara h3 {
  margin: 0;
  padding: 0;
  border: none;
  background: none;
  color: inherit;
  font-size: inherit;
  line-height: 1;
}
.post_content .rj-chara h2::before,
.post_content .rj-chara h2::after,
.post_content .rj-chara h3::before,
.post_content .rj-chara h3::after {
  content: none;
}
.post_content .rj-chara p {
  margin: 0;
}

/* --- フィギュア・ロゴ(カードの上にはみ出して重なる) --- */
/* .post_content h2 の position:relative に負けないよう .rj-chara を付ける */
.rj-chara .rj-chara__fig,
.rj-chara .rj-chara__logo {
  position: absolute;
  z-index: 2;
}
.rj-chara__fig {
  height: auto;
}
.rj-chara__logo img {
  display: block;
  width: 100%;
  height: auto;
}

/* --- カード --- */
.rj-chara__card {
  position: relative;
  margin-top: var(--card-top);
  padding: var(--content-top) 0 100px;
  border-radius: 100px;
  background: var(--c-card);
  color: var(--c-text);
  font-size: 14px;
  line-height: 2;
  letter-spacing: .04em;
  text-align: center;
}
.post_content .rj-chara__card p + p {
  margin-top: 2em;  /* 段落の間は1行あける */
}

/* カード右上(または左上)の短い紹介文 */
.rj-chara__lead {
  position: absolute;
  color: var(--c-accent);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.6;
  text-align: left;
}

/* 見出し(趣味・性格など) */
.post_content .rj-chara__card h3 {
  margin-bottom: 14px;
  color: var(--c-accent);
  font-family: inherit;  /* 見出し共通の Jost ではなく、ボタンと同じ丸ゴシックにする */
  font-size: 24px;
  font-weight: 800;
  letter-spacing: .05em;
}

/* --- 雲の吹き出し(画像を本文の大きさに合わせて伸縮) --- */
.rj-chara__cloud {
  margin: 0 auto;
  background: url(../../img/character/cloud.webp) center / 100% 100% no-repeat;
}
.rj-chara__cloud.-lg {
  width: 74.9cqw;
  padding: 65px 40px;
}
.rj-chara__cloud.-md {
  width: 72.9cqw;
  padding: 56px 60px 84px;
}
.rj-chara__cloud.-sm {
  width: 41.5cqw;
  padding: 70px 30px;
}
.rj-chara__cloud + .rj-chara__cloud {
  margin-top: 45px;
}
.rj-chara__cloud.-sm + .rj-chara__cloud.-sm {
  margin-top: 30px;
}

/* --- 角が段になった白い枠(縦長と横長の角丸四角を重ねて作る) --- */
.rj-chara__frame {
  position: relative;
  z-index: 0;
  width: 68.7cqw;
  margin: 0 auto;
  padding: 44px 40px;
}
.rj-chara__frame::before,
.rj-chara__frame::after {
  content: '';
  position: absolute;
  z-index: -1;
  background: #fff;
  border-radius: 24px;
}
.rj-chara__frame::before {
  inset: 0 35px;   /* 上下いっぱい・左右を少し内側に */
}
.rj-chara__frame::after {
  inset: 34px 0;   /* 左右いっぱい・上下を少し内側に */
}

/* --- 商品を見るボタン --- */
.rj-chara__btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 416px;
  max-width: calc(100% - 48px);
  height: 68px;
  margin: 56px auto 0;
  border-radius: 999px;
  background: var(--c-accent);
  color: #fff !important;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: .05em;
  text-decoration: none;
  transition: opacity .2s;
}
.rj-chara__btn:hover {
  opacity: .8;
}

/* ==========================================================
   キャラクターごとの色・配置(PC)
   位置の値は、デザイン(カード幅932px)上の px ÷ 932 × 100 = cqw
   ========================================================== */

/* --- Nanci: フィギュア左・ロゴ右 --- */
.rj-chara.-nanci {
  --c-card: #ffe2ed;
  --c-accent: #d963a8;
  --c-text: #aa8ba2;
  --card-top: 30.58cqw;
  --content-top: 27.9cqw;
}
.-nanci .rj-chara__fig  { top: 0;        left: 2.68cqw;  width: 48.18cqw; }
.-nanci .rj-chara__logo { top: 13.04cqw; left: 51.61cqw; width: 38.3cqw; }
.-nanci .rj-chara__lead { top: 5.15cqw;  left: 52.68cqw; }
.-nanci .rj-chara__card { padding-bottom: 110px; }

/* --- SURI: ロゴ左・フィギュア右 --- */
.rj-chara.-suri {
  --c-card: #ffe2e2;
  --c-accent: #e15656;
  --c-text: #aa8ba2;
  --gap: 42px;
  --card-top: 41.52cqw;
  --content-top: 18.35cqw;
}
.-suri .rj-chara__fig  { top: 0;        left: 54.29cqw; width: 33.9cqw; }
.-suri .rj-chara__logo { top: 28.33cqw; left: 15.67cqw; width: 35.62cqw; }
.-suri .rj-chara__lead { top: 5.26cqw;  left: 28.54cqw; }
.-suri .rj-chara__card { padding-bottom: 94px; }

/* --- Cream & Cookii: フィギュア左・ロゴ右 --- */
.rj-chara.-cream {
  --c-card: #ffe9e2;
  --c-accent: #ad714b;
  --c-text: #ba8e68;
  --gap: 192px;
  --card-top: 29.08cqw;
  --content-top: 17.7cqw;
}
.-cream .rj-chara__fig  { top: 0;        left: -3.65cqw; width: 43.35cqw; }
.-cream .rj-chara__logo { top: 16.74cqw; left: 43.78cqw; width: 48.71cqw; }
.-cream .rj-chara__btn  { margin-top: 36px; }
.-cream .rj-chara__card { padding-bottom: 95px; }

/* --- YOZCO: ロゴ左・フィギュア右 --- */
.rj-chara.-yozco {
  --c-card: #fff3e2;
  --c-accent: #de9c81;
  --c-text: #ae948a;
  --gap: 57px;
  --card-top: 38.3cqw;
  --content-top: 15.88cqw;
}
.-yozco .rj-chara__fig  { top: 0;        left: 59.01cqw; width: 33.9cqw; }
.-yozco .rj-chara__logo { top: 23.61cqw; left: 15.67cqw; width: 43.35cqw; }
.-yozco .rj-chara__card { padding-bottom: 95px; }

/* ==========================================================
   スマホ: フィギュア → ロゴ → カード の縦並び
   ========================================================== */
@media (max-width: 700px) {
  .rj-charas {
    padding: 40px 0 80px;
  }
  .rj-chara {
    --gap: 72px !important;
  }
  .rj-chara .rj-chara__fig,
  .rj-chara .rj-chara__logo {
    position: relative;
    top: auto !important;
    left: auto !important;
  }
  .rj-chara__fig {
    display: block;
    width: 62% !important;
    margin: 0 auto -32px;  /* カードに少し重ねる */
  }
  .post_content .rj-chara .rj-chara__logo {  /* 見出しの余白リセットより優先させる */
    display: block;
    width: 70% !important;
    margin: 0 auto 16px;
  }
  .rj-chara.-cream .rj-chara__logo {
    width: 88% !important;
  }
  /* ロゴをフィギュアより前(上)に出す */
  .rj-chara {
    display: flex;
    flex-direction: column;
  }
  .rj-chara__logo { order: 1; }
  .rj-chara__fig  { order: 2; }
  .rj-chara__card { order: 3; }

  .rj-chara__card {
    margin-top: 0;
    padding: 64px 16px 56px !important;
    border-radius: 48px;
    font-size: 12px;
    line-height: 1.9;
    letter-spacing: 0;
  }
  .rj-chara__lead {
    position: static;
    margin: 0 8px 28px !important;
    text-align: center;
  }
  .rj-chara__cloud.-lg,
  .rj-chara__cloud.-md,
  .rj-chara__cloud.-sm,
  .rj-chara__frame {
    width: 100%;
  }
  .rj-chara__cloud.-lg,
  .rj-chara__cloud.-md {
    padding: 56px 16px;
  }
  .rj-chara__cloud.-sm {
    width: 86%;
    padding: 48px 24px;
  }
  .rj-chara__frame {
    padding: 32px 14px;
  }
  .rj-chara__frame::before { inset: 0 20px; }
  .rj-chara__frame::after  { inset: 22px 0; }
  .post_content .rj-chara__card h3 {
    font-size: 19px;
  }
  .rj-chara__btn {
    height: 56px;
    margin-top: 40px !important;
    font-size: 18px;
  }
}
