@charset "utf-8";

/* =========================================
   アニメーションの定義
========================================= */
@keyframes spsFadeInUp {
    from { opacity: 0; transform: translateY(15px); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes spsBarGrow {
    from { width: 0%; }
    to { width: var(--bar-width, 0%); }
}

/* =========================================
   タイトル・ベース
========================================= */
.sect-review {
    margin: 50px auto;
}
.sect-review h2 {
    background: url("https://www.mushikichi.com/pic-labo/title_bar01-new.gif") no-repeat;
    background-size: cover;
}
.sps-review-wrap {
    margin: 0 auto;
    font-family: "Hiragino Kaku Gothic ProN", "Meiryo", "Noto Sans JP", "游ゴシック体", YuGothic, "游ゴシック Medium", "Yu Gothic Medium", "游ゴシック", "Yu Gothic", "Lucida Grande", "ヒラギノ角ゴ Pro W3", "Hiragino Kaku Gothic Pro", sans-serif;
    color: #333;
}

/* =========================================
   サマリー全体
========================================= */
.sps-review-summary {
    display: flex;
    align-items: center;
    gap: 40px;
    margin: 20px 0 30px;
    padding: 20px;
    background: #f5f5f5;
    border-radius: 5px;
    cursor: pointer;
    animation: spsFadeInUp 0.6s ease-out forwards;
}

/* 左側の総合評価エリア */
.sps-score-box {
    min-width: 200px;
    text-align: center;
}
.sps-score-num { 
    font-size: 40px;
    font-weight: bold; 
    line-height: 1.2;
    color: #333; 
}

/* 星マークのデザイン */
.sps-score-stars {
    display: inline-flex;
    gap: 2px;
    margin: 5px 0;
    font-size: 20px;
}
.sps-star {
    display: inline-block;
    color: transparent;
    background-image: linear-gradient(to right, #ff9e00 0%, #ff9e00 var(--star-percent, 0%), #e0e0e0 var(--star-percent, 0%), #e0e0e0 100%);
    -webkit-background-clip: text;
    background-clip: text;
}

.sps-review-count { 
    font-size: 13px; 
    color: #0066c0; 
    text-decoration: none; 
}
.sps-review-count:hover {
    text-decoration: underline;
}

/* 右側のグラフエリア */
.sps-graph-box { 
    flex-grow: 1; 
}
.sps-graph-row { 
    display: flex; 
    align-items: center; 
    margin-bottom: 4px;
    font-size: 13px; 
    color: #555;
}
.sps-graph-bar-bg {
    flex-grow: 1;
    height: 10px;
    margin: 0 10px;
    background-color: #eee;
    border-radius: 5px;
    overflow: hidden;
}
.sps-graph-bar-fill { 
    width: 0%; 
    height: 100%; 
    background-color: #ff9e00; 
    animation: spsBarGrow 1s cubic-bezier(0.2, 0.8, 0.2, 1) forwards; 
}
.sps-graph-percent {
    width: 30px;
    text-align: right;
}

/* =========================================
   検索・絞り込み・ソート 領域
========================================= */
.sps-filter-container {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    gap: 12px;
    margin: 15px 0;
}

/* 各種ボックス共通デザイン */
.sps-search-box, 
.sps-filter-box, 
.sps-sort-box {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    padding: 6px 12px;
    box-sizing: border-box;
    background-color: #f5f5f5;
    border-radius: 5px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
}
.sps-search-box input[type="text"] {
    border: none;
}

.sps-filter-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    color: #6b7280;
}

/* 検索入力欄 */
.sps-search-input {
    width: 100%;
    background: transparent;
    border: none;
    outline: none;
    font-size: 14px;
    color: #374151;
}

/* セレクトボックス共通 */
.sps-select-input {
    width: 100%;
    background: transparent;
    border: none;
    outline: none;
    cursor: pointer;
    font-size: 14px;
    color: #374151;
}

@media (min-width: 640px) {
    .sps-filter-container {
        flex-direction: row;
        align-items: center;
    }
    .sps-search-box, 
    .sps-filter-box, 
    .sps-sort-box {
        width: auto;
    }
    .sps-search-input {
        width: 150px;
    }
}

/* =========================================
   個別レビューカード
========================================= */
.sps-review-cards {
    margin-bottom: 20px;
}
.sps-review-stars-color {
    font-size: 16px;
    color: #ff9e00;
}
.sps-load-more-area {
    text-align: center;
}
.sps-action-btn {
    margin-top: 10px;
}
.sps-no-review,
.sps-no-match {
    padding: 20px;
    text-align: center;
    color: #666;
}

.sps-review-card {
    margin-bottom: 15px;
    padding: 20px;
    background: #f5f5f5;
    border-radius: 5px;
    letter-spacing: 1px;
    opacity: 0;
    animation: spsFadeInUp 0.5s ease-out forwards;
}

/* ユーザー名と日付 */
.sps-review-meta {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 8px;
    font-size: 12px;
    color: #777;
}
.sps-review-user { 
    font-weight: bold;
    color: #333;
}

/* 星とタイトル */
.sps-review-header { 
    display: flex; 
    align-items: center; 
    gap: 10px; 
    margin-bottom: 10px; 
}
.sps-review-title { 
    display: -webkit-box; 
    margin: 0; 
    overflow: hidden; 
    font-size: 16px; 
    font-weight: bold; 
    color: #333;
    -webkit-line-clamp: 1; 
    -webkit-box-orient: vertical; 
}

/* レビュー本文 */
.sps-review-card .sps-review-text {
    display: block;
    margin: 0;
    font-size: 14px;
    line-height: 1.7;
    color: #333;
}

/* =========================================
   もっと見る等のボタンデザイン
========================================= */
.Button--blueTransparent { 
    display: block; 
    width: 100%; 
    margin-top: 15px; 
    padding: 14px; 
    background-color: #fff;
    border: 1px solid #ccc;
    border-radius: 4px; 
    text-align: center; 
    cursor: pointer; 
    font-size: 14px;
    font-weight: bold; 
    color: #333;
    transition: all 0.2s ease; 
}
.Button--blueTransparent:hover { 
    background-color: #f9f9f9; 
    border-color: #999;
}

/* =========================================
   店舗からの返信コメント（吹き出しデザイン）
========================================= */
.sps-shop-comment-wrap {
    position: relative;
    margin-top: 10px;
    padding: 10px;
    background-color: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 5px;
}

/* 吹き出しの三角（しっぽ）部分を作成 */
.sps-shop-comment-wrap::before {
    content: "";
    position: absolute;
    top: -8px;
    left: 25px;
    border-bottom: 8px solid #fff;
    border-left: 9px solid transparent;
    border-right: 9px solid transparent;
    z-index: 2;
}
.sps-shop-comment-wrap::after {
    content: "";
    position: absolute;
    top: -10px;
    left: 24px;
    border-bottom: 10px solid #e0e0e0;
    border-left: 10px solid transparent;
    border-right: 10px solid transparent;
    z-index: 1;
}

/* 返信ヘッダー部分 */
.sps-shop-comment-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 5px;
    font-weight: bold;
    color: #0066cc;
}

/* 「店舗からの返信」という目立つラベル */
.sps-shop-comment-label {
    padding: 2px 10px;
    background-color: #666;
    border-radius: 0;
    font-size: 11px;
    font-weight: normal;
    color: #fff;
    letter-spacing: 0.5px;
}

/* 返信日 */
.sps-shop-comment-date {
    margin-left: 0;
    font-size: 12px;
    color: #666;
}

/* 返信本文 */
.sps-shop-comment-text {
    font-size: 13px;
    line-height: 1.6;
    color: #444;
}

/* =========================================
   スマホ用 (max-width:580px)
========================================= */
@media screen and (max-width: 580px) {
    /* サマリー全体を縦並びに */
    .sps-review-summary {
        justify-content: space-between;
        gap: unset;
        padding: 20px 5%;
    }

    /* 左側の総合評価エリアの下余白を追加 */
    .sps-score-box {
        min-width: unset;
        max-width: 40%;
        margin: 0;
    }
    
    /* 文字サイズの微調整 */
    .sps-score-stars {
        font-size: 17px;
    }
    .sps-review-count {
        font-size: 12px;
    }

    /* 右側のグラフエリア */
    .sps-graph-box {
        flex-grow: unset;
        width: 60%;
    }
    .sps-graph-row {
        line-height: 1.4;
    }
    .sps-graph-bar-bg {
        margin: 0 0 0 10px;
    }
}