.bar { display: flex; align-items: center; gap: 4px; opacity: 0; transition: opacity .6s var(--ease); }
.bar.built { opacity: 1; }
.bar-item { position: relative; }

.bar-btn { position: relative; display: flex; align-items: center; gap: 2px; height: 40px; padding: 0 17px; border: 0; border-radius: 999px; background: color-mix(in srgb, var(--card) 0%, transparent); color: var(--ink); font: inherit; font-weight: 800; font-size: 15px; line-height: 1; letter-spacing: .01em; text-decoration: none; white-space: nowrap; cursor: pointer; -webkit-tap-highlight-color: transparent;
	transition: background-color .6s var(--ease), color .6s var(--ease), box-shadow .6s var(--ease), scale .6s var(--ease); }
.drop .bar-btn { padding-right: 11px; }
@media (hover: hover) { .bar-btn:hover { background: var(--card); box-shadow: var(--shadow-sm); transition-duration: .35s; } }
.bar-btn:active { scale: .94; transition-duration: .35s, .35s, .35s, .4s; }
.drop.open .bar-btn { background: var(--ink); color: var(--paper); box-shadow: var(--shadow-md); transition-duration: .35s; }
.bar-arrow { flex: none; width: 19px; height: 19px; margin-top: 1px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; transition: rotate .6s var(--ease); }
.drop.open .bar-arrow { rotate: 180deg; transition-duration: .35s; }

.drop-panel { --nudge: 0px; position: absolute; z-index: 5; top: calc(100% + 10px); left: calc(50% + var(--nudge)); width: max-content; min-width: 236px; max-width: calc(100vw - 20px); padding: 7px; border-radius: 22px; background: var(--card); box-shadow: var(--shadow-md);
	opacity: 0; translate: -50% -8px; scale: .96; transform-origin: 50% 0; visibility: hidden;
	transition: opacity .35s var(--ease), translate .6s var(--ease), scale .6s var(--ease), visibility 0s linear .6s; }
.drop.open .drop-panel { opacity: 1; translate: -50% 0; scale: 1; visibility: visible; transition: opacity .35s var(--ease), translate .45s var(--ease), scale .45s var(--ease), visibility 0s; }
.drop-panel::before { content: ""; position: absolute; left: 0; right: 0; top: -12px; height: 12px; }
.drop-list { display: grid; gap: 2px; margin: 0; padding: 0; list-style: none; }
.drop-list li { opacity: 0; translate: 0 -5px; transition: opacity .3s var(--ease), translate .5s var(--ease); }
.drop.open .drop-list li { opacity: 1; translate: 0 0; transition-delay: calc(var(--i, 0) * 35ms + 40ms); }

.drop-item { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 50px; padding: 7px 12px 7px 7px; border: 0; border-radius: 15px; background: color-mix(in srgb, var(--paper) 0%, transparent); color: var(--ink); font: inherit; font-weight: 700; font-size: 15px; line-height: 1.2; text-align: left; text-decoration: none; cursor: pointer; -webkit-tap-highlight-color: transparent;
	transition: background-color .6s var(--ease), scale .6s var(--ease); }
.drop-item:focus-visible { outline-offset: -2px; border-radius: 15px; }
@media (hover: hover) { .drop-item:hover { background: var(--paper); transition-duration: .35s; } }
.drop-item:active { scale: .97; transition-duration: .35s, .4s; }
.drop-item.off { cursor: default; }
.drop-item.off .drop-text { color: var(--muted); }
.drop-ico { flex: none; display: grid; place-items: center; width: 36px; height: 36px; border-radius: 12px; background: var(--paper); color: var(--ink); transition: background-color .6s var(--ease), scale .6s var(--ease); }
@media (hover: hover) { .drop-item:hover .drop-ico { background: var(--card); scale: 1.06; transition-duration: .35s; } }
.drop-ico svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; overflow: visible; }
.drop-ico svg .fill { fill: currentColor; stroke: none; }
.drop-ico svg[data-oneshot] { width: 24px; height: 24px; }
.drop-ico img { width: auto; height: 21px; max-width: 27px; }
.drop-item.off .drop-ico img { opacity: .85; }
.drop-text { flex: 1; white-space: nowrap; }
.drop-tag { flex: none; padding: 4px 9px 3px; border-radius: 999px; background: color-mix(in srgb, var(--ink) 7%, transparent); color: var(--muted); font-size: 10.5px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }

.os-ring, .os-pills { fill: none; stroke: currentColor; stroke-linecap: round; }
.os-dot { fill: var(--orange); }

@media (max-width: 640px) {
	.bar { gap: 2px; }
	.bar-btn { height: 38px; padding: 0 13px; font-size: 14.5px; }
	.drop .bar-btn { padding-right: 8px; }
	.drop-panel { min-width: 224px; }
}

/* ---------- Contact, a top-level button since 15 Oct 2026: the word on wide screens, the envelope on phones (the word stays
	for screen readers), with tighter buttons there, so the bar keeps room for the fish and the settings button ---------- */
.bar-ico { display: grid; place-items: center; }
.bar-ico svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.bar a.bar-btn[href="/contact"] .bar-ico { display: none; }
@media (max-width: 480px) {
	.bar-btn { padding: 0 10px; }
	.drop .bar-btn { padding-right: 6px; }
	.bar a.bar-btn[href="/contact"] .bar-ico { display: grid; }
	.bar a.bar-btn[href="/contact"] .bar-text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
}
@media (max-width: 380px) {
	.bar-btn { padding: 0 8px; font-size: 14px; }
	.drop .bar-btn { padding-right: 4px; }
}
