/* ============================================================
   Paragon Agent Console Simulator — CSS
   Matches real Paragon UI from eLearning screenshots
   ============================================================ */

/* ---------- Reset / Base ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
body {
  font-family: "Amazon Ember", Arial, sans-serif;
  font-size: 13px;
  background: #f5f5f5;
  color: #111;
  min-height: 100vh;
}

/* ---------- App Shell ---------- */
#app-shell {
  display: flex;
  flex-direction: column;
  height: 100vh;
  overflow: hidden;
}

/* ---------- Top Bar ---------- */
#top-bar {
  background: #232f3e;
  color: #fff;
  display: flex;
  align-items: center;
  padding: 0 16px;
  height: 44px;
  flex-shrink: 0;
  gap: 16px;
}
#top-bar .tb-logo {
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0.5px;
  color: #f90;
}
#top-bar .tb-title {
  font-size: 13px;
  color: #ddd;
  flex: 1;
}
#top-bar .tb-agent {
  font-size: 12px;
  color: #aaa;
}

#case-topbar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 16px;
  border-bottom: 1px solid #e2e2e2;
  background: #fff;
  flex-shrink: 0;
}
.ctb-hamburger { cursor: pointer; font-size: 22px; color: #333; padding: 2px 4px; border-radius: 3px; flex-shrink: 0; }
.ctb-hamburger:hover { background: #eee; }
.ctb-hamburger-active { background: #e0f4f6; color: #008296; }
.ctb-hamburger-active:hover { background: #c7ebee; color: #00646f; }
.ctb-caseid { font-size: 26px; font-weight: 700; color: #232f3e; }
.ctb-spacer { flex: 1; }
.ctb-icon-btn { width: 26px; height: 26px; display: flex; align-items: center; justify-content: center; border-radius: 4px; cursor: pointer; font-size: 14px; position: relative; flex-shrink: 0; color: #333; }
.ctb-icon-btn:hover { background: #f0f0f0; }
.ctb-bell { position: relative; }
.ctb-badge { position: absolute; top: -3px; right: -3px; background: #d13212; color: #fff; font-size: 9px; font-weight: 700; border-radius: 8px; padding: 0 4px; line-height: 14px; }
.ctb-search { display: flex; align-items: center; border: 1px solid #ccc; border-radius: 4px; overflow: hidden; flex-shrink: 0; }
.ctb-search input { border: none; outline: none; padding: 5px 8px; font-size: 12px; width: 220px; }
.ctb-search-btn { border: none; background: #f2f2f2; padding: 5px 10px; cursor: pointer; font-size: 12px; color: #333; display: flex; align-items: center; }
#top-bar .tb-status-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #2ecc71;
  display: inline-block;
  margin-right: 4px;
}

/* ---------- Content Row ---------- */
#content-row {
  display: flex;
  flex: 1;
  overflow: hidden;
}

/* ---------- Left Panel (Queue / Case List) ---------- */
#left-panel {
  /* 2026-08-06: switched to a percentage width -- 500px only matched ~25%
     of viewport width at one specific reference-screenshot resolution;
     measured live captures showed it drifting to 19.5%-25.2% depending on
     viewport size. A true 25% keeps the assistant rail proportional at
     any screen size/zoom. */
  width: 25%;
  flex-shrink: 0;
  background: #fff;
  border-right: 1px solid #ddd;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
#queue-tabs {
  display: flex;
  border-bottom: 2px solid #008296;
  flex-shrink: 0;
}
.queue-tab {
  flex: 1;
  padding: 9px 6px;
  text-align: center;
  font-size: 12px;
  font-weight: 600;
  color: #555;
  cursor: pointer;
  border: none;
  background: #f3f3f3;
  border-bottom: 3px solid transparent;
  transition: all .15s;
}
.queue-tab.active {
  color: #008296;
  background: #fff;
  border-bottom: 3px solid #008296;
}
.queue-tab:hover:not(.active) { background: #e8f4f5; }

#case-list {
  flex: 1;
  overflow-y: auto;
}
.case-item {
  padding: 10px 12px;
  border-bottom: 1px solid #eee;
  cursor: pointer;
  transition: background .1s;
}
.case-item:hover { background: #f0f8f9; }
.case-item.selected { background: #e0f3f5; border-left: 3px solid #008296; }
.case-item.selected .ci-id { color: #008296; }

.ci-row1 {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 3px;
}
.ci-id {
  font-weight: 700;
  font-size: 12px;
  color: #0066c0;
}
.ci-status {
  font-size: 10px;
  padding: 1px 6px;
  border-radius: 10px;
  background: #eee;
  color: #555;
  font-weight: 600;
  white-space: nowrap;
}
.ci-status.unassigned { background: #fff3cd; color: #856404; }
.ci-status.wip { background: #d1ecf1; color: #0c5460; }
.ci-status.pending-amazon { background: #fce8d0; color: #7a3700; }
.ci-status.pending-merchant { background: #e2d9f3; color: #4a2580; }
.ci-status.resolved { background: #d4edda; color: #155724; }
.ci-status.reopened { background: #f8d7da; color: #721c24; }

.ci-badges {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  margin-left: auto;
}
.ci-badge {
  font-size: 9px;
  padding: 1px 5px;
  border-radius: 8px;
  background: #008296;
  color: #fff;
  font-weight: 600;
}
.ci-badge.frustrated { background: #c0392b; }
.ci-badge.reopen { background: #2980b9; }
.ci-badge.escalation { background: #8e44ad; }

.ci-row2 {
  font-size: 12px;
  color: #333;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.ci-row3 {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: #888;
  margin-top: 2px;
}
.ci-seller { color: #555; font-weight: 500; }
.ci-time { color: #aaa; }

/* ---------- Right Panel (Detail) ---------- */
#right-panel {
  flex: 1;
  overflow-y: auto;
  background: #f5f5f5;
  padding: 0;
}
.no-case-selected {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  color: #aaa;
  font-size: 16px;
}

/* ---------- Detail View ---------- */
.detail-view {
  display: flex;
  flex-direction: column;
  min-height: 100%;
  border-top: 3px solid #008296;
}

/* Header row: title + Case Actions button */
.detail-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 24px 10px;
  background: #fff;
  border-bottom: 2px solid #007a8a;
  flex-shrink: 0;
  gap: 12px;
}
.case-title-area {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.case-title { font-size: 19px; font-weight: 600; color: #0c5460; }
.case-title-area h2 {
  font-size: 16px;
  font-weight: 700;
  color: #111;
}
.status-tag {
  font-size: 11px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 10px;
  background: #ddd;
  color: #444;
  white-space: nowrap;
}
.status-tag.unassigned { background: #fff3cd; color: #856404; }
.status-tag.wip { background: #d1ecf1; color: #0c5460; }
.status-tag.pending-amazon { background: #fce8d0; color: #7a3700; }
.status-tag.pending-merchant { background: #e2d9f3; color: #4a2580; }
.status-tag.resolved { background: #d4edda; color: #155724; }
.status-tag.reopened { background: #f8d7da; color: #721c24; }
.status-tag.badge-frustrated { background: #e74c3c; color: #fff; }
.status-tag.badge-reopen { background: #2980b9; color: #fff; }
.status-tag.badge-escalation { background: #8e44ad; color: #fff; }

/* Case Actions dropdown */
.case-actions-wrap {
  position: relative;
  flex-shrink: 0;
}
.btn-case-actions {
  /* Reference shows this as a plain teal text link on the title
     underline, not a filled button. */
  background: none;
  color: #008296;
  border: none;
  padding: 4px 2px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  position: relative;
}
.btn-case-actions:hover { text-decoration: underline; }
.case-actions-menu {
  position: absolute;
  top: 100%;
  right: 0;
  background: #fff;
  border: 1px solid #ccc;
  border-radius: 3px;
  box-shadow: 0 3px 10px rgba(0,0,0,.15);
  z-index: 200;
  min-width: 200px;
  display: none;
}
.case-actions-menu.open { display: block; }
.cam-item {
  padding: 8px 14px;
  cursor: pointer;
  font-size: 13px;
  color: #111;
  white-space: nowrap;
}
.cam-item:hover { background: #f0f8f9; color: #008296; }
.cam-item + .cam-item { border-top: 1px solid #f0f0f0; }
.cam-sep {
  height: 1px;
  background: #e5e5e5;
  margin: 2px 0;
}
.cam-actions-wrap {
  position: relative;
  flex-shrink: 0;
}

/* ---------- Detail Body ---------- */
.detail-body {
  display: flex;
  flex: 1;
  gap: 0;
  overflow: visible;
}
.detail-main {
  /* 2026-08c: reference screenshot confirms a SINGLE full-width column,
     not a two-column split -- all sections stack in document order. */
  flex: 1;
  min-width: 0;
  padding: 12px 24px 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* ---------- Case Sections (collapsible) ---------- */
.case-section {
  /* 2026-08-06e: overflow:hidden was clipping open dropdowns (e.g. the
     Transfer reason list) down to ~4 visible rows instead of all 6 -- the
     corner-rounding it existed for is a minor cosmetic tradeoff vs that. */
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 4px;
  overflow: visible;
}
.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  background: #f3f3f3;
  border-bottom: 1px solid #ddd;
  cursor: pointer;
  user-select: none;
  font-size: 13px;
  font-weight: 600;
  color: #2b2b2b;
}
.section-head:hover { background: #e8e8e8; }
/* Annotation-related headings are green per the 2026-08 platform update;
   Correspondence deliberately stays the default grey (confirmed — it is
   NOT treated as an annotation heading even though annotations appear
   inside its timeline). */
.section-head.annotate-head { background: #f3f3f3; color: #2b2b2b; border-bottom: 1px solid #ddd; }
.section-head.annotate-head:hover { background: #e8e8e8; }
.section-head .sh-chevron {
  font-size: 11px;
  color: #666;
  transition: transform .2s;
}
.case-section.collapsed .sh-chevron { transform: rotate(-90deg); }
.case-section.collapsed .section-body { display: none; }
.sh-right {
  display: flex;
  align-items: center;
  gap: 8px;
}
.section-body {
  padding: 12px;
}

/* ---------- Issue Section Inner Layout ---------- */
.issue-inner {
  display: flex;
  gap: 16px;
}
.general-info-col {
  /* 2026-08-06: was a fixed 300px, which read as too slim; user marked up
     a screenshot showing the desired right edge, measured at ~345px from
     the column start at that viewport width. Floor raised to 345px (no
     narrow-window wrapping regression vs the old 300px), still allowed to
     grow on wide screens via the percentage/max. */
  width: clamp(345px, 20%, 420px);
  flex-shrink: 0;
  background: #fafafa;
  border-right: 1px solid #eee;
  padding-right: 16px;
}
.seller-issue-col {
  flex: 1;
  min-width: 0;
}

/* General Info Grid */
.gi-header {
  /* 2026-08-06e: reference screenshot shows this reading as too bold/big
     vs the real tool -- brought down from 17px/700 toward the
     .section-head proportions (13px/600) used elsewhere for headings
     that weren't flagged. */
  font-size: 18px;
  font-weight: 600;
  color: #2b2b2b;
  margin-bottom: 10px;
}
.gi-grid {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 4px 8px;
  font-size: 12px;
}
.gi-label { color: #2b2b2b; font-weight: 600; }
.gi-val { color: #444; word-break: break-word; }
.gi-val a, .paragon-link {
  color: #0066c0;
  text-decoration: none;
  cursor: pointer;
}
.gi-val a:hover, .paragon-link:hover { text-decoration: underline; }
.paragon-link.small { font-size: 11px; }
.gi-more {
  margin-top: 8px;
  padding-top: 6px;
  border-top: 1px solid #eee;
}
.show-more-link {
  font-size: 11px;
  color: #0066c0;
  cursor: pointer;
  text-decoration: none;
  background: none;
  border: none;
  padding: 0;
}
.show-more-link:hover { text-decoration: underline; }
.btn-view-seller {
  /* 2026-08-06d: reference screenshot has this button right-aligned in
     its column, not sitting flush left. */
  background: #232f3e;
  color: #fff;
  border: none;
  border-radius: 3px;
  padding: 5px 12px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  margin-top: 8px;
  margin-left: auto;
  display: block;
}
.btn-view-seller:hover { background: #006b7a; }

/* Seller / Issue col */
.si-header {
  /* 2026-08-06e: same fix as .gi-header -- was 17px/700, too heavy. */
  font-size: 18px;
  font-weight: 600;
  color: #2b2b2b;
  margin-bottom: 10px;
}
.si-label {
  /* 2026-08-06g: user confirmed labels/headings must be visually dominant
     over their values. Restored to sub-heading style: 12px bold dark,
     clearly above the paragraph text that follows it. */
  font-size: 14px;
  font-weight: 600;
  color: #2b2b2b;
  margin-bottom: 2px;
}
.si-summary-text { font-size: 13px; color: #111; line-height: 1.5; margin-bottom: 10px; }
.key-actions-list { margin: 6px 0 10px 16px; font-size: 12px; color: #333; line-height: 1.8; }
.key-ids-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  margin-top: 4px;
}
.ki-label { font-size: 11px; color: #666; }
.ki-id {
  font-size: 11px;
  color: #0066c0;
  background: #f0f8f9;
  border: 1px solid #cce5e8;
  border-radius: 3px;
  padding: 1px 6px;
  cursor: pointer;
}
.ki-id:hover { text-decoration: underline; }
.see-source { font-size: 11px; color: #0066c0; cursor: pointer; margin-left: 4px; }

/* ---------- Inline Annotate-and-Reply / Transfer panels ----------
   (rendered inside standard .case-section/.section-body wrappers,
   same chevron-collapse pattern as Issue summary / Related items.) */
.ar-body, .tr-body { padding: 12px; }
.ar-hint { font-size: 12px; color: #555; margin-bottom: 8px; }
.ar-info { cursor: help; }
.ar-textarea { width: 100%; min-height: 90px; box-sizing: border-box; }
.ar-textarea.input-error { border-color: #c8102e; box-shadow: 0 0 0 1px #c8102e; }
.ar-note { font-size: 11px; color: #777; margin-top: 6px; }
.ar-err { color: #c8102e; font-size: 12px; margin-top: 4px; }
.ar-btns { display: flex; gap: 8px; margin-top: 10px; flex-wrap: wrap; }

/* Draft-response split button + "Send manual email" chevron menu, added
   2026-08-07 to mirror the real Paragon tool's second entry point. */
.ar-split-btn { position: relative; display: inline-flex; }
.ar-split-main { border-radius: 3px 0 0 3px; margin-right: 0; }
.ar-split-chevron {
  border-radius: 0 3px 3px 0;
  border-left: 1px solid rgba(255,255,255,0.35);
  padding: 0 8px;
  min-width: auto;
}
.ar-draft-menu {
  position: absolute;
  top: 100%;
  right: 0;
  margin-top: 2px;
  z-index: 20;
  background: #fff;
  border: 1px solid #bbb;
  border-radius: 3px;
  min-width: 170px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.12);
}
.ar-draft-menu-item {
  padding: 8px 12px;
  font-size: 12px;
  color: #222;
  cursor: pointer;
  white-space: nowrap;
}
.ar-draft-menu-item:hover { background: #eef7f9; color: #008296; }


/* ---------- Related Items Panel ---------- */
.related-items-panel {
  padding: 8px 0;
}
.workflow-row {
  display: flex;
  align-items: center;
  padding: 7px 12px;
  border-bottom: 1px solid #f3f3f3;
  cursor: pointer;
  transition: background .1s;
}
.workflow-row:hover { background: #f0f8f9; }
.wf-icon {
  width: 20px;
  text-align: center;
  margin-right: 8px;
  font-size: 13px;
  color: #008296;
}
.wf-label { flex: 1; font-size: 12px; color: #333; }
.wf-count {
  font-size: 11px;
  color: #fff;
  background: #008296;
  border-radius: 8px;
  padding: 1px 7px;
  margin-right: 6px;
}
.wf-chev { color: #aaa; font-size: 11px; }
.attached-items {
  padding: 8px 12px;
  border-top: 1px solid #eee;
  background: #fafafa;
}
.ai-item {
  font-size: 12px;
  color: #0066c0;
  padding: 3px 0;
  cursor: pointer;
}
.ai-item:hover { text-decoration: underline; }

/* ---------- Correspondence Section ---------- */
.initial-contact-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 8px 12px;
  border: 1px solid #ddd;
  border-radius: 4px;
  background: #fafafa;
  margin-bottom: 8px;
}
.ic-icon {
  font-size: 18px;
  color: #008296;
  flex-shrink: 0;
  margin-top: 2px;
}
.ic-from { font-size: 12px; font-weight: 600; color: #333; }
.ic-blurred {
  font-size: 12px;
  color: #888;
  filter: blur(3px);
  user-select: none;
  pointer-events: none;
}
.ic-snippet { font-size: 12px; color: #555; line-height: 1.4; }
.ic-snippet.expanded { white-space: pre-wrap; }
.initial-contact-row.ic-clickable { cursor: pointer; }
.initial-contact-row.ic-clickable:hover { background: #f0f0f0; }
.ic-expand-hint { font-size: 11px; color: #008296; font-weight: 600; flex-shrink: 0; }
.ic-time { font-size: 11px; color: #aaa; margin-top: 3px; }

.corr-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}
.corr-controls {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 8px 0 12px;
}
.corr-controls-row {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  align-items: center;
}
/* Filter dropdown trigger -- "Filter (N)" with a chevron that flips when open */
.corr-filter-btn {
  color: #0972d3;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  user-select: none;
}
.corr-filter-btn:hover { text-decoration: underline; }
.corr-filter-btn .cfb-chevron { font-size: 10px; margin-left: 3px; display: inline-block; }
/* Filter checkbox panel, shown under the controls row while Filter is open */
.corr-filter-checks {
  display: flex;
  gap: 28px;
  flex-wrap: wrap;
  padding: 10px 4px 2px;
}
.corr-filter-check {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: #333;
  cursor: pointer;
  user-select: none;
}
.corr-filter-check input[type="checkbox"] {
  width: 15px;
  height: 15px;
  cursor: pointer;
  accent-color: #0972d3;
}
/* Translator toggle -- real switch look (grey=off, teal=on) + label */
.corr-toggle-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  user-select: none;
}
.corr-toggle-switch {
  width: 34px;
  height: 18px;
  border-radius: 10px;
  background: #c7cbcd;
  position: relative;
  flex-shrink: 0;
  transition: background .15s;
}
.corr-toggle-switch.active { background: #008296; }
.corr-toggle-switch .cts-knob {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 2px rgba(0,0,0,.35);
  transition: left .15s;
}
.corr-toggle-switch.active .cts-knob { left: 18px; }
.corr-translator-label { font-size: 13px; color: #333; }
/* Expand: All / Inbound / Outbound / Annotations -- bold label, pushed right */
.corr-expand-group {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-left: auto;
}
.expand-label { font-size: 13px; color: #16191f; font-weight: 700; }
.expand-opt { font-size: 13px; color: #16191f; cursor: pointer; user-select: none; }
.expand-opt:hover { text-decoration: underline; }
.expand-opt.active { font-weight: 700; color: #008296; }

/* Reply form */
.reply-form {
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 4px;
  padding: 12px;
  margin-top: 10px;
}
.rf-section { margin-bottom: 12px; }
.rf-label {
  font-size: 12px;
  font-weight: 600;
  color: #333;
  margin-bottom: 4px;
  display: block;
}
.rf-req-star { color: #c00; margin-left: 2px; }
/* "Send manual email" form header + attributes section, added 2026-08-07
   to match the real Paragon layout (title/subtext above the message
   field, then a labeled "Choose attributes" group for Status/Reason). */
.rf-manual-head { margin-bottom: 12px; }
.rf-manual-title { font-size: 15px; font-weight: 700; color: #111; margin-bottom: 3px; }
.rf-manual-sub { font-size: 12px; color: #555; }
.rf-attrs-section { margin-top: 14px; padding-top: 12px; border-top: 1px solid #eee; }

.rf-radios { display: flex; gap: 12px; flex-wrap: wrap; }
.rf-radio { display: flex; align-items: center; gap: 4px; font-size: 12px; cursor: pointer; }
.rf-row { display: flex; gap: 10px; flex-wrap: wrap; }
.rf-field { display: flex; flex-direction: column; gap: 3px; flex: 1; min-width: 120px; }
.rf-select, .rf-input {
  border: 1px solid #bbb;
  border-radius: 3px;
  padding: 5px 8px;
  font-size: 12px;
  color: #111;
  background: #fff;
  width: 100%;
}
.tr-reason-wrap { position: relative; }
.tr-reason-trigger {
  border: 1px solid #bbb;
  border-radius: 3px;
  padding: 5px 8px;
  font-size: 12px;
  color: #111;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
}
.tr-reason-trigger:hover { border-color: #008296; }
.tr-reason-placeholder { color: #687078; }
.tr-reason-chevron { color: #687078; font-size: 11px; margin-left: 6px; }
.tr-reason-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  z-index: 20;
  background: #fff;
  border: 1px solid #bbb;
  border-top: none;
  border-radius: 0 0 3px 3px;
  max-height: 260px;
  overflow-y: auto;
  box-shadow: 0 4px 10px rgba(0,0,0,0.12);
}
.tr-reason-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 7px 10px;
  font-size: 12px;
  color: #222;
  cursor: pointer;
  border-bottom: 1px solid #f0f0f0;
}
.tr-reason-item:last-child { border-bottom: none; }
.tr-reason-item:hover { background: #eef7f9; color: #008296; }
.tr-reason-help {
  position: relative;
  flex-shrink: 0;
  width: 15px;
  height: 15px;
  border-radius: 50%;
  border: 1px solid #888;
  color: #687078;
  font-size: 10px;
  line-height: 13px;
  text-align: center;
  cursor: help;
}
.tr-reason-help:hover { border-color: #008296; color: #008296; }
.tr-reason-tooltip {
  display: none;
  position: absolute;
  right: 100%;
  top: 50%;
  transform: translateY(-50%);
  margin-right: 10px;
  width: 180px;
  background: #0b3d4f;
  color: #fff;
  padding: 10px 12px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 400;
  line-height: 1.4;
  text-align: left;
  box-shadow: 0 3px 10px rgba(0,0,0,0.25);
  z-index: 30;
  cursor: default;
}
.tr-reason-tooltip::after {
  content: "";
  position: absolute;
  left: 100%;
  top: 50%;
  transform: translateY(-50%);
  border: 5px solid transparent;
  border-left-color: #0b3d4f;
}
.tr-reason-help:hover .tr-reason-tooltip { display: block; }

/* ---------- Transfer reason follow-up fields (language/store/resolver/agent) ---------- */
.tr-extra-field { margin-top: -2px; }
.tr-extra-search-wrap { position: relative; }
.tr-extra-search-trigger {
  border: 1px solid #bbb;
  border-radius: 3px;
  padding: 5px 8px;
  font-size: 12px;
  color: #111;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
}
.tr-extra-search-trigger:hover { border-color: #008296; }
.tr-extra-search-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  z-index: 20;
  background: #fff;
  border: 1px solid #bbb;
  border-top: none;
  border-radius: 0 0 3px 3px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.12);
}
.tr-extra-search-input-row {
  display: flex;
  align-items: center;
  border-bottom: 1px solid #eee;
  padding: 0 8px;
}
.tr-extra-search-input {
  flex: 1;
  border: none;
  padding: 7px 4px;
  font-size: 12px;
  outline: none;
}
.tr-extra-search-icon { font-size: 12px; color: #888; }
.tr-extra-search-list { max-height: 220px; overflow-y: auto; }
.tr-extra-search-item {
  padding: 7px 10px;
  font-size: 12px;
  color: #222;
  cursor: pointer;
  border-bottom: 1px solid #f5f5f5;
}
.tr-extra-search-item:last-child { border-bottom: none; }
.tr-extra-search-item:hover { background: #eef7f9; color: #008296; }
.rf-select:focus, .rf-input:focus { border-color: #008296; outline: none; }
.rf-input.half { max-width: 160px; }
.rf-textarea {
  width: 100%;
  border: 1px solid #bbb;
  border-radius: 3px;
  padding: 6px 8px;
  font-size: 12px;
  resize: vertical;
  min-height: 80px;
  font-family: inherit;
  color: #111;
}
.rf-textarea:focus { border-color: #008296; outline: none; }
.rf-blurb-row {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px 8px;
  background: #fffbea;
  border: 1px solid #f0d060;
  border-radius: 3px;
  font-size: 11px;
  color: #666;
}
.rf-err { color: #c00; font-size: 11px; margin-top: 3px; }
.rf-warning {
  background: #fff3cd;
  border: 1px solid #ffc107;
  border-radius: 3px;
  padding: 6px 10px;
  font-size: 12px;
  color: #856404;
  margin-bottom: 8px;
}
.rf-attach-zone {
  border: 2px dashed #bbb;
  border-radius: 4px;
  padding: 12px;
  text-align: center;
  color: #aaa;
  font-size: 12px;
  cursor: pointer;
}
.rf-attach-zone:hover { border-color: #008296; color: #008296; }
.rf-check { display: flex; align-items: center; gap: 6px; font-size: 12px; cursor: pointer; }

/* ---------- Contact Reason Rail ---------- */
.contact-reason-rail {
  width: 260px;
  flex-shrink: 0;
  border-left: 1px solid #ddd;
  background: #fff;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  padding: 0;
}
.cr-panel-inner {
  padding: 10px 12px;
  flex: 1;
}
.cr-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}
.cr-title {
  font-size: 13px;
  font-weight: 700;
  color: #111;
}
.cr-x {
  background: none;
  border: none;
  font-size: 16px;
  color: #888;
  cursor: pointer;
  line-height: 1;
}
.cr-x:hover { color: #c00; }
.cr-plus {
  background: none;
  border: 1px solid #008296;
  border-radius: 50%;
  width: 20px;
  height: 20px;
  color: #008296;
  font-size: 14px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}
.cr-plus:hover { background: #008296; color: #fff; }
.cr-links-row {
  display: flex;
  gap: 10px;
  margin-bottom: 10px;
}
.cr-link {
  font-size: 11px;
  color: #0066c0;
  cursor: pointer;
  text-decoration: none;
  background: none;
  border: none;
  padding: 0;
}
.cr-link:hover { text-decoration: underline; }

.cr-task-block { margin-bottom: 12px; }
.cr-error-banner {
  background: #fdecea;
  color: #c0392b;
  border: 1px solid #f5c2c0;
  padding: 6px 10px;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 6px;
}
/* 2026-08-07: distinct tone for the 3rd-attempt answer reveal -- informational
   (the learner now knows the right answer), not a red "you're wrong" error. */
.cr-error-banner.cr-error-reveal {
  background: #eaf2fd;
  color: #1a5fb4;
  border: 1px solid #b8d4f7;
}
.cr-task-row-head {
  font-size: 11px;
  font-weight: 600;
  color: #555;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  margin-bottom: 4px;
}
.cr-select {
  /* 2026-08-06: real tool leaves a clear ~15px gap between each cascading
     dropdown in this tree; 6px read as cramped/"same line". */
  width: 100%;
  border: 1px solid #bbb;
  border-radius: 3px;
  padding: 5px 8px;
  font-size: 12px;
  color: #111;
  background: #fff;
  margin-bottom: 14px;
}
.cr-select:focus { border-color: #008296; outline: none; }
.btn.btn-select-task {
  background: #008296;
  color: #fff;
  border: none;
  border-radius: 3px;
  padding: 5px 12px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  width: 100%;
}
.btn-select-task:hover { background: #006b7a; }
.cr-selected-badge {
  background: #e0f3f5;
  border: 1px solid #008296;
  border-radius: 3px;
  padding: 4px 8px;
  font-size: 11px;
  color: #006b7a;
  margin-bottom: 8px;
  word-break: break-word;
}
.cr-announce-header {
  font-size: 11px;
  font-weight: 700;
  color: #555;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  margin-bottom: 6px;
  margin-top: 10px;
}
.cr-announce-list { display: flex; flex-direction: column; gap: 4px; }
.cr-ann-item {
  background: #fafafa;
  border: 1px solid #eee;
  border-radius: 3px;
  padding: 5px 8px;
}
.cr-alert { font-size: 10px; font-weight: 700; color: #c0392b; text-transform: uppercase; }
.cr-announce-link {
  font-size: 12px;
  color: #0066c0;
  cursor: pointer;
  text-decoration: none;
  display: block;
  line-height: 1.3;
}
.cr-announce-link:hover { text-decoration: underline; }
.cr-ann-when { font-size: 10px; color: #aaa; margin-top: 2px; }
.cr-search-row { margin: 0 0 12px; position: relative; }
.cr-search-input {
  width: 100%;
  border: 1px solid #bbb;
  border-radius: 3px;
  padding: 5px 8px;
  font-size: 12px;
  color: #111;
}
.cr-search-input:focus { border-color: #008296; outline: none; }
.cr-search-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  z-index: 20;
  background: #fff;
  border: 1px solid #bbb;
  border-top: none;
  border-radius: 0 0 3px 3px;
  max-height: 260px;
  overflow-y: auto;
  box-shadow: 0 4px 10px rgba(0,0,0,0.12);
}
.cr-search-dropdown-item {
  padding: 6px 10px;
  font-size: 12px;
  color: #222;
  cursor: pointer;
  border-bottom: 1px solid #f0f0f0;
}
.cr-search-dropdown-item:last-child { border-bottom: none; }
.cr-search-dropdown-item:hover { background: #eef7f9; color: #008296; }
.cr-search-dropdown-empty { padding: 8px 10px; font-size: 12px; color: #888; font-style: italic; }

/* ---------- Contact Reason tab chip + icons (2026-08 update) ---------- */
.cr-tab-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #e6f3f7;
  color: #006b7a;
  border-bottom: 2px solid #008296;
  border-radius: 4px 4px 0 0;
  padding: 5px 10px;
  font-size: 12px;
  font-weight: 700;
}
.cr-icons-row { display: flex; align-items: center; gap: 6px; margin-left: auto; }
.cr-icon-btn {
  width: 22px; height: 22px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 4px;
  color: #777;
  font-size: 13px;
  cursor: pointer;
}
.cr-icon-btn:hover { background: #f0f0f0; color: #333; }

/* ---------- Contact Reason: two side-by-side recommendation cards ---------- */
.cr-cards-row {
  display: flex;
  gap: 12px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}
.cr-card {
  /* 2026-08-07: corrected against a clearer real-Paragon reference screenshot --
     both cards actually stretch to fill the row (~48% each with the row gap
     between), not hug the left with empty space on the right. flex-grow must
     be 1 (was 0) so each present card actually grows to fill available row
     width; max-width still caps it at 48% so a lone card (before the 2nd
     unlocks) doesn't stretch across the full panel. */
  flex: 1 1 420px;
  max-width: 48%;
  min-width: 220px;
  border: 1px solid #ddd;
  border-radius: 4px;
  padding: 10px 12px;
  background: #fff;
}
/* 2026-08-13 (reverted): the two rules that used to live here made a
   solved card expand to 100% width (pushing an unsolved sibling below it),
   reverting to 48%/48% only once BOTH cards were solved. A real-Paragon
   reference screenshot confirmed the two-card row should stay side-by-side
   at all times, solved or not -- so both rules are removed and .cr-card's
   base rule above (flex:1 1 420px; max-width:48%) is now the only width
   rule, unconditionally. Guidance content must fit within that 48% column;
   see .wf-guidance-box / .wf-step-* rules below for the narrow-column
   styling that makes that work. */
.cr-card-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}
.cr-card-title { font-size: 14px; font-weight: 700; color: #111; }
.cr-card-vh { font-size: 10.5px; white-space: nowrap; }
.cr-select-indent { margin-left: 12px; width: calc(100% - 12px); }
.cr-select-indent2 {
  /* 2026-08-06: the 3rd-level select was reusing the same 12px indent as
     the 2nd level, so it never stepped further right - no cascade. */
  margin-left: 24px;
  width: calc(100% - 24px);
}
/* ---------- Training Panel ---------- */
.practice-scenario-banner {
  /* 2026-08-06i: relocated out of the pixel-matched case body -- this is
     wrapper/meta UI, not part of the real tool, so it's styled to read
     as clearly separate (full-bleed strip above the case header) rather
     than blending into the replica like the old inline version did. */
  background: #fffbea;
  border-bottom: 1px solid #f0d060;
  padding: 10px 16px;
  margin: 0 0 4px;
}
.psb-label {
  font-size: 11px;
  font-weight: 700;
  color: #856404;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 4px;
}
.tp-objective {
  font-size: 12px;
  color: #5a4500;
  line-height: 1.5;
  margin-bottom: 6px;
}
.tp-hint-toggle {
  font-size: 11px;
  color: #0066c0;
  cursor: pointer;
  background: none;
  border: none;
  padding: 0;
  text-decoration: none;
}
.tp-hint-toggle:hover { text-decoration: underline; }
.tp-hint {
  display: none;
  font-size: 12px;
  color: #5a4500;
  background: #fff8d0;
  border: 1px dashed #c8a000;
  border-radius: 3px;
  padding: 6px 8px;
  margin-top: 6px;
  line-height: 1.5;
}
.tp-hint.shown { display: block; }

/* ---------- Follow-up Section ---------- */
.followup-section {
  margin-top: 8px;
  border-top: 1px solid #eee;
  padding-top: 8px;
}
.fu-header {
  font-size: 11px;
  font-weight: 700;
  color: #555;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  margin-bottom: 6px;
}
.fu-item {
  background: #fafafa;
  border: 1px solid #eee;
  border-radius: 3px;
  padding: 6px 10px;
  margin-bottom: 4px;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 8px;
}
.fu-when { font-size: 11px; color: #888; white-space: nowrap; }
.fu-notes { font-size: 12px; color: #333; flex: 1; line-height: 1.4; }
.fu-clear {
  background: none;
  border: none;
  color: #aaa;
  font-size: 14px;
  cursor: pointer;
  line-height: 1;
  flex-shrink: 0;
}
.fu-clear:hover { color: #c00; }

/* ---------- Modal System ---------- */
#modalOverlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.45);
  z-index: 1000;
  align-items: center;
  justify-content: center;
}
#modalOverlay.open {
  display: flex;
}
#modalBox {
  background: #fff;
  border-radius: 4px;
  box-shadow: 0 8px 32px rgba(0,0,0,.25);
  min-width: 480px;
  max-width: 680px;
  width: 90vw;
  max-height: 90vh;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
}
#modalBox.wide {
  max-width: 860px;
}
.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  border-bottom: 1px solid #ddd;
  flex-shrink: 0;
}
.modal-header h3 {
  font-size: 15px;
  font-weight: 700;
  color: #111;
}
.modal-close {
  background: none;
  border: none;
  font-size: 20px;
  color: #888;
  cursor: pointer;
  line-height: 1;
}
.modal-close:hover { color: #c00; }
.modal-body {
  padding: 16px;
  flex: 1;
  overflow-y: auto;
}
.modal-footer {
  padding: 10px 16px;
  border-top: 1px solid #ddd;
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  flex-shrink: 0;
  background: #f9f9f9;
}

/* Buttons in modals */
.btn-primary {
  background: #008296;
  color: #fff;
  border: none;
  border-radius: 3px;
  padding: 7px 18px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}
.btn-primary:hover { background: #006b7a; }
.btn-primary:disabled { background: #aaa; cursor: not-allowed; }
.btn-secondary {
  background: #fff;
  color: #333;
  border: 1px solid #bbb;
  border-radius: 3px;
  padding: 7px 18px;
  font-size: 13px;
  cursor: pointer;
}
.btn-secondary:hover { background: #f5f5f5; }
.btn-danger {
  background: #c0392b;
  color: #fff;
  border: none;
  border-radius: 3px;
  padding: 7px 18px;
  font-size: 13px;
  cursor: pointer;
}
.btn-danger:hover { background: #a52a1d; }

/* Modal info grid (seller info, etc.) */
.modal-info-grid {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 6px 10px;
  font-size: 13px;
  margin-bottom: 12px;
}
.mig-key { color: #666; font-weight: 500; }
.mig-val { color: #111; word-break: break-word; }
.mig-val a { color: #0066c0; text-decoration: none; }
.mig-val a:hover { text-decoration: underline; }

/* ---------- Transfer Form ---------- */
.transfer-form { font-size: 13px; }
.tf-type-row {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
}
.tf-type-btn {
  padding: 6px 14px;
  border: 1px solid #bbb;
  border-radius: 3px;
  background: #fff;
  color: #555;
  font-size: 12px;
  cursor: pointer;
}
.tf-type-btn.active {
  background: #008296;
  border-color: #008296;
  color: #fff;
}
.tf-search-input {
  width: 100%;
  border: 1px solid #bbb;
  border-radius: 3px;
  padding: 6px 8px;
  font-size: 12px;
  margin-bottom: 8px;
}
.tf-search-input:focus { border-color: #008296; outline: none; }
.tf-list {
  border: 1px solid #ddd;
  border-radius: 3px;
  max-height: 200px;
  overflow-y: auto;
}
.tf-list-item {
  padding: 7px 10px;
  border-bottom: 1px solid #f0f0f0;
  cursor: pointer;
  font-size: 12px;
}
.tf-list-item:last-child { border-bottom: none; }
.tf-list-item:hover { background: #f0f8f9; }
.tf-list-item.tf-sel { background: #e0f3f5; color: #006b7a; font-weight: 600; }
.tf-empty { padding: 12px; text-align: center; color: #aaa; font-size: 12px; }
.tf-hint {
  font-size: 11px;
  color: #888;
  margin-top: 6px;
}
.tf-selected-label {
  font-size: 12px;
  color: #006b7a;
  background: #e0f3f5;
  border: 1px solid #008296;
  border-radius: 3px;
  padding: 4px 8px;
  margin-bottom: 8px;
  font-weight: 600;
}

/* ---------- Review Modal ---------- */
.review-block {
  margin-bottom: 12px;
  border: 1px solid #eee;
  border-radius: 3px;
  overflow: hidden;
}
/* 2026-08-07: Knowledge Check modal -- short multiple-choice questions
   shown after a trainee sends a reply / updates status, before the debrief. */
.kc-intro { font-size: 12.5px; color: #444; margin: 0 0 12px; }
.kc-list { display: flex; flex-direction: column; gap: 14px; }
.kc-question {
  border: 1px solid #e2e2e2;
  border-radius: 4px;
  padding: 10px 12px;
  background: #fafafa;
}
.kc-prompt { font-size: 13px; font-weight: 600; color: #222; margin-bottom: 8px; }
.kc-choices { display: flex; flex-direction: column; gap: 6px; }
.kc-choice {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 12.5px;
  color: #333;
  cursor: pointer;
}
.kc-choice input { margin-top: 2px; flex-shrink: 0; }
.kc-error { color: #c00; font-size: 12px; margin-top: 10px; }
.review-row {
  display: flex;
  align-items: flex-start;
  padding: 6px 10px;
  border-bottom: 1px solid #f0f0f0;
  gap: 8px;
}
.review-row:last-child { border-bottom: none; }
.coach-intercept-banner {
  margin: 4px 0 12px;
  border: 1px solid #b7e0e6;
  background: #eef8fa;
  border-radius: 6px;
  padding: 10px 12px;
}
.coach-intercept-head { font-size: 12px; font-weight: 700; color: #006677; margin-bottom: 4px; }
.coach-intercept-body { font-size: 12.5px; line-height: 1.5; color: #222; white-space: pre-wrap; }
.coach-intercept-body.coach-typing { font-style: italic; color: #777; }
.review-key { font-size: 12px; color: #666; width: 100px; flex-shrink: 0; }
.review-body { flex: 1; font-size: 12px; color: #111; }
.review-pre {
  background: #f8f8f8;
  border: 1px solid #eee;
  border-radius: 3px;
  padding: 8px 10px;
  font-size: 12px;
  color: #111;
  white-space: pre-wrap;
  word-break: break-word;
  max-height: 200px;
  overflow-y: auto;
  line-height: 1.5;
}

/* ---------- Follow-up Modal Form ---------- */
.followup-modal-head {
  font-size: 13px;
  font-weight: 600;
  color: #333;
  margin-bottom: 12px;
}
.fu-form { display: flex; flex-direction: column; gap: 10px; }
.fu-form-label {
  font-size: 12px;
  font-weight: 600;
  color: #333;
  margin-bottom: 3px;
  display: block;
}
.fu-dt-row { display: flex; gap: 8px; }

/* ---------- Andon Form ---------- */
.andon-form { display: flex; flex-direction: column; gap: 10px; }
.andon-form .af-label {
  font-size: 12px;
  font-weight: 600;
  color: #333;
  margin-bottom: 3px;
  display: block;
}
.andon-form select, .andon-form textarea {
  width: 100%;
  border: 1px solid #bbb;
  border-radius: 3px;
  padding: 5px 8px;
  font-size: 12px;
  font-family: inherit;
}
.andon-form select:focus, .andon-form textarea:focus {
  border-color: #008296;
  outline: none;
}

/* ---------- Tab buttons (New Outbound Case) ---------- */
.modal-tabs {
  display: flex;
  gap: 0;
  border-bottom: 2px solid #008296;
  margin-bottom: 12px;
}
.modal-tab {
  padding: 7px 16px;
  border: none;
  background: #f3f3f3;
  color: #555;
  font-size: 13px;
  cursor: pointer;
  border-bottom: 3px solid transparent;
  font-weight: 500;
}
.modal-tab.active-tab {
  background: #fff;
  color: #008296;
  border-bottom: 3px solid #008296;
  font-weight: 700;
}
.modal-tab:hover:not(.active-tab) { background: #e8f4f5; }

/* ---------- Annotations Panel ---------- */
.annotations-panel { padding: 8px 0; }
.ann-item {
  padding: 7px 12px;
  border-bottom: 1px solid #f3f3f3;
  font-size: 12px;
  color: #333;
}
.ann-meta { font-size: 11px; color: #888; margin-bottom: 2px; }
.ann-text { color: #111; }

/* ---------- Phone Contacts Panel ---------- */
.phone-contacts-list { padding: 4px 0; }
.pc-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 7px 12px;
  border-bottom: 1px solid #f3f3f3;
  font-size: 12px;
}
.pc-direction {
  background: #008296;
  color: #fff;
  border-radius: 8px;
  padding: 1px 7px;
  font-size: 10px;
  font-weight: 700;
  margin-right: 6px;
}
.pc-direction.in { background: #27ae60; }
.pc-time { font-size: 11px; color: #888; }
.pc-duration { font-size: 11px; color: #555; }
.pc-agent { font-size: 11px; color: #555; }

/* ---------- Seller Info Modal ---------- */
.seller-info-section {
  margin-bottom: 14px;
}
.sis-title {
  font-size: 12px;
  font-weight: 700;
  color: #008296;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  margin-bottom: 6px;
  padding-bottom: 3px;
  border-bottom: 1px solid #e0f3f5;
}
.siv-grid {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 4px 8px;
  font-size: 12px;
}
.siv-label { color: #666; }
.siv-val { color: #111; word-break: break-word; }
.siv-val.good { color: #27ae60; font-weight: 600; }
.siv-val.warn { color: #e67e22; font-weight: 600; }
.siv-val.bad { color: #c0392b; font-weight: 600; }

/* ---------- Update Status Modal ---------- */
.us-hint {
  font-size: 12px;
  color: #555;
  margin-bottom: 10px;
  line-height: 1.5;
}
.us-radio-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.us-radio {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 10px;
  border: 1px solid #ddd;
  border-radius: 3px;
  cursor: pointer;
  font-size: 12px;
  transition: background .1s;
}
.us-radio:hover { background: #f0f8f9; }
.us-radio.selected { background: #e0f3f5; border-color: #008296; color: #006b7a; font-weight: 600; }
.us-radio input[type=radio] { margin: 0; }

/* ---------- Misc ---------- */
.text-muted { color: #888; font-size: 12px; }
.text-link { color: #0066c0; cursor: pointer; text-decoration: none; }
.text-link:hover { text-decoration: underline; }
.mt4 { margin-top: 4px; }
.mt8 { margin-top: 8px; }
.mt12 { margin-top: 12px; }
.mb4 { margin-bottom: 4px; }
.mb8 { margin-bottom: 8px; }
.flex-row { display: flex; align-items: center; gap: 6px; }
.flex-1 { flex: 1; }

/* Inline notice */
.inline-notice {
  background: #f0f8f9;
  border: 1px solid #008296;
  border-radius: 3px;
  padding: 8px 12px;
  font-size: 12px;
  color: #005566;
  margin-bottom: 8px;
}

/* Scrollbar (webkit) */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: #f0f0f0; }
::-webkit-scrollbar-thumb { background: #bbb; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #888; }

/* ---------- Toast notification ---------- */
#toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: #232f3e;
  color: #fff;
  padding: 10px 18px;
  border-radius: 4px;
  font-size: 13px;
  box-shadow: 0 4px 16px rgba(0,0,0,.25);
  z-index: 2000;
  opacity: 0;
  transition: opacity .3s;
  pointer-events: none;
}
#toast.show { opacity: 1; }

/* Empty queue message */
.queue-empty {
  padding: 20px 16px;
  text-align: center;
  color: #aaa;
  font-size: 13px;
}

/* ============================================================
   PATCH — Layout IDs + missing classes used by app.js
   ============================================================ */

/* App shell layout */
#app-shell {
  display: flex;
  flex-direction: column;
  height: 100vh;
  overflow: hidden;
}
#top-bar {
  background: #232f3e;
  color: #fff;
  display: flex;
  align-items: center;
  padding: 0 14px;
  height: 44px;
  gap: 10px;
  flex-shrink: 0;
}
.tb-logo { font-weight: 700; font-size: 15px; color: #f90; flex-shrink: 0; }
.tb-title { flex: 1; font-size: 13px; color: #ccc; }
.tb-agent { font-size: 12px; color: #bbb; }
.tb-status-dot { width: 8px; height: 8px; border-radius: 50%; background: #2ecc71; display: inline-block; }
#statusPill { font-size: 11px; padding: 1px 8px; border-radius: 8px; cursor: pointer; }
#statusPill.away { background: #e07a1a !important; }

#content-row {
  display: flex;
  flex: 1;
  overflow: hidden;
}
#left-panel {
  /* 2026-08-06: switched to a percentage width -- 500px only matched ~25%
     of viewport width at one specific reference-screenshot resolution;
     measured live captures showed it drifting to 19.5%-25.2% depending on
     viewport size. A true 25% keeps the assistant rail proportional at
     any screen size/zoom. */
  width: 25%;
  flex-shrink: 0;
  background: #fff;
  border-right: 1px solid #ddd;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
/* ---------- Case Handling Assistant (2026-08 platform update) ---------- */
#assistantPanel {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 10px 12px;
  overflow-y: auto;
}
#caseListWrap { display: flex; flex-direction: column; flex: 1; overflow: hidden; }
.ap-header { display: flex; align-items: center; gap: 8px; margin-bottom: 14px; }
.ap-hamburger { cursor: pointer; font-size: 16px; color: #555; padding: 2px 4px; border-radius: 3px; flex-shrink: 0; }
.ap-hamburger:hover { background: #eee; }
.ap-close-btn { cursor: pointer; font-size: 12px; font-weight: 700; color: #008296; background: #e0f4f6; padding: 4px 10px; border-radius: 12px; flex-shrink: 0; line-height: 1.2; white-space: nowrap; }
.ap-close-btn:hover { background: #c7ebee; color: #00646f; }
.cl-title-sep { color: #ccc; flex-shrink: 0; }
.ap-title { font-size: 26px; font-weight: 700; color: #232f3e; display: flex; align-items: center; gap: 6px; }
.ap-beta { font-size: 9px; font-weight: 700; background: #7b2ff7; color: #fff; padding: 1px 6px; border-radius: 8px; letter-spacing: .5px; }
.ap-header-icons { display: flex; align-items: center; gap: 6px; margin-left: auto; }
.ap-icon-btn { width: 24px; height: 24px; display: flex; align-items: center; justify-content: center; border-radius: 4px; color: #667; font-size: 14px; font-weight: 700; cursor: pointer; }
.ap-icon-btn:hover { background: #eee; color: #232f3e; }
.ap-collapse { font-size: 18px; font-weight: 700; }
.ap-prompt-label { font-size: 16px; font-weight: 700; color: #333; margin: 10px 0; }
.ap-sim-hint { display: flex; align-items: flex-start; gap: 8px; background: #fff8e1; border: 1px solid #f0d264; border-left: 4px solid #e0a800; border-radius: 4px; padding: 8px 12px; font-size: 12.5px; line-height: 1.4; color: #5c4b13; margin-bottom: 14px; flex-shrink: 0; }
.ap-sim-hint-icon { font-size: 14px; flex-shrink: 0; }
.ap-sim-hint strong { font-size: 15px; line-height: 1; }
.ap-prompts-wrap {
  /* 2026-08-06: user compared to the real tool -- the prompt cards there
     sit inset from the panel edges, not stretched flush to them, and are
     noticeably smaller/narrower than a full-width card. */
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 14%;
}
.ap-prompt-label { text-align: center; }
.ap-prompts { display: flex; flex-direction: column; gap: 14px; width: 100%; margin: 0 auto; }
.ap-prompt-card { border: 1px solid #ddd; border-radius: 6px; padding: 16px 18px; cursor: pointer; display: flex; align-items: flex-start; gap: 12px; }
.ap-prompt-card:hover { border-color: #008296; background: #f5fbfb; }
.ap-prompt-icon { flex-shrink: 0; margin-top: 1px; color: #0972d3; }
.ap-prompt-body { min-width: 0; }
.ap-prompt-title { font-size: 13px; font-weight: 700; color: #222; }
.ap-prompt-sub { font-size: 12px; color: #777; margin-top: 2px; }
.ap-input-row { margin-top: auto; padding-top: 10px; display: flex; align-items: flex-end; gap: 6px; }
.ap-input {
  /* 2026-08-06: real tool's message box is a tall multi-line area, not a
     thin single-line field. */
  flex: 1;
  border: 1px solid #ccc;
  border-radius: 16px;
  padding: 10px 14px;
  font-size: 12px;
  font-family: inherit;
  min-height: 64px;
  resize: none;
}
.ap-send { border: none; background: #232f3e; color: #fff; border-radius: 50%; width: 30px; height: 30px; cursor: pointer; flex-shrink: 0; margin-bottom: 4px; }
.ap-send:hover { background: #37475a; }
.ap-send:disabled, .ap-input:disabled { opacity: .5; cursor: not-allowed; }
/* 2026-08-09: chat message area, shown once a conversation has started
   (replaces the prompt-cards landing view -- same panel, same input row). */
.ap-messages { flex: 1; overflow-y: auto; padding: 4px 0 10px; }
.ap-msg { display: flex; margin-bottom: 8px; }
.ap-msg-user { justify-content: flex-end; }
.ap-msg-assistant { justify-content: flex-start; }
.ap-msg-bubble {
  max-width: 88%; padding: 8px 11px; border-radius: 10px; font-size: 12.5px; line-height: 1.45;
  white-space: pre-wrap; word-break: break-word;
}
.ap-msg-user .ap-msg-bubble { background: #008296; color: #fff; }
.ap-msg-assistant .ap-msg-bubble { background: #eef1f3; color: #222; }
.ap-typing { font-style: italic; color: #777; }
.ap-msg-bubble ul, .ap-msg-bubble ol { margin: 4px 0; padding-left: 18px; }
.ap-msg-bubble li { margin-bottom: 3px; }
.ap-msg-bubble strong { font-weight: 700; }
#sidebar {
  background: #232f3e;
  padding: 8px 0;
  flex-shrink: 0;
}
#sidebar h4 {
  font-size: 11px;
  font-weight: 700;
  color: #aaa;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 4px 14px 6px;
}
.queue-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 14px;
  cursor: pointer;
  color: #ccc;
  font-size: 13px;
  transition: background .15s;
}
.queue-item:hover { background: #2c3e50; color: #fff; }
.queue-item.active { background: #008296; color: #fff; }
.queue-item .count {
  background: rgba(255,255,255,.2);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  padding: 1px 7px;
  border-radius: 8px;
}
.queue-item.active .count { background: rgba(0,0,0,.2); }
.reset-bar {
  padding: 6px 14px;
  font-size: 11px;
  color: #888;
  margin-top: 4px;
  border-top: 1px solid #2c3e50;
}
.reset-bar a {
  color: #f90;
  cursor: pointer;
  text-decoration: none;
}
.reset-bar a:hover { text-decoration: underline; }
.reset-bar a.summary-ready {
  color: #2ecc71;
  font-weight: 700;
  animation: summaryPulse 1.6s ease-in-out infinite;
}
@keyframes summaryPulse { 0%,100% { opacity: 1; } 50% { opacity: .55; } }

#case-list-panel {
  flex: 1;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
#caseListTitle {
  font-size: 12px;
  font-weight: 700;
  color: #555;
  background: #f8f8f8;
  border-bottom: 1px solid #eee;
  padding: 8px 12px;
  flex-shrink: 0;
}
#caseList {
  flex: 1;
  overflow-y: auto;
}
#caseDetail {
  flex: 1;
  overflow-y: auto;
  background: #f5f5f5;
}

/* Case list rows */
.case-row {
  padding: 10px 12px;
  border-bottom: 1px solid #eee;
  cursor: pointer;
  transition: background .1s;
}
.case-row:hover { background: #f0f8f9; }
.case-row.selected { background: #e0f3f5; border-left: 3px solid #008296; }
.row-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 3px;
}
.case-id { font-weight: 700; font-size: 12px; color: #0066c0; }
.case-row.selected .case-id { color: #008296; }
.sender-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 2px;
}
.customer-name {
  font-size: 12px;
  font-weight: 600;
  color: #333;
  display: flex;
  align-items: center;
  gap: 4px;
}
.priority-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
}
.subject {
  font-size: 12px;
  color: #333;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 2px;
}
.email-snippet-preview {
  font-size: 11px;
  color: #888;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.empty-state {
  padding: 20px 16px;
  text-align: center;
  color: #aaa;
  font-size: 13px;
}
.detail-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  gap: 10px;
  color: #aaa;
  font-size: 14px;
}

/* Status badge */
.badge {
  font-size: 10px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 9px;
  white-space: nowrap;
}
.badge.unassigned { background: #fff3cd; color: #856404; }
.badge.workinprogress { background: #d1ecf1; color: #0c5460; }
.badge.pendingamazonaction { background: #fce8d0; color: #7a3700; }
.badge.pendingdeployment { background: #dbe4ff; color: #1e3a8a; }
.badge.pending { background: #e2d9f3; color: #4a2580; }
.badge.resolved { background: #d4edda; color: #155724; }
.badge.reopened { background: #f8d7da; color: #721c24; }

/* Generic btn system used by app.js */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 5px 12px;
  border: 1px solid #bbb;
  border-radius: 3px;
  background: #fff;
  color: #333;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
  transition: all .15s;
}
.btn:hover { background: #f5f5f5; }
.btn.small { padding: 3px 8px; font-size: 11px; }
.btn.primary { background: #008296; color: #fff; border-color: #008296; }
.btn.primary:hover { background: #006b7a; }
.btn.active-tab { background: #008296; color: #fff; border-color: #008296; }

/* Correspondence thread */
.email-item {
  border: 1px solid #ddd;
  border-radius: 4px;
  margin-bottom: 8px;
  overflow: hidden;
  background: #fff;
}
.email-item.from-customer { border-left: 3px solid #0066c0; }
.email-item.from-agent { border-left: 3px solid #008296; }
.email-item.from-system { border-left: 3px solid #888; }
.email-row {
  display: flex;
  align-items: flex-start;
  gap: 0;
}
.email-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #008296;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  flex-shrink: 0;
  margin: 10px 10px 10px 12px;
}
.email-item.from-customer .email-avatar { background: #0066c0; }
.email-item.from-system .email-avatar { background: #888; }
.email-row-main {
  flex: 1;
  min-width: 0;
  padding: 8px 12px 8px 0;
}
.email-row-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  cursor: pointer;
}
.email-from-name { font-size: 13px; font-weight: 600; color: #111; }
.email-time { font-size: 11px; color: #aaa; flex-shrink: 0; }
.email-snippet {
  font-size: 12px;
  color: #555;
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
/* 2026-08-06k: collapsed correspondence/initial-contact row -- just
   From + a truncated snippet + relative time on one line, matching real
   Paragon collapsed rows. Full From/To/Subject/Contact ID block only
   shows once the item is expanded (see .email-headers below). */
.email-collapsed-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  cursor: pointer;
  background: #d3d5d8;
}
.ecr-icon { font-size: 14px; color: #555; flex-shrink: 0; }
.ecr-from {
  font-size: 12px;
  color: #333;
  flex-shrink: 0;
  white-space: nowrap;
}
.ecr-clip { font-size: 12px; color: #888; flex-shrink: 0; }
.ecr-snippet {
  font-size: 12px;
  color: #777;
  flex: 1;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.ecr-time {
  font-size: 11px;
  color: #999;
  flex-shrink: 0;
  white-space: nowrap;
}
.email-headers {
  /* 2026-08-06b: reference screenshot shows a grey rectangle behind the
     From/To/Subject header block on every non-annotation thread message. */
  background: #e4e6e8;
  margin-top: 4px;
  margin-right: -12px;
  padding: 8px 10px;
  border-radius: 3px;
  font-size: 11px;
  color: #555;
}
.eh-time-block {
  /* 2026-08-06h: right-aligned time block inside the grey headers box */
  float: right;
  text-align: right;
  margin-left: 16px;
  line-height: 1.6;
}
.eh-time-rel { font-size: 11px; color: #555; }
.eh-time-abs { font-size: 10px; color: #888; display: block; }
.email-body {
  padding: 10px 12px 10px 0;
  font-size: 13px;
  color: #111;
  line-height: 1.6;
  white-space: pre-wrap;
  word-break: break-word;
}
.email-chevron {
  font-size: 11px;
  color: #aaa;
  margin-left: 4px;
  transition: transform .2s;
}
.email-item.expanded .email-chevron { transform: rotate(180deg); }
.msg-meta {
  font-size: 13px;
  color: #888;
  padding: 4px 12px;
  background: #fafafa;
  border-top: 1px solid #f0f0f0;
}
.note-banner {
  font-size: 13px;
  font-style: italic;
  color: #666;
  background: #fafafa;
  padding: 6px 12px;
  border-left: 3px solid #f0c060;
}
.note-banner.from-agent { border-left-color: #008296; }
.note-banner.annotation {
  background: #fff;
  border: 1px solid #ddd;
  border-left: 3px solid #7a9a5c;
  color: #333;
  font-style: normal;
  padding: 0;
}
.note-banner.annotation .msg-meta {
  background: #e3ecd6;
  color: #333;
  font-weight: 700;
  padding: 6px 12px;
}
.note-banner.annotation > div:last-child {
  padding: 8px 12px;
  background: #fff;
}
.note-banner .note-toggle { cursor: pointer; user-select: none; }
.note-chevron { display: inline-block; width: 12px; font-size: 10px; }
.note-banner.collapsed .note-banner-body { display: none; }
.note-banner a { color: #0066c0; text-decoration: underline; font-style: normal; }
.note-banner a:hover { text-decoration: none; }

/* h-row / h-label / h-val (annotation / modal header rows) */
.h-row { display: flex; gap: 8px; margin-bottom: 4px; font-size: 12px; }
.h-label { color: #4d4d4d; font-weight: 500; min-width: 100px; }
.h-val { color: #111; }
.h-val.h-contactid { color: #888; font-size: 11px; }

/* ---------- Active states for correspondence controls ---------- */
.expand-opt.active {
  font-weight: 700;
  color: #008296;
  text-decoration: underline;
}
.corr-toggle-btn.active {
  background: #006b7a;
}
.workflow-row[data-kind] {
  cursor: pointer;
}
.workflow-row[data-kind]:hover {
  background: #f0f8f9;
}

/* ---------- Scoring / debrief modal ---------- */
.debrief-score {
  font-size: 15px;
  font-weight: 700;
  color: #111;
  background: #f0f8f9;
  border: 1px solid #cfe8ea;
  border-radius: 6px;
  padding: 10px 14px;
  margin-bottom: 12px;
}
.deb-row { align-items: flex-start; }
.deb-mark { font-weight: 700; margin-right: 6px; }
.deb-row.deb-ok .deb-mark { color: #1a7f37; }
.deb-row.deb-miss .deb-mark { color: #c0392b; }
.deb-label { display: block; }
.deb-note { color: #666; font-size: 12px; margin-top: 2px; }
.reset-bar a { cursor: pointer; }

/* ---------- Coaching Assistant Widget ---------- */
#coachWidget { position: fixed; bottom: 20px; right: 20px; z-index: 500; }
.coach-bubble {
  width: 52px; height: 52px; border-radius: 50%; border: none;
  background: #008296; color: #fff; font-size: 22px; cursor: pointer;
  box-shadow: 0 2px 10px rgba(0,0,0,.25);
  display: flex; align-items: center; justify-content: center;
}
.coach-bubble:hover { background: #00697a; }
.coach-panel {
  width: 320px; height: 420px; background: #fff; border-radius: 10px;
  box-shadow: 0 4px 24px rgba(0,0,0,.3); display: flex; flex-direction: column;
  overflow: hidden; border: 1px solid #ddd;
}
.coach-header {
  background: #008296; color: #fff; padding: 10px 12px; font-size: 13px; font-weight: 700;
  display: flex; align-items: center; justify-content: space-between; flex-shrink: 0;
}
.coach-close { background: none; border: none; color: #fff; font-size: 14px; cursor: pointer; padding: 2px 6px; }
.coach-close:hover { opacity: .7; }
.coach-messages { flex: 1; overflow-y: auto; padding: 10px; background: #f7f9fa; }
.coach-empty { font-size: 12px; color: #888; text-align: center; margin-top: 30px; padding: 0 10px; line-height: 1.5; }
.coach-msg { display: flex; margin-bottom: 8px; }
.coach-msg-user { justify-content: flex-end; }
.coach-msg-assistant { justify-content: flex-start; }
.coach-msg-bubble {
  max-width: 85%; padding: 7px 10px; border-radius: 10px; font-size: 12.5px; line-height: 1.45;
  white-space: pre-wrap; word-break: break-word;
}
.coach-msg-user .coach-msg-bubble { background: #008296; color: #fff; }
.coach-msg-assistant .coach-msg-bubble { background: #e8ecee; color: #222; }
.coach-typing { font-style: italic; color: #777; }
.coach-input-row { display: flex; gap: 6px; padding: 8px; border-top: 1px solid #eee; flex-shrink: 0; }
.coach-input {
  flex: 1; border: 1px solid #ccc; border-radius: 6px; padding: 6px 8px; font-size: 12.5px; outline: none;
}
.coach-input:focus { border-color: #008296; }
.coach-send {
  background: #008296; color: #fff; border: none; border-radius: 6px; padding: 6px 12px;
  font-size: 12.5px; font-weight: 600; cursor: pointer;
}
.coach-send:hover { background: #00697a; }
.coach-send:disabled, .coach-input:disabled { opacity: .5; cursor: not-allowed; }

/* ---------- Workflow guidance panel (Seller Task rail) ---------- */
.wf-guidance-wrap:empty { display: none; }
.wf-guidance-box.wf-guidance-locked {
  background: #f7f7f7;
  border: 1px dashed #ccc;
}
.wf-guidance-locked .wf-guidance-title { color: #888; }
.wf-guidance-locked-msg { color: #666; font-style: italic; }
.wf-guidance-box {
  background: #f2f9fa;
  border: 1px solid #b8dfe4;
  border-radius: 3px;
  padding: 8px 10px;
  margin-bottom: 8px;
  font-size: 11px;
}
.wf-guidance-title {
  font-weight: 700;
  color: #006b7a;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  font-size: 10px;
  margin-bottom: 6px;
}
.wf-guidance-col { margin-bottom: 6px; }
.wf-guidance-col:last-child { margin-bottom: 0; }
.wf-guidance-sub { font-weight: 600; color: #333; margin-bottom: 2px; }
.wf-guidance-col.wf-no .wf-guidance-sub { color: #b3341c; }
.wf-guidance-box ul { margin: 0; padding-left: 16px; }
.wf-guidance-box li { margin-bottom: 2px; line-height: 1.3; }
.wf-guidance-box ol { margin: 0; padding-left: 18px; }
.wf-guidance-box .wf-guidance-col + .wf-guidance-col { margin-top: 4px; }
.wf-guidance-col.wf-sop { border-left: 2px solid #2f6feb; padding-left: 6px; }
.wf-guidance-col.wf-sop .wf-guidance-sub { color: #2f6feb; }
.wf-sop-title { font-weight: 600; color: #333; margin-bottom: 2px; }
.wf-sop-note { color: #555; line-height: 1.35; }
.wf-sop-link { color: #2f6feb; text-decoration: none; }
.wf-sop-link:hover { text-decoration: underline; }

/* ---------- Generic PWF step engine (per-case, LXD-authored) ---------- */
.wf-steps-box .wf-step { margin-bottom: 8px; }
.wf-steps-box .wf-step:last-child { margin-bottom: 0; }
.wf-step-text { line-height: 1.4; }
.wf-step-text p { margin: 0 0 6px; }
.wf-step-text p:last-child { margin-bottom: 0; }
.wf-step-text ul { margin: 2px 0 6px; }
.wf-step-text ul:last-child { margin-bottom: 0; }
.wf-step-label { display: block; font-weight: 600; color: #333; margin-bottom: 3px; }
.wf-step-input-field {
  width: 100%;
  box-sizing: border-box;
  padding: 4px 6px;
  border: 1px solid #ccc;
  border-radius: 3px;
  font-size: 11px;
}
.wf-step-choice { display: flex; flex-direction: column; gap: 2px; }
.wf-step-radio { font-weight: 400; display: flex; align-items: center; gap: 4px; }
.wf-step-link a { color: #006b7a; font-weight: 600; text-decoration: underline; }
.wf-step-infocard {
  border-left: 2px solid #2f6feb;
  padding-left: 6px;
}
.wf-step-kv { line-height: 1.4; }
.wf-step-actions { display: flex; gap: 6px; flex-wrap: wrap; }
.wf-step-continue-wrap { margin-top: 8px; }
.wf-step-continue-btn:disabled { opacity: .45; cursor: not-allowed; }

/* ---------- Workflow Assistant (branching Yes/No -> suggested reply) ---------- */
.wf-form-box {
  background: #fff8ec;
  border: 1px solid #e8c988;
  border-radius: 3px;
  padding: 8px 10px;
  margin-bottom: 8px;
  font-size: 11px;
}
.wf-form-title {
  font-weight: 700;
  color: #8a5a00;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  font-size: 10px;
  margin-bottom: 6px;
}
.wf-form-q { margin-bottom: 8px; }
.wf-form-q-text { font-weight: 600; color: #333; margin-bottom: 4px; line-height: 1.35; }
.wf-form-btns { display: flex; gap: 6px; flex-wrap: wrap; }
.wf-form-btns-col { flex-direction: column; align-items: flex-start; }
.wf-answer-btn.active { background: #8a5a00; color: #fff; border-color: #8a5a00; }
.wf-form-error {
  margin-top: 6px;
  padding: 6px 8px;
  background: #fdecea;
  border: 1px solid #e6a19a;
  border-radius: 3px;
  color: #a83226;
  font-weight: 600;
}
.wf-form-result { margin-top: 6px; padding-top: 6px; border-top: 1px dashed #e8c988; }
.wf-form-status { margin-bottom: 6px; line-height: 1.35; }
.wf-form-blurb-label { font-weight: 600; color: #333; margin-bottom: 3px; }
.wf-form-blurb-pre {
  white-space: pre-wrap;
  background: #fff;
  border: 1px solid #eee;
  border-radius: 3px;
  padding: 6px 8px;
  margin: 0 0 6px 0;
  font-family: inherit;
  font-size: 11px;
  max-height: 220px;
  overflow-y: auto;
}

/* ---------- Email attachments ---------- */
.email-attachments { margin-top: 8px; display: flex; flex-direction: column; gap: 8px; }
.email-attachment-img img {
  max-width: 260px;
  max-height: 200px;
  border: 1px solid #ddd;
  border-radius: 3px;
  display: block;
}
.email-attachment-label { font-size: 11px; color: #666; margin-top: 3px; }
.email-attachment-file a { font-size: 12px; color: #0066c0; text-decoration: none; }
.email-attachment-file a:hover { text-decoration: underline; }
/* 2026-08-09: Session Summary per-item rubric breakdown (was total-only) */
.summary-case-block { margin-bottom: 18px; }
.summary-case-head { font-size: 14px; margin-bottom: 6px; }
.summary-case-items { margin-left: 14px; border-left: 2px solid #e2e6ea; padding-left: 12px; }
.deb-row { display: flex; align-items: baseline; gap: 6px; flex-wrap: wrap; padding: 3px 0; }
.deb-mark { font-weight: 700; }
.deb-ok .deb-mark { color: #1a7f37; }
.deb-miss .deb-mark { color: #c0392b; }
.deb-label { font-size: 13px; }
.deb-note { flex: 1 0 100%; font-size: 12px; color: #5a6470; margin-left: 20px; }
