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

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

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

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

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


/************************************
** プロフィール-サイドバー
************************************/
.sidebar .widget_author_box {
  background: #fff;
  padding-top: 1.2em;
  border-radius: 3px 3px 0 0;
  max-width: 360px;
  margin: 0 auto;
  box-shadow: 0 2px 4px rgba(0, 0, 0, .2);
}
.sidebar .author-box {
  padding: 120px 0 0;
  border: none;
  position: relative;
  margin: 0 0 3em;
  max-width: 100%;
  overflow:hidden;
}
.sidebar .author-content {
  background: -webkit-linear-gradient(0deg, rgba(28, 189, 255, 1) 0%, rgba(55, 219, 255, 1) 51.39%, rgba(70, 205, 255, 1) 100%);
  background: linear-gradient(90deg, rgba(28, 189, 255, 1) 0%, rgba(55, 219, 255, 1) 51.39%, rgba(70, 205, 255, 1) 100%);
  border-radius: 200px 200px 0px 0px / 100px 100px 0px 0px;
  color: #fff;
  padding: 20px;
  width:110%;
  margin-left:-5% !important;
}
.sidebar .author-box .author-name a {
  color: #42ace7;
  text-decoration: none;
  letter-spacing: 1px;
  font-size: 18px;
}
.sidebar .author-box .author-description {
  padding: 45px 25px 0px;
  text-align: justify;
  text-justify: inter-ideograph;
}
.sidebar .author-box p {
  line-height: 1.8;
  font-size: 14px;
}
.sidebar .author-box .author-thumb {
  width: 120px;
  margin: 0 auto;
  position: absolute;
  top: 50px;
  right: 0;
  left: 0;
  bottom: 0;
}
.sidebar .author-box .author-name {
  font-size: 1.1em;
  font-weight: bold;
  position: absolute;
  margin-bottom: 0.4em;
  top: 23px;
  bottom: 0;
  right: 0;
  left: 0;
}
.sidebar .author-box .author-widget-name {
  position: absolute;
  top: 3px;
  bottom: 0;
  right: 0;
  left: 0;
  font-size: 0.7em;
  color: #bbb;
}
.sidebar .author-box .sns-follow {
  padding: 15px 10px;
}
.sidebar .author-box .sns-follow-buttons {
  display: flex;
  justify-content: space-evenly;
}
.sidebar .author-box .sns-follow-buttons a {
  border-radius: 50%;
  border: none;
  width: 45px;
  height: 45px;
  line-height: 45px;
  font-size: 30px;
  box-shadow: 0 0 10px rgba(66, 172, 231, .5), 0 0 5px -5px rgba(66, 172, 231);
  background:#fff;
}
.sidebar .author-box .sns-follow-buttons a:hover {
  box-shadow: 0 10px 20px -2px rgba(0, 0, 0, .2);
  opacity: 1;
}
.sidebar .author-box .sns-follow-buttons .follow-button span:before {
  color: #46CDFF;
}
.sidebar .icon-instagram-new:before {
  content: "\ea92";
  font-size: 24px;
}
.sidebar .author-box .to-profile {
  position: absolute;
  background: #fff;
  border-radius: 50%;
  width: 50px;
  height: 50px;
  line-height: 50px;
  text-align: center;
  text-decoration: none;
  color: #46CDFF;
  box-shadow: 0 0 10px rgba(66, 172, 231, .5), 0 0 5px -5px rgba(66, 172, 231);
  top: 105px;
  right: 45px;
  font-size: 0.9em;
  font-weight: bold;
}
.sidebar .author-box .to-profile:hover {
  box-shadow: 0 10px 20px -2px rgba(0, 0, 0, .2);
}
.sidebar .author-box .sns-follow-message {
  margin-bottom: 10px;
  font-size: 13px;
}
.sidebar .author-box .sns-follow-message:before {
  content: "＼";
  margin-right: 5px;
}
.sidebar .author-box .sns-follow-message:after {
  content: "／";
  margin-left: 5px;
}
.sidebar .icon-twitter-logo:before {
  position: absolute;
  top: 8px;
  right: 0;
  bottom: 0;
  left: 0;
}
.sidebar .icon-facebook-logo:before {
  position: absolute;
  top: 6px;
  bottom: 0;
  right: 8px;
  left: 0;
}
.sidebar .icon-hatebu-logo:before {
  position: absolute;
  top: 8px;
  bottom: 0;
  right: 0;
  left: 0;
}
.sidebar .icon-feedly-logo:before {
  position: absolute;
  top: 8px;
  right: 0;
  bottom: 0;
  left: 0;
}
.sidebar .icon-rss-logo:before {
  position: absolute;
  top: 8px;
  right: 0;
  bottom: 0;
  left: 0;
}

#sidebar .author-box .sns-follow-message {
  display:block;
}

/************************************
** フッターSNS
************************************/
/* フッターのリンクリストを“区切り線つき”に */
.footer .widget_nav_menu ul{
  list-style:none;
  margin:0;
  padding:0;
}
.footer .widget_nav_menu li{
  border-bottom:1px solid rgba(0,0,0,.08);
  padding:14px 0;
}
.footer .widget_nav_menu li a{
  text-decoration:none;
}

/* 左側に “>” っぽい印象（簡易） */
.footer .widget_nav_menu li a:before{
  content:"›";
  display:inline-block;
  margin-right:10px;
  opacity:.6;
}

/* 右カラムの小リンク（X/ニュースレター/RSS） */
.footer-mini-links{
  display:flex;
  gap:10px;
  align-items:center;
  flex-wrap:wrap;
  margin-top:12px;
}
.footer-pill{
  display:inline-flex;
  align-items:center;
  padding:6px 10px;
  border:1px solid rgba(0,0,0,.12);
  border-radius:999px;
  text-decoration:none;
  font-size:13px;
}

/* フッター左・中央：文字サイズと行間を統一 */
.footer-left .widget_nav_menu .menu > li > a,
.footer-center .widget_nav_menu .menu > li > a{
  font-size: 14px;
  line-height: 1.6;
  letter-spacing: .02em;
}

/* =========================================================
   Cocoon ドロップダウンを “確実に” 大きくするセット
   ========================================================= */

/* 1) サブメニューが切れないように（親の overflow を解除） */
#header-container,
#header,
#navi,
#navi-in,
#gnavi,
.navi,
.navi-in{
  overflow: visible !important;
}

/* 2) サブメニューを前面に（背面に回っていると範囲が効かない） */
#navi .sub-menu,
#navi-in .sub-menu,
#gnavi .sub-menu,
.navi .sub-menu{
  z-index: 99999 !important;
}

/* 3) ドロップダウン（箱）自体のサイズを拡大 */
#navi .sub-menu,
#navi-in .sub-menu,
#gnavi .sub-menu,
.navi .sub-menu{
  min-width: 420px !important;   /* ← 横幅：好みで 360〜520 */
  padding: 12px 0 !important;    /* ← 上下余白 */
}

/* 4) 各項目の “当たり判定” を拡大（行の高さ・左右） */
#navi .sub-menu a,
#navi-in .sub-menu a,
#gnavi .sub-menu a,
.navi .sub-menu a{
  display: block !important;
  padding: 14px 20px !important; /* ← ここが体感に効く */
  line-height: 1.4 !important;
  white-space: normal !important; /* 長文を折り返して幅を活かす */
}

/* 5) 親→サブメニュー移動で閉じにくくする “のりしろ” */
#navi .menu-item-has-children,
#navi-in .menu-item-has-children,
#gnavi .menu-item-has-children,
.navi .menu-item-has-children{
  position: relative !important;
}

#navi .menu-item-has-children::after,
#navi-in .menu-item-has-children::after,
#gnavi .menu-item-has-children::after,
.navi .menu-item-has-children::after{
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  height: 26px;                 /* ← “外れにくさ” をもっと上げるなら 32〜40 */
}


/* ===== Theme tokens ===== */
:root{
  --bg: #ffffff;
  --text: #111;
  --muted: rgba(0,0,0,.65);

  /* 観省庵のモスグリーン基調（ライト） */
  --accent: #2f4f3a;
  --btn-bg: #eef4ef;
  --btn-border: #b8c9bd;
  --btn-hover: #dfeae3;

  color-scheme: light;
}

html[data-theme="dark"]{
  --bg: #0f1412;
  --text: #e7efe9;
  --muted: rgba(231,239,233,.70);

  /* ダーク側モスグリーン（沈ませた版） */
  --accent: #8db7a0;
  --btn-bg: #14211a;
  --btn-border: #2a3d32;
  --btn-hover: #1a2a21;

  color-scheme: dark;
}

/* ===== Apply to page (最低限) ===== */
body{
  background: var(--bg);
  color: var(--text);
}

/* ===== Your AI summary buttons (既存を変数対応) ===== */
.ai-summary-buttons .ai-btn{
  color: var(--accent);
  background: var(--btn-bg);
  border: 1px solid var(--btn-border);
}
.ai-summary-buttons .ai-btn:hover{
  background: var(--btn-hover);
}
/* ===== ダークモード時の色変更===== */
html[data-theme="dark"] .ai-summary-buttons .ai-btn{
  background: #1a2420 !important;
  color: #cfe3d7 !important;
  border-color: rgba(231,239,233,.25) !important;
}

html[data-theme="dark"] .ai-summary-buttons .ai-btn:hover{
  background: #22312b !important;
}



/* ===== Theme tokens ===== */
:root{
  --bg: #ffffff;
  --text: #111;
  --muted: rgba(0,0,0,.65);

  --accent: #2f4f3a;   /* moss */
  --card: #ffffff;
  --border: rgba(0,0,0,.10);

  color-scheme: light;
}
html[data-theme="dark"]{
  --bg: #0f1412;
  --text: #e7efe9;
  --muted: rgba(231,239,233,.70);

  --accent: #8db7a0;
  --card: #111816;
  --border: rgba(231,239,233,.12);

  color-scheme: dark;
}

/* ===== Global apply ===== */
body{ background: var(--bg); color: var(--text); }

/* Cocoonの白固定をまとめて潰す（重要） */
html[data-theme="dark"] body,
html[data-theme="dark"] #container,
html[data-theme="dark"] #content,
html[data-theme="dark"] #content-in,
html[data-theme="dark"] #main,
html[data-theme="dark"] #sidebar,
html[data-theme="dark"] .header,
html[data-theme="dark"] .footer{
  background: var(--bg) !important;
  color: var(--text) !important;
}

/* 背景画像が残るケース対策 */
html[data-theme="dark"] body,
html[data-theme="dark"] #container,
html[data-theme="dark"] #content-in{
  background-image: none !important;
}

/* カード/ウィジェット類（白ベタを潰す） */
html[data-theme="dark"] .article,
html[data-theme="dark"] .entry-content,
html[data-theme="dark"] .widget,
html[data-theme="dark"] .sidebar-content,
html[data-theme="dark"] .breadcrumb,
html[data-theme="dark"] .toc,
html[data-theme="dark"] .author-box{
  background: var(--card) !important;
  color: var(--text) !important;
  border-color: var(--border) !important;
}

/* 入力系（検索BOX含む） */
html[data-theme="dark"] input,
html[data-theme="dark"] textarea,
html[data-theme="dark"] select{
  background: #0f1412 !important;
  color: var(--text) !important;
  border-color: rgba(231,239,233,.18) !important;
}
html[data-theme="dark"] input::placeholder,
html[data-theme="dark"] textarea::placeholder{
  color: rgba(231,239,233,.55) !important;
}

/* リンク */
html[data-theme="dark"] a{ color: #9ec7b1 !important; }

/* ===== Toggle UI : Moss Green + icons ===== */
.ks-darkmode-wrap{
  display:inline-flex; align-items:center; gap:14px;
  padding:14px 20px;
  border:2px solid #2f4f3a;
  border-radius:18px;
  background:#f3f7f4;
}
.ks-darkmode-label{
  font-weight:800;
  font-size:24px; /* 2pt小さく */
  letter-spacing:.02em;
  color:#2f4f3a;
  line-height:1;
}
.ks-switch{ position:relative; width:68px; height:36px; display:inline-block; }
.ks-switch input{ opacity:0; width:0; height:0; }
.ks-slider{
  position:absolute; inset:0;
  background:#2f4f3a;
  border-radius:999px;
  cursor:pointer;
  overflow:hidden;
}
.ks-icon{ position:absolute; top:50%; transform:translateY(-50%); font-size:14px; line-height:1; pointer-events:none; opacity:.95; }
.ks-icon--sun{ left:10px; } .ks-icon--moon{ right:10px; }
.ks-icon--sun::before{ content:"☀️"; } .ks-icon--moon::before{ content:"🌙"; }
.ks-slider::after{
  content:""; position:absolute; width:26px; height:26px; left:5px; top:5px;
  background:#fff; border-radius:50%;
  transition:transform .18s ease;
  box-shadow:0 2px 10px rgba(0,0,0,.18);
}
.ks-switch input:checked + .ks-slider::after{ transform: translateX(32px); }
.ks-switch input:focus-visible + .ks-slider{ outline:3px solid rgba(47,79,58,.25); outline-offset:3px; }

/* Dark時トグルの微調整 */
html[data-theme="dark"] .ks-darkmode-wrap{ background: transparent; border-color: rgba(231,239,233,.35); }
html[data-theme="dark"] .ks-darkmode-label{ color: rgba(231,239,233,.92); }
html[data-theme="dark"] .ks-slider{ background: rgba(231,239,233,.28); }

/* アクセシビリティ色 */
html[data-theme="dark"] body {
  color: #e7efe9; /* もう一段明るく */
}

html[data-theme="dark"] .entry-content p {
  color: #dde9e2;
}

html[data-theme="dark"] a {
  color: #9ec7b1;
  text-decoration: underline;
}
html[data-theme="dark"] a:hover {
  text-decoration-thickness: 2px;
}

:focus-visible {
  outline: 3px solid #8db7a0;
  outline-offset: 3px;
}

html[data-theme="dark"] img {
  filter: brightness(.8) contrast(1.05);
}

:focus-visible{
  outline: 3px solid rgba(141,183,160,.9); /* モス系 */
  outline-offset: 3px;
}

a, button, input, select, textarea{
  scroll-margin-top: 90px; /* 固定ヘッダーがある場合の見切れ防止 */
}

/* Conversion Rate Calculator (Kanseian) */
.ks-cr-wrap{
  margin: 22px 0;
  padding: 16px;
  border: 1px solid #b8c9bd;
  border-radius: 14px;
  background: #eef4ef;
}

.ks-cr-title{
  font-weight: 800;
  font-size: 16px;
  color: #2f4f3a;
}

.ks-cr-sub{
  margin-top: 4px;
  font-size: 12px;
  color: #4f6f5a;
}

.ks-cr-grid{
  margin-top: 12px;
  display: grid;
  grid-template-columns: 1fr 1fr auto;
  gap: 10px;
  align-items: end;
}

.ks-cr-field{ display:block; }

.ks-cr-label{
  display:block;
  font-size: 12px;
  margin-bottom: 6px;
  color: #2f4f3a;
  font-weight: 700;
}

.ks-cr-input{
  width: 100%;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid #b8c9bd;
  background: #fff;
  color: #1f3b2a;
}

.ks-cr-btn{
  padding: 11px 14px;
  border-radius: 10px;
  border: 1px solid #b8c9bd;
  background: #2f4f3a;
  color: #fff;
  font-weight: 800;
  cursor: pointer;
  white-space: nowrap;
}

.ks-cr-btn:hover{ opacity: .92; }

.ks-cr-result{
  margin-top: 12px;
  padding: 12px;
  border-radius: 12px;
  border: 1px solid #b8c9bd;
  background: #fff;
  color: #1f3b2a;
  font-weight: 800;
}

.ks-cr-note{
  margin-top: 10px;
  font-size: 12px;
  color: #4f6f5a;
}

/* responsive */
@media (max-width: 760px){
  .ks-cr-grid{ grid-template-columns: 1fr; }
  .ks-cr-btn{ width: 100%; }
}

/* dark mode（あなたの仕組みが data-theme="dark" の場合） */
html[data-theme="dark"] .ks-cr-wrap{
  background: rgba(10,14,12,.65);
  border-color: rgba(141,183,160,.25);
}
html[data-theme="dark"] .ks-cr-title{ color: rgba(141,183,160,.95); }
html[data-theme="dark"] .ks-cr-sub,
html[data-theme="dark"] .ks-cr-note{ color: rgba(141,183,160,.75); }
html[data-theme="dark"] .ks-cr-input,
html[data-theme="dark"] .ks-cr-result{
  background: rgba(255,255,255,.06);
  color: rgba(255,255,255,.92);
  border-color: rgba(141,183,160,.25);
}
html[data-theme="dark"] .ks-cr-btn{
  background: rgba(141,183,160,.85);
  border-color: rgba(141,183,160,.25);
  color: #0b0f0d;
}



