/* Prototype Pill: contextual dark dock for the Ovation Phase 1 prototypes. Tooling, not product UI (Inter, not Rubik). See README.md.
   Dark tokens follow the screen library (Graphite); orange only marks the current item. */
@import url("https://fonts.googleapis.com/css2?family=Inter:opsz,wght@14..32,400..600&display=swap");
.pp-root, .pp-root * { box-sizing: border-box; }
.pp-root {
  --pp-ink: #f5f6f7; --pp-text: #c4c7cc; --pp-mute: #9a9ea6; --pp-faint: #878b93; --pp-line: #232528; --pp-line2: #33363b; --pp-fill: #1b1d20; --pp-brand: #FA8831;
  --pp-spring: cubic-bezier(.32, 1.25, .5, 1); --pp-ease: cubic-bezier(.2, .8, .2, 1);
  position: fixed; left: var(--pp-left, 20px); bottom: 20px; z-index: 99990; transform: translateY(var(--pp-lift, 0px));
  display: flex; flex-direction: column; align-items: flex-start; gap: 10px; width: max-content; max-width: calc(100vw - var(--pp-left, 20px) - 12px);
  font: 400 13px/1.35 Inter, system-ui, -apple-system, "Segoe UI", sans-serif; color: var(--pp-text); -webkit-font-smoothing: antialiased;
  transition: transform .28s var(--pp-ease), opacity .2s ease;
}
.pp-root[hidden] { display: none; }
.pp-root.pp-low { bottom: 6px; }
.pp-root.pp-low .pp-bar { padding: 3px; } .pp-root.pp-low .pp-tab { height: 28px; }
/* a dialog would sit under the dock: tuck it down to a thin handle; hover or focus brings it back */
.pp-root.pp-away { opacity: .7; transform: translateY(calc(100% + 20px - 8px)); }
.pp-root.pp-away:hover, .pp-root.pp-away:focus-within { opacity: 1; transform: none; }
.pp-surface, .pp-bar, .pp-panel {
  background: linear-gradient(180deg, rgba(27, 29, 32, .96), rgba(18, 19, 21, .96)); -webkit-backdrop-filter: blur(18px) saturate(1.4); backdrop-filter: blur(18px) saturate(1.4);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .18), inset 0 1px 0 rgba(255, 255, 255, .08), 0 24px 48px -16px rgba(0, 0, 0, .75), 0 6px 14px -6px rgba(0, 0, 0, .5);
}
.pp-bar { display: flex; align-items: center; gap: 4px; padding: 5px; border-radius: 16px; max-width: 100%; }
.pp-cur { max-width: 220px; padding: 0 12px 0 10px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 500; color: var(--pp-ink); font-size: 13px; }
.pp-root.pp-bare .pp-cur { max-width: 320px; font-weight: 400; color: var(--pp-mute); }
.pp-tab { all: unset; box-sizing: border-box; cursor: pointer; display: flex; align-items: center; gap: 6px; height: 32px; padding: 0 12px; border-radius: 12px; color: var(--pp-text); font-weight: 500; font-size: 13px; transition: background .15s, color .15s, transform .15s var(--pp-spring); }
.pp-tab[hidden] { display: none; }
.pp-tab:hover { background: rgba(255, 255, 255, .07); color: var(--pp-ink); } .pp-tab:active { transform: scale(.96); }
.pp-tab[aria-expanded="true"] { background: var(--pp-ink); color: #111; }
.pp-tab:focus-visible, .pp-item:focus-visible, .pp-root button:focus-visible, .pp-root a:focus-visible { outline: 2px solid rgba(255, 255, 255, .85); outline-offset: -2px; }
.pp-cnt { padding: 2px 8px; border-radius: 999px; font-size: 11px; font-weight: 500; background: rgba(255, 255, 255, .1); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .06); }
.pp-tab[aria-expanded="true"] .pp-cnt { background: rgba(0, 0, 0, .12); color: #111; box-shadow: none; }

.pp-panel { position: absolute; left: 0; bottom: calc(100% + 10px); width: 400px; max-width: calc(100vw - var(--pp-left, 20px) - 12px); max-height: min(60vh, 520px); display: flex; flex-direction: column; border-radius: 16px; transform-origin: 0 100%;
  opacity: 0; transform: translateY(14px) scale(.94); visibility: hidden; pointer-events: none; transition: opacity .2s ease, transform .45s var(--pp-spring), visibility 0s .45s; }
.pp-root.pp-open .pp-panel { opacity: 1; transform: none; visibility: visible; pointer-events: auto; transition-delay: 0s; }
.pp-sh { display: flex; align-items: baseline; justify-content: space-between; padding: 16px 20px 8px; }
.pp-ttl { font-size: 20px; letter-spacing: -.02em; font-weight: 500; color: var(--pp-ink); font-optical-sizing: auto; font-variation-settings: "opsz" 32; }
.pp-n { color: var(--pp-faint); font-size: 12px; }
.pp-scroll { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 4px 10px 10px; scrollbar-width: thin; scrollbar-color: rgba(255, 255, 255, .2) transparent; }
.pp-stg { opacity: 0; transform: translateY(8px); }
.pp-root.pp-open .pp-stg { animation: pp-in .45s var(--pp-ease) forwards; animation-delay: calc(var(--i, 0) * 30ms + 80ms); }
@keyframes pp-in { to { opacity: 1; transform: none; } }
.pp-gl { margin: 0; padding: 12px 12px 4px; font-size: 11px; font-weight: 500; letter-spacing: .07em; text-transform: uppercase; color: var(--pp-faint); }
.pp-empty { margin: 0; padding: 10px 12px; color: var(--pp-mute); }
.pp-nm { flex: 1; min-width: 0; color: var(--pp-ink); font-weight: 500; }
.pp-ct { font-size: 11px; color: var(--pp-faint); white-space: nowrap; }
.pp-kd { flex: none; padding: 1px 7px; border-radius: 999px; font-size: 10px; font-weight: 500; letter-spacing: .02em; color: var(--pp-mute); background: rgba(255, 255, 255, .06); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .07); }
.pp-k-error { color: #fc8580; background: rgba(251, 92, 85, .12); box-shadow: none; } .pp-k-modal { color: #a9b8ff; background: rgba(143, 162, 255, .12); box-shadow: none; } .pp-k-toast { color: #8fd7a0; background: rgba(110, 202, 127, .12); box-shadow: none; }
.pp-th { position: relative; flex: none; overflow: hidden; border-radius: 8px; }
.pp-th iframe { max-width: none; max-height: none; position: absolute; left: 0; top: 0; width: 1280px; height: 800px; border: 0; transform-origin: 0 0; pointer-events: none; opacity: 0; transition: opacity .3s; }
.pp-th.pp-th-on iframe { opacity: 1; }
.pp-th::after { content: ""; position: absolute; inset: 0; background: linear-gradient(110deg, #e9ebee 30%, #f6f7f8 50%, #e9ebee 70%); background-size: 200% 100%; animation: pp-sh 1.2s linear infinite; transition: opacity .3s; pointer-events: none; }
.pp-th.pp-th-on::after { opacity: 0; animation: none; }
@keyframes pp-sh { to { background-position: -200% 0; } }
.pp-ra { all: unset; box-sizing: border-box; display: flex; align-items: center; gap: 12px; width: 100%; padding: 8px 10px 8px 12px; border-radius: 12px; cursor: pointer; position: relative; transition: background .15s, transform .15s var(--pp-spring); color: var(--pp-text); }
.pp-ra:hover { background: rgba(255, 255, 255, .05); } .pp-ra:active { transform: scale(.985); }
.pp-tx { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; } .pp-ds { font-size: 12px; color: var(--pp-mute); line-height: 1.3; }
.pp-ra[aria-current="true"] { background: rgba(255, 255, 255, .05); }
.pp-ra[aria-current="true"]::before, .pp-st[aria-current="true"]::before { content: ""; position: absolute; left: 0; top: 9px; bottom: 9px; width: 2px; border-radius: 2px; background: var(--pp-brand); }
.pp-fl { border-radius: 12px; } .pp-fl.pp-x { background: rgba(255, 255, 255, .03); }
.pp-fh { all: unset; box-sizing: border-box; display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px 12px; border-radius: 12px; cursor: pointer; color: var(--pp-text); transition: background .15s; }
.pp-fh:hover { background: rgba(255, 255, 255, .05); }
.pp-fh[aria-current="true"] .pp-nm::after { content: ""; display: inline-block; width: 6px; height: 6px; margin-left: 8px; border-radius: 50%; background: var(--pp-brand); vertical-align: middle; }
.pp-chv { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; transition: transform .4s var(--pp-spring); opacity: .6; } .pp-fl.pp-x .pp-chv { transform: rotate(90deg); }
.pp-ico { width: 14px; height: 14px; }
.pp-tl { list-style: none; margin: 0; padding: 0 8px 0 0; overflow: hidden; max-height: 0; opacity: 0; visibility: hidden; transition: max-height .5s var(--pp-spring), opacity .25s, padding .3s, visibility 0s .5s; }
.pp-fl.pp-x .pp-tl { max-height: 520px; opacity: 1; padding: 2px 8px 10px 0; visibility: visible; transition-delay: 0s; }
.pp-tl li { position: relative; } .pp-tl li::before { content: ""; position: absolute; left: 21px; top: 0; bottom: 0; width: 1px; background: var(--pp-line2); } .pp-tl li:first-child::before { top: 50%; } .pp-tl li:last-child::before { bottom: 50%; }
.pp-st { all: unset; box-sizing: border-box; position: relative; display: flex; align-items: center; gap: 10px; width: 100%; padding: 6px 8px 6px 12px; border-radius: 10px; cursor: pointer; color: var(--pp-text); transition: background .15s; }
.pp-st:hover { background: rgba(255, 255, 255, .06); color: var(--pp-ink); }
.pp-nn { position: relative; z-index: 1; flex: none; width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; font-size: 10px; font-weight: 500; background: var(--pp-fill); box-shadow: 0 0 0 1px var(--pp-line2); color: var(--pp-mute); transition: background .2s, color .2s, box-shadow .2s; }
.pp-tt { flex: 1; min-width: 0; font-size: 12.5px; }
.pp-st[aria-current="true"] { color: var(--pp-ink); } .pp-st[aria-current="true"] .pp-nn { background: var(--pp-brand); color: #1a0d03; box-shadow: none; } .pp-st[aria-current="true"]::before { top: 6px; bottom: 6px; }
.pp-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 8px 14px 10px; border-top: 1px solid var(--pp-line); }
.pp-link { all: unset; box-sizing: border-box; cursor: pointer; padding: 5px 8px; border-radius: 8px; font-size: 12px; color: var(--pp-mute); transition: background .12s, color .12s; }
.pp-link:hover { background: rgba(255, 255, 255, .06); color: var(--pp-ink); }
.pp-actions { display: none !important; }
@media (max-width: 600px) { .pp-cur { max-width: 34vw; } }
@media (prefers-reduced-motion: reduce) { .pp-root, .pp-panel, .pp-tab, .pp-chv, .pp-tl, .pp-ra, .pp-st, .pp-th iframe { transition: none !important; } .pp-stg { opacity: 1; transform: none; animation: none !important; } .pp-th::after { animation: none; } }

/* Responsive: on a phone the pill is a compact bottom bar (full width minus 16px) and its panel a bottom sheet (max 75vh). Tooling, layout only. */
@media (max-width: 599px) {
  .pp-root { left: 8px !important; right: 8px; bottom: max(8px, env(safe-area-inset-bottom)); width: auto; max-width: none; align-items: stretch; }
  .pp-root.pp-low { bottom: max(6px, env(safe-area-inset-bottom)); }
  .pp-bar { width: 100%; overflow-x: auto; scrollbar-width: none; }
  .pp-cur, .pp-root.pp-bare .pp-cur { flex: 1 1 auto; min-width: 0; max-width: none; }
  .pp-tab { height: 44px; flex: none; }
  .pp-panel { left: 0; right: 0; width: auto; max-width: none; max-height: min(75dvh, calc(100dvh - 90px)); border-radius: 16px 16px 8px 8px; }
  .pp-link, .pp-ra, .pp-st, .pp-fh { min-height: 44px; }
}
@media (max-width: 1024px) { .pp-tab { min-height: 40px; } }

/* Touch: 44px tab, fields at 16px so iOS never zooms */
@media (pointer: coarse) { .pp-tab { min-height: 44px; } .pp-root :is(input, select, textarea) { font-size: 16px; } }

/* ---- Position and minimise (2026-11-01): far left, 16px from the window edge and bottom; ?pill=a|b|c compares three minimised forms ---- */
.pp-root { --pp-l: 16px; left: var(--pp-l); bottom: 16px; max-width: calc(100vw - var(--pp-l) - 12px); }
.pp-root.pp-low { bottom: 6px; }
.pp-panel { max-width: calc(100vw - var(--pp-l) - 12px); }
.pp-bar { transition: border-radius .35s var(--pp-ease), transform .4s var(--pp-ease), padding .3s var(--pp-ease); }
.pp-full { display: flex; align-items: center; gap: 4px; min-width: 0; max-width: 700px; overflow: hidden; transition: max-width .4s var(--pp-ease), opacity .25s ease, visibility 0s; }
.pp-tabs { display: flex; align-items: center; gap: 4px; max-width: 300px; overflow: hidden; transition: max-width .4s var(--pp-ease), opacity .25s ease, visibility 0s; }
.pp-tabs[hidden] { display: none; }
.pp-mn { all: unset; box-sizing: border-box; flex: none; cursor: pointer; width: 32px; height: 32px; display: grid; place-items: center; border-radius: 12px; color: var(--pp-text); font-size: 12px; transition: background .15s, color .15s, transform .4s var(--pp-spring); }
.pp-mn:hover { background: rgba(255, 255, 255, .07); color: var(--pp-ink); }
.pp-mn:active { transform: scale(.94); }
.pp-mn .fa { font-size: 12px; line-height: 1; }
.pp-fab { all: unset; box-sizing: border-box; position: relative; flex: none; cursor: pointer; width: 0; height: 40px; opacity: 0; visibility: hidden; display: grid; place-items: center; border-radius: 50%; color: var(--pp-ink); font-size: 16px; transition: width .4s var(--pp-ease), opacity .25s ease, visibility 0s .4s, background .15s; }
.pp-fab:hover { background: rgba(255, 255, 255, .08); }
.pp-fab .fa { font-size: 16px; line-height: 1; }
.pp-bdg { position: absolute; top: -4px; right: -4px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 999px; display: grid; place-items: center; background: var(--pp-brand); color: #1a0d03; font: 500 10px/1 Inter, system-ui, sans-serif; box-shadow: 0 0 0 2px #15171a; }
.pp-edge { all: unset; box-sizing: border-box; position: absolute; left: calc(-1 * var(--pp-l)); bottom: 0; width: 28px; height: 112px; display: grid; place-items: center; cursor: pointer; border-radius: 0 12px 12px 0; color: var(--pp-text);
  background: linear-gradient(180deg, rgba(27, 29, 32, .96), rgba(18, 19, 21, .96)); box-shadow: 0 0 0 1px rgba(255, 255, 255, .18), inset 0 1px 0 rgba(255, 255, 255, .08), 6px 6px 18px -8px rgba(0, 0, 0, .6);
  transform: translateX(-100%); visibility: hidden; transition: transform .4s var(--pp-ease), visibility 0s .4s, color .15s; }
.pp-edge:hover { color: var(--pp-ink); }
.pp-edge-t { writing-mode: vertical-rl; transform: rotate(180deg); font-size: 12px; font-weight: 500; letter-spacing: .04em; white-space: nowrap; }
.pp-mn:focus-visible, .pp-fab:focus-visible, .pp-edge:focus-visible, .pp-v-c .pp-cur:focus-visible { outline: 2px solid var(--pp-brand); outline-offset: 2px; }
.pp-v-c .pp-cur { cursor: pointer; border-radius: 12px; display: flex; align-items: center; height: 32px; transition: background .15s; } .pp-v-c .pp-cur:hover { background: rgba(255, 255, 255, .07); }

/* a: collapse to a 40px chip */
.pp-v-a.pp-min .pp-bar { padding: 0; border-radius: 20px; }
.pp-v-a.pp-min .pp-full { max-width: 0; opacity: 0; visibility: hidden; pointer-events: none; transition: max-width .4s var(--pp-ease), opacity .2s ease, visibility 0s .4s; }
.pp-v-a.pp-min .pp-fab { width: 40px; opacity: 1; visibility: visible; transition: width .4s var(--pp-ease), opacity .3s ease .1s, visibility 0s, background .15s; }
.pp-v-a:not(.pp-min) .pp-fab { pointer-events: none; }
.pp-v-a.pp-min.pp-open .pp-panel { display: none; }
.pp-v-b .pp-fab, .pp-v-c .pp-fab { display: none; }
.pp-v-a .pp-mn .fa { transition: transform .4s var(--pp-spring); }

/* b: edge tab (the pill slides off to the left, a 28px tab stays) */
.pp-v-b.pp-min .pp-bar { transform: translateX(calc(-100% - 24px)); opacity: 0; visibility: hidden; pointer-events: none; transition: transform .4s var(--pp-ease), opacity .25s ease, visibility 0s .4s; }
.pp-v-b.pp-min .pp-edge { transform: none; visibility: visible; transition: transform .4s var(--pp-ease), visibility 0s, color .15s; }
.pp-v-b:not(.pp-min) .pp-edge { pointer-events: none; }

/* c: peek handle (name + chevron; States and Flows hide) */
.pp-v-c.pp-min .pp-tabs { max-width: 0; opacity: 0; visibility: hidden; pointer-events: none; transition: max-width .4s var(--pp-ease), opacity .2s ease, visibility 0s .4s; }
.pp-v-c .pp-mn .fa { transition: transform .4s var(--pp-spring); }
.pp-v-c.pp-min .pp-mn .fa { transform: rotate(180deg); }
.pp-v-c.pp-min.pp-open .pp-panel { display: none; }

@media (max-width: 599px) {
  .pp-root { --pp-l: 8px; bottom: max(16px, env(safe-area-inset-bottom)); } .pp-root.pp-low { bottom: max(6px, env(safe-area-inset-bottom)); }
  .pp-v-a.pp-min { right: auto; width: 40px; align-items: flex-start; }
  .pp-v-a.pp-min .pp-bar { width: 40px; overflow: visible; }
  .pp-mn, .pp-fab, .pp-v-a.pp-min .pp-fab { min-height: 44px; }
  .pp-v-a.pp-min .pp-fab { width: 44px; height: 44px; } .pp-v-a.pp-min .pp-bar { width: 44px; border-radius: 22px; }
  .pp-edge { width: 28px; min-height: 112px; }
}
@media (prefers-reduced-motion: reduce) { .pp-bar, .pp-full, .pp-tabs, .pp-fab, .pp-edge, .pp-mn, .pp-mn .fa { transition: none !important; } }

/* icon fallback when the live thumbnail is too heavy (phones) or failed to load */
.pp-th.pp-th-ic { display: grid; place-items: center; background: rgba(255, 255, 255, .08); color: rgba(255, 255, 255, .72); box-shadow: 0 0 0 1px rgba(255, 255, 255, .12); }
.pp-th.pp-th-ic::after { content: none; animation: none; }
.pp-th.pp-th-ic .fa { font-size: 18px; line-height: 1; }

/* r16: one icon tile for every state and flow step: fixed size, muted tile, icon centred (no live iframes) */
.pp-th.pp-th-ic .fa { font-size: 16px; }
.pp-th.pp-th-fs { width: 24px; height: 24px; position: relative; z-index: 1; background: var(--pp-fill, rgba(255,255,255,.08)); } .pp-th.pp-th-fs .fa { font-size: 12px; }
.pp-tl li::before { left: 24px; }
.pp-st[aria-current="true"] .pp-th.pp-th-fs { background: var(--pp-brand); color: #1a0d03; box-shadow: none; }

/* r16: 480 and below, the expanded pill never clips: the state name shrinks with an ellipsis first; States + count, Flows + count and the chevron stay whole */
@media (max-width: 480px) {
  .pp-root:not(.pp-min) .pp-bar { overflow: hidden; gap: 2px; padding: 4px; }
  .pp-root:not(.pp-min) .pp-full { flex: 1 1 auto; min-width: 0; max-width: none; width: 100%; gap: 2px; overflow: hidden; }
  .pp-root:not(.pp-min) .pp-cur, .pp-root:not(.pp-min).pp-bare .pp-cur { flex: 1 1 0; min-width: 0; padding: 0 6px 0 8px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .pp-root:not(.pp-min) .pp-tabs { flex: none; max-width: none; overflow: visible; gap: 2px; }
  .pp-root:not(.pp-min) .pp-tab { padding: 0 8px; gap: 4px; flex: none; white-space: nowrap; }
  .pp-root:not(.pp-min) .pp-mn { flex: none; }
}
