/* 喜平価格表示コンポーネントのベーススタイル */
.kh-price-section {
    margin-top: 10%;
}

.kh-price-section .kh-price-main-title-wrapper {
}

.kh-price-section .kh-price-main-title {
    font-weight: bold;
}

/* プルダウンセレクター */
.kh-price-selector {
    width: 300px;
    margin: 20px auto;
}

.kh-price-select-wrapper {
    position: relative;
    width: 100%;
}

.kh-price-selector select {
    width: 100%;
    padding: 8px 45px 8px 12px;
    border-radius: 24px;
    border: 1px solid #e60012;
    font-size: 1rem;
    cursor: pointer;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background-color: #fff;
    font-weight: bold;
}

.kh-price-selector select:focus {
    border-color: #e60012;
    /* ボーダー色を赤のまま維持 */
    outline: none;
    /* ブラウザのデフォルトの枠線を削除 */
    box-shadow: none;
    /* 影が付く場合も削除 */
}

/* プルダウンのカスタム矢印（丸） */
.kh-price-select-wrapper::after {
    content: "";
    position: absolute;
    top: 50%;
    right: 12px;
    transform: translateY(-50%);
    width: 14px;
    height: 14px;
    background-color: #e60012;
    border-radius: 50%;
    pointer-events: none;
}

/* プルダウンのカスタム矢印（三角） */
.kh-price-select-wrapper::before {
    content: "";
    position: absolute;
    top: 50%;
    right: 14.65px;
    transform: translateY(-50%) translateY(1px);
    width: 0;
    height: 0;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    border-top: 5px solid #fff;
    z-index: 2;
    pointer-events: none;
}

/* テーブルエリア */
.kh-price-table-area {
    margin-top: 20px;
}

.kh-price-table-container .kh-price-table-title {
    color: #000;
    font-weight: bold;
    text-align: center;
    margin-bottom: 1em;
    padding: 0;
}

/* データテーブルのスタイル */
.kh-price-data-table {
    border-collapse: separate;
    border-spacing: 0;
    width: 100%;
    border: 1px solid #787878;
    border-radius: 12px;
    overflow: hidden;
}

.kh-price-data-table th {
    background-color: #787878;
    color: #fff;
    font-weight: 500;
    padding: 12px;
    text-align: center;
    font-size: 14px;
}

.kh-price-data-table td {
    padding: 12px 8px;
    text-align: center;
}

.kh-price-data-table td.kh-date-col,
.kh-price-data-table td.kh-price-col {
    color: #000;
    font-weight: bold;
    font-size: 20px;
}

/* ▼▼▼ 変更点：ボーダーを行(tr)ではなくセル(td)に適用 ▼▼▼ */
.kh-price-data-table tbody td {
    border-bottom: 1px solid #787878;
}

.kh-price-data-table tbody tr:last-child td {
    border-bottom: none;
    /* 最後の行のボーダーは消す */
}

.kh-price-data-table tbody tr:nth-child(odd) {
    background-color: #f2f2f2;
}

.kh-price-data-table tbody tr:nth-child(even) {
    background-color: #fff;
}

.kh-price-data-table th:nth-child(2),
.kh-price-data-table td:nth-child(2),
.kh-price-data-table th:nth-child(3),
.kh-price-data-table td:nth-child(3) {
    border-left: 1px solid #000;
}

.kh-price-data-table .kh-yen-unit {
    font-size: 12px;
    font-weight: 400;
    margin-left: 3px;
    color: inherit;
}

.kh-price-data-table td.kh-price-col,
.kh-price-data-table td.kh-diff-col {
    text-align: right;
    padding-right: 1em;
}

.kh-diff-plus {
    color: #e60012;
}

.kh-diff-minus {
    color: #007bff;
}

.kh-diff-zero {
    color: #333;
}

.kh-price-table-note {
    font-size: 12px;
    color: #000;
    margin-top: 10px;
}

.kh-price-bottom-link {
    margin-top: 1em;
    text-align: center;
}

.kh-price-bottom-link a {
    color: #e60012;
    text-decoration: underline;
    font-weight: bold;
}

@media (max-width: 767px) {
    .kh-price-selector {
        width: 90%;
    }

    .kh-price-data-table td.kh-price-col,
    .kh-price-data-table td.kh-diff-col {
        padding-right: 0.5em;
    }

    .kh-price-table-container .kh-price-table-title {
        font-size: 3.8vw;
    }
}
