/* 価格表示スタイル */
.cost-display {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    margin: 20px 0;
    padding: 20px;
    background: #ffffff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(69, 84, 108, 0.1);
    position: relative;
    border: 1px solid #799aa3;
}

/* カテゴリタイトル */
.cost-category-title {
    font-size: 14px;
    font-weight: 300;
    color: #799aa3;
    margin-bottom: 10px;
    text-align: right;
    padding: 0px 12px;
    border-radius: 4px;
    display: block;
    align-self: flex-end;
    font-style: italic;
    position: relative;
    margin-left: auto;
    margin-right: 0;
}


/* 価格コンテンツ */
.cost-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    width: 100%;
}

.cost-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    min-width: 120px;
}

.cost-label {
    font-size: 14px;
    color: #799aa3;
    margin-bottom: 8px;
    font-weight: 500;
}

.cost-value {
    font-size: 18px;
    font-weight: bold;
    color: #182b38;
}

/* スライダーコンテナ */
.cost-slider-container {
    flex: 1;
    max-width: 300px;
    margin: 0 20px;
}

/* スライダートラック */
.slider-track {
    position: relative;
    height: 8px;
    background: linear-gradient(90deg, #799aa3, #182b38);
    border-radius: 4px;
    margin: 20px 0 10px 0;
    overflow: visible;
}

/* スライダーフィル */
.slider-fill {
    position: absolute;
    height: 100%;
    background: linear-gradient(90deg, #799aa3, #182b38);
    border-radius: 4px;
    transition: all 0.3s ease;
    box-shadow: inset 0 1px 2px rgba(69, 84, 108, 0.1);
}

/* スライダーサム（つまみ） */
.slider-thumb {
    position: absolute;
    width: 20px;
    height: 20px;
    background: #fff;
    border: 3px solid;
    border-radius: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    z-index: 10;
}

.slider-thumb.low {
    border-color: #182b38;
    background: #182b38;
    color: white;
}

.slider-thumb.high {
    border-color: #182b38;
    background: #182b38;
    color: white;
}

.slider-thumb.median {
    border-color: #fab549;
    background: #fab549;
    width: 16px;
    height: 16px;
    z-index: 15;
}

/* スライダーラベル */
.slider-labels {
    display: flex;
    justify-content: space-between;
    margin-top: 5px;
}

.slider-label.low {
    font-size: 12px;
    color: #799aa3;
    font-weight: 500;
}

.slider-label.high {
    font-size: 12px;
    color: #182b38;
    font-weight: 500;
}

/* ホバー効果 */
.slider-thumb:hover {
    transform: translate(-50%, -50%) scale(1.2);
    box-shadow: 0 4px 8px rgba(0,0,0,0.3);
}

/* ツールチップ風の表示 */
.slider-thumb::after {
    content: attr(data-value);
    position: absolute;
    top: -30px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0,0,0,0.8);
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    white-space: nowrap;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.slider-thumb:hover::after {
    opacity: 1;
}

/* レスポンシブ対応 */
@media (max-width: 768px) {
    .cost-display {
        padding: 15px;
        margin: 15px 0;
        width: 100%;
        box-sizing: border-box;
    }
    
    .cost-category-title {
        font-size: 14px;
        margin-bottom: 15px;
        padding: 6px 10px;
        text-align: center;
        align-self: center;
        width: 100%;
    }
    
    .cost-content {
        flex-direction: column;
        gap: 15px;
        width: 100%;
    }
    
    .cost-slider-container {
        width: 100%;
        max-width: 100%;
        margin: 15px 0;
    }
    
    .cost-item {
        min-width: auto;
        width: 100%;
        text-align: center;
    }
    
    .slider-track {
        width: 100%;
        margin: 20px 0 10px 0;
    }
    
    .slider-labels {
        width: 100%;
        justify-content: space-between;
    }
}

/* スマートフォン専用対応 */
@media (max-width: 480px) {
    .cost-display {
        padding: 12px;
        margin: 10px 0;
        width: 100%;
        min-width: 100%;
    }
    
    .cost-category-title {
        font-size: 13px;
        margin-bottom: 12px;
        padding: 5px 8px;
    }
    
    .cost-content {
        gap: 12px;
    }
    
    .cost-item {
        padding: 0 5px;
    }
    
    .cost-label {
        font-size: 13px;
    }
    
    .cost-value {
        font-size: 16px;
    }
    
    .slider-track {
        height: 6px;
        margin: 15px 0 8px 0;
    }
    
    .slider-thumb {
        width: 18px;
        height: 18px;
    }
    
    .slider-thumb.median {
        width: 14px;
        height: 14px;
    }
    
    .slider-label {
        font-size: 11px;
    }
}

/* ホバー効果 */
.cost-display:hover {
    box-shadow: 0 4px 12px rgba(69, 84, 108, 0.15);
    transition: box-shadow 0.3s ease;
}

.cost-value:hover {
    color: #799aa3;
    transition: color 0.3s ease;
}
