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

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

/* 検索フォーム全体 */
.custom-search-container {
  background-color: #fff4e6;
  padding: 20px;
  max-width: 90%;
  border-radius: 10px;
  font-family: sans-serif;
  margin: 0 auto;
  font-size: 16px;
}

/* 検索バーの横並び */
.search-bar-row {
  display: flex;
  gap: 10px;
  align-items: flex-end;
  margin-bottom: 15px;
}

.search-bar-row > * {
  flex: 1;
}

/* カテゴリードロップダウン */
.category-dropdown {
  position: relative;
  width: 100%;
}

/* カテゴリー選択ボタン */
#dropdownToggle {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid #ccc;
  background-color: white;
  cursor: pointer;
  border-radius: 5px;
  text-align: left;
  box-sizing: border-box;
  height: 42px;
  font-size: 16px;
}

/* ドロップダウンメニュー */
.dropdown-content {
  display: none;
  background-color: #ffffff;
  border: 1px solid #ccc;
  padding: 10px;
  border-radius: 5px;
  position: absolute;
  top: 110%;
  left: 0;
  width: 100%;
  box-sizing: border-box;
  max-height: 70vh;
  overflow-y: auto;
  z-index: 1000;
  font-size: 16px;
}

/* カテゴリー選択ラベル */
.dropdown-content label {
  display: inline-table;
  margin: 8px;
}

/* キーワード入力 */
input[type="text"] {
  flex: 2;
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 5px;
  height: 42px;
  font-size: 16px;
}

/* 小さめの検索ボタン（カテゴリ内） */
.search-btn.small {
  background-color: #e91e63;
  color: white;
  padding: 8px 12px;
  font-size: 16px;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  margin-top: 0;
  height: 38px;
}

/* メインの検索ボタン */
.pink-search-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background-color: #e91e63;
  color: white;
  padding: 8px 16px;
  font-size: 16px;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  height: 42px;
}

/* ボタン群のラッパー */
.dropdown-buttons {
  display: flex;
  justify-content: space-between;
  max-width: 300px;
  margin-top: 15px;
  gap: 10px;
}

/* ボタン共通サイズ */
.dropdown-buttons .search-btn.small,
.dropdown-buttons .clear-btn {
  flex: 1;
}

/* クリアボタン */
.clear-btn {
  background-color: #ccc;
  color: white;
  padding: 8px 12px;
  font-size: 16px;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  height: 38px;
}

/************************************
** レスポンシブデザイン用のメディアクエリ
************************************/

/*1023px以下（タブレット）*/
@media screen and (max-width: 1023px) {
  .custom-search-container {
    padding: 14px;
  }
  .dropdown-content {
    position: static;
    width: 100%;
    margin-top: 10px;
  }
}

/*834px以下（小型タブレット・スマホ）*/
@media screen and (max-width: 834px) {
  .search-bar-row {
    flex-direction: column;
  }
  .search-bar-row > * {
    width: 100%;
  }
  .dropdown-content {
    position: static;
    width: 100%;
    margin-top: 10px;
  }
}

/*480px以下（スマホ）*/
@media screen and (max-width: 480px) {
  .custom-search-container {
    padding: 12px;
  }
  #dropdownToggle {
    padding: 8px 12px;
  }
  .dropdown-content {
    padding: 8px;
  }
  .search-btn,
  .clear-btn {
    padding: 8px;
  }
}
