@charset "UTF-8";

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

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

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

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

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


/* ===== 2026-09-23 リデザイン（Claude Code）ここから ===== */
#content-in.content-in { display: flex !important; flex-wrap: nowrap !important; gap: 28px; align-items: stretch; }
.content .main { width: auto !important; max-width: none !important; flex: 1 1 0; min-width: 0; margin: 0 !important; float: none !important; }
#sidebar.sidebar { width: 336px !important; flex: 0 0 336px; margin: 0 !important; padding: 0 !important; align-self: stretch; height: auto; }
.no-sidebar .content .main { width: auto !important; max-width: 920px !important; margin: 0 auto !important; }
@media screen and (max-width: 1023px){
  #content-in.content-in { display: block !important; }
  #sidebar.sidebar { width: auto !important; flex: none; margin-top: 28px !important; }
  .content .main { width: 100% !important; }
}
#sidebar .widget_text:first-child { position: sticky; top: 16px; z-index: 2; }
.ksd-course { border-radius: 12px; overflow: hidden; background: #2b1d60; }
.ksd-course__link { display: block; padding: 0 0 18px; color: #fff !important; text-decoration: none !important; }
.ksd-course__eyebrow { display: block; font-size: 10.5px; letter-spacing: .14em; font-weight: 700; color: #d9ccff; background: rgba(255,255,255,.08); padding: 9px 16px; }
.ksd-course__logo { display: block; font-size: 15px; font-weight: 400; letter-spacing: .02em; margin: 16px 16px 0; }
.ksd-course__logo b { font-weight: 900; }
.ksd-course__kf { display: flex; align-items: center; margin: 10px 16px 12px; }
.ksd-course__kf i { width: 9px; height: 9px; background: #a77bff; transform: rotate(45deg); display: block; flex: none; }
.ksd-course__kf s { flex: 1; height: 1px; background: rgba(255,255,255,.35); display: block; text-decoration: none; }
.ksd-course__title { display: block; font-size: 21px; font-weight: 900; line-height: 1.45; margin: 0 16px 8px; }
.ksd-course__list { display: block; font-size: 12.5px; line-height: 1.75; color: #e6defc; margin: 0 16px 14px; }
.ksd-course__btn { display: block; text-align: center; background: #fff; color: #2b1d60 !important; border-radius: 999px; padding: 9px 0; font-weight: 900; font-size: 13.5px; margin: 0 16px; }
.ksd-course__by { display: block; font-size: 10px; color: #b9aee0; text-align: center; margin: 9px 16px 0; }
.ksd-course__link:hover .ksd-course__btn { background: #f0ebff; }
.article .entry-content { font-size: 16px; line-height: 1.95; }
.article .entry-content p { margin: 0 0 1.5em; }
.article h2 { font-size: 22px; line-height: 1.5; }
.article h3 { font-size: 18.5px; line-height: 1.55; }
.entry-title, .article h2, .article h3, .article h4 { font-weight: 700; }
@media screen and (max-width: 834px){
  .article .entry-content { font-size: 16px; line-height: 1.9; }
  .article h2 { font-size: 19px; }
  .article h3 { font-size: 17px; }
}

/* 4. 著者ボックス：記事の上と、記事下の重複を消す（残すのは記事下の1つ） */
.article-header #authorbox { display: none !important; }
.article-footer > #authorbox ~ #authorbox { display: none !important; }
.article-footer > .publisher { display: none; }

/* 5. サイドバーの見出しが白文字で読めない問題 */
#sidebar .widget-sidebar-title, #sidebar .widget-title {
  color: #1d1b1a !important; background: transparent !important;
  border-left: 4px solid #e6205a; padding: 0 0 0 10px !important; margin: 0 0 12px !important;
  font-size: 14px !important; line-height: 1.5; text-align: left !important;
}
#sidebar .widget { margin-bottom: 26px; }

/* 6. スマホ下部の講座バー（1枠だけ） */
#ksd-dock { display: none; }
@media screen and (max-width: 834px){
  #ksd-dock { display: flex; align-items: stretch; position: fixed; left: 0; right: 0; bottom: 52px; z-index: 999;
    background: #2b1d60; color: #fff; box-shadow: 0 -2px 10px rgba(0,0,0,.18); }
  #ksd-dock[hidden] { display: none; }
  .ksd-dock__link { display: flex; align-items: center; gap: 10px; flex: 1; min-width: 0; padding: 8px 10px 8px 14px; color: #fff !important; text-decoration: none !important; }
  .ksd-dock__body { display: block; min-width: 0; }
  .ksd-dock__body b { display: block; font-size: 13px; font-weight: 700; line-height: 1.35; }
  .ksd-dock__body small { display: block; font-size: 10.5px; color: #cdc1f0; line-height: 1.35; }
  .ksd-dock__btn { background: #fff; color: #2b1d60; border-radius: 999px; font-size: 11.5px; font-weight: 900; padding: 6px 12px; white-space: nowrap; margin-left: auto; }
  .ksd-dock__close { background: none; border: 0; color: #cdc1f0; font-size: 18px; line-height: 1; width: 40px; cursor: pointer; }
}

/* 7. Palmie風：ヘッダーを細い1行に、ピックアップのバナーは外す */
/* ピックアップの4バナーは表示（2026-09-23 戻した） */
@media screen and (min-width: 1024px){
  #header-container-in.hlt-center-logo { display: flex !important; align-items: center; gap: 24px; padding: 6px 24px; position: relative; }
  #header-container-in.hlt-center-logo #header { position: absolute; left: 24px; top: 50%; transform: translateY(-50%); }
  #header-container-in.hlt-center-logo #navi { flex: 1 1 100%; }
  #header-container-in.hlt-center-logo #header { flex: 0 0 auto; padding: 0; height: auto; }
  #header-container-in.hlt-center-logo #header-in { padding: 0 !important; width: auto !important; display: flex; align-items: center; min-height: 0; }
  #header-container-in.hlt-center-logo .tagline { display: none !important; }
  #header-container-in.hlt-center-logo .header-site-logo-image { height: 40px !important; width: auto !important; margin: 0 !important; }
  #header-container-in.hlt-center-logo #navi { flex: 1 1 auto; margin: 0; height: auto; }
  #header-container-in.hlt-center-logo #navi-in { padding: 0 !important; width: auto !important; }
  #header-container-in.hlt-center-logo .menu-header { display: flex; justify-content: center; align-items: center; gap: 2px; }
  #header-container-in.hlt-center-logo .menu-header li { height: auto; }
  #header-container-in.hlt-center-logo .menu-header li a { height: auto !important; line-height: 1.4 !important; padding: 7px 12px !important; font-size: 13px; }
  #header-container-in.hlt-center-logo .menu-adanime { margin-left: 10px; }
  #header-container-in.hlt-center-logo .menu-adanime > a { padding: 0 !important; }
  #header-container-in.hlt-center-logo .menu-adanime .caption-wrap { padding: 7px 16px; }
}
/* 8. メニューの講座ボタン（紫）と、PCで重なるアイコンの整理 */
.menu-adanime .caption-wrap { background: #2b1d60; border-radius: 999px; display: inline-flex; align-items: center; transition: background .2s; }
.menu-adanime .item-label { color: #fff !important; font-weight: 700; }
.menu-adanime > a:hover .caption-wrap { background: #6940df; }
@media screen and (min-width: 1024px){
  #header-container .nav_btn, #header-container #search_btn, #header-container #navbtn { display: none !important; }
}
/* 9. 記事カードとランキング（Palmie風） */
.entry-card-wrap { background:#fff; border-radius:10px; overflow:hidden; box-shadow:0 1px 4px rgba(0,0,0,.08); border:0 !important; position:relative; }
.entry-card-wrap .entry-card-thumb { margin:0 !important; }
.entry-card-wrap .entry-card-thumb img { width:100%; aspect-ratio:5/3; object-fit:cover; display:block; }
.entry-card-wrap .entry-card-content { padding:12px 14px 14px; margin-left:0 !important; }
.entry-card-wrap .entry-card-title { font-size:15px; line-height:1.55; font-weight:700; margin:0 0 8px; }
.entry-card-wrap .entry-card-meta { font-size:11px; color:#8a847c; }
.entry-card-wrap .entry-card-snippet { font-size:12.5px; line-height:1.7; color:#6b6560; }
.entry-card-wrap .cat-label { position:absolute; left:8px; top:8px; background:rgba(255,255,255,.94); color:#e6205a; border:0; border-radius:4px; font-size:10.5px; font-weight:700; padding:2px 8px; z-index:2; }
.entry-card-wrap:hover { box-shadow:0 4px 14px rgba(0,0,0,.14); }
.ecb-entry-border .entry-card-wrap { border:0; }

/* サイドバーの「よく読まれている記事」 */
.ksd-rank { list-style:none; margin:0; padding:0; counter-reset:ksdr; }
.ksd-rank li { counter-increment:ksdr; border-top:1px solid #efece7; }
.ksd-rank li:first-child { border-top:0; }
.ksd-rank a { display:grid; grid-template-columns:22px 64px 1fr; gap:9px; align-items:center; padding:9px 0; color:#1d1b1a !important; text-decoration:none !important; }
.ksd-rank a:before { content:counter(ksdr); font-weight:900; color:#e6205a; font-size:14px; text-align:center; }
.ksd-rank img { width:64px; height:44px; object-fit:cover; border-radius:4px; display:block; }
.ksd-rank span { font-size:12px; line-height:1.5; font-weight:700; }
.ksd-rank a:hover span { color:#e6205a !important; }
/* 10. カテゴリのタブ */
.ksd-tabs { display:flex; gap:0; background:#fff; border-radius:8px; overflow:hidden; box-shadow:0 1px 3px rgba(0,0,0,.07); margin:0 0 18px; flex-wrap:nowrap; overflow-x:auto; -webkit-overflow-scrolling:touch; }
.ksd-tabs__item { flex:1 0 auto; text-align:center; font-size:12.5px; font-weight:700; padding:10px 14px; color:#6b6560 !important; text-decoration:none !important; border-right:1px solid #f0ece6; white-space:nowrap; }
.ksd-tabs__item:last-child { border-right:0; }
.ksd-tabs__item:hover { background:#fdf2f5; color:#e6205a !important; }
.ksd-tabs__item.is-current { background:#e6205a; color:#fff !important; }
@media screen and (max-width:834px){ .ksd-tabs { margin:0 0 14px; } .ksd-tabs__item { font-size:12px; padding:9px 12px; flex:0 0 auto; } }
/* ===== 2026-09-23 リデザイン ここまで ===== */


/* 2026-09-24 スマホ下の追従帯をバナー画像（700×100）に（Claude Code） */
@media screen and (max-width: 834px){
  #ksd-dock { background: #fff; padding: 4px; box-shadow: 0 -2px 10px rgba(0,0,0,.18); }
  #ksd-dock .ksd-dock__link { padding: 0; gap: 0; }
  #ksd-dock .ksd-dock__img { display: block; width: 100%; height: auto; border-radius: 6px; }
  #ksd-dock .ksd-dock__close { position: absolute; top: -12px; right: 6px; width: 26px; height: 26px; border-radius: 50%;
    background: #2b1d60; color: #fff; font-size: 14px; line-height: 26px; padding: 0; box-shadow: 0 1px 4px rgba(0,0,0,.25); }
}

/* 11. トップ・一覧のカード：本文を外し、タイトルと画像を大きく（2026-09-24 Claude Code） */
.entry-card-wrap .entry-card-snippet { display: none !important; }
.entry-card-wrap .entry-card-content { padding: 14px 18px 14px; }
.entry-card-wrap .entry-card-title { font-size: 18px; line-height: 1.55; margin: 0 0 10px; }
.entry-card-wrap .byline { display: flex !important; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: nowrap; }
.entry-card-wrap .byline .date-tags { flex: none; margin: 0; }
.entry-card-wrap .byline .author { display: flex !important; align-items: center; gap: 6px; min-width: 0; margin: 0; float: none !important; }
.entry-card-wrap .byline .author .fn { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 12px; }
@media screen and (min-width: 1024px){
  .home #content-in.content-in, .archive #content-in.content-in, .pickup_content { width: min(1360px, calc(100% - 24px)) !important; max-width: none !important; }
  .home .main, .archive .main, .blog .main { padding-left: 24px !important; padding-right: 24px !important; }
  #list.ect-2-columns { display: grid !important; grid-template-columns: 1fr 1fr; gap: 22px; }
  #list.ect-2-columns > .entry-card-wrap { width: auto !important; margin: 0 !important; }
}
@media screen and (max-width: 834px){
  .entry-card-wrap .entry-card-title { font-size: 17px; }
}
@media screen and (min-width: 1024px) and (max-width: 1399px){
  .home #sidebar.sidebar, .archive #sidebar.sidebar { width: 300px !important; flex: 0 0 300px; }
}

/* 12. PCのロゴを本文エリアの左端にそろえる（2026-09-24 Claude Code） */
@media screen and (min-width: 1024px){
  #header-container-in.hlt-center-logo #header { left: max(8px, calc((100% - 1264px) / 2 - 16px)); }
  .home #header-container-in.hlt-center-logo #header,
  .archive #header-container-in.hlt-center-logo #header { left: max(2px, calc((100% - 1360px) / 2 - 10px)); }
}

/* 13. もしも（カエレバ）の商品リンクのカード（2026-10-06 Claude Code・粕田さん指示） */
/* 幅いっぱい・余白を詰める・商品画像を大きく・商品名を太字・飛び出しアイコンと posted with を消す */
.cstmreba .kaerebalink-box{width:100%!important;max-width:100%!important;box-sizing:border-box;display:flex;align-items:flex-start;gap:22px;padding:18px 22px!important;border:1px solid #ddd!important;border-radius:10px;margin:1.6em 0!important;background:#fff}
.cstmreba .kaerebalink-image{flex:0 0 160px;margin:0!important;text-align:center}
.cstmreba .kaerebalink-image a{display:block;line-height:0}
.cstmreba .kaerebalink-image img:not([width="1"]){width:160px!important;height:auto!important;max-height:none!important;box-shadow:0 2px 8px rgba(0,0,0,.12)}
.cstmreba img[width="1"]{position:absolute!important;width:1px!important;height:1px!important;opacity:0}
.cstmreba .kaerebalink-info{flex:1;min-width:0;display:flex;flex-direction:column;gap:8px;padding-top:6px}
.cstmreba .kaerebalink-info p{margin:0!important}
.cstmreba .kaerebalink-info p:empty,.cstmreba .kaerebalink-info br,.cstmreba .booklink-footer,.cstmreba .kaerebalink-powered-date{display:none!important}
.cstmreba .kaerebalink-name a{font-weight:700;font-size:18px;line-height:1.5;color:#2B1D60!important;text-decoration:none!important}
.cstmreba .kaerebalink-name a:hover{text-decoration:underline!important}
.cstmreba .kaerebalink-detail{font-size:13px;color:#666}
.cstmreba a::after{display:none!important;content:none!important}
/* ボタン：Amazon・楽天をカードの右端まで横並びで大きく（2026-10-06 粕田さん） */
.cstmreba .kaerebalink-info{align-self:stretch}
.cstmreba .kaerebalink-link1{display:flex!important;gap:12px;flex-wrap:nowrap;margin-top:auto!important;width:100%}
.cstmreba .kaerebalink-link1>div{flex:1 1 0;margin:0!important;padding:0!important;min-width:0}
.cstmreba .kaerebalink-link1>div>a{display:flex!important;align-items:center;justify-content:center;width:100%!important;box-sizing:border-box;min-height:54px;padding:12px 10px!important;font-size:17px!important;font-weight:700!important;letter-spacing:.04em;border-radius:8px!important;box-shadow:0 3px 0 rgba(0,0,0,.18);text-decoration:none!important;transition:transform .1s,box-shadow .1s}
.cstmreba .kaerebalink-link1>div>a:hover{transform:translateY(1px);box-shadow:0 2px 0 rgba(0,0,0,.18)}
@media (max-width:600px){
  .cstmreba .kaerebalink-box{gap:14px;padding:14px!important}
  .cstmreba .kaerebalink-image{flex-basis:110px}
  .cstmreba .kaerebalink-image img:not([width="1"]){width:110px!important}
  .cstmreba .kaerebalink-name a{font-size:16px}
  .cstmreba .kaerebalink-link1{flex-direction:column;gap:10px}
  .cstmreba .kaerebalink-link1>div>a{min-height:48px;font-size:16px!important}
}

/* 14. 記事下の並びを整理（2026-10-06 Claude Code・粕田さん指示） */
/* 編集部より（文字＋講座バナー）→ 関連記事4本 → この記事を書いた人。FOLLOW・コメント欄・前後の記事・著者の新着は出さない */
.single .article-footer{display:flex;flex-direction:column}
.single .article-footer #text-35{order:1}
.single .article-footer #related-box{order:2}
.single .article-footer #authorbox{order:3;margin-top:12px}
.single .article-footer .fb-likebtn,.single #comment-area,.single #respond,.single #pager-post-navi,.single #author-newpost{display:none!important}
.single #related-box .related-h .gf{font-size:0}
.single #related-box .related-h .gf::before{content:"関連記事";font-size:22px}
.single #related-box .related-h::after{content:"あわせて読みたい"!important}
.single #related-box li:nth-child(n+5){display:none!important}
.ksd-cta{border:2px solid #2B1D60;border-radius:12px;padding:22px 24px;margin:28px 0 8px;background:#fbfaff}
.ksd-cta__lbl{display:inline-block;font-size:12px;font-weight:700;color:#fff;background:#2B1D60;border-radius:99px;padding:3px 12px;margin:0 0 10px}
.ksd-cta__ttl{margin:0 0 8px!important;font-size:21px;font-weight:700;line-height:1.5;color:#2B1D60}
.ksd-cta__txt{margin:0 0 16px!important;line-height:1.8;font-size:15px}
.ksd-cta__bnr{display:block;max-width:560px;margin:0 auto}
.ksd-cta__bnr img{display:block;width:100%;height:auto;border-radius:8px}
.ksd-cta__bnr::after{display:none!important;content:none!important}
.ksd-cta__note{margin:12px 0 0!important;font-size:12px;color:#777;text-align:center}
@media (max-width:600px){.ksd-cta{padding:18px 16px}.ksd-cta__ttl{font-size:19px}}

/* 15. サイドバー：上は回遊（人気記事・カテゴリー）、追従は一番下の講座バナー＋スポンサーリンクだけ（2026-10-06 Claude Code・粕田さん指示） */
/* 人気記事＝text-30（先頭）、講座バナー＋広告＝text-27（#sidebar-scroll の中）。新着記事は出さない */
#sidebar .widget_text:first-child{position:static!important}
#sidebar #sidebar-scroll{position:sticky!important;top:16px!important}
#sidebar-scroll #text-27{position:static!important;margin:0!important}
#newentryimagewidget-10,#sidebar #text-29{display:none!important}
#categories-6 ul{display:flex;flex-wrap:wrap;gap:6px;padding:0!important;margin:0!important}
#categories-6 li{list-style:none;margin:0!important;border:0!important}
#categories-6 li a{display:inline-flex!important;align-items:center;gap:4px;padding:5px 12px!important;border:1px solid #ddd;border-radius:99px;font-size:12.5px!important;line-height:1.4;background:#fff}
#categories-6 li a:hover{border-color:#E52054;color:#E52054!important}
#categories-6 li a .post-count{font-size:11px;color:#999}
#categories-6 li a::before,#categories-6 li a::after{display:none!important;content:none!important}
