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

/* ====================================
   リスト部分のデザイン
   ==================================== */
/* トップページ・アーカイブ用のクラス(.home-music-list)もここに追加 */
.music-list-container,
.home-music-list { 
    margin-top: 20px; 
    border-top: 2px solid #ddd; 
}

.music-item { display: flex; flex-wrap: wrap; justify-content: space-between; padding: 20px 0; border-bottom: 2px dashed #ddd; align-items: flex-start; }
.music-info { width: 70%; padding-right: 20px; box-sizing: border-box; }
.music-title { font-size: 1.2em; font-weight: bold; color: #008080; margin: 0 0 10px 0; }
.music-meta { font-size: 0.9em; color: #666; margin-bottom: 10px; display: flex; gap: 15px; align-items: center; }
.music-actions { width: 28%; display: flex; gap: 10px; justify-content: flex-end; align-items: center; }

/* ボタン類 */
.btn-download, .btn-play {
    display: flex; justify-content: center; align-items: center;
    width: 50px; height: 50px; border-radius: 5px; text-decoration: none; transition: 0.3s; border: none; cursor: pointer;
}
.btn-download { background-color: #dbe4eb; color: #5d7ca3; }
.btn-download:hover { background-color: #cdd6dd; }
.btn-download .dashicons { font-size: 24px; }
.btn-play { background-color: #e5e5e5; color: #555; }
.btn-play:hover { background-color: #d4d4d4; color: #000; }
.btn-play .dashicons { font-size: 30px; width: 30px; height: 30px; }

/* ====================================
   PCレイアウト（詳細ページ ＆ アーカイブページ対応）
   ==================================== */
@media screen and (min-width: 835px) {
  /* body.archive（一覧ページ）を追加して適用範囲を広げました */
  body.single .content, body.single #content, body.single #inner-content, body.single .wrap,
  body.archive .content, body.archive #content, body.archive #inner-content, body.archive .wrap {
    background-color: transparent !important; border: none !important; box-shadow: none !important;
  }
  
  /* 横並びの指定 */
  body.single #inner-content,
  body.archive #inner-content {
    display: flex !important; justify-content: space-between; align-items: flex-start; gap: 30px; width: 100%; box-sizing: border-box;
  }
  
  /* メインコンテンツ（左） */
  body.single .main,
  body.archive .main {
    flex: 1; width: auto !important; background-color: #fff !important; padding: 30px !important; border-radius: 5px; margin: 0 !important; min-width: 0; box-shadow: 0 2px 5px rgba(0,0,0,0.05);
  }
  
  /* サイドバー（右） */
  body.single .sidebar,
  body.archive .sidebar {
    width: 336px !important; flex-shrink: 0; background-color: #fff !important; padding: 20px !important; border-radius: 5px; margin: 0 !important; display: block; box-shadow: 0 2px 5px rgba(0,0,0,0.05);
  }
}

/* ====================================
   MusMus風 浮遊型プレイヤー (完全非表示修正版)
   ==================================== */
#musmus-player {
    position: fixed;
    bottom: 60px;
    left: 50%;
    
    /* ★修正箇所：初期状態は画面外＆透明＆操作不可 */
    transform: translateX(-50%) translateY(200%);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    
    width: 95%;
    max-width: 1000px;
    height: 75px;
    
    background-color: #222 !important;
    color: #fff;
    border-radius: 10px;
    z-index: 2147483647;
    transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 5px 20px rgba(0,0,0,0.4);
    
    display: flex;
    justify-content: center;
    overflow: visible;
}

#musmus-player.is-active {
    /* ★修正箇所：再生時は元の位置＆不透明＆操作可能 */
    transform: translateX(-50%) translateY(0);
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

/* プログレスバー */
.player-progress-container {
    position: absolute;
    top: 0;
    left: 10px;
    right: 10px;
    width: auto;
    height: 4px;
    background-color: rgba(255,255,255,0.2);
    cursor: pointer;
    z-index: 10;
    border-radius: 2px;
}
.player-progress-bar {
    width: 0%;
    height: 100%;
    background-color: #ff9800;
    border-radius: 2px;
    position: relative;
}
.player-progress-bar::after {
    content: '';
    position: absolute;
    right: -4px;
    top: -3px;
    width: 10px;
    height: 10px;
    background-color: #fff;
    border-radius: 50%;
    box-shadow: 0 1px 3px rgba(0,0,0,0.3);
}

/* コントロールエリア */
.player-controls-body {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 25px;
    box-sizing: border-box;
}

/* 曲情報 */
.player-info {
    width: 250px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: center;
}
#player-title {
    font-size: 15px;
    font-weight: bold;
    color: #fff !important;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 2px;
    text-align: left;
}
#player-time {
    font-size: 12px;
    color: #bbb;
    text-align: left;
}

/* 中央ボタン */
.player-center-controls {
    display: flex;
    align-items: center;
    gap: 25px;
}
.ctrl-btn {
    background: none;
    border: none;
    color: #ddd;
    cursor: pointer;
    padding: 0;
    display: flex;
    align-items: center;
    transition: all 0.2s;
}
.ctrl-btn:hover { color: #fff; transform: scale(1.1); }
.ctrl-btn .dashicons { font-size: 28px; width: 28px; height: 28px; }
#ctrl-play .dashicons { font-size: 46px; width: 46px; height: 46px; color: #fff; }

/* 右側ボタン */
.player-right-controls {
    width: 250px;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 15px;
}

/* 音量バー */
.volume-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    height: 50px;
}
.volume-slider-popup {
    position: absolute;
    bottom: 45px;
    left: 50%;
    transform: translateX(-50%);
    width: 36px;
    height: 110px;
    background-color: #333;
    border-radius: 6px;
    display: none;
    justify-content: center;
    align-items: center;
    box-shadow: 0 4px 10px rgba(0,0,0,0.5);
    z-index: 100;
    padding-bottom: 5px;
}
.volume-slider-popup::after {
    content: '';
    position: absolute;
    bottom: -6px;
    left: 50%;
    transform: translateX(-50%);
    border-left: 6px solid transparent;
    border-right: 6px solid transparent;
    border-top: 6px solid #333;
}
.volume-wrapper:hover .volume-slider-popup {
    display: flex;
}
#volume-slider {
    transform: rotate(-90deg);
    width: 90px;
    height: 5px;
    cursor: pointer;
}
/* ★音量アイコン専用スタイル */
#ctrl-volume-icon .dashicons {
    color: #ddd;
    font-size: 28px;
    width: 28px;
    height: 28px;
}
#ctrl-volume-icon:hover .dashicons {
    color: #fff;
}

/* スマホ表示 */
@media screen and (max-width: 768px) {
    #musmus-player { 
        width: 95%; 
        height: auto; 
        padding-bottom: 10px; 
        flex-wrap: wrap; 
        bottom: 20px; /* スマホは少し下でもOK */
    }
    .player-controls-body { flex-direction: column; padding: 15px 10px; gap: 10px; }
    .player-info { width: 100%; text-align: center; }
    #player-title, #player-time { text-align: center; }
    .player-center-controls { margin: 5px 0; }
    .player-right-controls { width: 100%; justify-content: center; }
}

/* ====================================
   トップページ専用デザイン（甘茶さん風）
   ==================================== */

/* --- 1. 紹介文エリア --- */
.top-intro-box {
    background-color: #fff;
    border: 3px solid #66bb6a; /* 甘茶さん風の緑枠 */
    padding: 20px;
    margin-bottom: 30px;
    border-radius: 5px;
}
.top-intro-title {
    font-size: 1.4em;
    font-weight: bold;
    color: #2e7d32; /* 濃い緑 */
    margin-bottom: 10px;
    border-bottom: 1px solid #ddd;
    padding-bottom: 5px;
}
.top-intro-text {
    font-size: 0.95em;
    line-height: 1.8;
    color: #333;
}

/* --- 2. 新着楽曲リスト（ボックス型） --- */
.home-music-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.music-box-item {
    background-color: #f5f5f5; /* 薄いグレー背景 */
    border: 1px solid #ccc;
    border-radius: 4px;
    padding: 15px;
}

/* ヘッダー部分（曲名と日付） */
.music-box-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #ddd;
    padding-bottom: 10px;
    margin-bottom: 10px;
}
.music-box-title {
    font-size: 1.2em;
    margin: 0;
    color: #333;
}
.music-box-date {
    font-size: 0.85em;
    color: #666;
}

/* コンテンツ部分（横並び） */
.music-box-body {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
}

/* 左：再生ボタン */
.music-box-play-area {
    display: flex;
    align-items: center;
    gap: 10px;
}
.btn-play-square {
    background-color: #4caf50; /* 甘茶さん風の緑 */
    color: white;
    border: none;
    border-radius: 3px;
    width: 40px;
    height: 40px;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: 0.3s;
}
.btn-play-square:hover {
    background-color: #43a047;
}
.btn-play-square .dashicons {
    font-size: 24px;
    width: 24px;
    height: 24px;
}
.play-label {
    font-weight: bold;
    color: #4caf50;
    font-size: 0.9em;
}

/* 中央：情報 */
.music-box-info {
    flex: 1;
    display: flex;
    gap: 15px;
    font-size: 0.9em;
    color: #555;
    flex-wrap: wrap;
}
.info-tag {
    display: flex;
    align-items: center;
}
.info-tag .dashicons {
    margin-right: 4px;
    color: #888;
}

/* 右：ダウンロードボタン */
.music-box-download {
    text-align: right;
}
.btn-dl-rect {
    display: inline-block;
    background-color: #2196f3; /* 青色 */
    color: white;
    text-decoration: none;
    padding: 8px 15px;
    border-radius: 3px;
    font-size: 0.9em;
    font-weight: bold;
    transition: 0.3s;
}
.btn-dl-rect:hover {
    background-color: #1e88e5;
    color: #fff;
}
.btn-dl-rect .dashicons {
    vertical-align: middle;
    margin-right: 3px;
}

/* スマホ対応 */
@media screen and (max-width: 600px) {
    .music-box-body {
        flex-direction: column;
        align-items: flex-start;
    }
    .music-box-download {
        width: 100%;
        text-align: center;
        margin-top: 10px;
    }
    .btn-dl-rect {
        display: block;
        width: 100%;
        box-sizing: border-box;
    }
}

/* ====================================
   アーカイブページ（カテゴリー等）の調整
   ==================================== */

/* タイトル部分のデザイン */
.archive-title {
    font-size: 1.4em;
    font-weight: bold;
    color: #333;
    background-color: #fff;
    padding: 15px;
    margin-bottom: 20px;
    border-left: 5px solid #66bb6a; /* 甘茶さん風の緑 */
    border-radius: 3px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

/* タイトルの中にある余計な文字サイズ調整をリセット */
.archive-title span {
    font-size: inherit;
}

/* ====================================
   サイドバーメニューの投稿数デザイン
   ==================================== */

/* メニューのリンクを横並びレイアウトにする */
.widget_nav_menu ul li a {
    display: flex !important;
    justify-content: space-between; /* 文字と数字を両端に配置 */
    align-items: center;
    width: 100%;
}

/* 数字（カウント）のデザイン */
.menu-count {
    font-size: 0.85em;
    color: #666;
    background-color: #eee; /* 薄いグレーの背景 */
    padding: 2px 8px;       /* 数字周りの余白 */
    border-radius: 10px;    /* 丸くする */
    margin-left: 10px;
    min-width: 20px;
    text-align: center;
}

/* ホバー時に数字の色も変える（お好みで） */
.widget_nav_menu ul li a:hover .menu-count {
    background-color: #fff;
    color: #333;
}

/* ====================================
   曲解説（アコーディオン）用スタイル
   ==================================== */

/* タイトル周りの調整 */
.music-box-title-wrap {
    display: flex;
    align-items: center;
    gap: 15px; /* タイトルとボタンの間隔 */
    flex-wrap: wrap;
}

/* 解説ボタンのデザイン */
.btn-desc-toggle {
    background-color: #fff;
    border: 1px solid #66bb6a; /* 緑の枠線 */
    color: #66bb6a;
    font-size: 0.85em;
    padding: 4px 12px;
    border-radius: 20px;
    cursor: pointer;
    transition: 0.3s;
    display: flex;
    align-items: center;
    gap: 4px;
}
.btn-desc-toggle:hover {
    background-color: #66bb6a;
    color: #fff;
}
/* 開いている時のボタン */
.btn-desc-toggle.is-open {
    background-color: #66bb6a;
    color: #fff;
}
.btn-desc-toggle.is-open .dashicons {
    transform: rotate(180deg); /* 矢印をひっくり返す */
}

/* 解説エリア（最初は隠す） */
.music-desc-area {
    height: 0;
    overflow: hidden;
    opacity: 0;
    transition: all 0.4s ease; /* ぬるっと開くアニメーション */
    border-bottom: 1px dashed #ddd;
    margin-bottom: 0;
}

/* 開いた時のスタイル */
.music-desc-area.is-open {
    height: auto;
    opacity: 1;
    margin-bottom: 15px;
    padding: 10px 0;
}

.music-desc-content {
    font-size: 0.95em;
    line-height: 1.8;
    color: #444;
    padding: 10px;
    background-color: #f9fdf9; /* ほんのり緑の背景 */
    border-radius: 4px;
}

/* --- プレイヤーの新機能ボタン用スタイル --- */

/* ランダム・リピートボタンの基本 */
.sub-ctrl .dashicons {
    font-size: 20px;
    width: 20px;
    height: 20px;
    color: #888; /* 最初はグレー */
}

/* 機能がONになった時のスタイル */
.ctrl-btn.is-active .dashicons {
    color: #66bb6a; /* 緑色に光る */
    text-shadow: 0 0 5px rgba(102, 187, 106, 0.5);
}

/* スマホでの配置調整 */
@media screen and (max-width: 768px) {
    .player-center-controls {
        gap: 15px; /* ボタン同士の間隔を調整 */
        width: 100%;
        justify-content: center;
    }
}

/* ====================================
   アーカイブページの表示変更（プレイヤー化）
   ==================================== */

/* アーカイブページ（カテゴリーなど）において */
.archive .entry-card-wrap,
.search .entry-card-wrap {
    /* カード自体の装飾をリセット */
    background: none !important;
    border: none !important;
    box-shadow: none !important;
    padding: 0 !important;
    margin-bottom: 20px !important;
}

/* プレイヤーを表示させるので、元の「サムネイル」「タイトル」「抜粋文」は消す */
.archive .entry-card-thumb,
.archive .entry-card-title,
.archive .entry-card-snippet,
.archive .entry-card-meta,
.search .entry-card-thumb,
.search .entry-card-title,
.search .entry-card-snippet,
.search .entry-card-meta {
    display: none !important;
}

/* リンク（aタグ）の干渉を防ぐ */
.archive .entry-card-wrap a.entry-card-link,
.search .entry-card-wrap a.entry-card-link {
    display: none !important; /* カード全体を覆うリンクを無効化 */
}

/* プレイヤー部分のスタイル微調整 */
.archive-player-item {
    width: 100%;
    margin: 0 auto;
    /* トップページと同じ影をつける */
    box-shadow: 0 2px 5px rgba(0,0,0,0.1); 
    background-color: #f5f5f5; /* 薄いグレー */
}

/* ====================================
   グローバルナビの巨大化（可変幅・完全版）
   ==================================== */

/* 1. バー全体の高さを90pxに固定 */
#navi, #navi .navi-in {
    height: 90px !important;
}

/* 2. ボタンの調整：文字数に合わせて横幅を自動で広げる */
#navi .navi-in .menu-header .menu-item a {
    font-size: 24px !important;    /* 文字サイズ */
    font-weight: bold !important;
    height: 90px !important;       /* バーの高さと同じ */
    padding: 0 25px !important;    /* 左右のゆとり（ここを減らすと横幅を詰められます） */
    display: flex !important;      
    align-items: center !important; 
    justify-content: center !important; 
    width: auto !important;        /* ★横幅を自動（可変）にする */
    min-width: 100px !important;   /* 最低限の幅 */
    text-decoration: none !important;
}

/* 3. 文字ラベルの調整：改行を絶対にさせない */
#navi .navi-in .menu-header .menu-item a .item-label {
    width: auto !important;
    max-width: none !important;
    overflow: visible !important;
    white-space: nowrap !important; /* ★絶対に改行・途切れをさせない */
    line-height: normal !important; 
}

/* 4. メニュー全体の配置：一列に並べる */
#navi .navi-in .menu-header {
    display: flex !important;
    justify-content: center !important; /* 中央寄せ（お好みで） */
    flex-wrap: nowrap !important;       /* 折り返しを禁止 */
}