
.btmh-gpp-card {
    --btmh-red: #a91414;
    --btmh-green: #12763d;
    --btmh-border: #eadfcd;
    margin: 24px 0;
    overflow: hidden;
    border: 1px solid var(--btmh-border);
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 10px 30px rgba(58, 41, 12, .07);
}

.btmh-gpp-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 18px 20px;
    border-bottom: 1px solid var(--btmh-border);
    background: linear-gradient(135deg, #fff8e9 0%, #fff 72%);
}

.btmh-gpp-header h2 {
    margin: 0 0 6px;
    color: #211b10;
    font-size: clamp(21px, 2.6vw, 29px);
    line-height: 1.3;
}

.btmh-gpp-updated,
.btmh-gpp-unit,
.btmh-gpp-source {
    color: #6d6557;
    font-size: 14px;
}

.btmh-gpp-unit {
    padding: 7px 11px;
    white-space: nowrap;
    border: 1px solid #eadfc9;
    border-radius: 999px;
    background: #fff;
}

.btmh-gpp-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    margin-right: 7px;
    border-radius: 50%;
    background: #15904a;
    box-shadow: 0 0 0 4px rgba(21, 144, 74, .12);
}

.btmh-gpp-table-wrap {
    width: 100%;
    overflow-x: auto;
}

.btmh-gpp-table {
    width: 100%;
    margin: 0;
    border: 0;
    border-collapse: collapse;
}

.btmh-gpp-table th,
.btmh-gpp-table td {
    padding: 14px 16px;
    border: 0;
    border-bottom: 1px solid #eee8dd;
    text-align: right;
    vertical-align: middle;
}

.btmh-gpp-table th:first-child,
.btmh-gpp-table td:first-child {
    width: 45%;
    text-align: left;
}

.btmh-gpp-table thead th {
    background: #871515;
    color: #fff;
    font-size: 14px;
}

.btmh-gpp-table tbody tr:nth-child(even) {
    background: #fffdf8;
}

.btmh-gpp-table tbody tr:hover {
    background: #fff7e6;
}

.btmh-gpp-price {
    white-space: nowrap;
    font-weight: 700;
}

.btmh-gpp-buy {
    color: var(--btmh-green);
}

.btmh-gpp-sell {
    color: var(--btmh-red);
}

.btmh-gpp-source {
    padding: 12px 18px;
    background: #fcfbf8;
}

.btmh-gpp-note {
    margin: -10px 0 24px;
    padding: 15px 18px;
    border: 1px solid #eadfc6;
    border-left: 4px solid #ac7b20;
    border-radius: 10px;
    background: #fffaf0;
    color: #463b29;
    line-height: 1.65;
}

.btmh-gpp-error {
    margin: 18px 0;
    padding: 14px 16px;
    border: 1px solid #efc2bd;
    border-left: 4px solid #b42318;
    border-radius: 9px;
    background: #fff5f4;
    color: #7a271a;
}

@media (max-width: 680px) {
    .btmh-gpp-header {
        align-items: flex-start;
        flex-direction: column;
        padding: 15px;
    }

    .btmh-gpp-unit {
        font-size: 12px;
    }

    .btmh-gpp-table,
    .btmh-gpp-table tbody,
    .btmh-gpp-table tr,
    .btmh-gpp-table td {
        display: block;
        width: 100%;
    }

    .btmh-gpp-table thead {
        display: none;
    }

    .btmh-gpp-table tbody tr {
        padding: 10px 14px;
        border-bottom: 8px solid #f4efe5;
    }

    .btmh-gpp-table tbody tr:last-child {
        border-bottom: 0;
    }

    .btmh-gpp-table td,
    .btmh-gpp-table td:first-child {
        width: 100%;
        padding: 7px 0;
        border-bottom: 1px dashed #e2d8c7;
        text-align: right;
    }

    .btmh-gpp-table td:last-child {
        border-bottom: 0;
    }

    .btmh-gpp-table td::before {
        content: attr(data-label);
        float: left;
        margin-right: 14px;
        color: #706654;
        font-weight: 500;
    }

    .btmh-gpp-table td:first-child {
        padding-bottom: 10px;
        text-align: left;
        font-size: 16px;
    }

    .btmh-gpp-table td:first-child::before {
        display: none;
    }
}


.btmh-gpp-analysis-box,
.btmh-gpp-chart-card {
    margin: 24px 0;
    border: 1px solid #eadfcd;
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 10px 30px rgba(58, 41, 12, .06);
}
.btmh-gpp-analysis-box {
    padding: 20px 24px;
    border-left: 5px solid #c79720;
    background: #fffdf8;
}
.btmh-gpp-analysis-box h3,
.btmh-gpp-chart-card h3 {
    margin: 0 0 14px;
    color: #251d10;
    font-size: 22px;
}
.btmh-gpp-analysis-list p {
    margin: 0;
    padding: 10px 0;
    border-bottom: 1px dashed #e8dfcf;
    line-height: 1.65;
}
.btmh-gpp-analysis-list p:last-child { border-bottom: 0; }
.btmh-gpp-analysis-dash { margin-right: 5px; color: #a57413; }
.btmh-gpp-chart-card { padding: 20px; }
.btmh-gpp-chart-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 18px;
    margin-bottom: 12px;
}
.btmh-gpp-chart-head h3 { margin-bottom: 4px; }
.btmh-gpp-chart-head p { margin: 0; color: #716756; }
.btmh-gpp-chart-periods { display: flex; gap: 7px; flex-wrap: wrap; }
.btmh-gpp-chart-periods button {
    border: 1px solid #dfd2b9;
    border-radius: 999px;
    padding: 7px 12px;
    background: #fff;
    color: #5c503c;
    cursor: pointer;
}
.btmh-gpp-chart-periods button.is-active {
    border-color: #9d7018;
    background: #9d7018;
    color: #fff;
}
.btmh-gpp-chart { min-height: 300px; position: relative; }
.btmh-gpp-chart svg { display: block; width: 100%; height: 300px; overflow: visible; }
.btmh-gpp-chart-empty {
    display: flex;
    min-height: 260px;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #766d5d;
    background: #fcfaf5;
    border-radius: 10px;
}
.btmh-gpp-chart-legend { display: flex; gap: 20px; margin-top: 8px; color: #625846; font-size: 14px; }
.btmh-gpp-chart-legend i { display: inline-block; width: 20px; height: 3px; margin-right: 7px; vertical-align: middle; border-radius: 4px; }
.btmh-gpp-legend-buy { background: #167744; }
.btmh-gpp-legend-sell { background: #a91414; }
.btmh-gpp-chart-hint { margin: 12px 0 0; color: #756b5b; font-size: 14px; }
@media (max-width: 680px) {
    .btmh-gpp-analysis-box, .btmh-gpp-chart-card { padding: 15px; border-radius: 11px; }
    .btmh-gpp-chart-head { flex-direction: column; }
    .btmh-gpp-chart { min-height: 260px; overflow-x: auto; }
    .btmh-gpp-chart svg { min-width: 620px; height: 270px; }
}

/* Biểu đồ dạng accordion, mặc định đóng */
.btmh-gpp-chart-accordion {
    margin: 24px 0;
    overflow: hidden;
    border: 1px solid #e6d9bf;
    border-radius: 13px;
    background: #fff;
}
.btmh-gpp-chart-toggle {
    display: flex;
    width: 100%;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin: 0;
    padding: 16px 19px;
    border: 0;
    background: linear-gradient(135deg, #bd8d22, #9e6f12);
    color: #fff;
    cursor: pointer;
    font: inherit;
    font-weight: 700;
    text-align: left;
}
.btmh-gpp-chart-toggle:hover,
.btmh-gpp-chart-toggle:focus-visible {
    filter: brightness(.97);
}
.btmh-gpp-chart-toggle-label {
    display: inline-flex;
    align-items: center;
    gap: 10px;
}
.btmh-gpp-chart-toggle-icon {
    font-size: 20px;
    line-height: 1;
}
.btmh-gpp-chart-toggle-arrow {
    font-size: 25px;
    line-height: 1;
    transition: transform .22s ease;
}
.btmh-gpp-chart-accordion.is-open .btmh-gpp-chart-toggle-arrow {
    transform: rotate(180deg);
}
.btmh-gpp-chart-panel[hidden] {
    display: none !important;
}
.btmh-gpp-chart-panel {
    border-top: 1px solid #eadfcd;
}
.btmh-gpp-chart-accordion .btmh-gpp-chart-card {
    margin: 0;
    border: 0;
    border-radius: 0;
    box-shadow: none;
}
@media (max-width: 680px) {
    .btmh-gpp-chart-toggle {
        padding: 14px 15px;
        font-size: 15px;
    }
}

/* Accordion dùng chung cho phần phân tích và biểu đồ */
.btmh-gpp-accordion {
    margin: 18px 0;
    overflow: hidden;
    border: 1px solid #e6d9bf;
    border-radius: 13px;
    background: #fff;
}
.btmh-gpp-accordion-toggle {
    display: flex;
    width: 100%;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin: 0;
    padding: 16px 19px;
    border: 0;
    background: linear-gradient(135deg, #bd8d22, #9e6f12);
    color: #fff;
    cursor: pointer;
    font: inherit;
    font-weight: 700;
    text-align: left;
}
.btmh-gpp-accordion-toggle:hover,
.btmh-gpp-accordion-toggle:focus-visible {
    filter: brightness(.97);
}
.btmh-gpp-accordion-label {
    display: inline-flex;
    align-items: center;
    gap: 10px;
}
.btmh-gpp-accordion-icon {
    font-size: 20px;
    line-height: 1;
}
.btmh-gpp-accordion-arrow {
    font-size: 25px;
    line-height: 1;
    transition: transform .22s ease;
}
.btmh-gpp-accordion.is-open > .btmh-gpp-accordion-toggle .btmh-gpp-accordion-arrow {
    transform: rotate(180deg);
}
.btmh-gpp-accordion-panel[hidden] {
    display: none !important;
}
.btmh-gpp-accordion-panel {
    border-top: 1px solid #eadfcd;
}
.btmh-gpp-analysis-accordion .btmh-gpp-analysis-box {
    margin: 0;
    border: 0;
    border-left: 0;
    border-radius: 0;
    box-shadow: none;
}
@media (max-width: 680px) {
    .btmh-gpp-accordion-toggle {
        padding: 14px 15px;
        font-size: 15px;
    }
}
