/* The devkit reporter's styles (MA10): report mode, the report window, the image editor and the Reports page.
   Mortar / my-gui classes (m-) and tokens (--m-); the app's own helpers it relies on (app-muted, app-dlg-actions,
   app-tiles / app-tile, app-glass, app-est) come from the app. Load after the GUI kit. */
/* the queue list and the full-scale switch (the same rules as in an app that has them) */
.app-filter-switch { display: inline-flex; align-items: center; gap: 8px; height: 32px; cursor: pointer; color: var(--m-text-2); }
.app-q-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.app-q-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; padding: 6px 0; border-bottom: 1px solid var(--m-line); }
.app-q-row:last-child { border-bottom: 0; }
.app-q-row > .app-rank-go { min-width: 240px; }
/* the blocks of the Reports page keep their distance whatever the app's container does */
#app-rep-tiles, #app-rep-queue { margin-bottom: 16px; }
.app-rep-filter { margin-bottom: 8px; }
/* MA21: on a phone the filter switch scrolls inside the card instead of widening the page */
.app-rep-filter { max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.app-rep-filter > button { flex: none; }
.app-rep-tkinds { margin: 0 0 10px; }
.app-rep-fixall { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 16px; padding-bottom: 14px; border-bottom: 1px solid rgba(var(--m-ink), .06); }
.app-rep-fixall > p { flex-basis: 100%; margin: 0; }
.app-rep-full { white-space: pre-wrap; overflow-wrap: anywhere; color: var(--m-text); }   /* C0111: the report's text in the strongest text colour */
#app-bug.is-on { color: #fff; background: #e5484d; }
body.app-bugmode .m-main { outline: 2px dashed rgba(229, 72, 77, .45); outline-offset: -2px; }
.app-bug-target { outline: 3px solid #e5484d !important; outline-offset: 2px; border-radius: 6px; }
.app-bug-panel { position: fixed; z-index: 2100; width: 720px; max-width: calc(100vw - 16px); max-height: calc(100vh - 16px); overflow: auto; box-shadow: 0 12px 40px rgba(0, 0, 0, .35); }   /* C0082 */
.app-bug-panel.app-glass { position: fixed; }   /* the glass look keeps it floating */
.app-bug-cols { display: grid; grid-template-columns: minmax(0, 1fr) 240px; gap: 12px; align-items: start; }
@media (max-width: 640px) { .app-bug-cols { grid-template-columns: minmax(0, 1fr); } }
.app-bug-main { display: flex; flex-direction: column; gap: 8px; }
.app-bug-main .m-seg { margin: 0; }
.app-bug-side { display: flex; flex-direction: column; gap: 8px; margin-top: 8px; }
.app-bug-shot { min-height: 120px; display: flex; align-items: center; justify-content: center; border: 1px solid var(--m-line); border-radius: 8px; background: var(--m-raise); overflow: hidden; }
.app-bug-shot img { display: block; width: 100%; height: auto; max-height: 240px; object-fit: contain; }
.app-bug-meta { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 2px 8px; margin: 0; }
.app-bug-meta dt { color: var(--m-text-2, inherit); opacity: .75; }
.app-bug-meta dd { margin: 0; overflow-wrap: anywhere; }
.app-bug-stats { margin: 8px 0 0; text-align: right; }
.app-bug-warn { margin: 8px 0 4px; }
.app-bug-warn .m-i { margin-right: 4px; vertical-align: -2px; }
.app-bug-panel .m-h3 { display: flex; align-items: center; gap: 6px; margin: 0 0 4px; }
.app-bug-panel .m-seg { margin: 8px 0; display: flex; }
.app-bug-text { width: 100%; resize: vertical; min-height: 180px; }
.app-bug-title { width: 100%; }
/* the kit's text area and dictation (textarea.css, voice.css) in the window: their lines take the whole width */
.app-voice-note { margin: -4px 0 0; }
.app-qa-new > .m-textarea-bar, .app-qa-new > .m-textarea-count, .app-qa-new > .m-voice { align-self: stretch; }
/* 239 (D272): the one report window, for a new report and an existing one */
.app-bug-panel--wide { width: 880px; }
.app-rw-x { margin-left: auto; }
.app-rw-sub { margin: 0 0 4px; }
.app-rw-img { display: block; width: 100%; }
/* 240 (D273): its side parts open and close; the arrow shows which way */
.app-rw-blk { border-top: 1px solid var(--m-line); }
/* D275: the saved details and the questions under the two columns, full width; the details in three pairs a row */
.app-rw-foot { display: flex; flex-direction: column; margin-top: 10px; }
.app-rw-foot .app-bug-meta { grid-template-columns: repeat(3, auto minmax(0, 1fr)); column-gap: 10px; }
@media (max-width: 640px) { .app-rw-foot .app-bug-meta { grid-template-columns: auto minmax(0, 1fr); } }
.app-rw-blkh { display: flex; align-items: center; gap: 6px; padding: 6px 2px; cursor: pointer; list-style: none; font-weight: 600; color: var(--m-text-2, inherit); }
.app-rw-blkh::-webkit-details-marker { display: none; }
.app-rw-blkh::before { content: ''; width: 6px; height: 6px; border: solid currentColor; border-width: 0 1.5px 1.5px 0; transform: rotate(-45deg); transition: transform .15s; }
.app-rw-blk[open] > .app-rw-blkh::before { transform: rotate(45deg); }
.app-rw-blkh:focus-visible { outline: 2px solid var(--m-accent, currentColor); outline-offset: 2px; border-radius: 4px; }
.app-rw-blkb { display: flex; flex-direction: column; gap: 6px; padding: 0 2px 8px; }
@media (prefers-reduced-motion: reduce) { .app-rw-blkh::before { transition: none; } }
.app-rep-paused { background: rgba(128, 128, 128, .25); }
/* 241 (D274): the talk about a report, as bubbles: the developer's on the left, the reporter's on the right */
.app-qa { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; max-height: 260px; overflow-y: auto; }
.app-qa-msg { max-width: 88%; display: flex; flex-direction: column; gap: 2px; padding: 6px 9px; border-radius: var(--m-r-md); background: var(--m-well); font-size: 13px; }
.app-qa-msg.is-dev { align-self: flex-start; border-bottom-left-radius: var(--m-r-xs); }
.app-qa-msg.is-user { align-self: flex-end; border-bottom-right-radius: var(--m-r-xs); background: var(--m-accent-wash); }
.app-qa-who { font-size: 11px; color: var(--m-text-3); }
.app-qa-tx { white-space: pre-wrap; overflow-wrap: anywhere; }
.app-qa-new { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.app-qa-in { width: 100%; resize: vertical; }
.app-qa-new > .app-voice-note { margin: -2px 0 0; }
.app-rep-q { background: rgba(250, 178, 25, .25); color: var(--m-warn-text); }
.app-rep-from { text-transform: none; letter-spacing: 0; }   /* L13: a name and an e-mail */
.app-rep-title { margin-right: 4px; }
.app-rep-big { display: block; max-width: 100%; height: auto; margin: 0 auto; }
.app-rep-new { background: rgba(229, 72, 77, .2); } .app-rep-planned { background: rgba(245, 165, 36, .25); } .app-rep-done { background: rgba(47, 191, 113, .25); }
/* C0023: an open report can be corrected or deleted */
.app-rep-tools, .app-rep-ask { display: inline-flex; align-items: center; gap: 4px; margin-left: auto; }
.app-rep-ask { font-size: 13px; }
.app-rep-kinds { max-width: 360px; margin-bottom: 8px; }
/* C0097, C0094, C0098: the reports as a table */
.app-rep-table td { vertical-align: middle; }
/* MA21: the list takes the whole width and fits a laptop screen; the filter field above it */
.app-rep-table { width: 100%; }
.app-rep-table th, .app-rep-table td { padding-inline: 6px; }
.app-rep-table th { white-space: normal; letter-spacing: 0; }
.app-rep-search { max-width: 360px; margin-bottom: 4px; }
.app-rep-tr { cursor: pointer; }
.app-rep-tr:hover, .app-rep-tr:focus-visible { background: var(--m-raise); }
.app-rep-tr.is-urgent { box-shadow: inset 3px 0 0 #e5484d; }
.app-rep-acts { width: 1%; white-space: nowrap; }
.app-rep-acts .m-btn + .m-btn { margin-left: 2px; }
/* 244: the thumbnail column – an edited picture in the image editor's orange */
.app-rep-thc { width: 1%; }
.app-rep-thumb { display: block; width: 56px; height: 40px; padding: 0; border: 1px solid var(--m-line); border-radius: var(--m-r-xs); background: var(--m-well); overflow: hidden; cursor: zoom-in; }
.app-rep-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
.app-rep-thumb.is-edited { border: 2px solid #ff8a1f; }
.app-rep-thumb:focus-visible { outline: 2px solid var(--m-accent); outline-offset: 1px; }
.app-rep-table .app-rep-tx { min-width: 180px; max-width: 480px; white-space: normal; overflow-wrap: anywhere; }
.app-rep-tx .app-rep-text { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.app-rep-table .app-rep-wh { min-width: 90px; max-width: 280px; white-space: normal; overflow-wrap: anywhere; }
.app-rep-path { display: block; margin-top: 2px; font: 11px/1.3 ui-monospace, Consolas, monospace; opacity: .7; overflow-wrap: anywhere; }
.app-rep-table .app-rep-note { max-width: 180px; white-space: normal; overflow-wrap: anywhere; }
.app-rep-urgent { background: rgba(229, 72, 77, .2); }
.app-rep-chart { margin-top: 16px; max-width: 640px; }
.app-rep-chart .m-h3 { display: flex; align-items: center; gap: 6px; }
.app-rep-bar { display: grid; grid-template-columns: 120px minmax(0, 1fr) auto; gap: 8px; align-items: center; margin: 6px 0; }
.app-rep-bar-t { height: 12px; border-radius: 6px; background: var(--m-raise); overflow: hidden; }
.app-rep-bar-t i { display: block; height: 100%; width: var(--v); background: var(--m-series-1, var(--m-accent)); border-radius: 6px; }
/* C0096: a report's details under its text, in two columns */
.app-rep-dlg .app-rep-path { margin: 0; }
.app-rep-dlg .app-bug-side .m-btn { justify-content: center; }
@media (max-width: 640px) { .app-rep-bar { grid-template-columns: 80px minmax(0, 1fr) auto; } }
/* C0103 (189): the price of the fixes in time, next to the averages; the kinds in their own colours */
.app-rep-charts { display: grid; grid-template-columns: minmax(0, 420px) minmax(0, 1fr); gap: 24px; align-items: start; }
.app-rep-charts .app-rep-chart { max-width: none; }
.app-rep-bar.is-ui .app-rep-bar-t i, .app-rep-tbar .is-ui { background: var(--m-series-1); }
.app-rep-bar.is-bug .app-rep-bar-t i, .app-rep-tbar .is-bug { background: var(--m-series-2); }
.app-rep-bar.is-idea .app-rep-bar-t i, .app-rep-tbar .is-idea { background: var(--m-series-3); }
.app-rep-tbars { display: flex; align-items: flex-end; gap: 1px; height: 160px; margin: 8px 0; border-bottom: 1px solid var(--m-line); }
.app-rep-tbars.is-thin { gap: 0; }
.app-rep-tbar { flex: 1 1 0; min-width: 0; height: 100%; display: flex; align-items: flex-end; }
.app-rep-tbar i { display: flex; flex-direction: column; width: 100%; height: var(--h); min-height: 1px; border-radius: 2px 2px 0 0; overflow: hidden; }
.app-rep-tbar b { display: block; flex-basis: 0; }
.app-rep-tbar:hover i { filter: brightness(1.15); }
@media (max-width: 900px) { .app-rep-charts { grid-template-columns: minmax(0, 1fr); } }
/* C0109: the kinds switched on and off; C0110: a cut bar; C0113, C0114: the weekly sums and the share by kind */
.app-rep-kindsw { display: flex; flex-wrap: wrap; gap: 6px; margin: 20px 0 4px; }
.app-rep-kbtn i { width: 10px; height: 10px; border-radius: 3px; background: currentColor; opacity: .35; }
.app-rep-kbtn.is-ui i { background: var(--m-series-1); }
.app-rep-kbtn.is-bug i { background: var(--m-series-2); }
.app-rep-kbtn.is-idea i { background: var(--m-series-3); }
.app-rep-kbtn[aria-pressed="false"] { opacity: .55; }
.app-rep-kbtn[aria-pressed="false"] i { background: transparent; box-shadow: inset 0 0 0 1.5px var(--m-text-3); }
.app-rep-kbtn[aria-pressed="true"] { border-color: var(--m-line-strong, var(--m-line)); background: var(--m-raise); }
.app-rep-tbar.is-cut i { position: relative; }
.app-rep-tbar.is-cut i::after { content: ''; position: absolute; left: -2px; right: -2px; top: 10px; height: 4px; background: var(--m-card-solid); transform: skewY(-20deg); }
.app-rep-h2 { margin-top: 20px; }
.app-rep-wfull { margin: 0 0 6px; }
/* 243: the token column from yellow (the fewest) to red (the most), a wash readable in both themes; a cut cell is marked */
.app-rep-tok { background: color-mix(in oklab, color-mix(in oklab, #f2c200, #e5484d calc(var(--p, 0) * 100%)) 32%, transparent); }
.app-rep-tok.is-cut { box-shadow: inset 0 3px 0 #e5484d; }
.app-rep-kfull { margin: 0 0 6px; }
/* 242 (D276): the image editor – a large window over the page (and over the report window), the picture as big as it fits */
.app-se-back { position: fixed; inset: 0; z-index: 2200; display: flex; align-items: center; justify-content: center; padding: 8px; background: rgba(0, 0, 0, .45); }
.app-se-back:has(> .app-se.is-dragging) { background: transparent; }
.app-se { width: min(1100px, 100%); max-height: 100%; overflow: auto; box-shadow: 0 16px 48px rgba(0, 0, 0, .45); }
.app-se-body { display: flex; flex-direction: column; gap: 8px; }
.app-se-h { display: flex; align-items: center; gap: 6px; margin: 0; }
.app-se-x { margin-left: auto; }
.app-se-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; }
.app-se-tool[aria-pressed="true"] { background: rgba(255, 138, 31, .22); border-color: #FF8A1F; color: inherit; }
.app-se-gap { flex: 1; }
.app-se-opt { display: inline-flex; align-items: center; gap: 4px; margin-left: 6px; }
.app-se-opt[hidden] { display: none; }
.app-se-sw { width: 24px; height: 24px; padding: 0; border-radius: 50%; border: 2px solid var(--m-raise, #fff); background: var(--sw); box-shadow: 0 0 0 1px rgba(0, 0, 0, .25); cursor: pointer; }
.app-se-sw[aria-pressed="true"] { box-shadow: 0 0 0 2px var(--sw), 0 0 0 4px var(--m-ring, rgba(0, 0, 0, .35)); }
.app-se-sw:focus-visible { outline: 2px solid var(--m-ring); outline-offset: 2px; }
.app-se-sw[data-value="orange"] { --sw: #FF8A1F; }
.app-se-sw[data-value="blue"] { --sw: #2F80ED; }
.app-se-sw[data-value="red"] { --sw: #E5383B; }
.app-se-sw[data-value="green"] { --sw: #2E9E4F; }
.app-se-sw[data-value="brown"] { --sw: #8B5A2B; }
.app-se-stage { position: relative; display: flex; justify-content: center; min-height: 120px; padding: 6px; border-radius: 8px; background: var(--m-well); outline: none; }
.app-se-cv { display: block; touch-action: none; cursor: crosshair; box-shadow: 0 2px 10px rgba(0, 0, 0, .25); }
.app-se-cv[data-tool="select"] { cursor: default; }
.app-se-cv[data-tool="text"] { cursor: text; }
.app-se-txt { position: absolute; width: 240px; max-width: calc(100% - 12px); }
.app-se-hint { margin: 0; min-height: 1.4em; }
@media (max-width: 640px) { .app-se-tool span { display: none; } }
