/* report/report.css — "Bug or idea?" side card + screenshot annotator (report/index.js). */

/* A side card on the LEFT, hugging the sidebar (JS pins `left` to its right
   edge): the mirror of the right-hand cards — rounded on the right, no left
   border. Not a modal: the app stays usable, the draft survives a close. It
   unrolls from the sidebar edge (clip-path) instead of sliding over it. */
.rep-panel {
  position: fixed; top: 8px; bottom: 8px; left: 0; width: 460px; max-width: 92vw;
  background: var(--surface);
  border: 1px solid var(--border); border-left: none;
  border-top-right-radius: 14px; border-bottom-right-radius: 14px;
  z-index: 108; display: flex; flex-direction: column;
  clip-path: inset(0 100% 0 0); opacity: 0; visibility: hidden;
  transition: clip-path .28s cubic-bezier(.4,0,.2,1), opacity .2s, visibility 0s linear .28s, left .25s cubic-bezier(.4,0,.2,1);
}
.rep-panel.open {
  /* -40px on the right lets the close tab stick out of the card. */
  clip-path: inset(0 -40px 0 0); opacity: 1; visibility: visible;
  box-shadow: 8px 0 32px rgba(0,0,0,.14);
  transition: clip-path .28s cubic-bezier(.4,0,.2,1), opacity .2s, visibility 0s, left .25s cubic-bezier(.4,0,.2,1);
}
/* While the window is captured, the card steps aside (no fade: it must be gone
   in the very next frame). */
.rep-panel.rep-hidden, .rep-close-tab.rep-hidden { opacity: 0 !important; transition: none !important; }
.rep-scroll { flex: 1; min-height: 0; overflow-y: auto; scrollbar-width: none; }
.rep-scroll::-webkit-scrollbar { display: none; }
/* The card's tab — on its right edge when open ("«" closes), parked on the
   sidebar edge when closed with a request in progress ("»" reopens). Lives in
   <body>, positioned by JS (_pinToSidebar). */
.rep-close-tab {
  position: fixed; top: 50%; transform: translateY(-50%); z-index: 109;
  /* Same hover as the right-hand cards' tabs: grows (wider + taller) with the
     springy height curve, darker orange. */
  transition: left .28s cubic-bezier(.4,0,.2,1), background .15s, width .15s, height .2s cubic-bezier(.34,1.45,.6,1);
  width: 30px; height: 88px; padding: 0; border: none; border-radius: 0 14px 14px 0;
  background: var(--primary); color: var(--on-accent);
  box-shadow: 6px 0 22px color-mix(in srgb, var(--primary) 45%, transparent);
  cursor: pointer; font-size: 19px; font-weight: 800; line-height: 1;
}
.rep-close-tab[hidden] { display: none; }
.rep-close-tab:hover { background: var(--primary-hover); width: 36px; height: 128px; }

.rep-card {
  padding: 20px 18px 18px;
  display: flex; flex-direction: column; gap: 10px;
}

/* One accent per kind (problem red, improvement violet, idea green, question
   pink) — the same four as Zonara's requests. */
.rep-kind-list { display: flex; flex-direction: column; gap: 8px; margin-top: 4px; }
.rep-kind-card {
  display: flex; align-items: center; gap: 12px; width: 100%; padding: 12px; text-align: left;
  border: 1px solid var(--border); border-radius: 12px; background: none; cursor: pointer; font-family: inherit;
  transition: border-color .15s, background .15s;
}
/* Doubled class: a global button rule fixes a height that squashed the two lines. */
.rep-kind-card.rep-kind-card { height: auto; min-height: 62px; }
.rep-kind-card:hover { border-color: var(--kc); background: color-mix(in srgb, var(--kc) 7%, transparent); }
.rep-kind-ico {
  width: 38px; height: 38px; border-radius: 10px; flex-shrink: 0;
  display: inline-flex; align-items: center; justify-content: center;
  background: color-mix(in srgb, var(--kc) 14%, transparent);
}
.rep-kind-ico .icon { background: var(--kc); }
.rep-kind-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.rep-kind-name { font-size: 14px; font-weight: 700; color: var(--text); }
.rep-kind-hint { font-size: 12px; color: var(--muted); line-height: 1.35; }
.rep-kind-chev { background: var(--muted); flex-shrink: 0; }
/* The chosen kind, above the form — click to pick another. */
.rep-card .rep-input {
  width: 100%; box-sizing: border-box; padding: 9px 11px;
  border: 1px solid var(--border); border-radius: 9px; background: var(--surface-2);
  color: var(--text); font-size: 13px; font-family: inherit; outline: none;
}
.rep-card .rep-input:focus { border-color: var(--primary); }
.rep-card .rep-textarea { min-height: 200px; resize: vertical; line-height: 1.5; }

.rep-shots { display: flex; flex-wrap: wrap; gap: 8px; }
.rep-shot { position: relative; width: 104px; height: 66px; }
.rep-shot-img {
  width: 100%; height: 100%; padding: 0; border: 1px solid var(--border); border-radius: 8px;
  overflow: hidden; cursor: pointer; background: var(--surface-2); position: relative;
}
.rep-shot-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.rep-shot-pen {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  background: rgba(0,0,0,.45); opacity: 0; transition: opacity .15s;
}
.rep-shot-pen .icon { background: #fff; }
.rep-shot-img:hover .rep-shot-pen { opacity: 1; }
.rep-shot-x {
  position: absolute; top: -6px; right: -6px; width: 20px; height: 20px; padding: 0;
  display: inline-flex; align-items: center; justify-content: center;
  border: 0; border-radius: 50%; background: var(--text); cursor: pointer;
}
.rep-shot-x .icon { background: var(--surface); }
.rep-hint { font-size: 11px; color: var(--muted); margin-top: -4px; }


.rep-check { display: flex; gap: 9px; align-items: flex-start; font-size: 12.5px; color: var(--text); line-height: 1.4; cursor: pointer; }
.rep-check input { margin-top: 2px; accent-color: var(--primary); flex-shrink: 0; }
.rep-check--public {
  padding: 10px 12px; border-radius: 10px;
  background: color-mix(in srgb, var(--primary) 9%, transparent);
  border: 1px solid color-mix(in srgb, var(--primary) 35%, transparent);
}
.rep-error { font-size: 12.5px; color: var(--danger-text); }

.rep-foot { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-top: 2px; }
.rep-btn.rep-btn--ghost { background: none; border-color: transparent; color: var(--muted); }
.rep-btn.rep-btn--ghost:hover { color: var(--text); background: var(--surface-2); }
.rep-btn {
  height: 38px; padding: 0 16px; display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  border: 1px solid var(--border); border-radius: 10px; background: var(--surface-2); color: var(--text);
  font-size: 13px; font-weight: 700; cursor: pointer; font-family: inherit;
}
.rep-btn .icon { background: currentColor; }
.rep-btn:disabled { opacity: .45; cursor: not-allowed; filter: none; }


/* Catalogue product picker (catalogue corrections). */
.rep-prod-search { position: relative; }
.rep-prod-search > .icon { position: absolute; left: 11px; top: 50%; transform: translateY(-50%); background: var(--muted); }
.rep-card .rep-prod-search .rep-input { padding-left: 32px; }
.rep-prod-results { display: flex; flex-direction: column; gap: 4px; }
.rep-prod-results:empty { display: none; }
.rep-prod {
  display: flex; align-items: center; gap: 10px; width: 100%; padding: 6px 8px; text-align: left;
  border: 1px solid transparent; border-radius: 10px; background: none; cursor: pointer; font-family: inherit;
}
.rep-prod.rep-prod { height: auto; }
.rep-prod:hover { background: var(--surface-2); }
.rep-prod img, .rep-prod-noimg { width: 38px; height: 38px; border-radius: 7px; object-fit: cover; flex-shrink: 0; background: var(--surface-2); }
.rep-prod-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.rep-prod-name { font-size: 13px; font-weight: 600; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rep-prod-sub { font-size: 11.5px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rep-prod-empty { font-size: 12px; color: var(--muted); padding: 4px 2px; }
.rep-prod--picked { cursor: default; border-color: color-mix(in srgb, #f08c00 45%, transparent); background: color-mix(in srgb, #f08c00 8%, transparent); }
.rep-prod--picked:hover { background: color-mix(in srgb, #f08c00 8%, transparent); }
.rep-prod-x {
  width: 26px; height: 26px; padding: 0; flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center;
  border: 0; border-radius: 7px; background: none; cursor: pointer;
}
.rep-prod-x .icon { background: var(--muted); }
.rep-prod-x:hover { background: var(--surface-2); }
/* A PDF attachment: named chip in the same slot as a screenshot thumb. */
.rep-shot--pdf .rep-pdf {
  width: 100%; height: 100%; box-sizing: border-box; padding: 6px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  border: 1px solid var(--border); border-radius: 8px; background: var(--surface-2);
}
.rep-pdf .icon { background: var(--danger); }
.rep-shot--json .rep-pdf .icon { background: #FFC83D; }
.rep-pdf-name { font-size: 10.5px; color: var(--text); max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ── Annotator (annotator.js) ── */
.rep-anno {
  position: fixed; inset: 0; z-index: 10050; display: flex; align-items: center; justify-content: center;
  padding: 28px; background: rgba(8,10,18,.62); backdrop-filter: blur(6px);
  animation: rep-anno-fade .18s ease-out;
}
.rep-anno-card {
  position: relative; display: flex; flex-direction: column;
  width: min(1180px, 100%); max-height: 100%; overflow: hidden;
  background: #11131a; border: 1px solid rgba(255,255,255,.1); border-radius: 16px;
  box-shadow: 0 24px 70px rgba(0,0,0,.55);
  animation: rep-anno-pop .22s cubic-bezier(.2,.9,.3,1.2);
}
.rep-anno-head { display: flex; flex-direction: column; gap: 2px; padding: 14px 18px 10px; }
.rep-anno-title { font-size: 16px; font-weight: 800; color: #fff; }
.rep-anno-sub { font-size: 12.5px; color: #9aa0b4; }
.rep-anno-bar {
  display: flex; align-items: center; gap: 6px; padding: 8px 12px; flex-wrap: wrap;
  background: #15171f; border-top: 1px solid rgba(255,255,255,.06); border-bottom: 1px solid rgba(255,255,255,.08);
}
@keyframes rep-anno-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes rep-anno-pop { from { opacity: 0; transform: translateY(8px) scale(.98); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .rep-anno, .rep-anno-card { animation: none; } }
.rep-anno-group { display: flex; align-items: center; gap: 3px; }
.rep-anno-tool {
  position: relative; width: 36px; height: 36px; padding: 0;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid transparent; border-radius: 8px; background: none; cursor: pointer;
}
.rep-anno-tool .icon { background: #c9cbd6; }
.rep-anno-tool kbd {
  position: absolute; right: 2px; bottom: 1px; font: 600 8px/1 ui-monospace, Menlo, monospace;
  color: #7d8193; background: none; border: 0; padding: 0;
}
.rep-anno-tool:hover:not(:disabled) { background: rgba(255,255,255,.07); }
.rep-anno-tool:disabled { opacity: .3; cursor: default; }
.rep-anno-tool.is-on { border-color: var(--primary); background: color-mix(in srgb, var(--primary) 18%, transparent); }
.rep-anno-tool.is-on .icon { background: var(--primary); }
.rep-anno-color { width: 22px; height: 22px; border-radius: 50%; border: 2px solid rgba(255,255,255,.22); cursor: pointer; padding: 0; margin: 0 1px; }
.rep-anno-color.is-on { outline: 2px solid var(--primary); outline-offset: 2px; }
.rep-anno-size {
  min-width: 30px; height: 28px; padding: 0 6px; border-radius: 7px; border: 1px solid rgba(255,255,255,.12);
  background: none; color: #c9cbd6; font: 700 11px system-ui, sans-serif; cursor: pointer;
}
.rep-anno-size.is-on { border-color: var(--primary); color: var(--primary-text); background: color-mix(in srgb, var(--primary) 14%, transparent); }
.rep-anno-sep { width: 1px; height: 24px; background: rgba(255,255,255,.12); margin: 0 4px; }
.rep-anno-grow { flex: 1; }
.rep-anno-stage { flex: 1; min-height: 0; display: flex; align-items: center; justify-content: center; padding: 18px; }
.rep-anno-canvas-wrap { position: relative; max-width: 100%; max-height: 100%; display: flex; }
.rep-anno-stage canvas {
  max-width: 100%; max-height: calc(100vh - 56px - 170px); touch-action: none; display: block;
  border-radius: 6px; box-shadow: 0 10px 40px rgba(0,0,0,.5);
}
/* Inline text box, placed over the canvas where the text goes. */
.rep-anno-text {
  position: absolute; min-width: 80px; padding: 0; margin: 0; border: 1px dashed rgba(25,113,194,.9);
  background: rgba(255,255,255,.04); outline: none; resize: none; overflow: hidden;
  font-weight: 700; font-family: system-ui, -apple-system, "Segoe UI", sans-serif; white-space: pre;
}
.rep-anno-tip {
  position: absolute; left: 50%; bottom: 14px; transform: translateX(-50%);
  padding: 6px 12px; border-radius: 8px; background: rgba(21,23,31,.92); color: #c9cbd6;
  font-size: 12px; pointer-events: none; white-space: nowrap;
}
.rep-anno-tip[hidden] { display: none; }

/* Attachments: a dashed drop zone at rest, so dropping files reads as possible. */
.rep-attach-count { font-weight: 600; letter-spacing: 0; color: var(--muted); text-transform: none; }

/* While files are dragged over the window: the whole card becomes the target. */
.rep-drop {
  position: absolute; inset: 8px; z-index: 5; border-radius: 12px;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; text-align: center;
  border: 2px dashed var(--primary); background: color-mix(in srgb, var(--surface) 82%, var(--primary) 18%);
  opacity: 0; pointer-events: none; transition: opacity .15s;
}
.rep-drop .icon { background: var(--primary); }
.rep-drop-title { font-size: 16px; font-weight: 800; color: var(--text); }
.rep-drop-sub { font-size: 12.5px; color: var(--muted); padding: 0 24px; }
.rep-panel.rep-dragging .rep-drop { opacity: 1; }
.rep-panel.rep-dragging .rep-drop .icon { animation: rep-drop-bob 1s ease-in-out infinite; }
@keyframes rep-drop-bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(5px); } }

/* "‹ Back" to the kind picker, above the form title. */
.rep-back {
  align-self: flex-start; display: inline-flex; align-items: center; gap: 4px; height: 26px; padding: 0 8px 0 4px; margin: -6px 0 -4px -4px;
  border: 0; border-radius: 7px; background: none; color: var(--muted); font-size: 12.5px; font-weight: 600; cursor: pointer; font-family: inherit;
}
.rep-back .icon { background: currentColor; }
.rep-back:hover { color: var(--text); background: var(--surface-2); }

/* Buy me a coffee — yellow like the brand button in the sidebar. */
.rep-coffee {
  display: flex; align-items: center; gap: 12px; width: 100%; margin-top: 6px; padding: 10px 12px; text-align: left;
  border: 1px solid color-mix(in srgb, #ffdd00 55%, transparent); border-radius: 12px;
  background: color-mix(in srgb, #ffdd00 10%, transparent); cursor: pointer; font-family: inherit;
  transition: background .15s, transform .15s;
}
.rep-coffee.rep-coffee { height: auto; }
.rep-coffee:hover { background: color-mix(in srgb, #ffdd00 18%, transparent); }
.rep-coffee-cup { width: 30px; height: 30px; flex-shrink: 0; }
.rep-coffee-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.rep-coffee-title { font-size: 13.5px; font-weight: 800; color: var(--text); }
.rep-coffee-sub { font-size: 12px; color: var(--muted); line-height: 1.4; }
.rep-coffee-cta {
  flex-basis: 100%; height: 36px; display: inline-flex; align-items: center; justify-content: center;
  border-radius: 10px; background: #ffdd00; color: #1a1a1a; font-size: 13px; font-weight: 800;
}
.rep-close-tab.is-parked { animation: rep-tab-nudge 2.4s ease-in-out 2; }
@keyframes rep-tab-nudge { 0%, 70%, 100% { transform: translateY(-50%); } 80% { transform: translate(4px, -50%); } 90% { transform: translate(0, -50%); } }

/* New request | My requests */
.rep-views { display: flex; gap: 4px; padding: 3px; border-radius: 10px; background: var(--surface-2); }
.rep-view {
  flex: 1; height: 32px; display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  border: 0; border-radius: 8px; background: none; color: var(--muted); font-size: 13px; font-weight: 700; cursor: pointer; font-family: inherit;
}
.rep-view.is-on { background: var(--surface); color: var(--text); box-shadow: 0 1px 3px rgba(0,0,0,.12); }
.rep-view-count { min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--primary); color: var(--on-accent); font-size: 11px; display: inline-flex; align-items: center; justify-content: center; }

/* My requests */
.rep-mine { display: flex; flex-direction: column; gap: 6px; }
.rep-mine-row { display: flex; align-items: center; gap: 10px; padding: 10px; border: 1px solid var(--border); border-radius: 12px; }
.rep-mine-row.is-final { opacity: .7; }
.rep-mine-row .rep-kind-ico { width: 32px; height: 32px; border-radius: 9px; }
.rep-mine-main { flex: 1; min-width: 0; }
.rep-mine-title { font-size: 13px; font-weight: 700; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rep-mine-sub { font-size: 11.5px; color: var(--muted); margin-top: 2px; }
.rep-status {
  flex-shrink: 0; height: 22px; padding: 0 8px; border-radius: 11px; display: inline-flex; align-items: center;
  font-size: 11px; font-weight: 700; color: var(--sc); background: color-mix(in srgb, var(--sc) 14%, transparent);
}
.rep-mine-acts { display: flex; align-items: center; gap: 2px; flex-shrink: 0; }
.rep-mine-btn {
  width: 28px; height: 28px; padding: 0; display: inline-flex; align-items: center; justify-content: center;
  border: 0; border-radius: 7px; background: none; cursor: pointer;
}
.rep-mine-btn .icon { background: var(--muted); }
.rep-mine-btn:hover { background: var(--surface-2); }
.rep-mine-btn:hover .icon { background: var(--text); }
.rep-mine-confirm {
  height: 28px; padding: 0 10px; border: 0; border-radius: 7px; background: var(--danger); color: #fff;
  font-size: 12px; font-weight: 700; cursor: pointer; font-family: inherit; white-space: nowrap;
}
.rep-mine-closing { width: 28px; text-align: center; color: var(--muted); }
.rep-mine-empty { font-size: 13px; color: var(--muted); padding: 18px 4px; text-align: center; line-height: 1.5; }

/* ═══ v2 — after the founder's mockup (4 screens + motion) ═══════════════════ */
.rep-panel { width: 540px; }   /* three tabs + request titles fit on one line */
.rep-card { position: relative; padding: 18px 18px 20px; gap: 12px; }
.rep-card--center { align-items: stretch; text-align: center; padding-top: 34px; }
.rep-x {
  position: absolute; top: 14px; right: 14px; width: 30px; height: 30px; z-index: 2;
  display: inline-flex; align-items: center; justify-content: center;
  border: 0; border-radius: 8px; background: none; cursor: pointer;
}
.rep-x .icon { background: var(--muted); }
.rep-x:hover { background: var(--ink-08, var(--surface-2)); }
.rep-x:hover .icon { background: var(--text); }

/* Screen change: horizontal slide (200 ms). */
.rep-in-right { animation: rep-in-right .2s cubic-bezier(.4,0,.2,1); }
.rep-in-left  { animation: rep-in-left  .2s cubic-bezier(.4,0,.2,1); }
@keyframes rep-in-right { from { transform: translateX(28px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes rep-in-left  { from { transform: translateX(-28px); opacity: 0; } to { transform: none; opacity: 1; } }

/* 1 — hero + tabs */
.rep-hero { display: flex; gap: 14px; align-items: flex-start; padding: 6px 40px 4px 2px; }
.rep-hero-ico { flex-shrink: 0; width: 52px; height: 52px; border-radius: 16px; display: inline-flex; align-items: center; justify-content: center;
  background: linear-gradient(140deg, #3b82f6, #6d28d9); box-shadow: 0 6px 22px rgba(59,130,246,.35); }
.rep-hero-ico .icon { background: #fff; }
.rep-hero-title { font-size: 21px; font-weight: 800; color: var(--text); letter-spacing: -.01em; }
.rep-hero-sub { font-size: 13px; color: var(--muted); line-height: 1.45; margin-top: 4px; }
.rep-views { display: flex; gap: 4px; padding: 4px; border-radius: 12px; background: var(--surface-2); }
.rep-view { height: 36px; gap: 7px; border-radius: 9px; font-size: 13px; }
.rep-view .icon { background: currentColor; }
.rep-view.is-on { background: #2563eb; color: #fff; box-shadow: 0 2px 10px rgba(37,99,235,.35); }
.rep-view.is-on .rep-view-count { background: #fff; color: #2563eb; }

/* Topic cards: a coloured tile on the left (--ki from KINDS, filled below with
   a white icon), chevron on the right — no separate accent stripe. Hover (180 ms):
   lighter ground, subtle border in the kind's colour, icon at 1.06. */
.rep-kind-list { gap: 8px; margin-top: 2px; }
.rep-kind-card.rep-kind-card {
  min-height: 64px; padding: 0 14px 0 0; gap: 14px; overflow: hidden; border-radius: 12px;
  background: color-mix(in srgb, var(--surface-2) 70%, transparent);
  transition: border-color 180ms, background 180ms;
}
.rep-kind-card .rep-kind-ico {
  align-self: stretch; width: 64px; height: auto; border-radius: 0; flex-shrink: 0;
  background: var(--kt);
}
.rep-kind-card .rep-kind-ico .icon { background: var(--ki); transition: transform 180ms; }
.rep-kind-card:hover {
  border-color: color-mix(in srgb, var(--ki) 45%, transparent);
  background: color-mix(in srgb, #fff 5%, var(--surface-2));
}
.rep-kind-card:hover .rep-kind-ico .icon { transform: scale(1.06); }
.rep-kind-chev { transition: transform 180ms, background 180ms; }
.rep-kind-card:hover .rep-kind-chev { transform: translateX(3px); background: var(--ki); }
@media (prefers-reduced-motion: reduce) {
  .rep-kind-card.rep-kind-card, .rep-kind-card .rep-kind-ico .icon, .rep-kind-chev { transition: none; }
  .rep-kind-card:hover .rep-kind-ico .icon, .rep-kind-card:hover .rep-kind-chev { transform: none; }
}
.rep-kind-name { font-size: 14.5px; }

/* Coffee card */
.rep-coffee {
  display: flex; align-items: flex-start; gap: 14px; margin-top: 6px; padding: 16px;
  border: 1.5px solid #f5c400; border-radius: 14px; background: color-mix(in srgb, #ffdd00 8%, transparent); cursor: default;
}
.rep-coffee-cup { width: 34px; height: 34px; }
.rep-coffee-title { font-size: 14px; }
.rep-coffee-sub { margin-top: 2px; }
.rep-coffee-cta.rep-coffee-cta {
  flex-basis: auto; align-self: flex-start; margin-top: 10px; height: 32px; padding: 0 14px; gap: 6px; border: 0; cursor: pointer;
  border-radius: 9px; background: #ffdd00; color: #1a1a1a; font-size: 13px; font-weight: 800; font-family: inherit;
  display: inline-flex; align-items: center;
}
.rep-coffee-cta .icon { background: #1a1a1a; }
.rep-coffee-cta:hover { filter: brightness(1.05); }

/* My requests rows: tile in the kind colour */
.rep-mine-row .rep-kind-ico { background: color-mix(in srgb, var(--kc) 16%, transparent); display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
.rep-mine-row .rep-kind-ico .icon { background: var(--kc); }

/* 2 — form */
.rep-topbar { display: flex; align-items: center; justify-content: space-between; min-height: 30px; }
.rep-topbar .rep-x { position: static; }
.rep-back { margin: 0; height: 30px; font-size: 13px; color: var(--text); }
.rep-form-head { display: flex; gap: 14px; align-items: flex-start; }
/* Which product the request is about (its issue lands in that product's repo). */
.rep-targets { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; margin-bottom: 4px; }
.rep-target {
  display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 10px 4px 8px;
  border-radius: 12px; border: 1px solid var(--border); background: transparent;
  color: var(--muted); font: inherit; font-size: 12px; font-weight: 600; cursor: pointer;
  transition: background .12s, color .12s, border-color .12s;
}
/* Doubled class: the global button rule fixes a height that squashed the tile. */
.rep-target.rep-target { height: auto; }
.rep-target:hover { background: var(--surface-2); color: var(--text); }
.rep-target.is-on { background: color-mix(in srgb, var(--kc, var(--primary)) 16%, transparent); border-color: var(--kc, var(--primary)); color: var(--text); }
.rep-target-ico {
  width: 34px; height: 34px; background-color: currentColor;
  -webkit-mask: var(--ico) center / contain no-repeat; mask: var(--ico) center / contain no-repeat;
}
.rep-target.is-on .rep-target-ico { background-color: var(--kc, var(--primary)); }
.rep-kind-ico--big { width: 54px; height: 54px; border-radius: 14px; flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--kc), color-mix(in srgb, var(--kc) 60%, #000)); }
.rep-kind-ico--big .icon { background: #fff; }
.rep-form-title { font-size: 17px; font-weight: 800; color: var(--text); }
.rep-form-lead { font-size: 12.5px; color: var(--muted); line-height: 1.45; margin-top: 3px; }
.rep-label { font-size: 13px; font-weight: 700; color: var(--text); margin: 4px 0 -6px; display: flex; align-items: center; gap: 6px; }
.rep-req { color: var(--danger-text); }
.rep-card .rep-input { padding: 10px 12px; border-radius: 10px; }
.rep-editor { border: 1px solid var(--border); border-radius: 10px; background: var(--surface-2); position: relative; }
.rep-editor:focus-within { border-color: var(--kc); }
.rep-fmt { display: flex; gap: 2px; padding: 6px 8px; border-bottom: 1px solid var(--border); position: relative; }
.rep-fmt-btn { width: 30px; height: 28px; border: 0; border-radius: 7px; background: none; color: var(--text); cursor: pointer; display: inline-flex; align-items: center; justify-content: center; font-size: 14px; font-family: Georgia, serif; }
.rep-fmt-btn .icon { background: var(--text); }
.rep-fmt-btn:hover { background: var(--ink-08, rgba(255,255,255,.06)); }
.rep-emojis { position: absolute; top: 36px; left: 8px; z-index: 5; display: grid; grid-template-columns: repeat(6, 32px); gap: 2px; padding: 6px;
  background: var(--surface); border: 1px solid var(--border); border-radius: 10px; box-shadow: 0 8px 24px rgba(0,0,0,.3); }
.rep-emojis[hidden] { display: none; }
.rep-emoji { width: 32px; height: 32px; border: 0; border-radius: 7px; background: none; cursor: pointer; font-size: 18px; }
.rep-emoji:hover { background: var(--surface-2); }
.rep-editor .rep-textarea { display: block; width: 100%; box-sizing: border-box; min-height: 180px; padding: 10px 12px; border: 0; background: none;
  color: var(--text); font-size: 13px; font-family: inherit; line-height: 1.5; resize: vertical; outline: none; }
/* Drop zone */
.rep-dropzone { border: 1.5px dashed var(--border); border-radius: 12px; padding: 12px; display: flex; flex-direction: column; gap: 10px; }
.rep-dz-row { display: flex; gap: 12px; align-items: center; }
.rep-dz-ico { width: 52px; height: 52px; border-radius: 10px; flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center; background: var(--surface-2); border: 1px solid var(--border); }
.rep-dz-ico .icon { background: var(--muted); }
.rep-dz-txt { font-size: 12.5px; color: var(--muted); display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; }
.rep-dz-txt > div { flex-basis: 100%; }
.rep-dz-browse { border: 0; background: none; padding: 0; color: var(--info-text); cursor: pointer; font-size: 12.5px; font-family: inherit; }
.rep-dz-browse:hover { text-decoration: underline; }
.rep-dz-capture { flex-basis: auto; margin-top: 6px; height: 30px; padding: 0 12px; gap: 6px; display: inline-flex; align-items: center;
  border: 1px solid #3b82f6; border-radius: 8px; background: none; color: var(--text); font-size: 12.5px; font-weight: 600; cursor: pointer; font-family: inherit; }
.rep-dz-capture .icon { background: #3b82f6; }
.rep-dz-capture:hover { background: color-mix(in srgb, #3b82f6 12%, transparent); }
.rep-formats { font-size: 11.5px; color: var(--muted); margin-top: -6px; }
/* Automatic information */
.rep-info { border: 1px solid var(--border); border-radius: 12px; overflow: hidden; }
.rep-info-head { width: 100%; height: 40px; display: flex; align-items: center; gap: 8px; padding: 0 12px; border: 0; background: var(--surface-2); color: var(--text); font-size: 13px; font-weight: 700; cursor: pointer; font-family: inherit; }
.rep-info-head .icon { background: var(--muted); }
.rep-info-chev { margin-left: auto; transition: transform .2s; }
.rep-info.is-open .rep-info-chev { transform: rotate(90deg); }
.rep-info-body { display: none; padding: 8px 12px 10px; }
.rep-info.is-open .rep-info-body { display: block; }
.rep-info-row { display: grid; grid-template-columns: 16px 1fr auto; gap: 8px; align-items: center; padding: 4px 0; font-size: 12.5px; }
.rep-info-row .icon { background: var(--muted); }
.rep-info-k { color: var(--muted); }
.rep-info-v { color: var(--text); text-align: right; max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* Send button in the topic colour */
.rep-btn--send { flex: 1; height: 44px; border: 0; font-size: 14px; color: #fff; background: var(--kc); box-shadow: 0 4px 16px color-mix(in srgb, var(--kc) 40%, transparent); }
.rep-btn--send .icon { background: #fff; }
.rep-btn--send:hover:not(:disabled) { filter: brightness(1.08); }
.rep-anon { display: flex; align-items: center; justify-content: center; gap: 6px; font-size: 12px; color: var(--muted); margin-top: -4px; }
.rep-anon .icon { background: var(--muted); }

/* 3 — sending */
.rep-sending-ring { position: relative; width: 112px; height: 112px; margin: 14px auto 8px; display: flex; align-items: center; justify-content: center; }
.rep-sending-ring::before { content: ""; position: absolute; inset: 0; border-radius: 50%;
  border: 5px solid color-mix(in srgb, #3b82f6 18%, transparent); border-top-color: #3b82f6; border-right-color: #3b82f6; animation: rep-spin 1s linear infinite; }
.rep-sending-ring .icon { background: #3b82f6; animation: rep-fly 1.2s ease-in-out infinite; }
@keyframes rep-spin { to { transform: rotate(360deg); } }
@keyframes rep-fly { 0%, 100% { transform: translate(0, 0); } 50% { transform: translate(3px, -3px); } }
.rep-big-title { font-size: 21px; font-weight: 800; color: var(--text); }
.rep-big-sub { font-size: 13.5px; color: var(--muted); line-height: 1.5; }
.rep-steps { text-align: left; border: 1px solid var(--border); border-radius: 12px; padding: 6px 14px; margin-top: 8px; }
.rep-step { display: flex; align-items: center; gap: 12px; padding: 9px 0; font-size: 13px; color: var(--muted); }
.rep-step-dot { width: 20px; height: 20px; border-radius: 50%; border: 2px solid var(--border); flex-shrink: 0; position: relative; box-sizing: border-box; }
.rep-step.is-done { color: var(--text); }
.rep-step.is-done .rep-step-dot { border-color: #2f9e44; background: #2f9e44; animation: rep-pop .3s ease-out; }
.rep-step.is-done .rep-step-dot::after { content: ""; position: absolute; left: 5.5px; top: 2.5px; width: 5px; height: 9px; border: solid #fff; border-width: 0 2px 2px 0; transform: rotate(45deg); }
.rep-step.is-now { color: var(--text); }
.rep-step.is-now .rep-step-dot { border-color: color-mix(in srgb, #3b82f6 25%, transparent); border-top-color: #3b82f6; animation: rep-spin .8s linear infinite; }
@keyframes rep-pop { from { transform: scale(.5); } to { transform: scale(1); } }
.rep-didyouknow { display: flex; gap: 12px; align-items: flex-start; text-align: left; margin-top: 18px; padding: 14px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface-2); }
.rep-didyouknow .icon { background: #f5c400; flex-shrink: 0; margin-top: 2px; }
.rep-dyk-title { font-size: 13px; font-weight: 800; color: var(--text); }
.rep-dyk-sub { font-size: 12.5px; color: var(--muted); line-height: 1.45; margin-top: 2px; }

/* 4 — confirmation: check drawn + light confetti (600 ms) */
.rep-success { position: relative; width: 100px; height: 100px; margin: 24px auto 26px; }
.rep-check-svg { width: 100px; height: 100px; }
.rep-check-svg circle { fill: color-mix(in srgb, #2f9e44 12%, transparent); stroke: #2f9e44; stroke-width: 2.5; stroke-dasharray: 145; stroke-dashoffset: 145; animation: rep-draw .45s ease-out forwards; }
.rep-check-svg path { fill: none; stroke: #2f9e44; stroke-width: 3.5; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 40; stroke-dashoffset: 40; animation: rep-draw .3s .35s ease-out forwards; }
@keyframes rep-draw { to { stroke-dashoffset: 0; } }
.rep-confetti { position: absolute; inset: -30px; pointer-events: none; }
.rep-confetti i {
  position: absolute; left: 50%; top: 50%; width: 4px; height: 12px; border-radius: 2px;
  background: hsl(calc(var(--i) * 47) 85% 60%); opacity: 0;
  /* Burst (≈0.6 s), short hold, then a soft fade into a blur — gone for good. */
  animation: rep-confetti 1.8s .1s ease-out forwards;
  --a: calc(var(--i) * 25.7deg);
}
@keyframes rep-confetti {
  0%   { opacity: 1; filter: blur(0); transform: translate(-50%, -50%) rotate(var(--a)) translateY(0); }
  33%  { opacity: 1; filter: blur(0); transform: translate(-50%, -50%) rotate(var(--a)) translateY(-78px) rotate(40deg); }
  55%  { opacity: .9; filter: blur(0); transform: translate(-50%, -50%) rotate(var(--a)) translateY(-84px) rotate(55deg); }
  100% { opacity: 0; filter: blur(5px); transform: translate(-50%, -50%) rotate(var(--a)) translateY(-96px) rotate(80deg); }
}
.rep-track { display: flex; align-items: center; gap: 12px; text-align: left; padding: 12px 14px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface-2); margin: 8px 0 2px; }
.rep-track > .icon { background: #3b82f6; }
.rep-track-txt { flex: 1; }
.rep-track-k { font-size: 11.5px; color: var(--muted); }
.rep-track-v { font-size: 15px; font-weight: 800; color: var(--text); font-family: var(--mono, ui-monospace, monospace); }
.rep-track-copy { width: 34px; height: 34px; border: 1px solid var(--border); border-radius: 8px; background: none; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; }
.rep-track-copy .icon { background: var(--muted); }
.rep-track-copy.is-copied { border-color: #2f9e44; }
.rep-track-copy.is-copied .icon { background: #2f9e44; }
.rep-btn--wide { width: 100%; height: 44px; }
.rep-btn--blue { background: #2563eb; border-color: #2563eb; color: #fff; }
.rep-btn--blue .icon { background: #fff; }
.rep-btn--blue:hover { filter: brightness(1.08); }
.rep-btn--outline { background: none; border-color: var(--border); }
.rep-btn--outline:hover { background: var(--surface-2); }
.rep-adventure { display: flex; gap: 14px; align-items: flex-start; text-align: left; margin-top: 14px; padding: 14px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface-2); }
.rep-adventure .icon { background: #ef4444; flex-shrink: 0; }
.rep-adventure-title { font-size: 13.5px; font-weight: 800; color: var(--text); }
.rep-adventure-sub { font-size: 12.5px; color: var(--muted); line-height: 1.45; margin-top: 2px; }
/* Primary button (screenshot editor's "Done"). */
.rep-btn--primary { background: var(--primary); border-color: var(--primary); color: var(--on-accent); }
.rep-btn--primary:hover { filter: brightness(1.06); }
/* Coffee card on the thank-you screen: same card, a little space above. */
.rep-card--center .rep-coffee { text-align: left; margin-top: 10px; }
/* Count bubble on "My requests": the digit dead centre — grid centring with a
   1-unit line box (the font's ascender pushed it low), tabular figures. */
.rep-view .rep-view-count {
  display: inline-grid; place-items: center; box-sizing: border-box;
  min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px;
  font-size: 11px; font-weight: 800; line-height: 1; font-variant-numeric: tabular-nums;
}

/* Opening: the card slides OUT FROM BEHIND the sidebar — it moves inside
   `.rep-clip`, a click-through window whose left edge is the sidebar's right
   edge (JS), so whatever is still "under" the menu is simply cut off. */
.rep-clip { position: fixed; top: 0; bottom: 0; left: 0; width: 600px; max-width: 100vw; overflow: hidden; pointer-events: none; z-index: 108; }
/* Same motion as the right-hand cards (`.detail-panel` — the product card…):
   a plain .25s translate on cubic-bezier(.4,0,.2,1), no fade, the shadow
   arriving with it — mirrored. */
.rep-panel {
  position: absolute; left: 0 !important; pointer-events: auto;
  clip-path: none; transform: translateX(-100%); opacity: 1; box-shadow: none;
  transition: transform .25s cubic-bezier(.4,0,.2,1), box-shadow .25s, visibility 0s linear .25s;
}
.rep-panel.open {
  clip-path: none; transform: translateX(0); opacity: 1; box-shadow: 8px 0 32px rgba(0,0,0,.12);
  transition: transform .25s cubic-bezier(.4,0,.2,1), box-shadow .25s, visibility 0s;
}
/* TigerSquad card — same build as the coffee card, in the squad's orange. */
.rep-squad.rep-squad { border-color: color-mix(in srgb, #FF923F 75%, transparent); background: color-mix(in srgb, #FF923F 9%, transparent); }
.rep-squad .rep-coffee-cup { width: 40px; height: 40px; object-fit: contain; }
.rep-squad .rep-coffee-cta.rep-coffee-cta { background: linear-gradient(180deg, #FF8A2E, #FF6F12); color: #17120E; }
.rep-squad .rep-coffee-cta .icon { background: #17120E; }
/* Already in the TigerSquad — the member's badge, their level and the squad's head count. */
.rep-squad--in.rep-squad--in { border-color: color-mix(in srgb, var(--sq-a, #FF923F) 70%, transparent); background: color-mix(in srgb, var(--sq-a, #FF923F) 9%, transparent); }
.rep-squad--in .rep-coffee-cup { width: 46px; height: 46px; }
.rep-squad--in .rep-coffee-title { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; }
.rep-squad-tier {
  padding: 1px 8px; border-radius: 999px; font-size: 10.5px; font-weight: 800; letter-spacing: .3px;
  background: linear-gradient(135deg, var(--sq-a, #FFD600), var(--sq-b, #FF9F1C)); color: var(--sq-ink, #1a1205);
}
.rep-squad-count { display: inline-flex; align-items: center; gap: 6px; margin-top: 6px; font-size: 12px; color: var(--text); }
.rep-squad-count[hidden] { display: none; }
.rep-squad-count .icon { width: 15px; height: 15px; background: var(--sq-a, #FF923F); }
.rep-squad--in .rep-coffee-cta.rep-coffee-cta { background: transparent; color: var(--text); border: 1px solid var(--border); }
.rep-squad--in .rep-coffee-cta.rep-coffee-cta:hover { background: var(--surface-2); filter: none; }

/* Step 1 — which part of the ecosystem: the topic cards, each with the
   product's own artwork in white on the orange-tinted tile. */
.rep-step-title { font-size: 12px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); margin: 4px 2px -2px; }
.rep-kind-card--product { --ki: var(--primary); --kt: color-mix(in srgb, var(--primary) 14%, var(--surface-2)); }
.rep-kind-card--product .rep-target-ico { width: 36px; height: 36px; background-color: var(--on-accent); transition: transform 180ms; }
/* White artwork: the light theme's pale tile turns into a filled orange one so it still reads. */
:root:not([data-theme="dark"]) .rep-kind-card--product { --kt: var(--primary); }
.rep-kind-card--product:hover .rep-target-ico { transform: scale(1.06); }
/* Step 2 — the product picked, as a way back. */
.rep-picked.rep-picked {
  display: inline-flex; align-items: center; gap: 8px; align-self: flex-start; height: auto;
  padding: 6px 12px 6px 8px; border-radius: 999px; border: 1px solid var(--border);
  background: var(--surface-2); color: var(--text); font: inherit; font-size: 13px; font-weight: 700; cursor: pointer;
}
.rep-picked:hover { border-color: var(--primary); }
.rep-picked .icon { background: var(--muted); }
.rep-picked .rep-target-ico { width: 22px; height: 22px; background-color: var(--primary); }
/* "Capture the Tiger Touch screen" — the screen's own artwork, in the brand orange. */
.rep-dz-capture--ttc .rep-ttc-ico {
  width: 18px; height: 18px; flex: none; background-color: var(--primary);
  -webkit-mask: url('../../assets/svg/icons/icon_tigertouch_3d.svg') center / contain no-repeat;
          mask: url('../../assets/svg/icons/icon_tigertouch_3d.svg') center / contain no-repeat;
}
.rep-dz-capture--ttc:hover { background: color-mix(in srgb, var(--primary) 12%, transparent); }
.rep-dz-capture--ttc:disabled { opacity: .5; cursor: progress; }
.rep-dz-capture--scale .rep-ttc-ico {
  -webkit-mask-image: url('../../assets/svg/icons/icon_tigerscale_3d.svg'); mask-image: url('../../assets/svg/icons/icon_tigerscale_3d.svg');
}
/* "Join the TigerSquad to send" — the only way to unlock Send. */
.rep-squad-gate {
  display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 12px;
  border: 1px solid color-mix(in srgb, #f5b301 45%, transparent);
  background: color-mix(in srgb, #f5b301 9%, var(--surface-2));
}
.rep-squad-gate[hidden] { display: none; }
.rep-squad-gate img { width: 38px; height: 38px; object-fit: contain; flex: none; }
.rep-squad-gate-txt { display: flex; flex-direction: column; gap: 2px; flex: 1; min-width: 0; font-size: 12px; color: var(--muted); }
.rep-squad-gate-txt b { font-size: 13px; color: var(--text); }
.rep-squad-gate .rep-coffee-cta { margin: 0; flex: none; }
/* Not a member yet: looks unavailable, but a click opens the squad's presentation. */
.rep-btn.is-locked { opacity: .45; filter: none; cursor: pointer; }
/* What "Send" points at on an incomplete form. */
.rep-miss { animation: rep-miss 1.4s ease; }
@keyframes rep-miss {
  0%, 100% { box-shadow: 0 0 0 0 transparent; }
  15%, 70% { box-shadow: 0 0 0 2px var(--primary); }
}
.rep-check--public { position: relative; }
.rep-bubble {
  position: absolute; left: 4px; bottom: calc(100% + 8px); z-index: 2;
  padding: 7px 11px; border-radius: 8px; background: var(--primary); color: #fff;
  font-size: 12.5px; font-weight: 700; white-space: nowrap; pointer-events: none;
  box-shadow: 0 6px 18px rgba(0,0,0,.35); animation: rep-bubble-in .2s ease-out;
}
.rep-bubble::after {
  content: ""; position: absolute; left: 14px; top: 100%;
  border: 6px solid transparent; border-top-color: var(--primary);
}
@keyframes rep-bubble-in { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
.rep-check--public:has(.rep-bubble) input { outline: 2px solid var(--primary); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) { .rep-miss, .rep-bubble { animation: none; } }
.rep-dz-capture--spool .rep-ttc-ico {
  -webkit-mask-image: url('../../assets/svg/icons/icon_tigerspool_3d.svg'); mask-image: url('../../assets/svg/icons/icon_tigerspool_3d.svg');
}
/* "Attach a printer's data" — the account's printers, one tap attaches one
   (addPrinterData in index.js); an attached printer is ticked and greyed. */
.rep-dz-capture--printer.is-open { background: color-mix(in srgb, #3b82f6 12%, transparent); }
.rep-printer-pick { display: flex; flex-direction: column; gap: 4px; margin-top: 10px; padding-top: 10px;
  border-top: 1px solid var(--border); animation: repPickIn .18s ease-out both; }
@keyframes repPickIn { from { opacity: 0; transform: translateY(-4px); } }
@media (prefers-reduced-motion: reduce) { .rep-printer-pick { animation: none; } }
.rep-printer-row { display: flex; align-items: center; gap: 10px; width: 100%; height: auto; padding: 6px 8px;
  border: 1px solid transparent; border-radius: 8px; background: none; color: var(--text);
  font: inherit; font-size: 12.5px; text-align: left; cursor: pointer; }
.rep-printer-row:hover:not(:disabled) { background: var(--surface-2); border-color: var(--border); }
.rep-printer-row:disabled { opacity: .55; cursor: default; }
.rep-printer-row .icon-check { background: var(--success); }
.rep-printer-img { width: 32px; aspect-ratio: 1; flex: none; display: grid; place-items: center; }
.rep-printer-img img { width: 100%; height: 100%; object-fit: contain; }
.rep-printer-img .icon { background: var(--muted); }
.rep-printer-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; }
.rep-printer-dot { width: 8px; aspect-ratio: 1; border-radius: 50%; flex: none; background: var(--border); }
.rep-printer-dot.is-on { background: var(--success); }
.rep-printer-note { margin: 4px 0 0; font-size: 11.5px; color: var(--muted); }

/* ── My requests: a row opens its conversation; unseen team replies flagged ── */
.rep-mine-row .rep-mine-main { display: flex; flex-direction: column; align-items: stretch; border: 0; background: none; padding: 0; text-align: left; font: inherit; color: inherit; cursor: pointer; }
.rep-mine-row .rep-mine-main:disabled { cursor: default; }
.rep-mine-row:has(.rep-mine-main:not(:disabled)):hover { background: var(--surface-2); }
.rep-mine-row.has-news { border-color: color-mix(in srgb, #2563eb 55%, var(--border)); }
.rep-mine-new { display: inline-block; margin-right: 6px; padding: 1px 7px; border-radius: 9px; vertical-align: 1px;
  font-size: 10.5px; font-weight: 800; color: #fff; background: #2563eb; }

/* ── Conversation: the request + every comment, team left, the user right ── */
.rep-thread-head { display: flex; align-items: center; gap: 10px; padding: 10px; border: 1px solid var(--border); border-radius: 12px; }
.rep-thread-head .rep-kind-ico { width: 32px; height: 32px; border-radius: 9px; flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center;
  background: color-mix(in srgb, var(--kc) 16%, transparent); }
.rep-thread-head .rep-kind-ico .icon { background: var(--kc); }
.rep-thread-title { font-size: 14px; font-weight: 800; color: var(--text); line-height: 1.3; }
.rep-msgs { display: flex; flex-direction: column; gap: 10px; }
.rep-msg { display: flex; align-items: flex-end; gap: 8px; max-width: 92%; }
.rep-msg--you { align-self: flex-end; flex-direction: row-reverse; }
.rep-msg-ava { width: 28px; height: 28px; border-radius: 50%; flex-shrink: 0; object-fit: cover; }
.rep-msg-ava--none { display: inline-flex; align-items: center; justify-content: center; background: var(--surface-2); }
.rep-msg-ava--none .icon { background: var(--muted); }
.rep-msg-bubble { min-width: 0; padding: 8px 11px; border-radius: 14px 14px 14px 4px; background: var(--surface-2); border: 1px solid var(--border); }
.rep-msg--you .rep-msg-bubble { border-radius: 14px 14px 4px 14px; background: color-mix(in srgb, #2563eb 16%, var(--surface)); border-color: color-mix(in srgb, #2563eb 35%, var(--border)); }
.rep-msg--team .rep-msg-bubble { border-color: color-mix(in srgb, var(--primary) 45%, var(--border)); }
.rep-msg-head { display: flex; align-items: baseline; gap: 8px; font-size: 11.5px; color: var(--muted); margin-bottom: 3px; }
.rep-msg-head b { color: var(--text); font-size: 12px; }
.rep-msg--team .rep-msg-head b { color: var(--primary-text); }
.rep-msg-text { font-size: 13px; line-height: 1.5; color: var(--text); overflow-wrap: anywhere; }
.rep-msg-text code { font-size: 12px; padding: 0 4px; border-radius: 4px; background: var(--surface); }
.rep-msg-link { color: var(--info-text); text-decoration: underline; }
.rep-msg-imgs { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.rep-msg-img { width: 84px; aspect-ratio: 4 / 3; padding: 0; border: 1px solid var(--border); border-radius: 8px; overflow: hidden; cursor: zoom-in; background: var(--surface); }
.rep-msg-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.rep-msg-note { align-self: center; font-size: 11.5px; color: var(--muted); text-align: center; padding: 2px 10px; }
.rep-msg-note--closed { padding: 10px; border: 1px dashed var(--border); border-radius: 10px; }

/* Answer box */
.rep-reply { display: flex; flex-direction: column; gap: 8px; padding: 10px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); }
.rep-reply textarea { width: 100%; resize: vertical; min-height: 64px; border: 0; background: none; color: var(--text); font-family: inherit; font-size: 13px; line-height: 1.5; outline: none; }
.rep-reply-bar { display: flex; align-items: center; gap: 8px; }
.rep-reply-public { flex: 1; font-size: 11px; color: var(--muted); line-height: 1.3; }
.rep-reply-bar .rep-btn:disabled { opacity: .5; cursor: default; filter: none; }
.rep-reply-imgs { display: flex; gap: 6px; }
.rep-reply-img { position: relative; width: 64px; aspect-ratio: 4 / 3; border-radius: 7px; overflow: hidden; border: 1px solid var(--border); }
.rep-reply-img img { width: 100%; height: 100%; object-fit: cover; }
.rep-reply-img button { position: absolute; top: 2px; right: 2px; width: 18px; height: 18px; padding: 0; border: 0; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center; background: rgba(0, 0, 0, .6); cursor: pointer; }
.rep-reply-img button .icon { background: #fff; }

/* "Your request moved" is an openDialog() notice (report/index.js _showAlert, renderer/dialog.js). */
/* The user closes their own request from its conversation too (asks once, like in the list). */
.rep-thread-close { display: flex; justify-content: center; }
.rep-thread-close .rep-back { color: var(--muted); }

/* ── Requests as pills, like the spool cards: the kind's illustration fills the
   left edge, full height, its icon drawn large. ── */
.rep-mine-row, .rep-thread-head { padding: 0 10px 0 0; gap: 12px; overflow: hidden; min-height: 58px; border-radius: 14px; }
.rep-mine-row .rep-kind-ico, .rep-thread-head .rep-kind-ico {
  width: 58px; height: auto; align-self: stretch; border-radius: 0; flex-shrink: 0;
  background: linear-gradient(135deg, color-mix(in srgb, var(--kc) 34%, var(--surface)), color-mix(in srgb, var(--kc) 14%, var(--surface)));
  border-right: 1px solid color-mix(in srgb, var(--kc) 30%, var(--border)); }
.rep-mine-row .rep-kind-ico .icon, .rep-thread-head .rep-kind-ico .icon {
  width: 28px; height: 28px; background: var(--kc); filter: drop-shadow(0 2px 6px color-mix(in srgb, var(--kc) 45%, transparent)); }
.rep-mine-row .rep-mine-main, .rep-thread-head .rep-mine-main { padding: 9px 0; }

/* Coloured tiles carry a WHITE icon: the kind's colour fills the tile, the
   artwork reads on top of it — topic cards, request pills and the product chip. */
.rep-kind-card .rep-kind-ico { background: linear-gradient(135deg, var(--ki), color-mix(in srgb, var(--ki) 62%, #000)); }
.rep-kind-card .rep-kind-ico .icon { background: #fff; }
.rep-mine-row .rep-kind-ico, .rep-thread-head .rep-kind-ico {
  background: linear-gradient(135deg, var(--kc), color-mix(in srgb, var(--kc) 62%, #000)); border-right: 0; }
.rep-mine-row .rep-kind-ico .icon, .rep-thread-head .rep-kind-ico .icon { background: #fff; filter: none; }
.rep-picked .rep-target-ico.rep-target-ico { background-color: #fff; }
.rep-kind-card:not(.rep-kind-card--product) .rep-kind-ico .icon { width: 26px; height: 26px; }

/* Answer box = the request form's editor + drop zone. */
.rep-reply .rep-editor { margin: 0; }
.rep-reply .rep-textarea { min-height: 90px; }
.rep-reply .rep-label { margin-top: 2px; }
/* Documents in a message (PDF, a printer's JSON…). */
.rep-msg-files { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.rep-msg-file { display: inline-flex; align-items: center; gap: 6px; max-width: 100%; padding: 4px 9px; border: 1px solid var(--border); border-radius: 8px;
  background: var(--surface); color: var(--text); font: inherit; font-size: 12px; cursor: pointer; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rep-msg-file .icon { background: var(--muted); flex-shrink: 0; }
.rep-msg-file:hover { border-color: #3b82f6; }

/* All requests (TigerMasters): open / everything filter, team actions. */
.rep-all-filter { display: flex; gap: 6px; }
.rep-all-filter .rep-chip { height: 28px; padding: 0 12px; border-radius: 14px; border: 1px solid var(--border); background: none; color: var(--muted);
  font: inherit; font-size: 12px; font-weight: 700; cursor: pointer; }
.rep-all-filter .rep-chip.is-on { color: #fff; background: #2563eb; border-color: #2563eb; }
/* Search + filters (both request lists): the chips open a small menu under themselves. */
.rep-fsearch { margin-bottom: 8px; }
.rep-ftools { flex-wrap: wrap; margin-bottom: 10px; }
.rep-fwrap { position: relative; display: inline-flex; }
.rep-all-filter .rep-chip--menu, .rep-all-filter .rep-chip--reset { display: inline-flex; align-items: center; gap: 6px; }
.rep-all-filter .rep-chip--reset { width: 28px; padding: 0; justify-content: center; }   /* the reset button is only an icon */
.rep-chip--reset .icon { background: var(--primary); }   /* the app's accent, as on the main search bar */
.rep-chip-chev { background: currentColor; transform: rotate(90deg); }
.rep-fmenu { position: absolute; top: calc(100% + 4px); left: 0; z-index: 5; min-width: 190px; max-width: 280px; padding: 5px;
  display: flex; flex-direction: column; gap: 1px; border: 1px solid var(--border); border-radius: 10px; background: var(--surface-2); box-shadow: var(--shadow); }
.rep-fopt { display: flex; align-items: center; justify-content: flex-start; width: 100%; text-align: left; padding: 7px 10px; border: 0; border-radius: 7px; background: none; color: var(--text); font: inherit; font-size: 12px; cursor: pointer; }
.rep-fopt:hover { background: color-mix(in srgb, var(--text) 8%, transparent); }
.rep-fopt.is-on { background: color-mix(in srgb, #2563eb 20%, transparent); font-weight: 700; }
/* The repository a request landed in: a small tag in the sub-line, in the sub-line's own colour. */
.rep-repo { display: inline-flex; align-items: center; height: 18px; padding: 0 8px; border-radius: 9px; border: 1px solid var(--border); color: inherit; font-size: 11px; vertical-align: 1px; }
.rep-team-acts { gap: 8px; }
.rep-team-done.rep-team-done { color: var(--success-text); }
/* The title and sub-line of a pill never shrink away (overflow: hidden makes their min-height 0). */
.rep-mine-row .rep-mine-main > * { flex-shrink: 0; }
/* Three tabs (TigerMasters): one line each. */
.rep-views:has(.rep-view:nth-child(3)) .rep-view { white-space: nowrap; font-size: 12px; padding-inline: 8px; }

/* Team only: TigerCoins messages reported by their recipient (msgReportsHTML). */
.rep-msgreps { margin: 0 0 10px; border: 1px solid rgba(229, 72, 77, .35); border-radius: 12px; background: rgba(229, 72, 77, .06); }
.rep-msgreps > summary { display: flex; align-items: center; gap: 8px; padding: 10px 12px; cursor: pointer; list-style: none; font-weight: 700; font-size: 13px; }
.rep-msgreps > summary::-webkit-details-marker { display: none; }
.rep-msgreps > summary .icon { background: #e5484d; }
.rep-msgreps ul { margin: 0; padding: 0 12px 10px; list-style: none; display: flex; flex-direction: column; gap: 8px; }
.rep-msgrep { padding: 10px; border-radius: 10px; background: var(--surface-2); border: 1px solid var(--border); }
.rep-msgrep.is-final { opacity: .6; }
.rep-msgrep-txt { font-size: 13px; color: var(--text); white-space: pre-wrap; word-break: break-word; }
.rep-msgrep-sub { margin-top: 4px; font-size: 11.5px; color: var(--muted); }
.rep-msgrep-acts { display: flex; gap: 8px; margin-top: 8px; }

/* Copy a message (to paste it into a translator): quiet until the bubble is hovered. */
.rep-msg-bubble:has(> .rep-msg-head .rep-msg-copy) { position: relative; }
.rep-msg-copy { position: absolute; top: 6px; right: 6px; display: inline-flex; align-items: center; justify-content: center;
  width: 22px; aspect-ratio: 1; border: 0; border-radius: 6px; background: transparent; color: var(--muted); cursor: pointer;
  opacity: 0; transition: opacity .15s ease, background .15s ease, color .15s ease; }
.rep-msg-bubble:hover .rep-msg-copy, .rep-msg-copy:focus-visible { opacity: 1; }
.rep-msg-copy:hover { background: color-mix(in srgb, var(--text) 10%, transparent); color: var(--text); }
.rep-msg-copy.is-copied { opacity: 1; }
.rep-msg-copy.is-copied .icon { background: #2f9e44; }
