:root { --accent: #9ce8dc; --accent-ink: #102b29; --bg: #101518; --surface: #1a2227; --surface-soft: #141c20; --raised: #243139; --border: #2c3a41; --tint: #203c38; }
:root[data-theme='light'] { --accent: #216e61; --accent-ink: #fff; --bg: #eef2f1; --surface: #fff; --surface-soft: #f6f8f7; --raised: #e8efec; --border: #d6e1dc; --tint: #deeee7; }
.approvals { grid-column: 1 / -1; min-width: 0; border: 1px solid var(--border); border-radius: 14px; background: var(--surface-soft); overflow: hidden; margin-bottom: 8px; }
.is-panel .approvals { display: none; }
.approvals h2 { font-size: 14px; margin: 0; padding: 13px 18px; }
.approval-count { font-size: 11px; margin-left: 5px; color: var(--muted); }
.approval-list { max-height: 240px; overflow-y: auto; overscroll-behavior: contain; }
.approval-item { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: start; gap: 16px; padding: 10px 18px; border-top: 1px solid var(--border); }
.approval-copy { min-width: 0; }
.approval-title { background: transparent; border: 0; border-radius: 3px; padding: 7px 0; text-align: left; font-size: 13px; overflow-wrap: anywhere; }
.approval-title:hover { color: var(--accent); }
.approval-summary { margin: 4px 0; color: var(--muted); font-size: 13px; line-height: 1.6; white-space: pre-wrap; overflow-wrap: anywhere; }
.approval-tag { color: var(--muted); font-size: 11px; padding-top: 10px; }
.approval-item > .button, .report-meta .approve-fix { font-size: 12px; min-height: 36px; padding: 8px 16px; }
@media (min-width: 1081px) { .board-active .review:has(> #approvals[hidden]) #views { grid-row: 2 / 5; } }
@media (max-width: 600px) { .approval-item { gap: 6px 12px; padding: 8px 14px; grid-template-columns: minmax(0, 1fr) auto; } .approval-copy { grid-column: 1; } .approval-tag { grid-column: 1; grid-row: 2; padding-top: 0; } .approval-item > .button { grid-column: 2; grid-row: 1 / 3; min-height: 44px; } }
.board-active { background: radial-gradient(ellipse at 78% 0, color-mix(in srgb, var(--accent) 6%, transparent), transparent 52%), var(--bg); }
.board-active .header { max-width: 1740px; height: 76px; padding-inline: 32px; border-bottom: 1px solid var(--border); }
.board-active .review { max-width: 1740px; padding: 36px 32px 28px; display: grid; grid-template-columns: 158px minmax(0, 1fr); gap: 20px 28px; }
.board-active.multi-active #single-view { display: none; }
.board-active .page-heading { grid-column: 1 / -1; margin: 0 0 14px; }
.board-active .page-heading h1 { font-size: clamp(30px, 3vw, 46px); letter-spacing: -1.8px; font-weight: 650; }
.heading-period { color: var(--accent); }
.board-active .page-heading .muted { font-size: 13px; margin-top: 10px; }
.board-active #refresh { border: 1px solid var(--border); border-radius: 9px; padding: 11px 15px; background: var(--surface); }
.board-active .toolbar { display: contents; }
nav:before { display: none; }
.tab.active { background: var(--tint); color: var(--accent); }
.board-active #views { grid-column: 1; grid-row: 3 / 6; align-self: start; position: sticky; top: 20px; display: flex; flex-direction: column; border: 0; border-radius: 0; background: transparent; padding: 0; gap: 6px; }
.board-active #views:after { content: 'FILTER REPORTS'; order: -1; font-size: 9px; font-weight: 650; letter-spacing: 1.6px; color: var(--faint); padding: 14px 12px; }
.board-active .tab { display: flex; justify-content: space-between; align-items: center; padding: 13px 12px; min-height: 44px; font-size: 12px; text-align: left; flex: initial; }
.board-active .tab:hover { background: var(--raised); }
.board-active .tab.active { background: var(--tint); box-shadow: inset 2px 0 var(--accent); }
.board-active .tab span { background: var(--surface); font-size: 10px; padding: 3px 6px; height: auto; min-width: 26px; }
.search-tools { display: flex; align-items: center; gap: 12px; min-width: 0; }
.board-active .search-tools { grid-column: 2; }
.search-field { display: flex; flex: 1; align-items: center; min-width: 0; gap: 10px; padding: 0 14px; border: 1px solid var(--border); border-radius: 11px; background: var(--surface-soft); transition: border-color 150ms, box-shadow 150ms; }
.search-field:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 10%, transparent); }
.search-field > span { font-size: 25px; color: var(--muted); }
.search-tools .search-field input { width: 100%; background: transparent; border: 0; padding: 14px 0; outline: none; box-shadow: none; font-size: 12px; }
.search-field kbd { color: var(--faint); font-size: 11px; border: 1px solid var(--border); border-radius: 4px; padding: 2px 6px; }
.search-tools select { background: var(--surface); border: 1px solid var(--border); border-radius: 10px; padding: 13px 12px; font-size: 12px; min-width: 125px; }
.report-board { grid-column: 2; display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 22px; align-items: start; min-width: 0; }
.board-list { min-width: 0; border: 1px solid var(--border); border-radius: 14px; background: var(--surface-soft); overflow: hidden; }
.board-heading { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 21px 22px 16px; }
.board-heading .eyebrow { font-size: 9px !important; margin-bottom: 7px !important; }
.board-heading h2, .selection-panel h2 { font-size: 18px; letter-spacing: -.4px; margin: 0; font-weight: 600; }
.board-heading #board-count { font-variant-numeric: tabular-nums; font-size: 11px; padding: 6px 10px; background: var(--raised); border-radius: 20px; white-space: nowrap; }
.feed-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 0 18px 14px; border-bottom: 1px solid var(--border); }
.feed-tools button { font-size: 11px; border: 1px solid var(--border); border-radius: 6px; padding: 7px 9px; }
.feed-tools button[aria-pressed='true'] { background: var(--tint); border-color: var(--accent); color: var(--accent); }
#selected-total { font-variant-numeric: tabular-nums; margin-left: 5px; }
.feed-tip { color: var(--faint); font-size: 10px; margin-left: auto; }
.report-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; padding: 18px; max-height: max(420px, calc(100dvh - 365px)); overflow-y: auto; scrollbar-gutter: stable; align-items: stretch; }
.report-cards > .empty { grid-column: 1 / -1; padding: 60px 20px; }
.report-tile { --status-color: #e9bc80; position: relative; min-width: 0; border: 1px solid var(--border); border-radius: 10px; background: var(--surface); overflow: hidden; display: flex; flex-direction: column; transition: transform 180ms, box-shadow 180ms, border-color 180ms; animation: card-arrive 220ms ease-out; }
.tile-content { display: flex; flex-direction: column; flex: 1; gap: 15px; padding: 17px; }
.report-tile[data-status='saved'] { --status-color: #aeb9ee; }
.report-tile[data-status='done'] { --status-color: #9cd4b8; }
:root[data-theme='light'] .report-tile { --status-color: #916018; }
:root[data-theme='light'] .report-tile[data-status='saved'] { --status-color: #6553a6; }
:root[data-theme='light'] .report-tile[data-status='done'] { --status-color: #286d50; }
@media (hover: hover) { .report-tile:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--accent) 45%, var(--border)); box-shadow: 0 8px 20px #0002; } }
.report-tile.is-selected { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); background: color-mix(in srgb, var(--tint) 32%, var(--surface)); }
.tile-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; color: var(--muted); font-size: 10px; }
.tile-id { font-family: ui-monospace, monospace; color: var(--faint); }
.tile-status { color: var(--status-color); display: inline-flex; align-items: center; gap: 5px; }
.tile-status:before { content: ''; width: 5px; height: 5px; background: currentColor; border-radius: 50%; }
.tile-select { display: flex; align-items: center; gap: 11px; width: 100%; min-height: 54px; padding: 14px 17px; cursor: pointer; background: var(--raised); border-bottom: 1px solid var(--border); font-size: 14px; font-weight: 550; transition: background-color 150ms; }
.tile-select:hover { background: var(--hover); }
.tile-select:focus-within { box-shadow: inset 0 0 0 2px var(--accent); }
.is-selected .tile-select { background: var(--tint); color: var(--accent); }
.tile-select .tile-id { margin-left: auto; font-size: 11px; font-weight: 400; }
.tile-select input { accent-color: var(--accent); width: 20px; height: 20px; margin: 0; cursor: pointer; }
.tile-chat { margin-left: auto; padding: 6px 0; font-size: 11px; color: var(--accent); }
.report-tile h3 { margin: 0; font-size: 15px; line-height: 1.55; letter-spacing: -.1px; }
.report-tile h3 button { background: none; border: 0; text-align: left; padding: 0; font: inherit; font-weight: 600; width: 100%; }
.report-tile h3 button:hover { color: var(--accent); }
.tile-description { color: var(--body); font-size: 12px; line-height: 1.7; white-space: pre-wrap; overflow-wrap: anywhere; background: var(--surface-soft); border: 1px solid color-mix(in srgb, var(--border) 65%, transparent); border-radius: 7px; padding: 11px 12px; }
.tile-context { display: flex; flex-wrap: wrap; gap: 5px; }
.tile-context:empty { display: none; }
.tile-context span { color: var(--muted); font: 9px ui-monospace, monospace; border: 1px solid var(--border); border-radius: 4px; padding: 4px 6px; }
.tile-byline { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px; margin-top: auto; font-size: 10px; color: var(--muted); }
.tile-byline > span { display: inline-flex; align-items: center; gap: 6px; overflow-wrap: anywhere; }
.tile-byline i { display: inline-grid; place-items: center; width: 21px; height: 21px; border-radius: 50%; background: var(--raised); font-size: 9px; font-style: normal; color: var(--body); }
.tile-footer { border-top: 1px solid var(--border); }
.tile-footer .button { width: 100%; min-height: 56px; justify-content: center; padding: 16px; font-size: 14px; border: 0; background: var(--tint); color: var(--accent); border-radius: 0; }
.tile-footer .button:hover { background: color-mix(in srgb, var(--accent) 20%, var(--surface)); }
.tile-footer .button:focus-visible { outline-offset: -4px; }
.tile-footer .return-work { width: 100%; min-height: 40px; font-size: 12px; }
.selection-panel { position: sticky; top: 20px; min-width: 0; border: 1px solid var(--border); border-top: 2px solid var(--accent); border-radius: 12px; padding: 24px 20px 16px; background: linear-gradient(160deg, color-mix(in srgb, var(--tint) 45%, var(--surface)), var(--surface) 35%); display: flex; flex-direction: column; gap: 10px; }
.selection-panel .eyebrow { font-size: 8px !important; letter-spacing: 1.3px; margin-bottom: 12px !important; }
.selection-panel .muted { font-size: 11px; line-height: 1.7; margin: 8px 0 0; }
.selection-empty { padding: 22px 12px; margin-top: 18px; border: 1px dashed var(--border); border-radius: 9px; text-align: center; color: var(--muted); }
.selection-empty > span { display: inline-grid; place-items: center; width: 34px; height: 34px; border: 1px solid var(--border); border-radius: 10px; color: var(--accent); font-size: 22px; }
.selection-empty p { font-size: 11px; margin: 12px 0 7px; color: var(--body); }
.selection-empty small { font-size: 10px; line-height: 1.6; }
.selected-reports { display: grid; gap: 7px; max-height: 220px; overflow-y: auto; margin-top: 15px; }
.selected-reports:empty { display: none; }
.selected-report { display: flex; align-items: start; gap: 6px; background: var(--surface-soft); border: 1px solid var(--border); border-radius: 7px; padding: 10px; font-size: 11px; line-height: 1.5; }
.selected-report span { flex: 1; overflow-wrap: anywhere; }
.selected-report button { padding: 0 4px; font-size: 17px; }
.selection-panel label { display: block; margin: 22px 0 9px; font-size: 11px; font-weight: 550; }
.selection-panel textarea { width: 100%; min-height: 120px; resize: vertical; border: 1px solid var(--border); border-radius: 8px; padding: 12px; background: var(--surface-soft); font-size: 11px; line-height: 1.7; }
.draft-hint { font-size: 9px; color: var(--faint); margin: 7px 0 6px; }
.selection-panel > .button { font-size: 12px; padding: 12px; border-radius: 8px; }
.selection-panel #copy-selection { background: transparent; }
.selection-panel #clear-selection { font-size: 10px; padding: 9px; }
.board-active .refresh-status { grid-column: 2; margin: -7px 0 0; }
.report-dialog { width: min(1040px, calc(100vw - 48px)); max-width: none; max-height: calc(100dvh - 48px); padding: 0; border: 1px solid var(--border); border-radius: 17px; background: var(--bg); color: var(--text); overflow: hidden; }
.report-dialog[open] { display: flex; flex-direction: column; animation: popup-arrive 180ms ease-out; }
.board-active:has(#report-dialog[open]), body:has(#evidence-dialog[open]) { overflow: hidden; }
.report-dialog::backdrop, .evidence-dialog::backdrop { background: #04090db8; backdrop-filter: blur(7px); }
.report-dialog-heading { margin: 0; padding: 19px 24px; border-bottom: 1px solid var(--border); flex-shrink: 0; gap: 12px; background: var(--surface-soft); }
.report-dialog-heading .eyebrow { font-size: 8px !important; margin-bottom: 6px !important; }
.report-dialog-heading h2 { margin: 0; font-size: 17px; letter-spacing: -.3px; }
.report-dialog-heading #jump-replies { font-size: 11px; margin-left: auto; border: 1px solid var(--border); border-radius: 7px; padding: 9px 12px; }
.report-dialog-heading #close-report { width: 35px; height: 35px; font-size: 22px; padding: 0; border: 1px solid var(--border); border-radius: 8px; }
.report-dialog-body { padding: 20px; min-height: 0; overflow-y: auto; overscroll-behavior: contain; }
.report-dialog .report { margin-bottom: 0; box-shadow: none; border-radius: 10px; }
.report-dialog .queue-bar { margin-bottom: 16px; }
.report-dialog .pager button { background: var(--surface); border: 1px solid var(--border); min-width: 32px; min-height: 32px; }
.report-dialog .discussion { scroll-margin-top: 12px; }
.report-dialog .discussion-heading h3 { font-size: 14px; color: var(--text); }
.report-dialog .reply { padding: 15px; background: var(--surface); border: 1px solid var(--border); border-radius: 9px; margin: 12px 0; }
.report-dialog .reply .body-text { font-size: 13px; }
.report-dialog #actions { position: static; transform: none; animation: none; width: auto; max-width: none; margin: 0; border-radius: 0; box-shadow: none; border: 0; border-top: 1px solid var(--border); padding: 14px 22px; background: var(--surface-soft); }
.report-dialog #report-dialog-actions { flex-shrink: 0; }
.image-preview { position: relative; display: block; max-width: 100%; padding: 0; border: 1px solid var(--border); border-radius: 10px; overflow: hidden; background: var(--surface-soft); cursor: zoom-in; }
.image-preview img { display: block; transition: transform 220ms; }
.image-preview:hover img { transform: scale(1.015); }
.image-zoom { position: absolute; right: 8px; bottom: 8px; border: 1px solid #fff3; border-radius: 6px; background: #101518dc; color: #fff; padding: 6px 9px; font-size: 10px; pointer-events: none; }
.evidence-dialog { width: min(1200px, calc(100vw - 32px)); max-width: none; max-height: calc(100dvh - 32px); padding: 18px; overflow-y: auto; background: var(--surface); color: var(--text); border-color: var(--border); }
.evidence-dialog .dialog-heading { gap: 15px; margin-bottom: 15px; }
.evidence-dialog h2 { font-size: 15px; overflow-wrap: anywhere; }
.evidence-stage { display: grid; place-items: center; min-height: 150px; border: 1px solid var(--border); border-radius: 9px; background: var(--bg); }
.evidence-stage img { max-width: 100%; max-height: calc(100dvh - 170px); object-fit: contain; }
.evidence-hint { text-align: center; margin: 12px 0 0; font-size: 10px; }
.is-panel .search-tools { width: 100%; }
.is-panel .search-tools kbd, .is-panel .search-tools select { display: none; }
.is-panel #views { flex-wrap: wrap; }
@keyframes card-arrive { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: none; } }
@keyframes popup-arrive { from { opacity: 0; transform: translateY(12px) scale(.99); } to { opacity: 1; transform: none; } }
@media (min-width: 1650px) { .report-cards { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 1250px) {
  .board-active .review { grid-template-columns: 132px minmax(0, 1fr); column-gap: 20px; padding-inline: 24px; }
  .report-board { grid-template-columns: minmax(0, 1fr) 248px; gap: 16px; }
  .report-cards { padding: 12px; gap: 12px; }
  .tile-content { padding: 14px; }
  .selection-panel { padding: 20px 16px 14px; }
  .feed-tip { display: none; }
}
@media (max-width: 1080px) {
  .board-active .review { grid-template-columns: minmax(0, 1fr); }
  .board-active .page-heading, .board-active .search-tools, .report-board, .board-active .refresh-status { grid-column: 1; }
  .board-active #views { grid-column: 1; grid-row: auto; flex-direction: row; position: static; overflow-x: auto; gap: 5px; padding: 3px; }
  .board-active #views:after { display: none; }
  .board-active .tab { flex: 1; min-width: 108px; padding: 10px; }
  .board-active .tab.active { box-shadow: inset 0 -2px var(--accent); }
  .report-cards { max-height: max(400px, calc(100dvh - 405px)); }
}
@media (max-width: 760px) {
  .board-active .header { padding-inline: 16px; height: 64px; }
  .board-active .review { padding: 24px 14px; gap: 15px; }
  .board-active .page-heading { align-items: end; }
  .board-active .page-heading h1 { font-size: 32px; }
  .board-active .page-heading .muted { max-width: 250px; font-size: 11px; }
  .report-board { grid-template-columns: minmax(0, 1fr); }
  .report-cards { max-height: 65dvh; }
  .selection-panel { position: static; }
  .search-field kbd { display: none; }
  .search-tools select { min-width: 106px; padding: 13px 6px; font-size: 11px; }
  .search-field { padding-inline: 10px; }
  .report-dialog { width: calc(100vw - 16px); max-height: calc(100dvh - 16px); }
  .report-dialog-body { padding: 10px; }
  .report-dialog-heading { padding: 14px; gap: 8px; }
  .report-dialog-heading #jump-replies { font-size: 10px; padding: 8px; }
  .report-dialog #actions { padding: 10px; }
}
@media (max-width: 480px) { .report-cards { grid-template-columns: minmax(0, 1fr); } .account #user-name { display: none; } .board-active #refresh { font-size: 11px; padding: 9px; } }
@media (pointer: coarse) { .tile-select, .tile-footer button, .selected-report button, #close-report, #close-evidence { min-height: 44px; } }
@media (prefers-reduced-motion: reduce) { .report-tile, .report-dialog[open], .image-preview img { animation: none; transition: none; } .report-tile:hover, .image-preview:hover img { transform: none; } }
