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

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

/* サイト全体の背景を灰色に */
body {
  background-color: #f2f2f2 !important;
}

/* 中央カラム（本文＋サイドバー部分）を白に */
#container, .body-in {
  background-color: #ffffff !important;
  padding: 20px;
  border-radius: 8px;
}

/* パンくずリスト・関連記事タイトルを1行表示 */
.breadcrumb,
.same-category-posts a {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.same-category-posts a {
  display: block !important;
}

/* タイトルの余白リセット */
.entry-title,
.article-title,
.post-title,
.single-post .entry-title,
.single-post .article-title,
.single-post .post-title,
.post-type-post .entry-title,
.post-type-post .article-title,
.post-type-post .post-title,
.entry-header,
.article-header,
.single-post .entry-header,
.single-post .article-header,
.post-type-post .entry-header,
.post-type-post .article-header {
  padding: 0 !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
}

.entry-title,
.article-title,
.post-title,
.single-post .entry-title,
.single-post .article-title,
.single-post .post-title,
.post-type-post .entry-title,
.post-type-post .article-title,
.post-type-post .post-title {
  width: 100% !important;
  box-sizing: border-box !important;
}

/* 固定ページで日付を完全に非表示 */
.page .post-date,
.page .post-update,
.page .entry-date,
.page .date-tags,
.page .entry-meta,
.page .post-meta,
.sidebar .post-date {
  display: none !important;
  visibility: hidden !important;
}

/* 投稿ページで日付を1行左揃え表示 */
.single-post .date-tags,
.post-type-post .date-tags,
.single-post .entry-meta,
.post-type-post .entry-meta,
.single-post .post-meta,
.post-type-post .post-meta {
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: nowrap !important;
  justify-content: flex-start !important;
  align-items: center !important;
  text-align: left !important;
  gap: 0.5rem !important;
  width: 100% !important;
  margin: 0 0 1.5rem 0 !important;
  padding: 0 !important;
  white-space: nowrap !important;
}

/* 投稿日・更新日の個別要素を1行表示 */
.single-post .post-date,
.single-post .post-update,
.single-post .entry-date,
.post-type-post .post-date,
.post-type-post .post-update,
.post-type-post .entry-date {
  display: inline-block !important;
  margin: 0 !important;
  padding: 0 !important;
  text-align: left !important;
  float: none !important;
  white-space: nowrap !important;
  flex-shrink: 0 !important;
}

/* 投稿日と更新日の区切り文字 */
.single-post .post-date::after,
.post-type-post .post-date::after {
  content: " | " !important;
  margin: 0 0.5rem !important;
  color: #999 !important;
  display: inline !important;
}

.single-post .post-date:only-child::after,
.post-type-post .post-date:only-child::after,
.single-post .post-update::after,
.single-post .post-date:last-child::after,
.post-type-post .post-update::after,
.post-type-post .post-date:last-child::after {
  display: none !important;
}

/* 日付のアイコン部分 */
.single-post .fa-clock,
.single-post .fa-history,
.post-type-post .fa-clock,
.post-type-post .fa-history {
  margin-right: 0.25rem !important;
}

/* 特定ページのヘッダー・ナビ・フッター非表示 */
.page-id-4398 header,
.page-id-3 header,
.page-id-4398 footer,
.page-id-3 footer {
  display: none;
}

.page-id-4398 .navi,
.page-id-3 .navi,
.page-id-4398 .breadcrumb,
.page-id-3 .breadcrumb {
  display: none;
}

/* 本文の行間調整 */
.entry-content p {
  line-height: 3;
}

/* サイドバー設定 */
.sidebar {
  background-color: #fff;
  color: #000000;
  padding: 15px;
  border-radius: 10px;
}

.sidebar h3.widget-title,
.sidebar .widgettitle {
  background: linear-gradient(30deg, #FCA235 50%, #FFDD99 95%) !important; 
  color: #fff !important; 
  font-size: 16px !important; 
  padding: 0.5em !important; 
  margin: 1.5em 0 !important; 
  text-align: left !important;
  border-radius: 5px !important;
}

/* トップページグリッド */
.post-grid-container {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 20px;
}

.post-grid-item {
  text-align: left;
}

.post-link {
  font-size: 12px;
  color: #0073aa;
  text-decoration: none;
}

.post-link:hover {
  text-decoration: underline;
}

/* 固定ページ設定 */
.page .entry-card-wrap {
  margin-bottom: -35px;
}

.page .entry-card {
  padding: 0;
}

.page .front-page-thumbnail,
.page .entry-thumbnail {
  margin: -15px 0;
}

.page .column-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
}

.page .box-menu {
  width: calc(100% / 3);
  text-align: center;
}

.page .box-menu-icon {
  width: 80px;
  height: 80px;
  display: block;
  margin: 0 auto;
}

.page .box-menu-label {
  font-size: 20px;
  color: #000000;
  margin-top: 10px;
}

.page .box-menu-description {
  font-size: 16px;
  color: gray;
  margin-top: 5px;
}

/* 最新記事ブロック */
.wp-block-latest-posts,
.wp-block-latest-posts__list {
  text-align: center;
}

.wp-block-latest-posts__list {
  list-style: none;
  padding: 0;
  margin: 0 auto;
}

.wp-block-latest-posts__list li {
  display: inline-block;
  margin-bottom: 20px;
  text-align: center;
}

.wp-block-latest-posts__list img {
  display: block;
  margin: 0 auto 5px;
  max-width: 100%;
  height: auto;
}

.wp-block-latest-posts__list a {
  display: block;
  text-align: center;
  color: auto;
  font-weight: bold;
}

.wp-block-latest-posts__list a:hover {
  color: #FF6600;
}

/* ヘッダー・ロゴ設定 */
.page .logo-header {
  display: none;
}

.front-top-page .main {
  padding-top: -10px;
}

.logo-text {
  padding: 0;
}

.tagline {
  margin: 0 0 .8em;
  font-weight: bold;
  font-size: 10pt;
}

/* 関連記事 */
.related-posts {
  margin-top: 20px;
  padding: 10px;
  border-top: 2px solid #ccc;
}

.related-posts h3 {
  font-family: 'Arial', 'Helvetica', '游ゴシック', 'Yu Gothic', sans-serif;
  font-size: 16px;
  font-weight: normal;
  margin-bottom: 10px;
  color: #333;
  border: none;
  text-align: center;
}

/* 人気記事ランキング */
.widget-entry-cards.ranking-visible .widget-entry-card-thumb::before {
  border-radius: 50%;
  top: -4px;
  left: -4px;
  width: 14px;
  height: 14px;
  font-family: 'Lato', sans-serif;
  font-size: 12px;
}

.widget-entry-cards.ranking-visible .no-1 .card-thumb::before,
.widget-entry-cards.ranking-visible .no-2 .card-thumb::before,
.widget-entry-cards.ranking-visible .no-3 .card-thumb::before,
.widget-entry-cards.ranking-visible .no-4 .card-thumb::before,
.widget-entry-cards.ranking-visible .no-5 .card-thumb::before {
  line-height: 14px;
}

.widget-entry-cards.ranking-visible .no-4 .card-thumb::before,
.widget-entry-cards.ranking-visible .no-5 .card-thumb::before {
  background: #d0d0d1;
}

/* その他設定 */
.home .widget_text {
  text-align: center;
}

.entry-title {
  display: none;
}

.archive-title {
  color: #5f5f5f;
  text-align: center;
  font-size: 30px !important;
  margin-left: -15px;
}

/* レスポンシブ設定 */
@media (max-width: 768px) {
  .container, .main, .content, .wrap, .main-wrap, .article, .post,
  .entry-content, .post-content, .article-content {
    margin: 0 !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }
  
  .container, .main, .content, .wrap, .main-wrap, .article, .post {
    padding: 0 5px !important;
  }
  
  .entry-content, .post-content, .article-content {
    padding: 0 5px !important;
  }
  
  .single-post .date-tags,
  .post-type-post .date-tags {
    margin: 0 0 0.5rem 0 !important;
  }

  .entry-content p {
    line-height: 2;
  }
  
  .entry-content h2 {
    left: -10px;
  }
  
  h2:before {
    left: 5px;
  }
  
  .entry-content h3 {
    text-indent: -5px;
  }
}

@media (max-width: 480px) {
  .container, .main, .content, .wrap, .main-wrap, .article, .post,
  .entry-content, .post-content, .article-content {
    padding-left: 2px !important;
    padding-right: 2px !important;
  }
  
  .single-post .date-tags,
  .post-type-post .date-tags {
    gap: 0.3rem !important;
    margin: 0 0 0.3rem 0 !important;
  }
  
  .single-post .post-date::after,
  .post-type-post .post-date::after {
    margin: 0 0.3rem !important;
  }
}

@media screen and (max-width: 599px) {
  .page .box-menus .box-menu {
    width: calc(100% / 7);
  }
  
  .page .box-menu-icon {
    font-size: 50px;
    margin: 0;
    padding-bottom: 0;
    height: auto;
  }
  
  .page .box-menu-label {
    font-size: 14px;
  }
  
  .page .box-menu {
    min-height: 10px;
  }
  
  .page .box-menu-description {
    font-size: 14px;
    color: gray;
  }
}


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

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

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