@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
*/

/************************************
** 子テーマ用スタイル
************************************/

/* ===== プロフィール文 見せ分け ===== */
.author-description p {
  display: none;
}

/* サイドバーのプロフィールウィジェット：1段落目（30字） */
#sidebar .widget_author_box .author-description p:nth-of-type(1) {
  display: block;
}

/* トップページ・記事一覧：2段落目（60字） */
.home .widget_author_box .author-description p:nth-of-type(2),
.archive .widget_author_box .author-description p:nth-of-type(2) {
  display: block;
}

/* 記事下（コメント上）：3段落目以降（全文） */
.above-single-comment-aria .author-description p {
  display: block;
}

/* ===== CTAボタンサイズ修正 ===== */
.wp-block-button.float-btn a {
  padding: 16px 28px !important;
  font-size: 16px !important;
  border-radius: 28px !important;
  line-height: 1.2 !important;
}

/* ===== 浮くカード ===== */
.float-card {
  background: #fff;
  border-radius: 16px;
  padding: 28px 24px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.08);
  transition: all .3s ease;
}

.float-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 22px 45px rgba(0,0,0,0.14);
}

/* ===== 浮くボタン ===== */
.float-btn a {
  box-shadow: 0 6px 16px rgba(0,0,0,0.15);
  transition: all .25s ease;
}

.float-btn a:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 24px rgba(0,0,0,0.2);
}

/* ===== CTAボタン（整理版） ===== */
/* 右CTA 通常 */
.hasshin-right .wp-block-button__link {
  background-color: #E5484D !important;
  color: #ffffff !important;
  border: none !important;
}

/* 右CTA hover */
.hasshin-right .wp-block-button__link:hover {
  background-color: #CC3A3F !important;
  color: #ffffff !important;
  border: none !important;
}

/* 左CTA 通常 */
.hasshin-left .wp-block-button__link {
  background-color: #3B82F6 !important;
  color: #ffffff !important;
  border: none !important;
}

/* 左CTA hover */
.hasshin-left .wp-block-button__link:hover {
  background-color: #2563EB !important;
}

/* 共通ボタン設定 */
.wp-block-button__link {
  padding: 15px 30px !important;
  font-size: 16px !important;
  font-weight: 700;
  transition: all .25s ease;
}

.wp-block-button__link:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.15);
  opacity: .9;
}

/* ===== 共通ホバーアニメーション ===== */
.hover-card {
  transition: all .35s ease;
}

.hover-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 30px rgba(0,0,0,0.12);
}

/* ===== 画像リンクホバー（ズーム） ===== */
.hover-img {
  overflow: hidden;
  border-radius: 12px;
}

.hover-img img {
  transition: transform .4s ease;
}

.hover-img:hover img {
  transform: scale(1.06);
}

/* ===== 3ステップカード ===== */
.step-card {
  background: #fff;
  border-radius: 18px;
  padding: 28px 22px;
  transition: all .35s ease;
  border: 1px solid #eee;
}

.step-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 18px 40px rgba(0,0,0,0.10);
  border-color: transparent;
}

/* ===== 共通リンクホバー ===== */
a:hover img {
  opacity: .95;
}

/* ===== スムーススクロール ===== */
html {
  scroll-behavior: smooth;
}

:target {
  scroll-margin-top: 120px;
}

/* ===== サイドバーCTAホバー ===== */
.sidebar a img {
  transition: all 0.3s ease;
}

.sidebar a:hover img {
  transform: translateY(-4px);
  box-shadow: 0 8px 18px rgba(0,0,0,0.2);
}

/* ===== CTA共通ホバー（記事下・他CTA全部） ===== */
.cta-btn img {
  transition: all 0.3s ease;
}

.cta-btn:hover img {
  transform: translateY(-4px);
  box-shadow: 0 10px 22px rgba(0,0,0,0.25);
  opacity: 0.9;
}

/* ===== 目次（TOC） ===== */
.toc-title {
  font-size: 0.85em;
}

.toc {
  margin-left: auto;
  margin-right: auto;
}

@media screen and (min-width: 1024px) {
  .toc {
    max-width: 600px;
    margin: 1.5em auto;
  }
}

@media screen and (max-width: 1023px) {
  .toc {
    max-width: 100%;
    margin: 1em 0;
  }
}

/* ===== 書籍専用CTA ===== */
.entry-content a.book-cta-btn {
  display: block;
  width: 100%;
  max-width: 480px;
  margin: 24px auto;
  padding: 14px 20px;
  background-color: #FF9900;
  color: #ffffff;
  text-align: center;
  font-weight: 700;
  font-size: 16px;
  line-height: 1.4;
  border-radius: 10px;
  text-decoration: none;
  box-shadow: 0 4px 8px rgba(0,0,0,0.08);
  transition: all 0.25s ease;
}

.entry-content a.book-cta-btn:hover {
  background-color: #E68A00;
  transform: translateY(-2px);
}

/* ===== 書籍カード ===== */
.book-card {
  border: 1px solid #e5e5e5;
  border-radius: 14px;
  padding: 24px;
  margin-bottom: 40px;
  background: #ffffff;
  transition: 0.3s ease;
}

.book-card:hover {
  box-shadow: 0 10px 25px rgba(0,0,0,0.08);
  transform: translateY(-4px);
}

.book-card h2 {
  margin-top: 0;
}

/* ===== トップ3カード ===== */
.top3-wrap {
  display: flex;
  gap: 24px;
  margin: 40px 0;
}

.top3-card {
  flex: 1;
  border: 1px solid #e5e5e5;
  border-radius: 16px;
  padding: 20px;
  background: #fff;
  text-align: center;
  transition: 0.3s ease;
}

.top3-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 25px rgba(0,0,0,0.08);
}

.top3-card img {
  width: 100%;
  max-width: 220px;
  height: auto;
  margin-bottom: 16px;
}

@media screen and (max-width: 768px) {
  .top3-wrap {
    flex-direction: column;
  }

  .top3-card {
    padding: 18px;
    margin-bottom: 24px;
  }

  .top3-card img {
    max-width: 70%;
    margin: 0 auto 14px;
    display: block;
  }

  .top3-card h3 {
    font-size: 1.05rem;
    line-height: 1.4;
    margin-bottom: 10px;
  }

  .top3-card p {
    font-size: 0.95rem;
    margin-bottom: 14px;
  }

  .top3-card a {
    display: block;
    width: 100%;
    padding: 12px;
    font-size: 0.95rem;
  }
}

/* ===== 今回追加したカード・ボタンCSS ===== */
/* 書籍カード内部 */
.book-card-inner {
  padding: 20px;
  border-radius: 14px;
  background: #fff;
  transition: all .3s ease;
}

.book-card-inner:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 25px rgba(0,0,0,0.08);
}

/* 書籍画像 */
.book-image {
  width: 100%;
  height: auto;
  border-radius: 12px;
  margin-bottom: 16px;
}

/* レビュー記事ボタン */
.review-btn .wp-block-button__link {
  display: inline-block;
  background: #2c5aa0;
  color: #ffffff;
  padding: 12px 22px;
  border-radius: 30px;
  text-decoration: none;
  font-weight: 600;
  transition: all 0.3s ease;
  box-shadow: 0 4px 10px rgba(0,0,0,0.08);
}

.review-btn .wp-block-button__link:hover {
  background: #1f3f75;
  transform: translateY(-3px);
  box-shadow: 0 8px 18px rgba(0,0,0,0.15);
}

/* Amazonボタン */
.amazon-btn .wp-block-button__link {
  background-color: #FF9900 !important;
  color: #ffffff !important;
  padding: 14px 22px !important;
  border-radius: 28px !important;
  font-weight: 700 !important;
  transition: all 0.3s ease !important;
}

.amazon-btn .wp-block-button__link:hover {
  background-color: #E68A00 !important;
  transform: translateY(-2px) !important;
}
/* 書籍カード全体 */
.book-card {
  border: 1px solid #eee;
  padding: 20px;
  margin-bottom: 28px;
  border-radius: 10px;
  text-align: center;
  background: #fff;
  transition: all 0.3s ease;
}

.book-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 25px rgba(0,0,0,0.08);
}

.book-card img {
  max-width: 220px;
  margin-bottom: 12px;
}

/* ボタン横並び */
.book-card-buttons {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

/* レビューボタン */
.review-btn {
  background: #2c7be5;
  color: #fff;
  padding: 10px 16px;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 700;
  transition: all 0.25s ease;
}

.review-btn:hover {
  background: #1f5abf;
  transform: translateY(-2px);
}

/* Amazonボタン */
.amazon-btn {
  background: #ff9900;
  color: #fff;
  padding: 10px 16px;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 700;
  transition: all 0.25s ease;
}

.amazon-btn:hover {
  background: #e68a00;
  transform: translateY(-2px);
}

/* ===== Accordion（アニメーション＋FAQ型対応）===== */

.accordion-btn {
  display: block;
  width: 100%;
  max-width: 420px;
  margin: 0 auto 12px;
  padding: 12px 16px;
  font-weight: 700;
  text-align: center;
  background: #2c7be5;
  color: #fff;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
}

.accordion-btn:hover {
  background: #1f5abf;
}

/* ＋アイコン */
.accordion-btn::after {
  content: "＋";
  position: absolute;
  right: 16px;
  font-size: 18px;
  transition: transform 0.3s ease;
}

/* 開いている時（−に変更） */
.accordion-btn.active::after {
  content: "−";
}

/* コンテンツ */
.accordion-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease;
  margin-bottom: 16px;
}

/* ===== 書籍カード（信頼感重視）===== */

.book-card {
  border: 1px solid #e5e7eb;
  padding: 24px;
  margin-bottom: 32px;
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

.book-card h3 {
  text-align: left;
  font-size: 18px;
  margin-bottom: 8px;
  color: #222;
}

.book-card p {
  text-align: left;
  color: #555;
  line-height: 1.6;
  margin-bottom: 16px;
}
/* ===== 折りたたみ全体（カード風）===== */
.accordion-wrapper {
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  padding: 24px;
  margin: 40px 0;
  background: #f9fafb;
}

/* ボタン */
.accordion-btn {
  width: 100%;
  padding: 14px;
  font-weight: 600;
  background: #374151;  /* ダークグレー */
  color: #fff;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  position: relative;
  transition: background 0.3s ease;
}

.accordion-btn:hover {
  background: #1f2937;
}

/* ＋ − */
.accordion-btn::after {
  content: "＋";
  position: absolute;
  right: 16px;
}

.accordion-btn.active::after {
  content: "−";
}

/* 中身 */
.accordion-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease;
}
/* ===== ボタン共通設定 ===== */
.review-btn,
.amazon-btn {
  display: inline-block;
  padding: 10px 18px;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 600;
  transition: all 0.25s ease;
}

/* ===== レビュー（信頼感ネイビー）===== */
.review-btn {
  background: #1e3a8a;
  color: #fff;
}

.review-btn:hover {
  background: #162d66;
  transform: translateY(-2px);
  box-shadow: 0 6px 14px rgba(0,0,0,0.15);
}

/* ===== Amazon（購入オレンジ）===== */
.amazon-btn {
  background: #f59e0b;
  color: #fff;
}

.amazon-btn:hover {
  background: #d97706;
  transform: translateY(-2px);
  box-shadow: 0 6px 14px rgba(0,0,0,0.15);
}
.book-card .review-btn {
  margin-right: 8px;
}
/* アコーディオン全体をカード風に */
.accordion-wrapper {
  border: 1px solid #eee;
  border-radius: 10px;
  padding: 20px;
  margin: 30px 0;
  background: #fafafa;
  box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

.accordion-content .book-card {
  background: #ffffff;
}
.book-points {
  text-align: left;
  padding-left: 20px;
  margin-bottom: 16px;
  color: #555;
}

.book-points li {
  margin-bottom: 6px;
}
.book-card hr {
  border: none;
  border-top: 1px solid #e5e7eb;
  margin: 20px 0;
}

