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

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

/* =========================================
 * 1. メインのカード一覧（記事一覧・カテゴリーなど）
 * =======================================*/

/* 枠は 320px 固定（好みで変更OK） */
.entry-card-thumb,
.card-thumb,
.related-entry-card-thumb,
.blogcard-thumbnail,
.carousel-entry-card-thumb {
  position: relative !important;
  padding-top: 0 !important;        /* Cocoonの16:9ハック無効化 */
  height: 320px !important;         /* ★ サムネの高さ（px） */
  overflow: hidden !important;      /* はみ出し部分は隠す */
}

/* 16:9ハック用の疑似要素を無効化 */
.card-thumb::before,
.entry-card-thumb::before,
.related-entry-card-thumb::before,
.blogcard-thumbnail::before,
.carousel-entry-card-thumb::before {
  content: none !important;
  padding-top: 0 !important;
}

/* 高画質サムネを枠いっぱいに表示（medium_large 前提） */
.entry-card-thumb img,
.card-thumb img,
.related-entry-card-thumb img,
.blogcard-thumbnail img,
.carousel-entry-card-thumb img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  object-position: top center !important;
  display: block !important;
  position: static !important;
  aspect-ratio: auto !important;
}

/* 枠を包むリンク */
.entry-card-thumb a,
.card-thumb a {
  height: 100% !important;
  display: block;
}

/* =========================================
 * 2. サイドバーなどのウィジェット用サムネ
 * =======================================*/

/* ウィジェットのサムネは高さ小さめ＆自動比率 */
.widget-entry-card-thumb {
  position: relative !important;
  padding-top: 0 !important;
  height: auto !important;          /* 高さ固定しない */
  max-height: 120px;                /* 必要なら上限だけ設定（お好みで） */
  overflow: hidden;                 /* はみ出し軽くカット */
}

.widget-entry-card-thumb img {
  width: auto !important;           /* 画像本来の比率を優先 */
  max-width: 100% !important;
  height: auto !important;
  object-fit: cover !important;     /* 多少のトリミングだけ */
  object-position: center center !important;
  display: block !important;
  position: static !important;
  aspect-ratio: auto !important;
}

/* =========================================
 * 3. カード全体の見た目
 * =======================================*/

.entry-card {
  box-shadow: 0 1px 6px rgba(0,0,0,.06);
  transition: transform .1s ease, box-shadow .1s ease;
}
.entry-card:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0,0,0,.12);
}

/* テキストの可読性 */
.entry-card-title {
  font-size: 1.05rem;
  line-height: 1.5;
}
.entry-card-snippet {
  color: #555;
}
/* prod-key タグを完全に非表示にする */
a.tag-link[href*="prod-key"],
.tagcloud a[href*="prod-key"],
.entry-tags a[href*="prod-key"] {
    display: none !important;
}

/* CTAボタン */
a.cta-btn {
  display: inline-block;
  padding: .7em 1.1em;
  border-radius: 8px;
  background: #1a73e8;
  color: #fff;
  font-weight: 700;
}
a.cta-btn:hover {
  filter: brightness(1.07);
}

/* レスポンシブ調整（必要なら追記） */
@media (max-width: 1023px){ }
@media (max-width: 834px){ }
@media (max-width: 480px){ }
