.gold-chart {
    display: flex;
    flex-direction: row;
    margin-bottom: 20px;
}

.gold-data {
    width: 100%;
}

.gold-data .gold-rate span {
    color: #0B0D13;
    display: inline-flex;
    align-items: center;
}
.gold-data .gold-rate span.up {
    color: #00B412;
}
.gold-data .gold-rate span.down {
    color: #E91F50;
}

.gold-rate-items .up::after {
    margin-left: 5px;
    content: "";
    border-radius: 5px;
    border: 6px solid;
    border-bottom: 7px solid;
    border-left-color: transparent;
    border-right-color: transparent;
    border-top: none;
    border-bottom-color: #00b412;
    margin-top: 0
}

.gold-rate-items .down::after {
    margin-left: 5px;
    margin-top: 2px;
    content: "";
    border-radius: 5px;
    border: 6px solid;
    border-top: 7px solid;
    border-left-color: transparent;
    border-right-color: transparent;
    border-bottom: none;
    border-top-color: #e91f50
}

.gold-rate {
    background: #FFF;
    box-shadow: 0 0 16.1px 0 rgba(119, 121, 127, 0.15);
    padding: 20px;
    margin-bottom: 20px;
    border-radius: 20px;
    display: flex;
    flex-direction: column;
}

.gold-data .gold-rate > span {
    position: relative;
    color: #A4A6AA;
    font-size: 12px;
    margin-left: auto;
    margin-top: -10px;
    margin-bottom: -20px;
}

.gold-rate .gold-rate-header,
.gold-rate .gold-rate-items {
    display: flex;
    justify-content: space-between;
    padding: 15px;
}

.gold-rate .gold-rate-header {
    font-weight: 500;
    font-size: 14px;
    color: #0B0D13;
}

.gold-rate .gold-rate-items:not(:last-child){
    margin-bottom: 5px;
}

.gold-rate .gold-rate-items :first-child,
.gold-rate .gold-rate-header :first-child {
    width: 40%;
}

.gold-rate .gold-rate-items :not(:first-child),
.gold-rate .gold-rate-header :not(:first-child) {
    width: 30%;
}

.gold-rate .gold-rate-items {
    border-radius: 20px;
    background: rgba(0, 0, 0, 0.05);
}

.chart-controls {
    text-align: center;
    padding: 20px;
    margin-right: 20px;
    border-radius: 20px;
    background: #FFF;
    box-shadow: 0 0 16.1px 0 rgba(119, 121, 127, 0.15);
    display: flex;
    flex-direction: column;
    min-width: 300px;
    max-width: 300px;
    height: fit-content;
}

.period-title {
    color: #0B0D13;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -4%;
    font-size: 20px;
    text-align: left;
    margin-bottom: 15px;
    padding: 15px 0 0 15px;
}

.period-buttons .field-checkbox {
    padding: 5px 15px;
}

.field-check-list__item .field-checkbox__text {
    font-weight: 500;
    color: #0B0D13;
}

.period-buttons .field-checkbox--radio:hover .field-radio__visual,
.period-buttons .field-checkbox--radio .field-checkbox__input:checked ~ .field-radio__visual {
    border: 2px solid #5B78FB;
}

.period-buttons .field-checkbox--radio .field-radio__visual::after {
    /* margin: 0.5px 0.1px 0 0; */
}


.gold-chart-container {
    width: 100%;
    height: 500px;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 0 16.1px 0 rgba(119, 121, 127, 0.15);
}

.period-buttons .btn {
    display: flex;
    border-radius: 15px;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    font-size: 16px;
    font-style: normal;
    line-height: normal;
    letter-spacing: -0.8px;
    border: 1px solid #C3C2D3;
    color: #48484C;
    background-color: transparent;
    font-weight: 700;
}
.period-buttons .btn.active {
    background: #6177F3;
    color: #FFF;
    font-weight: 700;
    box-shadow: none;
    border: 1px solid #6177F3;
}

.period-buttons .btn:hover:not(.active) {
    background-color: rgba(0, 0, 0, .05);
    color: #48484C;
    border: 1px solid #C3C2D3;
    box-shadow: none;
}
.custom-period-fields {
    margin-top: 10px;
    display: flex;
    flex-direction: column;
}

.custom-period-fields > span {
    display: flex;
    font-size: 12px;
    justify-content: center;
    align-items: center;
    margin: 10px auto;
    color: #77797F;
    font-weight: 500;
    letter-spacing: -4%;
}
.custom-period-fields .btn {
    width: 100%;
    display: flex;
    justify-content: center;
    border-radius: 20px;
    height: 42px;
}
.custom-period-fields input {
    margin: 0;
    padding: 4px;
    background: transparent;
    font-size: 16px;
    line-height: 1.3;
    font-weight: 500;
    letter-spacing: -4%;
}

.custom-period-fields .datepicker-block {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    background: #0000000D;
    border-radius: 20px;
    padding: 5px 10px;
}

.custom-period-fields .datepicker-block .datepicker-block__icon {
    position: relative;
    right: auto;
    top: auto;
    margin-left: 8px;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* .custom-period-fields .datepicker-block span {
    padding: 10px;
} */

.custom-period-fields .datepicker-block__input {
    height: 32px;
    text-align: center;
}

@media screen and (max-width: 1024px) {
    .gold-chart {
        flex-direction: column-reverse;
    }

    .chart-controls {
        margin-top: 20px;
        margin-right: 0;
        min-width: 100%;
        max-width: 100%;
    }

    .chart-controls .period-buttons {
        display: flex;
        flex-wrap: wrap;
    }
    
    .gold-rate .gold-rate-items > div {
        display: flex;
        flex-direction: column;
    }

    .gold-rate .gold-rate-items :first-child,
    .gold-rate .gold-rate-header :first-child {
        width: 30%;
    }

    .gold-rate .gold-rate-items :not(:first-child),
    .gold-rate .gold-rate-header :not(:first-child) {
        width: 35%;
    }
}