/* ============================================================================
 * Theme picker styles (DE-005 / DE-008).
 * The collapse block is rendered directly below the tabs nav as a
 * sibling of <nav class="tabs">, so the picker follows the ~/themes
 * trigger and never floats off-screen. `hidden` toggles the block;
 * the [data-collapsing] attribute animates max-height as a collapse.
 * Re-uses existing palette tokens (--bg, --fg, --accent, --dim, --line,
 * --line-strong, --accent-soft); no new CSS palette tokens are added.
 * ========================================================================== */

.theme-picker {
    overflow: hidden;
    max-height: 0;
    opacity: 0;
    transition: max-height 0.18s ease, opacity 0.18s ease;
    border-bottom: 1px dashed var(--line);
    font-family: var(--font-mono);
    font-size: 12px;
}

.theme-picker[hidden] {
    display: block;
    max-height: 0;
    opacity: 0;
}

.theme-picker:not([hidden]) {
    max-height: 12rem;
    opacity: 1;
    padding: 8px 24px;
}

.theme-picker__menu {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.theme-picker__item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border: 1px solid var(--line-strong);
    border-radius: var(--tag-radius);
    background: transparent;
    color: var(--fg);
    font-family: inherit;
    font-size: inherit;
    text-align: left;
    cursor: pointer;
}

.theme-picker__item:hover,
.theme-picker__item:focus-visible {
    border-color: var(--accent-dim);
    color: var(--accent);
}

.theme-picker__item--active {
    border-color: var(--accent);
    color: var(--accent);
}

.theme-picker__item-mark {
    font-size: 10px;
    color: var(--dim);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}