/* Copyright 2026 Element Creations Ltd. SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial Please see LICENSE in the repository root for full details. */ .container { display: flex; flex-direction: row; align-items: center; background-color: var(--cpd-color-bg-subtle-secondary); border-radius: 32px; transition: background-color 0.2s ease-in-out; } .containerOpen { background-color: var(--cpd-color-bg-action-primary-pressed); } .chevronIconOpen > svg { color: var(--cpd-color-icon-on-solid-primary); } .menuButton { width: 40px; background-color: transparent !important; } .itemIcon { color: var(--cpd-color-text-secondary); } .rotate { animation: spinner 1.5s linear infinite; } @keyframes spinner { to { transform: rotate(360deg); } } /* The width design sets: a long device name wraps. */ .menu { inline-size: 296px; } /* Its share of the measured call area: the menu is portalled out of the root, so CSS can't size it against the call. */ .deviceList { max-block-size: var(--device-list-max-height); /* Keeps a row reached by keyboard clear of the sticky heading. */ scroll-padding-block-start: var(--device-list-scroll-padding-start, 0); } /* Compound's heading rule heads each section; the design adds space below it. */ .menu h3 { margin-block-end: var(--cpd-space-5x); } /* And more above a heading that follows another section. */ .deviceList [role="group"] + [role="group"] h3 { margin-block-start: var(--cpd-space-7x); } /* Sticky within its own section, and opaque so rows scroll under it. */ .sectionHeading { position: sticky; inset-block-start: 0; background: var(--cpd-color-bg-canvas-default); } /* Sticky at the foot of the microphone section; opaque as above. */ .stickyMeter { position: sticky; inset-block-end: 0; background: var(--cpd-color-bg-canvas-default); } /* Fills the band between the meter and the frame, or rows show through it. */ .stickyMeter::after { content: ""; position: absolute; inset-inline: 0; inset-block-start: 100%; block-size: var(--cpd-menu-padding-block-end, 0px); background: var(--cpd-color-bg-canvas-default); } /* Not Compound's fade: that stays at the edge while a bounce carries the meter. This one starts at the chevron, below the meter at rest. */ .deviceList.deviceListWithMeter[data-more-below] { mask-image: linear-gradient( to bottom, #000 calc(100% - var(--cpd-space-6x)), transparent calc(100% - var(--cpd-space-3x)) ); } /* Radix focuses whatever the pointer is over, so the browser's ring would follow the mouse. Replaced by one shown only for keyboard focus. */ .menu [role^="menuitem"]:focus, .menu [role^="menuitem"]:focus-visible { outline: none; } .menu[data-focus-source="keyboard"] [role^="menuitem"]:focus { outline: var(--cpd-border-width-2) solid var(--cpd-color-border-focused); outline-offset: calc(-1 * var(--cpd-border-width-2)); }