/* OLFOR-E3: Reuse the existing City Profiles hover presentation when the
   disclosure is opened from the keyboard. No new visual styling is introduced. */
header .navigation ul li.profile-dropdown.keyboard-open .cities-dropdown-content {
    display: flex;
    flex-direction: row;
    border-top: 1px solid #4d4d4d;
    justify-content: center;
    opacity: 1;
}

header .navigation ul li.profile-dropdown.keyboard-open .region {
    border-right: 1px solid rgba(77, 77, 77, 0.5);
}

header .navigation ul li.cs-dd.keyboard-open .link-profiles svg {
    transform: rotate(180deg);
}

.profile-dropdown.keyboard-open .cities-dropdown-content {
    opacity: 1;
    visibility: visible;
    height: 420px;
    width: 100%;
    left: 0;
    top: 80px;
    transition:
        height 0.5s ease-in-out,
        visibility 0s linear;
}

.profile-dropdown.keyboard-open .region {
    opacity: 1;
    visibility: visible;
    height: 420px;
    left: 0;
    transition:
        height 0.8s ease-in-out,
        visibility 0.5s linear;
}

.profile-dropdown.keyboard-open .cities-list {
    opacity: 1;
    visibility: visible;
    height: 420px;
    left: 0;
    transition:
        height 0.8s ease-in-out,
        visibility 0.5s linear;
}

/* OLFOR-E300: Reuse the existing Share hover presentation when the disclosure
   is opened from the keyboard. This introduces no new visual design. */
.dropdown-content-share.keyboard-open .dropdown-content-share-links {
    transition: opacity 0.5s;
    opacity: 1;
    z-index: 3;
}


/* OLFOR-E24: Keep data table captions available to assistive technologies
   without changing the existing visual presentation. */
.level-access-visually-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    clip-path: inset(50%) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

/* OLFOR-E183: Preserve the existing visual treatment when metric labels use
   semantic row-header cells. The markup change improves table semantics only. */
.top-section .city-data-container .cdc-container .scores-section .bottom-scores .profile-scores-table tr th[scope="row"] {
    padding: 17px 0;
    font-family: "Inter", sans-serif;
    font-style: normal;
    font-weight: 400;
    font-size: 16px;
    line-height: 22px;
    letter-spacing: -0.16px;
    color: #999999;
    text-align: left;
}

.top-section .city-data-container .cdc-container .scores-section .bottom-scores .profile-scores-table tr td {
    width: 100px;
    text-align: right;
}

.top-section .city-data-container .cdc-container .scores-section .bottom-scores .profile-scores-table tr td span {
    color: #ffffff;
}

@media (max-width: 1024px) {
    .top-section .city-data-container .cdc-container .scores-section .bottom-scores .profile-scores-table tr th[scope="row"] {
        padding: 10px 0;
    }
}

@media (max-width: 768px) {
    .top-section .city-data-container .cdc-container .scores-section .bottom-scores .profile-scores-table tr th[scope="row"] {
        font-size: 14px;
    }
}

/* OLFOR-E192: Overlay semantic toggle buttons on the existing Chart.js legend.
   The controls use the legend's existing hit boxes, so the chart appearance is
   unchanged while keyboard and screen-reader users receive name, role, and state. */
.radar-chart-a11y-container {
    position: relative;
}

.radar-chart-legend-controls {
    position: absolute;
    inset: 0;
    z-index: 2;
    pointer-events: none;
}

.radar-chart-legend-toggle {
    position: absolute;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
    color: transparent;
    font-size: 0;
    line-height: 0;
    -webkit-appearance: none;
    appearance: none;
    cursor: pointer;
    pointer-events: auto;
}

