@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){
  /*必要ならばここにコードを書く*/
}
/* =====================================
   ランキングカード（Cocoon Child用）
===================================== */

.ranking-card {
  border: 2px solid #f0e0a0;
  background: #fffaf0;
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 30px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.05);
}

.ranking-header {
  display: flex;
  align-items: center;
  border-bottom: 2px dotted #e0c870;
  padding-bottom: 8px;
  margin-bottom: 15px;
}

.ranking-number {
  background: gold;
  color: white;
  font-weight: bold;
  font-size: 22px;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 10px;
}

.ranking-header h2 {
  font-size: 20px;
  color: #5a4500;
  margin: 0;
}

.ranking-body {
  display: flex;
  gap: 15px;
  flex-wrap: wrap;
}

.ranking-image img {
  width: 250px;
  border-radius: 8px;
}

.ranking-text {
  flex: 1;
}

.ranking-table {
  width: 100%;
  margin-top: 10px;
  border-collapse: collapse;
}

.ranking-table th {
  text-align: left;
  color: #444;
  width: 80px;
  padding: 4px 0;
}

.price {
  color: #e34b4b;
  font-size: 20px;
  font-weight: bold;
}

.stars {
  color: gold;
}

.ranking-buttons {
  margin-top: 15px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.btn {
  display: inline-block;
  padding: 10px 20px;
  border-radius: 6px;
  text-decoration: none;
  font-weight: bold;
  transition: 0.2s;
}

/* ボタン色（Cocoonのカラーに馴染む配色） */
.btn.detail {
  background: #7fc6d8;
  color: white;
}
.btn.detail:hover {
  background: #5ca5b8;
}

.btn.official {
  background: #f6c94a;
  color: #4a3b00;
}
.btn.official:hover {
  background: #e5b83f;
}
/* =====================================
   スマホ表示時のランキングレイアウト調整
===================================== */
@media screen and (max-width: 768px) {
  .ranking-body {
    flex-direction: column; /* ← 画像とテキストを縦並びに */
  }

  .ranking-image img {
    width: 100%; /* スマホでは横幅いっぱいに */
    height: auto;
  }

  .ranking-text {
    width: 100%;
  }

  .ranking-buttons {
    flex-direction: column; /* ボタンを縦並びに */
  }

  .ranking-buttons .btn {
    width: 100%;
    text-align: center;
  }
}
/* =====================================
   ランキングカード（PCレイアウト修正版）
===================================== */

/* 上部：画像とテキストを横並び50%ずつ */
.ranking-upper {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  margin-bottom: 15px;
}

.ranking-image {
  flex: 1 1 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.ranking-image img {
  width: 100%;
  height: auto;
  border-radius: 8px;
}

.ranking-text {
  flex: 1 1 50%;
}

/* 下部：テーブルとボタンを幅いっぱいに */
.ranking-lower {
  width: 100%;
}

.ranking-table {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
  margin-bottom: 15px;
}

.ranking-table th,
.ranking-table td {
  padding: 8px 10px;
  border: 1px solid #eee;
}

.ranking-table th {
  background: #f9f9f9;
  text-align: left;
  width: 20%;
}

.price {
  color: #e34b4b;
  font-size: 20px;
  font-weight: bold;
}

.stars {
  color: gold;
}

/* ボタンを横並びで幅いっぱいに */
.ranking-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.ranking-buttons .btn {
  flex: 1;
  text-align: center;
  padding: 12px 0;
  border-radius: 6px;
  text-decoration: none;
  font-weight: bold;
  transition: 0.2s;
}

/* カラー設定 */
.btn.detail {
  background: #7fc6d8;
  color: #fff;
}
.btn.detail:hover {
  background: #5ca5b8;
}

.btn.official {
  background: #f6c94a;
  color: #4a3b00;
}
.btn.official:hover {
  background: #e5b83f;
}

/* スマホ表示では縦並びに */
@media screen and (max-width: 768px) {
  .ranking-upper {
    flex-direction: column;
  }

  .ranking-image,
  .ranking-text {
    flex: 1 1 100%;
  }

  .ranking-buttons {
    flex-direction: column;
  }

  .ranking-buttons .btn {
    width: 100%;
  }
}
/* =============================
   順位バッジ（1位・2位・3位色分け）
============================= */
.ranking-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 15px;
}

.ranking-number {
  display: inline-block;
  width: 28px;
  height: 28px;
  line-height: 28px;
  text-align: center;
  border-radius: 50%;
  color: #fff;
  font-weight: bold;
  font-size: 16px;
}

/* 1位＝金色 */
.ranking-number.rank-1 {
  background: linear-gradient(145deg, #ffd700, #f4c400);
  box-shadow: 0 0 4px rgba(255, 215, 0, 0.6);
}

/* 2位＝銀色 */
.ranking-number.rank-2 {
  background: linear-gradient(145deg, #c0c0c0, #a9a9a9);
  box-shadow: 0 0 4px rgba(192, 192, 192, 0.6);
}

/* 3位＝銅色 */
.ranking-number.rank-3 {
  background: linear-gradient(145deg, #cd7f32, #b87333);
  box-shadow: 0 0 4px rgba(205, 127, 50, 0.6);
}

/* タイトル見出し */
.ranking-header h2 {
  font-size: 18px;
  background: #f8f8f8;
  padding: 4px 10px;
  border-radius: 4px;
  display: inline-block
