/* Helm Support demo: a fictional help desk, not a real product. Coordinates
   are stage pixels (1200x675). Palette: slate #1c2733 / #2e3d4f chrome,
   grey-800 #2f3941, grey-600 #68737d, canvas #f8f9f9, blue #2563eb,
   green #038153, violet #6c3fb5 for anything AI. */
html, body { margin: 0; height: 100%; background: #fff; }
.ud-frame { height: 100%; }
.ud-stage { --font: -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, ui-sans-serif, sans-serif; background: #f1f5f5; font-family: var(--font); color: #2f3941; }
.ud-cursor__ring { border-color: #2563eb; }
.ud-stage .hidden { display: none; }
.ic { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.ic--fill { fill: currentColor; stroke: none; }
.ic--ai { color: #6c3fb5; }
.caret { display: inline-block; width: 0; height: 0; border-left: 5px solid transparent; border-right: 5px solid transparent; border-top: 6px solid #2f3941; margin-left: 8px; }
.av { display: inline-flex; align-items: center; justify-content: center; width: 24px; height: 24px; border-radius: 50%; font: 600 10px/1 var(--font); color: #fff; flex: none; }
.av--p { background: #d93f4c; } .av--sys { background: #6c3fb5; } .av--sys .ic { width: 14px; height: 14px; }
.av--lg { width: 40px; height: 40px; font-size: 14px; }

/* Captions: 1 and 6 are opening/closing titles centred over the stage. The
   middle ones are coach-mark cards that float over the UI near whatever the
   cursor is doing, so the eye doesn't have to leave the action to read them.
   z-index 40 clears every in-app layer (max 8) and sits under the cursor (50). */
.caption { position: absolute; z-index: 40; text-align: center; font: 600 28px/1.2 var(--font); color: #1c2733; letter-spacing: -0.01em; opacity: 0; }
.caption .dot { color: #2563eb; }
.caption--title { left: 0; right: 0; top: 22px; }
/* Solid slate card with light text: a white card on the app's white UI reads
   as a rendering glitch rather than a callout, so the card owns its own surface.
   Each card straddles an app edge, bleeding ~40px onto the stage backdrop, so
   it reads as an overlay on the demo rather than a panel inside the product.
   The bleed side gets extra padding so text clears the app boundary. */
.caption--card { text-align: left; font: 600 19px/1.35 var(--font); color: #fff;
  box-sizing: border-box; padding: 16px 18px; border-radius: 10px; background: #1c2733;
  box-shadow: 0 18px 44px rgba(28, 39, 51, 0.38); }
/* App edges are x60 and x1140; bleed cards overhang by 40 and pad that side. */
.caption--left  { left: 20px;  padding-left: 58px; }
.caption--right { right: 20px; padding-right: 58px; text-align: right; }
.caption--top   { top: 40px;   padding-top: 56px; }
/* 2: triage fills the props column on the far left (x120..360), so the card
   hugs the right edge, low. */
.caption--triage { top: 400px; width: 330px; }
/* 3: the copilot clicks land mid and low in the conversation column
   (750,446 and 736,612), so the card hugs the right edge high above them. */
.caption--copilot { top: 150px; width: 330px; }
/* 4: the dashboard widgets fill the scene from y244 down, so the card bleeds
   off the TOP edge over the header band instead of covering a chart. */
.caption--reports { left: 340px; width: 400px; }
/* 5: the range picker is clicked at 1051,179 top-right, so the card hugs the
   left edge low, far from the menu. */
.caption--filter { top: 420px; width: 330px; }

/* App window: 60,80 → 1140,635 */
.app { position: absolute; left: 60px; top: 80px; width: 1080px; height: 555px; border-radius: 12px; background: #fff; overflow: hidden; opacity: 0;
  box-shadow: 0 30px 60px rgba(28, 39, 51, 0.22), 0 0 0 1px rgba(28, 39, 51, 0.08); }

/* Icon rail, width 60; nav item i is centred at app y 62+17+40i */
.rail { position: absolute; left: 0; top: 0; width: 60px; bottom: 0; background: #1c2733; padding-top: 62px; box-sizing: border-box; display: flex; flex-direction: column; align-items: center; gap: 6px; z-index: 3; }
.logo { position: absolute; left: 16px; top: 12px; width: 28px; height: 28px; }
.logo svg { width: 28px; height: 28px; fill: none; stroke: #fff; stroke-width: 1.8; stroke-linecap: round; }
.rail i { display: flex; align-items: center; justify-content: center; width: 36px; height: 34px; border-radius: 6px; color: #b8c4d1; opacity: 0; }
.rail__active { background: #2e3d4f; color: #fff !important; }
.rail__bottom { position: absolute; bottom: 10px; }

/* Top bar with ticket tabs, height 48 */
.top { position: absolute; left: 60px; top: 0; right: 0; height: 48px; background: #fff; border-bottom: 1px solid #d8dcde; display: flex; align-items: stretch; }
.tab { display: flex; align-items: center; gap: 8px; max-width: 250px; padding: 0 18px; font: 400 13px/1 var(--font); color: #68737d; border-right: 1px solid #d8dcde; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tab--active { color: #2f3941; font-weight: 600; box-shadow: inset 0 -3px 0 #2563eb; }
.tab__pri { flex: none; width: 8px; height: 8px; border-radius: 2px; background: #d8dcde; }
.top__add { width: 48px; display: flex; align-items: center; justify-content: center; font: 300 22px/1 var(--font); color: #68737d; }
.top__icons { margin-left: auto; display: flex; align-items: center; gap: 20px; padding-right: 20px; color: #68737d; }
.top__user { align-self: center; width: 30px; height: 30px; margin-right: 14px; border-radius: 50%; background: #2e3d4f; color: #fff; font: 600 11px/30px var(--font); text-align: center; }

/* ---- Scenes: app x 60..1080, y 48..555 ---------------------------------- */
.scene { position: absolute; left: 60px; top: 48px; right: 0; bottom: 0; }
.scene--hidden { opacity: 0; }

/* Ticket properties: app 60..300 */
.props { position: absolute; left: 0; top: 0; width: 240px; bottom: 0; box-sizing: border-box; padding: 14px 20px; background: #f8f9f9; border-right: 1px solid #d8dcde; }
.field { margin-bottom: 10px; opacity: 0; }
.field small { display: block; font: 400 11px/1 var(--font); color: #68737d; margin-bottom: 6px; }
.field > span { display: flex; align-items: center; gap: 8px; min-height: 32px; box-sizing: border-box; padding: 0 10px; border: 1px solid #d8dcde; border-radius: 4px; background: #fff; font: 400 13px/1 var(--font); color: #2f3941; }
.field .av { width: 20px; height: 20px; font-size: 8px; }
.pri--high { color: #cc3340; font-weight: 600; }
.tags { flex-wrap: wrap; gap: 6px !important; padding: 5px 8px !important; }
.tags b { padding: 4px 8px; border-radius: 4px; background: #e9ebed; font: 500 11px/1 var(--font); color: #2f3941; }
.tags .tag--ai { background: #eeeaf7; color: #6c3fb5; opacity: 0; }
.triage { margin-top: 12px; padding-top: 10px; border-top: 1px solid #d8dcde; }
.triage__head { display: flex; align-items: center; gap: 6px; font: 600 12px/1 var(--font); color: #2f3941; margin-bottom: 10px; opacity: 0; }
.triage__row { margin-bottom: 8px; opacity: 0; }
.triage__row small { display: block; font: 400 11px/1 var(--font); color: #68737d; margin-bottom: 4px; }
.triage__row span { display: flex; align-items: center; gap: 6px; font: 500 13px/1.3 var(--font); color: #2f3941; }
.triage__row em { margin-left: auto; font: 400 11px/1 var(--font); font-style: normal; color: #68737d; }
.dot { width: 8px; height: 8px; border-radius: 50%; }
.dot--neg { background: #cc3340; }

/* Conversation: app 300..760 */
.convo { position: absolute; left: 240px; top: 0; width: 460px; bottom: 0; background: #fff; border-right: 1px solid #d8dcde; }
.convo__head { padding: 18px 24px 14px; border-bottom: 1px solid #e9ebed; opacity: 0; }
.convo__title { font: 600 16px/1.3 var(--font); color: #2f3941; }
.convo__meta { display: flex; align-items: center; gap: 8px; margin-top: 6px; font: 400 12px/1 var(--font); color: #68737d; }
.status { padding: 3px 7px; border-radius: 3px; font: 600 10px/1 var(--font); text-transform: uppercase; color: #fff; }
.status--open { background: #cc3340; } .status--solved { background: #68737d; }
.msg { display: flex; gap: 12px; padding: 12px 24px 4px; opacity: 0; }
.msg__who { font: 600 13px/1.3 var(--font); color: #2f3941; }
.msg__who small { font-weight: 400; color: #68737d; margin-left: 6px; }
.msg p { margin: 6px 0 0; font: 400 13px/1.5 var(--font); color: #2f3941; }
.msg--note .msg__body { padding: 8px 12px; border-radius: 6px; background: #fff8e1; }
.msg--note .msg__who { font-size: 12px; }

/* Composer: convo bottom 212 → app y 343..555 */
.composer { position: absolute; left: 0; right: 0; bottom: 0; height: 212px; border-top: 1px solid #d8dcde; background: #fff; opacity: 0; }
.composer__bar { position: relative; height: 40px; display: flex; align-items: center; padding: 0 14px; border-bottom: 1px solid #e9ebed; }
.composer__tab { padding: 0 10px; font: 400 12px/40px var(--font); color: #68737d; }
.composer__tab--active { color: #2f3941; font-weight: 600; box-shadow: inset 0 -2px 0 #2f3941; }
.assist { position: absolute; right: 14px; top: 7px; height: 26px; width: 122px; display: flex; align-items: center; justify-content: center; gap: 6px; border: 1px solid #c9b8e8; border-radius: 4px; background: #f6f2fc; color: #6c3fb5; font: 600 12px/1 var(--font); }
.assist .ic { width: 14px; height: 14px; }
.thinking { position: absolute; left: 18px; top: 56px; display: flex; gap: 5px; opacity: 0; }
.thinking i { width: 7px; height: 7px; border-radius: 50%; background: #6c3fb5; }
.thinking i:nth-child(2) { opacity: 0.6; } .thinking i:nth-child(3) { opacity: 0.3; }
.composer__text { position: absolute; left: 18px; right: 18px; top: 48px; height: 104px; font: 400 13px/1.45 var(--font); color: #2f3941; white-space: pre-wrap; overflow: hidden; }
.composer__foot { position: absolute; left: 0; right: 0; bottom: 0; height: 52px; display: flex; align-items: center; gap: 10px; padding: 0 14px; border-top: 1px solid #e9ebed; }
.composer__tools { display: flex; gap: 14px; color: #68737d; margin-right: auto; }
.btn { height: 34px; border: 0; border-radius: 4px; font: 600 13px/1 var(--font); box-sizing: border-box; padding: 0 16px; }
.btn--ghost { background: #fff; border: 1px solid #d8dcde; color: #2f3941; }
.btn--primary { background: #2563eb; color: #fff; width: 150px; padding: 0; }
.toast { position: absolute; left: 24px; bottom: 226px; display: flex; align-items: center; gap: 8px; padding: 12px 16px; border-radius: 6px; background: #1c2733; color: #fff; font: 500 13px/1 var(--font); box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2); opacity: 0; z-index: 5; }
.toast .ic { color: #5eae91; }

/* Context panel: app 760..1080 */
.ctx { position: absolute; left: 700px; top: 0; width: 320px; bottom: 0; box-sizing: border-box; padding: 18px 20px; background: #fff; }
.ctx__section { padding-bottom: 14px; margin-bottom: 14px; border-bottom: 1px solid #e9ebed; opacity: 0; }
.ctx__section:last-child { border-bottom: 0; }
.ctx__title { font: 600 12px/1 var(--font); color: #68737d; text-transform: uppercase; letter-spacing: 0.04em; margin-bottom: 12px; }
.cust { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.cust b { display: block; font: 600 14px/1.3 var(--font); color: #2f3941; }
.cust small { font: 400 12px/1.3 var(--font); color: #68737d; }
.kv { display: flex; justify-content: space-between; padding: 5px 0; font: 400 12px/1.3 var(--font); color: #68737d; }
.kv b { font-weight: 500; color: #2f3941; }
.hist { display: flex; align-items: center; gap: 10px; padding: 7px 0; font: 400 13px/1.3 var(--font); color: #2563eb; }
.hist .ic { width: 16px; height: 16px; color: #68737d; }
.hist em { margin-left: auto; font: 500 11px/1 var(--font); font-style: normal; color: #038153; }

/* ---- Reports --------------------------------------------------------------- */
.head { position: absolute; left: 0; top: 0; right: 0; height: 96px; background: #fff; border-bottom: 1px solid #d8dcde; }
.head__title { position: absolute; left: 24px; top: 22px; display: flex; align-items: center; gap: 10px; font: 600 18px/1 var(--font); color: #2f3941; }
.head__sep { width: 1px; height: 20px; background: #d8dcde; }
.tabs { position: absolute; left: 24px; bottom: 0; display: flex; gap: 32px; font: 400 14px/1 var(--font); color: #68737d; }
.tabs span { padding: 0 4px 12px; }
.tabs__active { color: #2f3941; font-weight: 600; box-shadow: inset 0 -3px 0 #2563eb; }
/* Range picker centre ≈ stage 1046,176; menu item 2 centre ≈ stage 1046,260 */
.range { position: absolute; right: 24px; top: 30px; width: 140px; height: 36px; box-sizing: border-box; display: flex; align-items: center; justify-content: center; border: 1px solid #d8dcde; border-radius: 4px; background: #fff; font: 500 13px/1 var(--font); color: #2f3941; opacity: 0; }
.menu { position: absolute; right: 24px; top: 72px; width: 180px; box-sizing: border-box; padding: 6px 0; border-radius: 4px; background: #fff; border: 1px solid #d8dcde; box-shadow: 0 12px 30px rgba(0, 0, 0, 0.16); opacity: 0; z-index: 8; }
.menu__item { height: 36px; padding: 0 16px; font: 400 13px/36px var(--font); color: #2f3941; }
.menu__item--active { background: #eaf1fe; color: #2563eb; font-weight: 600; }

.dash { position: absolute; left: 24px; right: 24px; top: 116px; bottom: 0; }
.tile { position: absolute; top: 0; width: 228px; height: 86px; box-sizing: border-box; padding: 14px 16px; border-radius: 6px; background: #fff; border: 1px solid #d8dcde; opacity: 0; }
.tile:nth-child(1) { left: 0; } .tile:nth-child(2) { left: 248px; } .tile:nth-child(3) { left: 496px; } .tile:nth-child(4) { left: 744px; }
.tile small { display: block; font: 400 11px/1 var(--font); color: #68737d; }
.tile b { display: block; margin-top: 8px; font: 600 22px/1 var(--font); color: #2f3941; }
.tile em { display: block; margin-top: 6px; font: 400 11px/1 var(--font); font-style: normal; color: #68737d; }
.tile em.up { color: #038153; }
.wcard { position: absolute; box-sizing: border-box; padding: 16px 20px; border-radius: 6px; background: #fff; border: 1px solid #d8dcde; opacity: 0; }
.wcard--chart { left: 0; top: 106px; width: 640px; height: 268px; }
.wcard--side { left: 656px; top: 106px; width: 316px; height: 268px; padding-top: 16px; }
.wcard__title { font: 600 14px/1.3 var(--font); color: #2f3941; }
.chart { position: relative; height: 178px; margin-top: 16px; display: flex; align-items: flex-end; gap: 22px; padding: 0 6px; border-bottom: 1px solid #e9ebed; }
.bar { position: relative; flex: 1; height: var(--h); background: #2563eb; border-radius: 3px 3px 0 0; transform: scaleY(0); transform-origin: bottom; }
.bar:nth-child(n+6) { background: #b6c9f5; }
.bar span { position: absolute; left: 0; right: 0; bottom: -20px; text-align: center; font: 400 11px/1 var(--font); color: #68737d; }
.trow { display: grid; grid-template-columns: 1fr 70px 60px; align-items: center; height: 44px; border-top: 1px solid #e9ebed; font: 400 13px/1 var(--font); color: #2f3941; opacity: 0; }
.trow--head { margin-top: 10px; border-top: 0; height: 32px; font: 600 11px/1 var(--font); color: #68737d; text-transform: uppercase; letter-spacing: 0.04em; opacity: 1; }
.trow > span { display: flex; align-items: center; gap: 8px; }
.trow .ic { width: 16px; height: 16px; color: #68737d; }
