/*
 * © 2026 TomTom NV. All rights reserved.
 *
 * This software is the proprietary copyright of TomTom NV and its subsidiaries and may be
 * used for internal evaluation purposes or commercial use strictly subject to separate
 * license agreement between you and TomTom NV. If you are the licensee, you are only permitted
 * to use this software in accordance with the terms of your license agreement. If you are
 * not the licensee, you are not authorized to use this software in any manner and should
 * immediately return or destroy it.
 */

/* Dokka renders the module version in an unstyled, class-less <div> right after .library-name. The
   versions-dropdown takes its place there instead, so hide that native div without touching the dropdown
   itself or Dokka's own navigation controls (search, theme toggle), which are also .library-name siblings. */
:root .library-name ~ div:not(.versions-dropdown):not(.pull-right) {
    display: none;
}

:root .versions-dropdown {
    position: relative;
    margin-left: var(--spacing-medium);
    --dropdown-text: var(--gray-very-dark);
    --dropdown-background: var(--brand-white);
}
:root.theme-dark .versions-dropdown {
    --dropdown-text: var(--brand-white);
    --dropdown-background: var(--background-color);
}
:root .versions-dropdown-button {
    border: none;
    cursor: pointer;
    padding: 5px;
    display: flex;
    align-items: center;
    gap: 6px;
    background: none;
    color: var(--dropdown-text);
    font: inherit;
}

:root .versions-dropdown-button::after {
    content: "";
    -webkit-mask: none;
    mask: none;
    background: none;
    position: static;
    transform: none;
    width: 0;
    height: 0;
    border: 4px solid transparent;
    border-top-color: currentColor;
    margin-top: 4px;
}
:root .versions-dropdown-data {
    display: none;
    position: absolute;
    left: 0;
    min-width: 100%;
    background-color: var(--dropdown-background);
    border: 1px solid var(--gray-neutral);
    border-radius: var(--size-radius-highlight);
    box-shadow: var(--shadow-default);
    z-index: 1;
    overflow-y: auto;
    max-height: 200px;
}
:root .versions-dropdown-data a {
    padding: 5px 12px;
    display: block;
    white-space: nowrap;
    text-decoration: none;
    color: var(--dropdown-text);
    border-bottom: none !important;
}
:root .versions-dropdown-data a:hover {
    background: var(--gray-hover);
}
:root .versions-dropdown:hover .versions-dropdown-data {
    display: block;
}
