@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){
  /*必要ならばここにコードを書く*/
}

/* --- タグクラウドの見出し（タイル風デザイン） --- */
.widget_tag_cloud .widget-title {
  display: block;
  background-color: #dd9999 !important; /* メインカラー */
  color: #fff !important; /* 文字は白 */
  padding: 8px 12px !important;
  font-size: 15px; /* 少しコンパクトに */
  font-weight: bold;
  border: 1px solid #dd9999;
  border-radius: 0; /* タイル感を出すため角は丸めない */
  margin-bottom: 0 !important; /* 下のタグブロックと密着させる */
  box-shadow: none !important;
  border-left: none !important; /* 余計なアクセント線を消去 */
}

/* タイトルの装飾リセット */
.widget_tag_cloud .widget-title::before,
.widget_tag_cloud .widget-title::after {
  display: none !important;
}

/* --- タグクラウド本体（Grid） --- */
.tagcloud {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  padding: 0;
  border-left: 1px solid #dd9999;
  border-top: none;
}

/* --- タグのデザイン --- */
.tagcloud a {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 2px 0;
  border-right: 1px solid #dd9999;
  border-bottom: 1px solid #dd9999;
  font-size: 11px !important;
  font-weight: bold;
  color: #dd9999 !important;
  background-color: #fffafb;
  text-decoration: none;
  text-align: center;
  line-height: 1.1;
  letter-spacing: -0.8px;
  word-break: break-all;
}

/* 件数表示調整 */
.tag-link-count {
  display: inline-block;
  font-size: 10px;
  margin-left: 1px;
  letter-spacing: -0.5px;
  font-weight: bold;
  color: inherit;
}

.tag-link-count::after {
  content: "件";
  font-size: 9px;
}

/* エントリーカードタイトル */
.entry-card-title {
  min-height: 2.8em;
  max-height: 2.8em;
  overflow: hidden;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-height: 1.4;
  margin-bottom: 10px !important;
}

/* カード全体の余白調整 */
.entry-card-content {
  padding: 10px !important;
  display: flex;
  flex-direction: column;
}

/* ======================================================
 * Cocoon エントリカード画像最大化＋5行高さ完全統一
 * ====================================================== */
.entry-card-wrap {
  display: flex;
  padding: 0 !important;
  margin-bottom: 20px;
}

.entry-card-link {
  display: flex;
  flex-direction: column;
  height: 100%;
  width: 100%;
  border: 1px solid #eee;
  text-decoration: none !important;
  background-color: #fff;
}

.entry-card-thumb {
  width: 100% !important;
  margin: 0 !important;
  padding-top: 75%;
  position: relative;
  overflow: hidden;
  background-color: #f7f7f7;
}

.entry-card-thumb img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100% !important;
  height: 100% !important;
  object-fit: cover;
  object-position: center;
  border-radius: 0 !important;
  transition: transform 0.6s ease !important;
}

/* ホバー時画像拡大 */
.entry-card-link:hover .entry-card-thumb img {
  transform: scale(1.15) !important;
}

.entry-card-content {
  padding: 12px 10px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.entry-card-title {
  display: -webkit-box !important;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 5;
  overflow: hidden;
  min-height: 7em;
  max-height: 7em;
  line-height: 1.4;
  font-size: 14px;
  margin: 0 0 10px 0 !important;
  color: #333;
  font-weight: bold;
}

.entry-card-info,
.entry-card-snippet {
  margin-top: auto;
  font-size: 11px;
  color: #777;
}

.entry-cards {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
}

.entry-card-link:hover {
  opacity: 0.9;
  transition: opacity 0.3s ease;
}

/* ==============================
   人気ラベル（左上表示・白文字）
============================== */
.entry-card-thumb {
  position: relative !important;
}

.random-popular .entry-card-thumb::after {
  content: "人気急上昇！";
  position: absolute;
  top: 10px;
  left: 10px;
  background: #dd9999;
  color: #fff;
  font-weight: bold;
  padding: 4px 8px;
  font-size: 11px;
  border-radius: 4px;
  z-index: 9999 !important;
  pointer-events: none;
  animation: blinkLabel 1.2s infinite;
  box-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

@keyframes blinkLabel {
  0% {opacity: 1;}
  50% {opacity: 0.5;}
  100% {opacity: 1;}
}
