/* Tư-Trà UI Kit — Menu v3.47.0
   Apple's iOS menu, measured from its Figma kit (1pt = 1px) and set on the phi lattice (brief 17, part B). Every size
   is a token; every colour a palette variable. Each value below is a fallback: a site sets --tt-pl-uk-menu-* on :root
   (or on an anchor, whose values are copied onto its menu at open) and the menu follows.

   Concentric, as the lattice allows exactly: the menu's corner (--phi-space-l, 32.9) = the inner radius
   (--phi-step-1, 20.4: half a row, every tile and highlight) + the padding (--phi-space-xs, 12.6). Set A, chosen on the phone
   (17 Nov 2026); Apple's own padding (set B) is --tt-pl-uk-menu-pad: var(--phi-step--2).

   Sizes, phone to desktop (each token grows x1.25):
     corner --phi-space-l 32.9; inner radius --phi-step-1 20.4; row 2 x --phi-step-1 = 40.7 (a further line + 20.4);
     padding --phi-space-xs 12.6; tile --phi-space-xl 53.3, gap --phi-space-2xs 7.8; row from the menu's side
     --phi-space-s 16; label without an icon and the divider from the side --phi-space-m 25.9; with an icon the label
     at --phi-step-4 41.9 from the row's start, the icon centred at half of it; the end content --phi-step--2 9.9
     from the row's end; text --phi-step-0 16, section titles and tile labels --phi-step--1 12.6.
     Not tokens, reported: the divider (a 1px hairline) and the menu's least and most width (14.875rem and 20rem).

   Alphas are powers of phi on the lattice's half steps: the fill phi^-1 (0.618, light) and phi^-0.5 (0.786, dark, a step
   denser as Apple's); the frost's saturation phi; disabled text phi^-2.5 (0.3003); the divider phi^-5 (0.0902); the
   highlight and the selected tile phi^-5.5 (0.0709). Apple's: 0.7, 0.8, 0.3, 0.1, 0.07. */

.tt-pl-uk-menu {
	position: fixed;
	left: 0;
	top: 0;
	z-index: var(--tt-pl-uk-menu-z, 100001);
	box-sizing: border-box;
	width: max-content;
	min-width: var(--tt-pl-uk-menu-min, 14.875rem);
	max-width: min(var(--tt-pl-uk-menu-max, 20rem), calc(100vw - 2 * var(--tt-pl-uk-menu-side, var(--phi-space-s))));
	padding: var(--tt-pl-uk-menu-pad, var(--phi-space-xs)) 0;
	border-radius: var(--tt-pl-uk-menu-r, var(--phi-space-l));
	background: transparent;
	color: var(--tt-pl-uk-menu-ink, var(--color-linen-deep));
	font-family: var(--tt-pl-uk-menu-font-family, inherit);
	font-size: var(--tt-pl-uk-menu-font, var(--phi-step-0));
	line-height: var(--tt-pl-uk-menu-rr, var(--phi-step-1));
	text-align: left;
	-webkit-user-select: none;
	user-select: none;
	-webkit-tap-highlight-color: transparent;
	transform-origin: 50% 50%;
	outline: none;
}
.tt-pl-uk-menu[data-tone="dark"] { color: var(--tt-pl-uk-menu-ink-dark, var(--color-paper)); }
.tt-pl-uk-menu--inline { position: relative; left: auto; top: auto; z-index: auto; }

/* the fill: on the morph's frost, or on the kit glass's frost layer (a menu that fades in, or drawn in place) */
.tt-pl-uk-menu__frost {
	position: fixed;
	z-index: var(--tt-pl-uk-menu-z, 100001);
	pointer-events: none;
	transform-origin: 50% 50%;
	background: var(--tt-pl-uk-menu-fill, rgba(var(--color-paper-rgb), 0.618));
	-webkit-backdrop-filter: blur(var(--tt-pl-uk-menu-blur, var(--phi-space-s))) saturate(var(--phi, 1.618));
	backdrop-filter: blur(var(--tt-pl-uk-menu-blur, var(--phi-space-s))) saturate(var(--phi, 1.618));
}
.tt-pl-uk-menu > .tt-pl-uk-glass__frost {
	background: var(--tt-pl-uk-menu-fill, rgba(var(--color-paper-rgb), 0.618));
	-webkit-backdrop-filter: blur(var(--tt-pl-uk-menu-blur, var(--phi-space-s))) saturate(var(--phi, 1.618));
	backdrop-filter: blur(var(--tt-pl-uk-menu-blur, var(--phi-space-s))) saturate(var(--phi, 1.618));
}
.tt-pl-uk-menu__frost[data-tone="dark"],
.tt-pl-uk-menu[data-tone="dark"] > .tt-pl-uk-glass__frost { background: var(--tt-pl-uk-menu-fill-dark, rgba(var(--color-linen-deep-rgb), 0.786)); }
@media (prefers-reduced-transparency: reduce) {
	.tt-pl-uk-menu__frost, .tt-pl-uk-menu > .tt-pl-uk-glass__frost { -webkit-backdrop-filter: none; backdrop-filter: none; background: var(--color-paper); }
	.tt-pl-uk-menu__frost[data-tone="dark"], .tt-pl-uk-menu[data-tone="dark"] > .tt-pl-uk-glass__frost { background: var(--color-linen-deep); }
}

/* a menu that fades in (no drop to grow from): scaled from the anchor's side, the kit's sheet curve */
.tt-pl-uk-menu--fade { opacity: 0; transform: scale(0.9); transition: opacity 0.2s ease, transform 0.34s cubic-bezier(0.32, 0.72, 0, 1); }
.tt-pl-uk-menu--fade.is-open { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .tt-pl-uk-menu--fade { transform: none; transition-duration: 0.12s; } }

.tt-pl-uk-menu__view { position: relative; }
/* taller than the screen (3.46.1): the rows scroll inside the glass, held to the menu (contain) so neither the page nor
   a sheet behind it moves; the script sets the view's max-height to the room left on screen */
.tt-pl-uk-menu.is-scroll .tt-pl-uk-menu__view {
	overflow-y: auto;
	overscroll-behavior: contain;
	-webkit-overflow-scrolling: touch;
	touch-action: pan-y;
	scrollbar-width: none;
}
.tt-pl-uk-menu.is-scroll .tt-pl-uk-menu__view::-webkit-scrollbar { display: none; }
.tt-pl-uk-menu__page { display: flex; flex-direction: column; transition: opacity 0.2s ease; }
.tt-pl-uk-menu__page.is-entering { opacity: 0; transition: none; }

/* a row: its box is its highlight. From the menu's side --phi-space-s; first and last at the padding */
.tt-pl-uk-menu__row {
	position: relative;
	display: flex;
	align-items: center;
	box-sizing: border-box;
	width: calc(100% - 2 * var(--tt-pl-uk-menu-side, var(--phi-space-s)));
	min-height: calc(2 * var(--tt-pl-uk-menu-rr, var(--phi-step-1)));
	margin: 0 var(--tt-pl-uk-menu-side, var(--phi-space-s));
	padding: calc(var(--tt-pl-uk-menu-rr, var(--phi-step-1)) / 2) var(--tt-pl-uk-menu-end, var(--phi-step--2))
		calc(var(--tt-pl-uk-menu-rr, var(--phi-step-1)) / 2) calc(var(--tt-pl-uk-menu-sep-in, var(--phi-space-m)) - var(--tt-pl-uk-menu-side, var(--phi-space-s)));
	border: 0;
	border-radius: var(--tt-pl-uk-menu-rr, var(--phi-step-1));
	background: transparent;
	color: inherit;
	font: inherit;
	line-height: inherit;
	text-align: inherit;
	cursor: pointer;
	-webkit-tap-highlight-color: transparent;
	touch-action: manipulation;
	outline: none;
}
.tt-pl-uk-menu__row.has-icon, .tt-pl-uk-menu__row.has-check { padding-left: var(--tt-pl-uk-menu-icon-at, var(--phi-step-4)); }
.tt-pl-uk-menu__row.is-destructive { color: var(--tt-pl-uk-menu-danger, var(--color-lotus)); }
.tt-pl-uk-menu[data-tone="dark"] .tt-pl-uk-menu__row.is-destructive { color: var(--tt-pl-uk-menu-danger-dark, var(--color-lotus-light)); }
.tt-pl-uk-menu__row:disabled { cursor: default; color: var(--tt-pl-uk-menu-off, rgba(var(--color-linen-deep-rgb), 0.3003)); }
.tt-pl-uk-menu[data-tone="dark"] .tt-pl-uk-menu__row:disabled { color: var(--tt-pl-uk-menu-off-dark, rgba(var(--color-paper-rgb), 0.3003)); }
.tt-pl-uk-menu__row:disabled .tt-pl-uk-menu__key, .tt-pl-uk-menu__row:disabled .tt-pl-uk-menu__sub { color: inherit; }
.tt-pl-uk-menu__main { display: flex; flex-direction: column; min-width: 0; flex: 1 1 auto; }
.tt-pl-uk-menu__label {
	display: -webkit-box;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 2;
	overflow: hidden;
	overflow-wrap: anywhere;
}
.tt-pl-uk-menu__sub { font-size: var(--tt-pl-uk-menu-small, var(--phi-step--1)); line-height: var(--phi-space-s); color: var(--tt-pl-uk-menu-ink-2, var(--color-linen)); }
/* the icon (and the check), centred at half of the label's start */
.tt-pl-uk-menu__icon, .tt-pl-uk-menu__check {
	position: absolute;
	left: calc(var(--tt-pl-uk-menu-icon-at, var(--phi-step-4)) / 2);
	top: 50%;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: var(--tt-pl-uk-menu-rr, var(--phi-step-1));
	height: var(--tt-pl-uk-menu-rr, var(--phi-step-1));
	transform: translate(-50%, -50%);
	pointer-events: none;
}
.tt-pl-uk-menu__row.has-check.has-icon .tt-pl-uk-menu__check { left: calc(var(--tt-pl-uk-menu-icon-at, var(--phi-step-4)) / 4); }
.tt-pl-uk-menu__icon svg, .tt-pl-uk-menu__check svg, .tt-pl-uk-menu__end svg { width: 100%; height: 100%; }
.tt-pl-uk-menu__icon i, .tt-pl-uk-menu__icon span { font-size: var(--tt-pl-uk-menu-font, var(--phi-step-0)); line-height: 1; }
/* the end: a shortcut, or a submenu's chevron */
.tt-pl-uk-menu__end { flex: none; margin-left: var(--tt-pl-uk-menu-end, var(--phi-step--2)); pointer-events: none; }
.tt-pl-uk-menu__key { color: var(--tt-pl-uk-menu-ink-2, var(--color-linen)); font-variant-numeric: tabular-nums; }
.tt-pl-uk-menu[data-tone="dark"] .tt-pl-uk-menu__key,
.tt-pl-uk-menu[data-tone="dark"] .tt-pl-uk-menu__sub,
.tt-pl-uk-menu[data-tone="dark"] .tt-pl-uk-menu__title { color: var(--tt-pl-uk-menu-ink-2-dark, var(--color-linen-light)); }
.tt-pl-uk-menu__chev { display: inline-flex; width: var(--tt-pl-uk-menu-small, var(--phi-step--1)); height: var(--tt-pl-uk-menu-small, var(--phi-step--1)); }

/* sections: a hairline in a gap of its own (the padding above and below), inset as the labels; a title is a row's
   height, its text small and quiet */
.tt-pl-uk-menu__sep {
	flex: none;
	height: 1px;
	margin: var(--tt-pl-uk-menu-pad, var(--phi-space-xs)) var(--tt-pl-uk-menu-sep-in, var(--phi-space-m));
	background: var(--tt-pl-uk-menu-sep, rgba(var(--color-linen-deep-rgb), 0.0902));
}
.tt-pl-uk-menu[data-tone="dark"] .tt-pl-uk-menu__sep { background: var(--tt-pl-uk-menu-sep-dark, rgba(var(--color-paper-rgb), 0.0902)); }
.tt-pl-uk-menu__title {
	display: flex;
	align-items: center;
	min-height: calc(2 * var(--tt-pl-uk-menu-rr, var(--phi-step-1)));
	padding: 0 var(--tt-pl-uk-menu-sep-in, var(--phi-space-m));
	font-size: var(--tt-pl-uk-menu-small, var(--phi-step--1));
	color: var(--tt-pl-uk-menu-ink-2, var(--color-linen));
}
.tt-pl-uk-menu__sep + .tt-pl-uk-menu__title { margin-top: calc(var(--tt-pl-uk-menu-pad, var(--phi-space-xs)) * -1); }   /* the title's block starts at the divider */
.tt-pl-uk-menu__group { display: flex; flex-direction: column; }

/* the palette: equal tiles, at the padding from the menu's edges, concentric with its corner */
.tt-pl-uk-menu__palette {
	display: grid;
	gap: var(--tt-pl-uk-menu-tile-gap, var(--phi-space-2xs));
	margin: 0 var(--tt-pl-uk-menu-pad, var(--phi-space-xs));
}
.tt-pl-uk-menu__row.tt-pl-uk-menu__tile {
	flex-direction: column;
	justify-content: center;
	gap: var(--phi-space-3xs);
	width: auto;
	min-width: 0;
	min-height: var(--tt-pl-uk-menu-tile-h, var(--phi-space-xl));
	margin: 0;
	padding: 0 var(--phi-space-3xs);
	text-align: center;
}
.tt-pl-uk-menu__tile .tt-pl-uk-menu__icon { position: static; transform: none; }
.tt-pl-uk-menu__tile .tt-pl-uk-menu__label {
	display: block;
	max-width: 100%;
	font-size: var(--tt-pl-uk-menu-small, var(--phi-step--1));
	line-height: var(--phi-space-s);
	white-space: nowrap;
	text-overflow: ellipsis;
}
.tt-pl-uk-menu__tile.is-selected { background: var(--tt-pl-uk-menu-hl, rgba(var(--color-linen-deep-rgb), 0.0709)); }
.tt-pl-uk-menu[data-tone="dark"] .tt-pl-uk-menu__tile.is-selected { background: var(--tt-pl-uk-menu-hl-dark, rgba(var(--color-paper-rgb), 0.0709)); }

/* the submenu's head: a row, its label strong */
.tt-pl-uk-menu__head .tt-pl-uk-menu__label { font-weight: 600; }

/* the highlight: one layer sliding to the row under the finger */
.tt-pl-uk-menu__hl {
	position: absolute;
	left: 0;
	top: 0;
	width: 0;
	height: 0;
	border-radius: var(--tt-pl-uk-menu-rr, var(--phi-step-1));
	background: var(--tt-pl-uk-menu-hl, rgba(var(--color-linen-deep-rgb), 0.0709));
	opacity: var(--tt-pl-uk-menu-hl-o, 0);
	pointer-events: none;
	transition: transform 0.18s cubic-bezier(0.32, 0.72, 0, 1), width 0.18s cubic-bezier(0.32, 0.72, 0, 1), height 0.18s cubic-bezier(0.32, 0.72, 0, 1), opacity 0.12s ease;
}
.tt-pl-uk-menu[data-tone="dark"] .tt-pl-uk-menu__hl { background: var(--tt-pl-uk-menu-hl-dark, rgba(var(--color-paper-rgb), 0.0709)); }
@media (prefers-reduced-motion: reduce) { .tt-pl-uk-menu__hl { transition: opacity 0.12s ease; } }

/* the edit bar: a capsule of plain items, hairlines between them, a round chevron in it, concentric */
.tt-pl-uk-menu--bar {
	display: flex;
	align-items: center;
	min-width: 0;
	height: var(--tt-pl-uk-menu-bar-h, var(--phi-step-4));
	padding: 0 var(--tt-pl-uk-menu-bar-in, var(--phi-space-3xs)) 0 0;
	border-radius: calc(var(--tt-pl-uk-menu-bar-h, var(--phi-step-4)) / 2);
}
.tt-pl-uk-menu__barrow { flex-direction: row; align-items: center; }
.tt-pl-uk-menu__row.tt-pl-uk-menu__bitem {
	width: auto;
	min-height: calc(var(--tt-pl-uk-menu-bar-h, var(--phi-step-4)) - 2 * var(--tt-pl-uk-menu-bar-in, var(--phi-space-3xs)));
	margin: 0 0 0 var(--tt-pl-uk-menu-bar-in, var(--phi-space-3xs));
	padding: 0 calc(var(--tt-pl-uk-menu-rr, var(--phi-step-1)) - var(--tt-pl-uk-menu-bar-in, var(--phi-space-3xs)));
	white-space: nowrap;
}
.tt-pl-uk-menu__bsep { flex: none; width: 1px; height: var(--phi-space-s); background: var(--tt-pl-uk-menu-sep, rgba(var(--color-linen-deep-rgb), 0.0902)); }
.tt-pl-uk-menu[data-tone="dark"] .tt-pl-uk-menu__bsep { background: var(--tt-pl-uk-menu-sep-dark, rgba(var(--color-paper-rgb), 0.0902)); }
.tt-pl-uk-menu__bitem[hidden], .tt-pl-uk-menu__bsep[hidden], .tt-pl-uk-menu__more[hidden] { display: none; }
.tt-pl-uk-menu__more {
	flex: none;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: calc(var(--tt-pl-uk-menu-bar-h, var(--phi-step-4)) - 2 * var(--tt-pl-uk-menu-bar-in, var(--phi-space-3xs)));
	height: calc(var(--tt-pl-uk-menu-bar-h, var(--phi-step-4)) - 2 * var(--tt-pl-uk-menu-bar-in, var(--phi-space-3xs)));
	margin-left: var(--tt-pl-uk-menu-bar-in, var(--phi-space-3xs));
	padding: calc(var(--phi-space-2xs) + var(--phi-space-3xs));
	border: 0;
	border-radius: 50%;
	background: var(--tt-pl-uk-menu-hl, rgba(var(--color-linen-deep-rgb), 0.0709));
	color: inherit;
	cursor: pointer;
	-webkit-tap-highlight-color: transparent;
}
.tt-pl-uk-menu[data-tone="dark"] .tt-pl-uk-menu__more { background: var(--tt-pl-uk-menu-hl-dark, rgba(var(--color-paper-rgb), 0.0709)); }
.tt-pl-uk-menu__more svg { width: 100%; height: 100%; }
.tt-pl-uk-menu__more.is-back svg { transform: scaleX(-1); }
