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

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

/* すべての要素にbox-sizing: border-box; を適用し、パディングとボーダーが要素の合計幅に含まれるようにする */
/* これにより、レスポンシブレイアウトの計算が容易になり、横スクロールを防ぐのに役立ちます */
*, *::before, *::after {
    box-sizing: border-box;
}

/* 以下に、花火・お祭りファインダーMAP用のカスタムスタイルを追加します */

/* ヘッダーの背景画像とスタイリング (PCデフォルト) */
.header-bg {
    background-image: url('https://voyvoi.com/wp-content/uploads/2025/06/イエロー　青　ポップ　夏　祭り　イベント　花火　Twitter広告-8.png'); /* PC用画像URL */
    background-size: cover; /* 画像をカバーするように拡大縮小 */
    background-position: center; /* 画像を中央に配置 */
    color: white; /* テキストの色を白に */
    padding: 0 0 100px 0; /* padding-topを0に、padding-bottomは100pxに維持 */
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5); /* テキストに影をつけ、見やすくする */
    min-height: 250px; /* ヘッダーの最小高さを設定 */
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ヘッダーテキストのスタイリング */
.header-text h1 {
    font-family: 'Kaisei HarunoUmi', sans-serif; /* おしゃれなフォントを指定 */
    font-size: 3.5em; /* フォントサイズを調整 */
    font-weight: bold; /* 太字にする */
    line-height: 1.2;
}

/* モーダル関連のCSS (既存のものを維持または調整) */
.modal {
    z-index: 9999; /* 最前面に表示 */
}

.modal > div { /* モーダルコンテンツのスタイル */
    max-width: 90%; /* 最大幅 */
    max-height: 90vh; /* 最大高さ（ビューポートの90%）*/
    overflow-y: auto; /* コンテンツがはみ出したらスクロール */
}

/* 絞り込み検索セクションの高さ調整 (PC向け) */
#filters {
    padding-top: 2rem;
    padding-bottom: 2rem;
}

/* フィルターグループ間のマージンを調整 (PC向け) */
#filters .space-y-6 > div {
    margin-bottom: 1rem;
}

/* single-event.phpのメインコンテンツ幅調整（PC向け）*/
.site-main.max-w-screen-lg {
    max-width: 1024px; /* Tailwindのlgブレイクポイントの最大幅 */
    margin-left: auto;
    margin-right: auto;
}

/* PC版3カラムフィルターの幅調整 */
.md\:w-1\/3-minus-gap {
    width: calc(33.333333% - (1rem * 2 / 3)); /* gap-4 (1rem) を想定 */
    min-width: 250px; /* 各カラムの最小幅を確保 */
}
.lg\:w-1\/4-minus-gap {
    width: calc(25% - (1.5rem * 3 / 4)); /* gap-6 (1.5rem) を想定 */
    min-width: 200px; /* 各カラムの最小幅を確保 */
}

/* PC版の複数選択プルダウンの高さ調整 */
@media screen and (min-width: 768px) { /* mdブレイクポイント以上で適用 */
    select[multiple] {
        height: auto; /* デフォルトのheightをautoにリセット */
        min-height: 120px; /* 複数行表示のための最小高さを設定 */
        appearance: auto; /* ブラウザのネイティブな見た目を維持 */
        background-image: none; /* カスタム矢印を無効化 */
    }
}

/* お気に入りボタン用のスタイル */
.hanabi-favorite-button {
    background-color: #f0f0f0; /* デフォルトの背景色 */
    color: #333; /* デフォルトの文字色 */
    border: 1px solid #ccc;
    padding: 0.6em 1em;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: bold;
    border-radius: 5px;
}

/* アイコンのデフォルト色（白抜き星） */
.hanabi-favorite-button .favorite-icon {
    color: #ccc;
    font-size: 1.2em;
}

/* is-favorited クラスがついた時のスタイル */
.hanabi-favorite-button.is-favorited {
    background-color: #fff0f5; /* 背景色を薄いピンクに */
    border-color: #ff69b4; /* 枠線をピンクに */
    color: #ff69b4; /* 文字色をピンクに */
}

/* お気に入り登録済みのアイコン色（黄色い星） */
.hanabi-favorite-button.is-favorited .favorite-icon {
    color: #ffd700; /* 星を黄色に */
}


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

/*834px以下*/
@media screen and (max-width: 834px){
  #favorite-filter-wrapper {
      display: block !important;
      margin-top: 0.75rem;
  }
}

/*480px以下*/
@media screen and (max-width: 480px){
    /* モバイルヘッダーのテキストエリア調整 */
    .header-bg {
        padding: 0 0 30px 0;
        min-height: 150px;
    }

    .header-text h1 {
        font-size: 2em;
        line-height: 1.3;
    }

    .header-text p {
        font-size: 0.9em;
        margin-top: 0.5rem;
        padding: 0 10px;
    }

    /* サイト全体の横幅が画面に収まるように調整 */
    html, body {
        width: 100%;
        max-width: 100vw;
        overflow-x: hidden;
    }

    /* .container クラスの要素がスマホで中央寄せになるように強制 */
    .container {
        width: 100%;
        padding-left: 1rem;
        padding-right: 1rem;
        margin-left: auto;
        margin-right: auto;
    }

    /* スマホでのマップの高さ調整を縦画面の3/4に */
    .map-container {
        height: 75vh;
    }
    
    /* 絞り込み検索セクションのモバイル向け調整をさらにコンパクトに */
    #filters {
        padding-top: 1rem;
        padding-bottom: 1rem;
    }
    #filters h2 {
        font-size: 1.25rem !important;
        margin-bottom: 0.5rem !important;
    }
    #filters p {
        font-size: 0.8rem !important;
        margin-bottom: 0.5rem !important;
    }
    #current-filters-summary {
        padding: 0.5rem !important;
        margin-bottom: 0.75rem !important;
    }
    #current-filters-summary p {
        font-size: 0.8rem !important;
    }
    #current-filters-summary button {
        font-size: 0.7rem !important;
        padding: 0.25rem 0.5rem !important;
        margin-top: 0.5rem !important;
    }
    #filters .space-y-4 {
        --tw-space-y-reverse: 0;
        margin-top: 0 !important;
        margin-bottom: 0 !important;
    }
    #filters .space-y-4 > div {
        margin-top: 0.75rem !important;
        margin-bottom: 0.75rem !important;
    }
    #filters .space-y-4 > div:first-child {
        margin-top: 0 !important;
    }
    #filters .space-y-4 > div:last-child {
        margin-bottom: 0 !important;
    }

    #filters h3 {
        font-size: 0.9rem !important;
        margin-bottom: 0.25rem !important;
    }

    #date-filter-picker,
    #keyword-filter-mobile,
    #keyword-filter-pc {
        padding: 0.4rem 0.6rem !important;
        font-size: 0.8rem !important;
    }
    #clear-date-filter {
        padding: 0.3rem 0.6rem !important;
        font-size: 0.8rem !important;
        margin-top: 0.5rem !important;
    }


    /* イベントカードのレイアウト調整（スマホで1カラム表示用） */
    #event-list .event-card {
        flex-direction: column;
        align-items: center;
        padding: 1rem;
    }

    #event-list .event-card img {
        width: 100%;
        height: 200px;
        margin-bottom: 1rem;
        margin-right: 0;
    }

    #event-list .event-card > div { /* テキストコンテンツ部分 */
        width: 100%;
        text-align: left;
    }

    /* single-event.php のフォントサイズ調整 (モバイル) */
    article#post-<?php the_ID(); ?> h1 { /* イベント名 */
        font-size: 1.25em !important; /* 約20px */
        line-height: 1.3 !important;
        margin-bottom: 0.5rem !important;
    }
    main.site-main article .event-meta-info p {
        font-size: 1em !important; /* 約16px（基準とするサイズ） */
        line-height: 1.6 !important;
        margin-bottom: 0.5em !important;
    }

    main.site-main article .single-event-button {
        font-size: 1em !important; /* 約16px */
        padding: 0.6em 1em !important; /* ボタンのパディングを調整 */
        display: inline-block !important; /* displayも上書きする */
        width: auto !important; /* widthも上書きする */
    }
    main.site-main article .single-event-button.mt-4 {
        margin-top: 1rem !important;
    }
    main.site-main article .single-event-button.mt-6 {
        margin-top: 1.5rem !important;
    }


    /* single-event.php の画像高さ調整 (モバイル) */
    .event-thumbnail { /* single-event.phpのサムネイル画像 */
        height: 180px !important;
        width: 100% !important;
        object-fit: cover !important;
        aspect-ratio: 16 / 9;
    }
    
    /* single-event.php の横幅を画面いっぱいに広げる (モバイル) */
    main.site-main {
        max-width: 100% !important;
        padding-left: 1rem !important;
        padding-right: 1rem !important;
    }

    main.site-main article .single-event-content p,
    main.site-main article .single-event-content li {
        font-size: 1em !important; /* 約16px（基準とするサイズ） */
        line-height: 1.6 !important;
    }
    main.site-main article .single-event-content h2 {
        font-size: 1.2em !important; /* 約19px */
    }
    main.site-main article .single-event-content h3 {
        font-size: 1.1em !important; /* 約17px */
    }

    /* ローディングオーバーレイのスタイル（更新） */
    #loading-overlay {
      position: fixed;
      top: 0;
      left: 0;
      width: 100%;
      height: 100%;
      background-color: rgba(255, 255, 255, 0.95);
      display: flex;
      flex-direction: column;
      justify-content: center;
      align-items: center;
      z-index: 10000;
      transition: opacity 0.5s ease-out;
    }

    #lottie-container { }

    #loading-text {
      color: #5a3c3c;
      font-family: 'Mochiy Pop P One', sans-serif;
      font-size: 1.5rem;
      font-weight: bold;
      margin-top: -40px;
      text-shadow: 1px 1px 2px rgba(0,0,0,0.1);
    }

    #event-list .event-card:hover {
      background-color: #fff0f5;
      cursor: pointer;
      transition: background-color 0.3s ease-in-out;
    }

    /* イベント詳細ページのお気に入りボタンのコンテナ */
    main.site-main article .event-buttons-container {
        display: flex !important;
        flex-wrap: wrap !important;
        gap: 1rem !important;
        justify-content: center;
    }

    /* イベント詳細ページのお気に入りボタン本体 */
    main.site-main article .hanabi-favorite-button {
        display: inline-flex !important;
        align-items: center;
        flex-grow: 1;
        max-width: calc(50% - 0.5rem);
    }
}

/* お気に入りフィルタートグルの新デザイン用スタイル */
.favorite-toggle-label {
    display: inline-flex;
    align-items: center;
    padding: 0.5rem 1rem;
    background-color: #f3f4f6; /* 薄いグレー */
    border: 1px solid #fdd835;
    border-radius: 9999px; /* pill shape */
    cursor: pointer;
    transition: all 0.2s ease-in-out;
    font-weight: bold;
    color: #6b7280; /* グレー */
    user-select: none;
    font-size: 0.875rem;
    height: 38px; /* 高さを固定 */
}
.favorite-toggle-label:hover {
    background-color: #e5e7eb;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}
#favorite-filter-toggle:checked + .favorite-toggle-label {
    background-color: #f59e0b;
    color: white;
    border-color: #f59e0b;
}
#favorite-filter-toggle:checked + .favorite-toggle-label .fa-star {
    transform: scale(1.1);
}

/* 全クリアボタンのスタイルを定義して高さを統一 */
.clear-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 1rem;
    background-color: #e5e7eb; /* グレー系 */
    border: 1px solid #d1d5db;
    border-radius: 9999px; /* pill shape */
    cursor: pointer;
    transition: all 0.2s ease-in-out;
    font-weight: bold;
    color: #4b5563;
    user-select: none;
    font-size: 0.875rem;
    height: 38px; /* 高さを固定 */
}
.clear-button:hover {
    background-color: #d1d5db;
}


/* 固定ログインステータスウィジェット用のスタイル */
.login-status-widget-container {
    position: fixed;
    bottom: 25px;
    right: 25px;
    z-index: 9990;
}

.login-status-widget .login-status-menu {
    position: absolute;
    bottom: 70px;
    right: 0;
    width: 200px;
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
    border: 1px solid #ddd;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.25s ease-out;
}

.login-status-widget.logged-in:hover .login-status-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.login-status-menu a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 15px;
    font-size: 14px;
    color: #333;
    text-decoration: none;
    transition: background-color 0.2s;
}

.login-status-menu a:hover {
    background-color: #f5f5f5;
}

.login-status-menu .login-status-userinfo {
    padding: 12px 15px;
    border-bottom: 1px solid #eee;
    font-size: 14px;
    color: #555;
}

.login-status-avatar-wrapper,
.login-status-icon-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(145deg, #1e3a8a, #3b82f6);
    color: white;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    cursor: pointer;
    transition: transform 0.2s ease-out;
}

.login-status-icon-link:hover {
    transform: scale(1.1);
}

.login-status-avatar {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid white;
}

.login-status-icon-link i {
    font-size: 24px;
}

/* 現在の絞り込み条件の表示エリア */
#current-filters-summary.hidden {
    display: none;
}
#current-filters-summary {
    display: block; /* JSでhiddenクラスを外した時に表示されるように */
}

/* 絞り込み条件を表すタグ（ピル）のスタイル */
.filter-pill {
    display: inline-flex;
    align-items: center;
    padding: 0.3rem 0.8rem;
    font-size: 0.8rem;
    font-weight: 600;
    color: #4A5568; /* gray-700 */
    background-color: #E2E8F0; /* gray-200 */
    border-radius: 9999px; /* pill shape */
    border: 1px solid #CBD5E0; /* gray-400 */
}

.filter-pill .icon {
    margin-right: 0.4rem;
    color: #718096; /* gray-500 */
}

/* ▼▼▼ SNSボタン用のCSS（最終修正版） ▼▼▼ */
.custom-sns-share-title {
    font-weight: bold;
    text-align: center;
    margin-bottom: 1rem;
    color: #555;
    font-size: 1rem;
}
.custom-sns-share-buttons ul {
    display: flex;
    justify-content: center;
    gap: 16px;
    list-style: none;
    padding: 0;
    margin: 0;
}
.custom-sns-share-buttons a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 50% !important; /* ボタンを丸くするのを強化 */
    color: #fff !important;
    text-decoration: none;
    transition: opacity 0.2s;
    font-size: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}
.custom-sns-share-buttons a:hover {
    opacity: 0.8;
}
.custom-sns-share-buttons .sns-button-x { background-color: #000000; font-weight: bold; } /* Xの色を黒に */
.custom-sns-share-buttons .sns-button-facebook { background-color: #1877F2; }
.custom-sns-share-buttons .sns-button-hatena { background-color: #00A4DE; }
.custom-sns-share-buttons .sns-button-hatena b { font-family: 'Verdana', sans-serif; font-weight: 900; }
.custom-sns-share-buttons .sns-button-line { background-color: #00B900; }
.custom-sns-share-buttons .sns-button-copy { background-color: #718096; } /* URLコピーボタンの色 */
/* ▲▲▲ ここまで ▲▲▲ */