@charset "UTF-8";

/*!
Theme Name: Cocoon Child
Description: Cocoon専用の子テーマ
Theme URI: https://wp-cocoon.com/
Author: わいひら
Author URI: https://nelog.jp/
Template:   cocoon-master
Version:    1.1.3
*/

/************************************
** 子テーマ用のスタイルを書く
************************************/
/*必要ならばここにコードを書く*/

/* --------------------------------
カラーパレット（変数定義）
----------------------------------- */
:root {
  --main-blue: #3B6BB3;
  --sub-yellow: #F9CA24;
  --base-gray: #FAFAFA;
  --base-green: #F5FAF8;
  --text-gray: #2B2B2B;
  --line-gray: #E1E3E9;
  --line-green: #3AA785;
  --point-red: #E57373;
  --point-orange: #D86C00;
  --point-blue: #06A6C6;
  --bg-blue: #D2E3F5;
}
/* --------------------------------
サイト基礎フォント
----------------------------------- */
body {
  font-family: 'Noto Sans JP', sans-serif;
  color: var(--text-gray);
  background-color: var(--base-gray);
  line-height: 1.8;
}
h1, h2, h3, .logo {
  font-family: 'Zen Maru Gothic', 'Noto Sans JP', sans-serif;
}
strong, em {
  color: var(--point-orange);
  font-weight: 600;
  background: linear-gradient(transparent 60%, rgba(247, 183, 39, 0.25) 60%);
}

.bold-red {font-weight: bold; color: var(--cocoon-red-color);}
.bold-blue {font-weight: bold; color: var(--cocoon-blue-color);}

/* --------------------------------
リンク・ボタン
----------------------------------- */
.entry-content a {
  color: var(--main-blue);
  text-decoration: none;
  transition: 0.3s;
}
.entry-content a:hover {
  color: var(--point-blue);
}

button, .btn {
  background-color: var(--main-blue);
  color: #fff;
  padding: 0.5em 1em;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  transition: 0.3s;
}
button:hover, .btn:hover {
  transform: scale(1.02);
}

/* --------------------------------
見出しデザイン（H2帯付き）
----------------------------------- */
.entry-content h2 {
/*  border-left: 6px solid var(--main-blue);
  padding-left: 10px;
  font-size: 1.4em;
  margin-top: 2em;
  margin-bottom: 1em;
  background-color: #F2F5FA;
*/

  background-image: linear-gradient(45deg, #6BE0E6 0%, #6BE0E6 55%, #E1F9FA 85% ,#2DD3FF 90% , #2DD3FF 100%);
  border: 3px solid #404040;
  color: #404040;
  font-weight: bold;
  position: relative;
  padding: 1em 0.5em;
  text-align: center;
  width: 98%;
  text-shadow: 1px 1px 0 #fff;

}

.entry-content h2::before,.entry-content h2::after {
  background: #404040;
  border: 3px solid #404040;
  content: '';
  position: absolute;
}
.entry-content h2::before {
  top: 4px;
  right: -17px;
  width: 8px;
  height: 100%;
  transform: skewY(45deg);
}
.entry-content h2::after {
  bottom: -17px;
  left: 4px;
  width: 100%;
  height: 8px;
  transform: skewX(45deg);
}

.entry-content h3 {
  font-size:1.2em;
  padding: 1.5em 1em;
  border-left: 1px solid var(--cocoon-thin-color);
  background-image:
  linear-gradient(#fff 0 100%),
  repeating-linear-gradient(135deg, #06A6C6 0 5px, transparent 5px 10px);
  background-repeat: no-repeat;
  background-position: center;
  background-size: calc(100% - 10px) calc(100% - 10px), 100%;
}

/* --------------------------------
H4問題の連番表示
----------------------------------- */
/* 1. H3が出てくるたびに「mondai」という名前のカウントを0にリセット */
h3 { counter-reset: mondai; }
/* 2. H4が出てくるたびに「mondai」を1ずつ増やす */
h4 { counter-increment: mondai; }
/* 3. H4の前に「問題 + 数字」を表示する */
h4::before {
  content: counter(mondai);
  color: #999;
  margin-right: 10px;
}

/* --------------------------------
チャット表示
----------------------------------- */
.chat-block {
  display: flex;
  align-items: flex-start;
  margin: 12px 0;
}
.chat-left, .chat-right {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 80px;
}
.chat-right { order: 2; }
.chat-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  margin-bottom: 4px;
}
.chat-name {
  font-weight: bold;
  font-size: 0.75em;
  color: #555;
}
.bubble-left, .bubble-right, .bubble-system {
  padding: 10px 14px;
  border-radius: 16px;
  line-height: 1.6;
  max-width: 75%;
}
.bubble-left {
  background: #ffffff;
  margin-left: 8px;
  border: solid 1px var(--line-gray);
}
.bubble-right {
  background: #FFF5DA;
  margin-left: auto;
  margin-right: 8px;
}
/* ナレーション用（中央） */
.bubble-system {
  background: var(--base-green);
  border: solid 1px var(--line-green);
  color: #2B2B2B;
  text-align: center;
  margin: 16px auto;
  padding: 14px 20px;
  border-radius: 12px;
  font-style: italic;
  width: fit-content;
  max-width: 90%;
  box-shadow: 0 1px 4px rgba(58,167,133,0.15);
}
.chat-system {
  display: none;
}

/* --------------------------------
クイズカード（最適化＋アニメ対応）
----------------------------------- */
.quiz-card {
  background: #fff;
  border-radius: 1rem;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  transition: transform 0.2s ease;
  will-change: transform;
}
.quiz-question {
  font-weight: bold;
  margin-bottom: 0.8rem;
}
.quiz-choices {
  list-style: none;
  padding-left: 0;
  margin-bottom: 0.8rem;
}
.quiz-choice {
  padding: 0.4rem 0.6rem;
  background: #f8f8f8;
  margin-bottom: 0.4rem;
  border-radius: 6px;
  transition: background 0.3s;
}
.quiz-answer-btn {
  margin-top: 0.8rem;
  background: #F9CA24;
  color: #2B2B2B;
  padding: 0.5rem 1rem;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-weight: bold;
  transition: background 0.2s;
}
.quiz-answer-btn:hover {
  background: #ffdc5c;
}

/* ▼ アニメ付き答え・解説ボックス ▼ */
.quiz-answer-box {
  overflow: hidden;
  max-height: 0;
  opacity: 0;
  transform: translateY(-5px);
  transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
  background: #FFFBE6;
  border-radius: 8px;
  padding: 0 0.8rem;
  margin-top: 0;
}
.quiz-answer-box.show {
  max-height: 200px; /* 最大高さ（可変） */
  opacity: 1;
  transform: translateY(0);
  margin-top: 1rem;
  padding: 0.8rem;
}
.quiz-answer {
  color: var(--main-blue);
  font-weight: normal;
  margin-bottom: 0.5rem;
}
.quiz-answer strong {
  color: var(--text-gray);
  font-weight: bold;
  margin-bottom: 0.5rem;
}
.quiz-tips {
  font-size: 0.95rem;
  color: #444;
  background: #fff;
  border-left: 4px solid #F9CA24;
  padding: 0.5rem 0.8rem;
  border-radius: 4px;
}

/* --------------------------------
TipsBox（[tips_box]）
----------------------------------- */
.tips-box {
  background-color: #FFF5E1;
  border-left: 5px solid var(--sub-yellow);
  border-radius: 12px;
  padding: 1em;
  display: flex;
  align-items: center; 
  margin: 1.5em 0;
}
.tips-icon {
  font-size: 1.5em;
  margin-right: 0.5em;
  line-height: 1;
}
.tips-content {
  flex: 1;
}

/* --------------------------------
Tag List（タグ表示）
----------------------------------- */
.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}
.tag-item {
  background: #f2f2f2;
  border-radius: 20px;
  padding: 0.4rem 0.9rem;
  font-size: 0.9rem;
  color: #333;
}

/* --------------------------------
FooterQuote（[footer_quote]）
----------------------------------- */
.footer-quote {
  text-align: center;
  padding: 2em 0;
  font-family: 'Zen Maru Gothic', sans-serif;
  color: #555;
  opacity: 0.9;
}
.footer-quote p::before,
.footer-quote p::after {
  content: "“";
  color: var(--main-blue);
}
.footer-quote p::after {
  content: "”";
}

/* --------------------------------
アニメーション・トランジション
----------------------------------- */
.fade-in {
  animation: fadeIn 0.5s ease-out;
}


/* --------------------------------
記事カード（Cocoon標準構造リデザイン）
----------------------------------- */
.entry-card-thumb img {
  width: 100%;
  height: auto;
  border-bottom: 3px solid var(--main-blue);
}
.entry-card {
  position: relative;
  border-radius: 16px;
  padding: 10px;
  box-shadow: 0 0 0 3px rgba(59,107,179,0.15);

}
.entry-card-title,
.entry-card-snippet {
  letter-spacing: 0.02em;
}
.entry-card-snippet {
  line-height: 1.7;
}









/* --------------------------------
監修・執筆者情報（画像付き）
----------------------------------- */
/* 監修用の見出し */
.widget_author_box .widget-title {
  padding-left: 10px;
  font-size: 1.4em;
  margin-top: 2em;
  margin-bottom: 0;
  background-color: #F2F5FA;
  border-left: 4px solid var(--point-blue);
}

.author-box {
  background: #fafafa;
  border: 1px solid #e0e0e0;
  border-radius: 16px;
  padding: 24px;
  margin-top: 20px;
  line-height: 1.8;
  font-family: 'Noto Sans JP', sans-serif;
}

/* --------------------------------
アフィリエイト管理のショートコードで表示したPRの装飾
----------------------------------- */
.ad_area_title {
  padding-left: 10px;
  font-size: 1.4em;
  margin-top: 2em;
  margin-bottom: 1em;
  background-color: #F2F5FA;
  border-left: 4px solid var(--point-blue);
}

/* --------------------------------
ウィジェットで表示したブログカードの装飾
----------------------------------- */
.pickup_blogcard_title {
  padding-left: 10px;
  font-size: 1.4em;
  margin-top: 2em;
  margin-bottom: 1em;
  background-color: #F2F5FA;
  border-left: 4px solid var(--point-blue);
}
.widget_custom_html a.blogcard-wrap.internal-blogcard-wrap.a-wrap {
  display: block;
  position: relative;
  padding: 18px 20px;
  border-radius: 18px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.18);
  text-decoration: none !important;
  color: inherit;
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.25);
}
.widget_custom_html .textwidget.custom-html-widget > a.blogcard-wrap.internal-blogcard-wrap.a-wrap:nth-of-type(1) {
  background: linear-gradient(135deg, #6BE0E6 0%, #e9e9ff 60%, #6BE0E6 100%);
}
.widget_custom_html .textwidget.custom-html-widget > a.blogcard-wrap.internal-blogcard-wrap.a-wrap:nth-of-type(2) {
  background: linear-gradient(135deg, #FF9AA2 0%, #FFF4C2 60%, #FF9AA2 100%);
}
.widget_custom_html a.blogcard-wrap.internal-blogcard-wrap.a-wrap:hover {
  transform: translateY(-2px);
  box-shadow: none;
}
.widget_custom_html .blogcard.internal-blogcard {
  background: transparent;
  border: solid 3px #f1f1f1;
}
.widget_custom_html .internal-blogcard-footer{
  display: none;
}
.widget_custom_html .blogcard-snippet{
  display: none;
}
.widget_custom_html .blogcard-title{
  text-align: left;
  line-height: 1.7;
}
.widget_custom_html .internal-blogcard {
  text-align: right;
}
.widget_custom_html .internal-blogcard::after{
  content: '見てみる \00bb';
  display: inline-block;
  padding: 6px 12px;
  margin-left: 8px;
  color: #fff;
  font-size: 0.8rem;
  border-radius: 999px;
  vertical-align: middle;
  white-space: nowrap;
  background: linear-gradient(135deg, #ff6a88, #ffb56b);
}
.widget_custom_html .textwidget.custom-html-widget
  > a.blogcard-wrap.internal-blogcard-wrap.a-wrap:nth-of-type(1)
  .blogcard-title.internal-blogcard-title::before {
  content: "🔥 人気";
  display: inline-block;
  margin-right: 8px;
  padding: 2px 8px;
  background: #ffefef;
  color: #e60033;
  border-radius: 6px;
  font-size: 0.7rem;
}
.widget_custom_html .textwidget.custom-html-widget
  > a.blogcard-wrap.internal-blogcard-wrap.a-wrap:nth-of-type(2)
  .blogcard-title.internal-blogcard-title::before {
  content: "✨ 話題";
  display: inline-block;
  margin-right: 8px;
  padding: 2px 8px;
  background: #eef7ff;
  color: #0066cc;
  border-radius: 6px;
  font-size: 0.7rem;
}


/* =============================
   【固定ページ】カテゴリ一覧
   ============================= */
/* カテゴリ一覧をカード型タイルにする */
.q_category-tiles {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, 1fr); /* PCは2列固定 */
  gap: 1.2rem;
}
/* 各カード */
.q_category-card {
  background: #fff;
  border: 1px solid #e3e3e3;
  border-radius: 10px;
  padding: 16px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.q_category-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}
/* カテゴリ名 */
.q_category-card .q_category-title {
  display: block;
  font-size: 1.1rem;
  margin-bottom: 8px;
  color: #333;
}
/* 説明文 */
.q_category-card .q_category-desc {
  font-size: 0.85rem;
  color: #666;
  margin: 0 0 10px;
  line-height: 1.5;
}
/* 投稿数 */
.q_category-card .q_category-count {
  font-size: 0.8rem;
  color: #999;
}
/* 雑学（ID:7） */
.q_category-card.cat-7 {
  background: #FFF4C2;  /* イエロー */
}
/* 脳トレ（ID:6） */
.q_category-card.cat-6 {
  background: #DFF2FF;  /* ブルー */
}
/* なぞなぞ（ID:5） */
.q_category-card.cat-5 {
  background: #E4FFE4;  /* グリーン */
}
/* 謎解き（ID:10） */
.q_category-card.cat-10 {
  background: #F0E5FF;  /* パープル */
}
/* 難問（ID:9） */
.q_category-card.cat-9 {
  background: #FFE1E1;  /* レッド */
}
/* 子ども（ID:8） */
.q_category-card.cat-8 {
  background: #FFD89A; /* オレンジ */
}
/* コラム（ID:11） */
.q_category-card.cat-11 {
  background: #f3f3f3; /* 灰色 */
}

/* カードの境界色を少し薄めに */
.q_category-card.cat-5,
.q_category-card.cat-6,
.q_category-card.cat-7,
.q_category-card.cat-8,
.q_category-card.cat-9,
.q_category-card.cat-10,
.q_category-card.cat-11 {
  border-color: rgba(0,0,0,0.03);
}


/* スマホ（幅600px以下）は1列にする */
@media (max-width: 600px) {
  .q_category-tiles {
    grid-template-columns: 1fr; /* スマホは1列 */
  }
}


/* =============================
   アプリ紹介パーツ
   ============================= */
.q_appcard {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 16px;
  border: 1px solid #ddd;
  border-radius: 12px;
  background: #fafafa;
  max-width: 520px;
  margin: 20px 0;
}
.q_appcard__icon { /* アイコン画像 */
  width: 80px;
  height: 80px;
  border-radius: 16px;
  object-fit: cover;
  flex-shrink: 0;
}
.q_appcard__icontext { /* 頭文字アイコン風 */
  width: 80px;
  height: 80px;
  border-radius: 16px;
  background: linear-gradient(135deg, #f5b8ff, #8fb6ff);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  font-weight: 700;
  flex-shrink: 0;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}
.q_appcard__body {
  flex-grow: 1;
}
.q_appcard__name {
  font-size: 17px;
  font-weight: normal;
  margin: 0 0 5px 0;
}
.q_appcard__links {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}
.q_appcard__links a {
  color: #fff;
}
.q_appcard__button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  color: #fff;
  text-decoration: none;
  white-space: nowrap;
  width:140px;
	border-right: 2px solid #0686b1;
	border-bottom: 2px solid #0686b1;
  background-image: linear-gradient(132deg, rgba(85, 85, 85, 1) 31%, rgba(0, 0, 0, 1));
}
.q_appcard__button--apple::before {
  content: "●";
  color: #fff;
  font-weight: bold;
  display: inline-block;
}
.q_appcard__button--google::before {
  content: "";
  width: 0;
  height: 0;
  border-left: 14px solid #00BEC3;
  border-top: 10px solid transparent;
  border-bottom: 10px solid transparent;
}

/* スマホ対応 */
@media (max-width: 480px) {
  .q_appcard__button {
    gap: 6px;
    width:130px;
  }
}
@media (max-width: 414px) {
  .q_appcard__button {
    gap: 6px;
    font-size: 13px;
    width:115px;
  }
  .q_appcard__icon {
    margin-top: 5px;
    width: 70px;
    height: 70px;
  }
  .q_appcard__icontext {
    margin-top: 5px;
    width: 70px;
    height: 70px;
  }
}
@media (max-width: 413px) {
  .q_appcard__button {
    gap: 6px;
    font-size: 13px;
    width: 100%;
  }
  .q_appcard__icon {
    margin-top: 35px;
    width: 80px;
    height: 80px;
  }
  .q_appcard__icontext {
    margin-top: 35px;
    width: 80px;
    height: 80px;
  }
}




/************************************
** レスポンシブデザイン用のメディアクエリ
************************************/
/*1023px以下*/
@media screen and (max-width: 1023px){
  /*必要ならばここにコードを書く*/
}

/*834px以下*/
@media screen and (max-width: 834px){
  /*必要ならばここにコードを書く*/
}

/*480px以下*/
@media screen and (max-width: 480px){
  /*必要ならばここにコードを書く*/
}
