/* Salary intelligence panel under a job review.
   main.css has `* { border-radius: 5px !important }`, hence !important on every radius. */

.salary-intel {
    margin: 22px 0 6px;
    padding: 18px 22px 16px;
    background: #fff;
    border: 1px solid #E7EAEE;
    border-radius: 12px !important;
    color: #2F3742;
}

.salary-intel-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    margin-bottom: 22px;
}

.salary-intel-eyebrow {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: #8B929C;
}

.salary-intel-sample {
    display: inline-flex;
    align-items: center;
    padding: 3px 10px;
    border-radius: 999px !important;
    font-size: 12px;
    line-height: 1.4;
    white-space: nowrap;
    color: #0C447C;
    background: #E6F1FB;
}

.salary-intel-sample .fa {
    margin-right: 6px;
    font-size: 13px;
}

.salary-intel-headline {
    margin: 0 0 12px !important;
    font-size: 16px !important;
    font-weight: 500;
    line-height: 1.3;
    color: #2F3742 !important;
}

.salary-intel-chips {
    display: flex;
    flex-wrap: wrap;
    margin: 0;
}

.salary-intel-chips span {
    margin: 0 6px 6px 0;
    padding: 4px 10px;
    border-radius: 6px !important;
    background: #EDEFF2;
    font-size: 12px;
    color: #4B5563;
}

.salary-intel-chips .salary-intel-chips-label {
    padding: 4px 0;
    background: none;
    color: #6B7280;
}

/* top margin clears the bubble above the marker, the side padding keeps it centred at the ends */
.salary-intel-scale {
    margin: 46px 0 6px;
    padding: 0 48px;
}

.salary-intel-track {
    position: relative;
    display: flex;
    height: 8px;
}

/* below / typical / above at 1:2:1, the median tick at the centre of the typical stretch */
.salary-intel-segment {
    flex: 1 1 0;
    border-radius: 0 !important;
    background: #F09595;
}

.salary-intel-segment + .salary-intel-segment {
    margin-left: 4px;
}

.salary-intel-segment-below {
    border-radius: 999px 0 0 999px !important;
}

.salary-intel-segment-typical {
    flex-grow: 2;
    background: #B9D9C2;
}

.salary-intel-segment-above {
    border-radius: 0 999px 999px 0 !important;
    background: #97C459;
}

.salary-intel-tick {
    position: absolute;
    top: -4px;
    bottom: -4px;
    left: 50%;
    width: 1px;
    margin-left: -0.5px;
    background: #4B5563;
}

.salary-intel-marker {
    position: absolute;
    top: 50%;
    width: 18px;
    height: 18px;
    margin: -9px 0 0 -9px;
    background: #2C2C2A;
    border: 2px solid #fff;
    border-radius: 50% !important;
}

.salary-intel-bubble {
    position: absolute;
    bottom: 18px;
    left: 50%;
    -webkit-transform: translateX(-50%);
    transform: translateX(-50%);
    padding: 2px 8px;
    background: #2C2C2A;
    border-radius: 4px !important;
    font-size: 12px;
    font-weight: 600;
    line-height: 1.5;
    color: #F1EFE8;
    white-space: nowrap;
}

.salary-intel-axis {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    margin-top: 8px;
    font-size: 12px;
    color: #6B7280;
}

.salary-intel-axis > span:last-child {
    text-align: right;
}

.salary-intel-axis-median {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0 8px;
}

.salary-intel-axis-median > span {
    font-size: 13px;
    color: #2F3742;
}

@media (max-width: 767px) {
    .salary-intel {
        padding: 14px 14px 12px;
    }
    /* narrower gutter and a smaller bubble, so the track keeps its width */
    .salary-intel-scale {
        padding: 0 28px;
    }
    .salary-intel-bubble {
        padding: 2px 6px;
        font-size: 11px;
    }
    /* the median caption takes its own row so the side labels stop wrapping */
    .salary-intel-axis {
        grid-template-columns: 1fr 1fr;
    }
    .salary-intel-axis-median {
        grid-column: 1 / -1;
        grid-row: 1;
        margin-bottom: 6px;
        padding: 0;
    }
}
