:root {
  color-scheme: light;
  --ink: #172026;
  --muted: #64717a;
  --soft: #f4f7f6;
  --surface: #fbfaf7;
  --panel: #ffffff;
  --line: #dfe6e3;
  --primary: #1f5f5b;
  --primary-dark: #164643;
  --accent: #a45b43;
  --success: #2d7557;
  --warning: #b98225;
  --shadow: 0 18px 50px rgba(23, 32, 38, 0.08);
  --font-ui: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-terminal: "JetBrains Mono", "SFMono-Regular", "SF Mono", "Cascadia Code", "Roboto Mono", Menlo, Consolas, ui-monospace, monospace;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background:
    linear-gradient(180deg, #f6f3ed 0%, var(--surface) 34%, #ffffff 100%);
  font-family: var(--font-ui);
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  min-height: 42px;
  border: 0;
  border-radius: 8px;
  padding: 0 16px;
  color: #ffffff;
  background: var(--primary);
  cursor: pointer;
  font-weight: 700;
}

button:hover {
  background: var(--primary-dark);
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.5;
}

a {
  color: inherit;
  text-decoration: none;
}

h1,
h2,
p {
  margin: 0;
}

.app-shell {
  width: min(1440px, 100%);
  margin: 0 auto;
  padding: 22px;
}

.auth-screen {
  display: grid;
  min-height: 100vh;
  place-items: center;
  padding: 24px;
}

.auth-panel {
  width: min(440px, 100%);
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: var(--shadow);
  padding: 28px;
}

.auth-mark {
  margin-bottom: 18px;
}

.auth-panel h1 {
  margin-top: 8px;
  font-size: 34px;
  line-height: 1.08;
}

.auth-panel p:not(.eyebrow) {
  margin-top: 12px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.6;
}

.auth-primary {
  width: 100%;
  margin-top: 22px;
}

.auth-status {
  min-height: 20px;
  font-size: 12px !important;
  font-weight: 700;
}

.basics-panel {
  display: block;
}

.basics-field {
  display: grid;
  gap: 7px;
  margin-top: 16px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
}

.basics-field select {
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  background: #ffffff;
  padding: 0 12px;
  outline: none;
}

.basics-field select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(31, 95, 91, 0.12);
}

.app-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 70px;
  border-bottom: 1px solid var(--line);
}

.header-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 10px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 220px;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 8px;
  color: #ffffff;
  background: var(--ink);
  font-weight: 900;
}

.brand strong {
  display: block;
  font-size: 19px;
}

.brand small {
  display: block;
  color: var(--muted);
  font-size: 13px;
  margin-top: 2px;
}

.progress-nav {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
}

.progress-nav a {
  border-radius: 6px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
  padding: 9px 12px;
}

.progress-nav a.active {
  color: #ffffff;
  background: var(--primary);
}

.auth-control {
  display: flex;
  align-items: center;
  gap: 8px;
}

.auth-user {
  display: flex;
  align-items: center;
  max-width: 240px;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
  cursor: pointer;
  padding: 5px 8px 5px 5px;
  transition: background 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease, transform 0.16s ease;
}

.auth-user:hover {
  border-color: #c2d8d1;
  background: #ffffff;
  box-shadow: 0 10px 24px rgba(16, 24, 32, 0.08);
  transform: translateY(-1px);
}

.auth-user:focus-visible {
  outline: 3px solid rgba(31, 95, 91, 0.2);
  outline-offset: 2px;
}

.auth-avatar {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 30px;
  height: 30px;
  border-radius: 8px;
  color: #ffffff;
  background: var(--primary);
  font-size: 12px;
  font-weight: 900;
}

.auth-email {
  min-width: 0;
  overflow: hidden;
  color: var(--ink);
  font-size: 13px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.auth-button {
  min-height: 38px;
  white-space: nowrap;
}

.screen {
  padding: 34px 0 20px;
}

.interview-screen {
  padding-top: 18px;
}

.screen-copy {
  width: min(760px, 100%);
  margin-bottom: 24px;
}

.screen-copy.compact {
  width: min(680px, 100%);
}

.eyebrow {
  color: var(--primary);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.screen-copy h1 {
  margin-top: 8px;
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1.02;
}

.screen-copy p:not(.eyebrow) {
  margin-top: 12px;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.6;
}

.interview-layout,
.review-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 18px;
  align-items: start;
}

.chat-workspace {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 16px;
  height: calc(100vh - 128px);
  min-height: 620px;
}

.chat-card,
.signal-card,
.review-card,
.approval-card,
.usage-panel,
.metric-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.chat-sidebar {
  display: flex;
  flex-direction: column;
  position: sticky;
  top: 22px;
  height: calc(100vh - 128px);
  min-height: 620px;
  border: 1px solid #d7e1de;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.76);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.sidebar-heading {
  padding: 18px;
  border-bottom: 1px solid var(--line);
}

.sidebar-heading h1 {
  margin-top: 4px;
  font-size: 26px;
  line-height: 1;
}

.side-tabs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
  padding: 10px;
  border-bottom: 1px solid var(--line);
  background: #f7faf9;
}

.side-tabs button {
  min-height: 34px;
  border: 1px solid transparent;
  border-radius: 8px;
  color: var(--muted);
  background: transparent;
  font-size: 12px;
  font-weight: 900;
  padding: 0 8px;
}

.side-tabs button.active {
  border-color: #c7dbd5;
  color: var(--primary);
  background: #ffffff;
}

.side-panel {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 18px;
}

.side-panel h2 {
  margin-top: 4px;
  font-size: 20px;
}

.history-list {
  display: grid;
  gap: 10px;
  margin: 18px 0;
}

.history-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 34px;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  background: var(--soft);
  padding: 12px;
  cursor: pointer;
  text-align: left;
  transition: background 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease, transform 0.16s ease;
}

.history-item.active {
  border-color: #c7dbd5;
  background: #eff8f4;
}

.history-item:hover {
  border-color: #b8d6ce;
  color: var(--ink);
  background: #ffffff;
  box-shadow: 0 10px 24px rgba(16, 24, 32, 0.08);
  transform: translateY(-1px);
}

.history-item:focus-visible {
  outline: 3px solid rgba(31, 95, 91, 0.2);
  outline-offset: 2px;
}

.history-item-copy {
  min-width: 0;
}

.history-title-row {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.history-item-copy strong,
.history-item-copy span,
.history-item-copy small {
  display: block;
}

.history-item-copy strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 14px;
  line-height: 1.25;
}

.history-agent-name {
  cursor: text;
}

.history-name-input {
  width: 100%;
  min-width: 0;
  border: 1px solid #b8d6ce;
  border-radius: 6px;
  color: var(--ink);
  background: #ffffff;
  font: inherit;
  font-size: 14px;
  font-weight: 900;
  line-height: 1.25;
  padding: 3px 6px;
  outline: none;
}

.history-name-input:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(31, 95, 91, 0.12);
}

.history-item-copy span {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
}

.history-item-copy small {
  margin-top: 4px;
  color: #839099;
  font-size: 11px;
  font-weight: 600;
}

.history-delete {
  display: grid;
  place-items: center;
  width: 34px;
  min-height: 34px;
  border: 1px solid #efc8c0;
  border-radius: 8px;
  color: #9b3f31;
  background: #fff2ef;
  cursor: pointer;
  padding: 0;
  transition: background 0.16s ease, border-color 0.16s ease, color 0.16s ease, transform 0.16s ease;
}

.history-delete:hover {
  border-color: #d99588;
  color: #7f3125;
  background: #ffe4de;
  transform: scale(1.04);
}

.history-delete svg {
  width: 17px;
  height: 17px;
  fill: currentColor;
}

.history-delete:hover {
  color: #ffffff;
  background: var(--accent);
}

.history-empty {
  border: 1px dashed var(--line);
  border-radius: 8px;
  color: var(--muted);
  padding: 12px;
  font-size: 12px;
}

.confirm-overlay {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  padding: 22px;
  background: rgba(23, 32, 38, 0.46);
  backdrop-filter: blur(8px);
}

.confirm-dialog {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  gap: 16px;
  width: min(440px, 100%);
  border: 1px solid #ecd0c9;
  border-radius: 8px;
  background: #fffaf8;
  box-shadow: 0 24px 80px rgba(23, 32, 38, 0.28);
  padding: 18px;
}

.confirm-icon {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border: 1px solid #efc8c0;
  border-radius: 8px;
  color: #9b3f31;
  background: #fff2ef;
}

.confirm-icon svg {
  width: 24px;
  height: 24px;
  fill: currentColor;
}

.confirm-copy h2 {
  margin-top: 4px;
  font-size: 21px;
}

.confirm-copy p:not(.eyebrow) {
  margin-top: 8px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
}

.confirm-session {
  display: inline-flex;
  width: fit-content;
  border: 1px solid #efd8d2;
  border-radius: 8px;
  color: #8c4436 !important;
  background: #fff2ef;
  padding: 6px 9px;
  font-family: var(--font-terminal);
  font-size: 11px !important;
  font-weight: 800;
}

.confirm-actions {
  grid-column: 1 / -1;
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding-top: 2px;
}

.evidence-dialog {
  display: grid;
  gap: 16px;
  width: min(680px, 100%);
  max-height: min(720px, calc(100vh - 44px));
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 24px 80px rgba(23, 32, 38, 0.28);
}

.evidence-dialog-header {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  border-bottom: 1px solid var(--line);
  padding: 18px 18px 16px;
}

.evidence-dialog-header h2 {
  margin-top: 4px;
  font-size: 22px;
}

.evidence-dialog-header p:not(.eyebrow) {
  margin-top: 8px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
}

.evidence-close {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  /* width: 20px; */
  height: 34px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
  background: var(--soft);
  cursor: pointer;
}

.evidence-close span {
  position: relative;
  display: block;
  width: 14px;
  height: 14px;
}

.evidence-close span::before,
.evidence-close span::after {
  position: absolute;
  top: 6px;
  left: 0;
  width: 14px;
  height: 2px;
  border-radius: 999px;
  background: currentColor;
  content: "";
}

.evidence-close span::before {
  transform: rotate(45deg);
}

.evidence-close span::after {
  transform: rotate(-45deg);
}

.evidence-close:hover {
  color: var(--ink);
  background: #ffffff;
}

.evidence-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 0 18px;
}

.evidence-summary span {
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--soft);
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  padding: 7px 9px;
}

.evidence-list {
  display: grid;
  gap: 10px;
  overflow: auto;
  padding: 0 18px 18px;
}

.evidence-item {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
  padding: 14px;
}

.evidence-item-body {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  column-gap: 10px;
  row-gap: 8px;
  align-items: center;
}

.evidence-item-index {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  margin-top: 1px;
  border-radius: 999px;
  border: 1px solid #bfd8d1;
  color: #1f6656;
  background: #e9f7f1;
  font-size: 11px;
  font-weight: 900;
}

.evidence-item blockquote {
  grid-column: 2;
  margin: 0;
  color: var(--ink);
  font-size: 15px;
  font-weight: 800;
  line-height: 1.45;
}

.evidence-item p {
  grid-column: 2;
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.evidence-chat-link {
  color: #1f6656;
  text-decoration: none;
}

.evidence-chat-link:hover,
.evidence-chat-link:focus-visible {
  color: var(--teal);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.evidence-empty {
  border: 1px dashed var(--line);
  border-radius: 8px;
  color: var(--muted);
  background: var(--soft);
  padding: 16px;
  font-size: 13px;
}

.active-memory {
  margin-top: 18px;
  border-top: 1px solid var(--line);
  padding-top: 16px;
}

.memory-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.memory-heading span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
}

.memory-list {
  display: grid;
  gap: 8px;
  margin-top: 10px;
}

.memory-item,
.memory-empty {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  padding: 10px;
}

.memory-item strong,
.memory-item span {
  display: block;
}

.memory-item strong {
  color: var(--primary);
  font-size: 12px;
}

.memory-item span,
.memory-empty {
  color: var(--muted);
  font-size: 11px;
}

.memory-item span {
  margin-top: 4px;
}

.tone-suggestion {
  margin-top: 10px;
  border: 1px solid rgba(31, 95, 91, 0.18);
  border-radius: 8px;
  color: var(--primary);
  background: #f4fbf9;
  font-size: 11px;
  font-weight: 800;
  padding: 10px;
}

.side-link {
  display: block;
  margin-top: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--primary);
  background: #ffffff;
  font-size: 13px;
  font-weight: 900;
  padding: 11px 12px;
  text-align: center;
}

.context-intro {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
  margin-bottom: 14px;
  border: 1px solid #cfe1dc;
  border-radius: 8px;
  background: #f4fbf9;
  padding: 13px;
}

.context-visual {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 8px;
  color: #ffffff;
  background: var(--primary);
  font-weight: 900;
}

.context-intro h2 {
  margin-top: 3px;
  font-size: 18px;
}

.context-intro p:not(.eyebrow) {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.context-card {
  display: grid;
  gap: 12px;
  margin-top: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  padding: 13px;
}

.context-action-grid {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.context-action-button {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  background: #ffffff;
  padding: 12px;
  text-align: left;
  cursor: pointer;
}

.context-action-button:hover,
.context-action-button:focus-visible {
  border-color: #b8d8cf;
  background: #f4fbf9;
}

.context-action-button strong,
.context-action-button small {
  display: block;
  grid-column: 2;
}

.context-action-button strong {
  font-size: 13px;
}

.context-action-button small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  line-height: 1.35;
}

.context-card-muted {
  background: var(--soft);
}

.context-card-heading {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
}

.context-card-icon {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid #cfe1dc;
  border-radius: 8px;
  color: var(--primary);
  background: #eef8f3;
  font-size: 11px;
  font-weight: 900;
}

.context-card-heading h3 {
  font-size: 15px;
}

.context-card-heading p {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.context-form-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

.context-field {
  display: grid;
  gap: 7px;
  margin-top: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.context-field input,
.context-field select,
.context-field textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  background: #ffffff;
  font-size: 12px;
  outline: none;
  padding: 10px;
}

.context-field textarea {
  resize: vertical;
  line-height: 1.45;
}

.context-field textarea[readonly] {
  color: #47545b;
  background: #f8faf9;
}

.context-field input[type="file"] {
  cursor: pointer;
}

.quiet-note[data-state="working"] {
  color: var(--primary);
}

.quiet-note[data-state="success"] {
  color: #16803c;
  font-weight: 800;
}

.quiet-note[data-state="error"] {
  color: #b42318;
  font-weight: 800;
}

.whatsapp-import-log {
  display: grid;
  gap: 8px;
  margin-top: 0;
}

.whatsapp-import-item {
  border: 1px solid rgba(39, 119, 111, 0.22);
  border-radius: 8px;
  background: #f4fbf9;
  padding: 10px;
}

.whatsapp-import-item strong,
.whatsapp-import-item span {
  display: block;
}

.whatsapp-import-item strong {
  color: var(--ink);
  font-size: 13px;
}

.whatsapp-import-item span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
}

.context-source-list {
  display: grid;
  gap: 8px;
  margin-top: 0;
}

.context-source-item {
  border: 1px solid #d7e5e1;
  border-radius: 8px;
  background: #ffffff;
  padding: 11px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: start;
}

.context-source-copy strong,
.context-source-copy span {
  display: block;
}

.context-source-copy strong {
  font-size: 13px;
}

.context-source-copy span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
}

.context-source-delete {
  display: grid;
  place-items: center;
  width: 30px;
  min-height: 30px;
  border: 1px solid #efc8c0;
  border-radius: 8px;
  color: #9b3f31;
  background: #fff2ef;
  cursor: pointer;
  font-size: 22px;
  line-height: 1;
  padding: 0 0 2px;
}

.context-source-delete:hover,
.context-source-delete:focus-visible {
  border-color: #d99588;
  color: #7f3125;
  background: #ffe4de;
}

.context-source-empty {
  border: 1px dashed #cfded9;
  border-radius: 8px;
  color: var(--muted);
  background: #ffffff;
  font-size: 12px;
  font-weight: 800;
  padding: 12px;
}

.context-modal {
  display: grid;
  width: min(620px, 100%);
  max-height: min(760px, calc(100vh - 44px));
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 24px 80px rgba(23, 32, 38, 0.28);
}

.context-modal-body {
  display: grid;
  gap: 12px;
  overflow: auto;
  padding: 18px;
}

.context-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding-top: 4px;
}

.context-modal-actions button {
  min-width: 132px;
}

.chat-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 0;
  overflow: hidden;
}

.agentic-chat {
  border-color: #25333a;
  color: #e9f2f0;
  background:
    linear-gradient(180deg, rgba(22, 33, 39, 0.98), rgba(12, 18, 22, 0.98)),
    #10181d;
  font-family: var(--font-terminal);
  font-variant-ligatures: none;
  box-shadow: 0 26px 70px rgba(8, 13, 16, 0.32);
}

.card-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 20px;
  border-bottom: 1px solid var(--line);
}

.agentic-chat .card-heading {
  padding: 16px 18px;
  border-bottom-color: #24333a;
  background: rgba(255, 255, 255, 0.02);
}

.chat-controls {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.model-picker {
  display: grid;
  gap: 4px;
  min-width: 150px;
}

.model-picker span {
  color: #6e8586;
  font-family: var(--font-terminal);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.model-picker select,
.model-picker input {
  width: 100%;
  min-height: 34px;
  border: 1px solid #2d4548;
  border-radius: 8px;
  color: #d8ebe8;
  background: #132127;
  font-family: var(--font-terminal);
  font-size: 11px;
  outline: none;
  padding: 0 32px 0 10px;
}

.model-picker input {
  padding-right: 10px;
}

.agent-name-picker {
  min-width: 120px;
}

.model-picker select:focus,
.model-picker input:focus {
  border-color: #64d8cb;
  box-shadow: 0 0 0 3px rgba(100, 216, 203, 0.12);
}

.context-multiselect {
  position: relative;
  min-width: 230px;
}

.context-picker-button {
  width: 100%;
  min-height: 34px;
  border: 1px solid #2d4548;
  border-radius: 8px;
  color: #d8ebe8;
  background: #132127;
  font-family: var(--font-terminal);
  font-size: 11px;
  text-align: left;
  padding: 0 10px;
}

.context-picker-menu {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  z-index: 20;
  display: grid;
  gap: 6px;
  width: min(340px, 88vw);
  max-height: 300px;
  overflow-y: auto;
  border: 1px solid #2d4548;
  border-radius: 8px;
  background: #0f1b20;
  box-shadow: 0 18px 60px rgba(2, 8, 12, 0.4);
  padding: 8px;
}

.context-picker-option {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 8px;
  align-items: start;
  border-radius: 8px;
  padding: 8px;
  color: #d8ebe8;
}

.context-picker-option:hover {
  background: rgba(100, 216, 203, 0.08);
}

.context-picker-option input {
  margin-top: 2px;
}

.context-picker-option strong,
.context-picker-option small {
  display: block;
}

.context-picker-option strong {
  overflow-wrap: anywhere;
  font-size: 12px;
}

.context-picker-option small,
.context-picker-empty {
  color: #8aa5a7;
  font-size: 11px;
}

.context-picker-empty {
  padding: 10px;
}

.chat-title-lockup {
  display: grid;
  grid-template-columns: 12px auto;
  column-gap: 10px;
  align-items: center;
}

.terminal-mark {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: #64d8cb;
  box-shadow: 0 0 18px rgba(100, 216, 203, 0.72);
}

.card-heading h2,
.signal-card h2,
.approval-card h2 {
  margin-top: 4px;
  font-size: 20px;
}

.agentic-chat .card-heading h2 {
  margin: 0;
  color: #f7fbfa;
  font-size: 17px;
  font-weight: 760;
  letter-spacing: 0;
}

.agent-status {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.agentic-chat .agent-status {
  grid-column: 2;
  margin: 3px 0 0;
  color: #7f9897;
  font-size: 10.5px;
  letter-spacing: 0;
}

.secondary-button {
  color: var(--primary);
  background: #e8f1ef;
}

.agentic-chat .secondary-button {
  min-height: 34px;
  border: 1px solid #2d4548;
  color: #b8d8d3;
  background: rgba(100, 216, 203, 0.08);
  font-size: 12px;
  letter-spacing: 0;
}

.secondary-button:hover {
  color: #ffffff;
  background: var(--primary);
}

.agentic-chat .secondary-button:hover {
  color: #071113;
  background: #64d8cb;
}

.danger-button {
  background: var(--accent);
}

.danger-button:hover {
  background: #854632;
}

.chat-log {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 12px;
  padding: 18px;
  overflow: auto;
}

.agentic-chat .chat-log {
  background:
    linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.018) 1px, transparent 1px);
  background-size: 28px 28px;
}

.message {
  max-width: 78%;
  border-radius: 8px;
  padding: 13px 14px;
  font-size: 15px;
  line-height: 1.5;
}

.agentic-chat .message {
  max-width: min(82%, 680px);
  padding: 12px 14px;
  font-size: 13px;
  line-height: 1.62;
  letter-spacing: 0;
}

.message.agent {
  align-self: flex-start;
  border: 1px solid #d8e6e1;
  background: #f0f7f4;
}

.agentic-chat .message.agent {
  position: relative;
  border-color: #27424a;
  color: #dfecea;
  background: rgba(17, 29, 34, 0.9);
}

.agentic-chat .message.agent::before {
  position: absolute;
  top: 10px;
  bottom: 10px;
  left: -1px;
  width: 2px;
  border-radius: 999px;
  background: #64d8cb;
  content: "";
}

.message.user {
  align-self: flex-end;
  border: 1px solid #d5e3e8;
  background: #eef6f8;
}

.agentic-chat .message.user {
  border-color: #2b5960;
  color: #ecfbf8;
  background: rgba(31, 95, 91, 0.48);
}

.agentic-chat .message.user.low-information {
  border-color: #56646a;
  color: #9babaf;
  background: rgba(70, 83, 89, 0.42);
}

.agentic-chat .message.user.low-information::after {
  display: block;
  margin-top: 6px;
  color: #7f9094;
  font-size: 10px;
  content: "ignored";
}

.agentic-chat .message.evidence-highlight {
  outline: 2px solid #74e0d3;
  outline-offset: 3px;
  box-shadow: 0 0 0 6px rgba(100, 216, 203, 0.12);
}

.message-feedback {
  display: flex;
  position: absolute;
  right: 8px;
  bottom: -15px;
  z-index: 3;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  pointer-events: none;
}

.message-feedback-actions {
  display: flex;
  gap: 3px;
  opacity: 0;
  transform: translateY(-3px);
  transition:
    opacity 140ms ease,
    transform 140ms ease;
  pointer-events: auto;
}

.message.agent:hover .message-feedback-actions,
.message.agent:focus-within .message-feedback-actions,
.message-feedback:has(.message-feedback-popover) .message-feedback-actions {
  opacity: 1;
  transform: translateY(0);
}

.chat-log.feedback-open .message.agent:hover .message-feedback:not(.active) .message-feedback-actions,
.chat-log.feedback-open .message.agent:focus-within .message-feedback:not(.active) .message-feedback-actions {
  opacity: 0;
  pointer-events: none;
  transform: translateY(-3px);
}

.chat-log.feedback-open .message-feedback:not(.active) {
  display: none;
}

.message-feedback-reaction {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  min-height: 34px;
  border: 1px solid rgba(116, 224, 211, 0.24);
  border-radius: 999px;
  color: #d7efeb;
  background: rgba(12, 22, 27, 0.96);
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.24);
  cursor: pointer;
  line-height: 1;
  padding: 0;
}

.message-feedback-icon {
  width: 26px;
  height: 26px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.1;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.message-feedback-reaction[aria-label="Good"] {
  color: #9ff0c2;
  border-color: rgba(159, 240, 194, 0.28);
}

.message-feedback-reaction[aria-label="A little off"] {
  color: #d9d0a2;
  border-color: rgba(217, 208, 162, 0.28);
}

.message-feedback-reaction[aria-label="Bad"] {
  color: #f3b38f;
  border-color: rgba(243, 179, 143, 0.3);
}

.message-feedback-reaction[aria-label="Harmful"] {
  color: #f08f8f;
  border-color: rgba(240, 143, 143, 0.34);
}

.message-feedback-reaction:hover,
.message-feedback-reaction:focus-visible {
  border-color: rgba(116, 224, 211, 0.44);
  background: rgba(255, 255, 255, 0.075);
  outline: none;
  transform: translateY(-1px);
}

.message-feedback-reaction.selected {
  border-width: 1.5px;
  outline: none;
  transform: translateY(-1px);
}

.message-feedback-reaction.selected[aria-label="Good"] {
  border-color: rgba(159, 240, 194, 0.72);
  background:
    radial-gradient(circle at 50% 50%, rgba(159, 240, 194, 0.22), rgba(159, 240, 194, 0.08)),
    rgba(12, 22, 27, 0.98);
  box-shadow:
    0 0 0 2px rgba(159, 240, 194, 0.08),
    0 10px 26px rgba(0, 0, 0, 0.28);
}

.message-feedback-reaction.selected[aria-label="A little off"] {
  border-color: rgba(217, 208, 162, 0.72);
  background:
    radial-gradient(circle at 50% 50%, rgba(217, 208, 162, 0.22), rgba(217, 208, 162, 0.08)),
    rgba(12, 22, 27, 0.98);
  box-shadow:
    0 0 0 2px rgba(217, 208, 162, 0.08),
    0 10px 26px rgba(0, 0, 0, 0.28);
}

.message-feedback-reaction.selected[aria-label="Bad"] {
  border-color: rgba(243, 179, 143, 0.74);
  background:
    radial-gradient(circle at 50% 50%, rgba(243, 179, 143, 0.24), rgba(243, 179, 143, 0.08)),
    rgba(12, 22, 27, 0.98);
  box-shadow:
    0 0 0 2px rgba(243, 179, 143, 0.09),
    0 10px 26px rgba(0, 0, 0, 0.28);
}

.message-feedback-reaction.selected[aria-label="Harmful"] {
  border-color: rgba(240, 143, 143, 0.78);
  background:
    radial-gradient(circle at 50% 50%, rgba(240, 143, 143, 0.26), rgba(240, 143, 143, 0.09)),
    rgba(12, 22, 27, 0.98);
  box-shadow:
    0 0 0 2px rgba(240, 143, 143, 0.1),
    0 10px 26px rgba(0, 0, 0, 0.28);
}

.message-feedback-popover {
  display: grid;
  position: absolute;
  z-index: 4;
  top: 30px;
  left: 50%;
  width: min(310px, calc(100vw - 48px));
  gap: 8px;
  border: 1px solid #31525a;
  border-radius: 8px;
  background: #122128;
  box-shadow: 0 18px 52px rgba(0, 0, 0, 0.28);
  padding: 10px;
  pointer-events: auto;
  transform: translateX(-50%);
}

.message-feedback-popover-readonly {
  display: none;
  min-width: 150px;
  max-width: 240px;
  gap: 4px;
  pointer-events: none;
}

.message.agent:hover .message-feedback-popover-readonly,
.message.agent:focus-within .message-feedback-popover-readonly {
  display: grid;
}

.message-feedback-title {
  color: #dfecea;
  font-size: 11px;
  font-weight: 900;
}

.message-feedback-saved-comment {
  color: #9fbab5;
  font-size: 11px;
  line-height: 1.35;
}

.message-feedback-reasons {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.message-feedback-reason {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  border: 1px solid rgba(116, 224, 211, 0.16);
  border-radius: 999px;
  color: #bdd5d1;
  background: rgba(255, 255, 255, 0.03);
  cursor: pointer;
  font-size: 10px;
  font-weight: 800;
  padding: 5px 7px;
}

.message-feedback-reason input {
  accent-color: #64d8cb;
}

.message-feedback-comment {
  width: 100%;
  border: 1px solid #31525a;
  border-radius: 8px;
  color: #e9f2f0;
  background: rgba(255, 255, 255, 0.04);
  font: inherit;
  font-size: 12px;
  padding: 8px 9px;
}

.message-feedback-submit {
  justify-self: end;
  min-height: 28px;
  border-radius: 8px;
  font-size: 11px;
  padding: 5px 10px;
}

.message-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

.message-chips span {
  border: 1px solid #2d5558;
  border-radius: 999px;
  color: #9ee4dc;
  background: rgba(100, 216, 203, 0.08);
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0;
  padding: 4px 7px;
}

.chat-readiness-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  padding: 12px 16px 0;
  background: #10181d;
}

.chat-readiness-strip span {
  min-width: 0;
  border-top: 2px solid #2a383e;
  color: #647d7e;
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0;
  padding-top: 7px;
  text-align: center;
}

.chat-readiness-strip span.complete {
  border-top-color: #64d8cb;
  color: #b7efea;
}

.composer {
  display: grid;
  grid-template-columns: 1fr 92px;
  gap: 10px;
  padding: 16px;
  border-top: 1px solid var(--line);
  background: #ffffff;
}

.agentic-chat .composer {
  grid-template-columns: 1fr 76px;
  border-top-color: #24333a;
  background: #10181d;
}

.composer input,
.draft-form input,
.draft-form textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  background: #ffffff;
  outline: none;
}

.agentic-chat .composer input {
  border-color: #2b3e45;
  color: #f4fbfa;
  background: rgba(255, 255, 255, 0.035);
  font-size: 13px;
  letter-spacing: 0;
}

.agentic-chat .composer input::placeholder {
  color: #6e8486;
}

.agentic-chat .composer button {
  border: 1px solid #54bfb5;
  color: #081315;
  background: #64d8cb;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0;
}

.agentic-chat .composer button:hover {
  background: #87eee5;
}

.composer input {
  min-width: 0;
  min-height: 46px;
  padding: 0 14px;
}

.composer input:focus,
.draft-form input:focus,
.draft-form textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(31, 95, 91, 0.12);
}

.agentic-chat .composer input:focus {
  border-color: #64d8cb;
  box-shadow: 0 0 0 3px rgba(100, 216, 203, 0.12);
}

.signal-card,
.approval-card {
  padding: 20px;
}

.readiness {
  margin-top: 18px;
}

.readiness > span {
  display: block;
  margin-bottom: 8px;
  font-size: 28px;
  font-weight: 900;
}

.meter {
  height: 10px;
  border-radius: 999px;
  background: #e9eeee;
  overflow: hidden;
}

.meter i {
  display: block;
  width: 20%;
  height: 100%;
  background: var(--success);
}

.signal-list {
  display: grid;
  gap: 10px;
  margin: 20px 0;
  padding: 0;
  list-style: none;
}

.signal-list li {
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
  background: var(--soft);
  padding: 12px;
}

.signal-list li.complete {
  color: var(--ink);
  border-color: #cfe1d8;
  background: #eff8f4;
}

.primary-wide {
  width: 100%;
}

.quiet-note,
.approval-card p {
  margin-top: 12px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
}

.usage-summary {
  margin-top: 14px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
  background: #f8faf9;
  font-size: 12px;
  line-height: 1.6;
}

.sidebar-usage-total {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 4px;
}

.sidebar-usage-total strong {
  color: var(--ink);
  font-family: var(--font-terminal);
  font-size: 18px;
}

.sidebar-usage-list {
  display: grid;
  gap: 8px;
  margin-top: 10px;
}

.sidebar-usage-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  border: 1px solid var(--line);
  border-left: 3px solid var(--primary);
  border-radius: 8px;
  background: #ffffff;
  padding: 10px;
}

.sidebar-usage-item.failed {
  border-left-color: #d66b5d;
}

.sidebar-usage-item strong,
.sidebar-usage-item span {
  display: block;
}

.sidebar-usage-item strong {
  color: var(--ink);
  font-size: 12px;
}

.sidebar-usage-item span,
.sidebar-usage-empty {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.4;
}

.sidebar-usage-tokens {
  min-width: 88px;
  text-align: right;
}

.sidebar-usage-tokens strong {
  font-family: var(--font-terminal);
  font-size: 14px;
}

.review-card {
  overflow: hidden;
}

.draft-status {
  margin: 18px;
  border-radius: 8px;
  background: var(--soft);
  color: var(--muted);
  padding: 13px 14px;
}

.draft-status.approved {
  color: var(--success);
  background: #eef8f3;
}

.draft-status.deleted {
  color: var(--accent);
  background: #fff1ed;
}

.warning-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 18px 18px;
}

.warning-list span {
  border: 1px solid #ead8b7;
  border-radius: 999px;
  color: var(--warning);
  background: #fff8ea;
  font-size: 12px;
  font-weight: 800;
  padding: 7px 10px;
}

.draft-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  padding: 0 18px 18px;
}

.draft-form label {
  display: flex;
  flex-direction: column;
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.draft-form input,
.draft-form textarea {
  padding: 11px 12px;
  font-weight: 500;
}

.draft-form input {
  min-height: 44px;
}

.wide-field {
  grid-column: 1 / -1;
}

.action-stack {
  display: grid;
  gap: 10px;
  margin-top: 20px;
}

.matches-toolbar {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 14px;
}

.match-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.loading-row {
  grid-column: 1 / -1;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
  background: #ffffff;
  padding: 20px;
}

.match-item {
  display: flex;
  flex-direction: column;
  min-height: 340px;
  border: 1px solid var(--line);
  border-top: 4px solid var(--success);
  border-radius: 8px;
  background: #ffffff;
  box-shadow: var(--shadow);
  padding: 18px;
}

.match-item.rejected {
  border-top-color: var(--accent);
}

.match-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.match-top h2 {
  font-size: 22px;
}

.match-top p,
.match-copy {
  color: var(--muted);
}

.match-top strong {
  border-radius: 999px;
  color: var(--success);
  background: #eef8f3;
  padding: 8px 10px;
}

.rejected .match-top strong {
  color: var(--accent);
  background: #fff1ed;
}

.match-copy {
  margin-top: 14px;
  font-size: 14px;
  line-height: 1.55;
}

.breakdown {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  margin-top: 14px;
}

.breakdown span {
  border-radius: 8px;
  color: var(--muted);
  background: var(--soft);
  font-size: 12px;
  padding: 8px;
}

.match-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: auto;
  padding-top: 18px;
}

.usage-hero {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 22px;
}

.usage-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 16px;
  margin-bottom: 18px;
}

.metric-card {
  min-height: 132px;
  padding: 20px;
}

.metric-card span,
.metric-card small {
  display: block;
  color: var(--muted);
}

.metric-card span {
  font-size: 13px;
  font-weight: 800;
}

.metric-card strong {
  display: block;
  margin: 14px 0 8px;
  font-size: 34px;
  line-height: 1;
}

.metric-card small {
  font-size: 12px;
  line-height: 1.45;
}

.usage-panels {
  display: grid;
  grid-template-columns: 390px minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.usage-panel {
  overflow: hidden;
}

.usage-panel-wide {
  grid-column: 1 / -1;
}

.profile-layout {
  display: grid;
  grid-template-columns: minmax(320px, 420px) minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.profile-panel {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.profile-panel-wide {
  grid-column: 1 / -1;
}

.profile-form {
  display: grid;
  gap: 14px;
  padding: 18px;
}

.profile-form label {
  display: grid;
  gap: 7px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
}

.profile-form input,
.profile-form select {
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  background: #ffffff;
  padding: 0 12px;
  outline: none;
}

.profile-form input:read-only {
  color: var(--muted);
  background: var(--soft);
}

.profile-source-list {
  display: grid;
  gap: 10px;
  padding: 18px;
}

.profile-source-item {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
  padding: 13px;
}

.profile-source-item strong,
.profile-source-item span {
  display: block;
}

.profile-source-item strong {
  font-size: 14px;
}

.profile-source-item span,
.profile-source-item p {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.profile-source-item p {
  margin-top: 8px;
}

.panel-heading {
  padding: 18px;
  border-bottom: 1px solid var(--line);
}

.panel-heading h2 {
  margin-top: 4px;
  font-size: 19px;
}

.profile-facts-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.profile-fact-total {
  flex: 0 0 auto;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--soft);
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  padding: 7px 10px;
}

.profile-fact-groups {
  display: grid;
  gap: 16px;
  padding: 18px;
}

.profile-fact-group {
  display: grid;
  gap: 10px;
}

.profile-fact-group-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.profile-fact-group-heading h3 {
  font-size: 15px;
}

.profile-fact-group-heading span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.profile-fact-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 10px;
}

.profile-fact-card,
.profile-facts-empty {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
}

.profile-fact-card {
  display: grid;
  gap: 12px;
  min-height: 112px;
  padding: 14px;
}

.profile-fact-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.profile-fact-card-top strong {
  color: var(--ink);
  font-size: 14px;
  line-height: 1.35;
}

.confidence-pill {
  flex: 0 0 auto;
  border-radius: 999px;
  border: 1px solid transparent;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0;
  padding: 6px 9px;
}

.confidence-pill.high {
  border-color: #bfe2d5;
  background: #e9f7f1;
  color: #176049;
}

.confidence-pill.medium {
  border-color: #ecd896;
  background: #fff7dc;
  color: #715410;
}

.confidence-pill.low {
  border-color: var(--line);
  background: #f5f7f7;
  color: var(--muted);
}

.profile-fact-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.fact-tag {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  border: 1px solid #d8e3e0;
  border-radius: 999px;
  background: #fbfdfc;
  color: #5d6a71;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.1;
  padding: 6px 10px;
}

.fact-tag-key {
  color: #495b62;
  background: #ffffff;
}

.fact-tag-status {
  border-color: #bdded4;
  color: #1f6656;
  background: #edf8f4;
}

.fact-evidence-trigger {
  font-family: inherit;
  cursor: pointer;
}

.fact-evidence-trigger:hover,
.fact-evidence-trigger:focus-visible {
  border-color: #b9d6ce;
  color: var(--teal);
  background: #eef8f3;
}

.fact-evidence-trigger:disabled {
  cursor: default;
  opacity: 0.65;
}

.profile-facts-empty {
  display: grid;
  gap: 5px;
  padding: 18px;
}

.profile-facts-empty strong {
  font-size: 15px;
}

.profile-facts-empty span {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.raw-data-panel {
  border-style: dashed;
}

.raw-data-list {
  display: grid;
  gap: 8px;
  padding: 18px;
}

.raw-data-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfdfc;
  padding: 12px;
}

.raw-data-item-main {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.raw-data-item-main span {
  color: var(--teal);
  font-size: 10px;
  font-weight: 900;
  text-transform: uppercase;
}

.raw-data-item-main strong {
  color: var(--ink);
  font-size: 13px;
}

.raw-data-item-main code {
  overflow: hidden;
  color: #5c6870;
  font-family: var(--font-terminal);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.raw-data-item-meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}

.raw-data-item-meta span {
  border: 1px solid #d8e3e0;
  border-radius: 999px;
  color: #5d6a71;
  background: #ffffff;
  font-size: 11px;
  font-weight: 800;
  padding: 6px 8px;
}

.provider-list {
  padding: 0;
}

.rate-limit-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
  padding: 18px;
}

.rate-limit-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8faf9;
  padding: 14px;
}

.rate-limit-card.warning {
  border-color: #d9a441;
  background: #fffaf0;
}

.rate-limit-card.danger {
  border-color: #d66b5d;
  background: #fff4f1;
}

.rate-limit-card span,
.rate-limit-card small {
  display: block;
  color: var(--muted);
}

.rate-limit-card span {
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.rate-limit-card strong {
  display: block;
  margin: 8px 0 6px;
  color: var(--ink);
  font-family: var(--font-terminal);
  font-size: 21px;
  line-height: 1.1;
  word-break: break-word;
}

.rate-limit-card small {
  font-size: 11px;
  line-height: 1.35;
}

.provider-row {
  display: grid;
  gap: 8px;
}

.provider-row header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.provider-bar {
  height: 10px;
  border-radius: 999px;
  background: #e9eeee;
  overflow: hidden;
}

.provider-bar i {
  display: block;
  height: 100%;
  background: var(--primary);
}

.provider-table,
.usage-table {
  width: 100%;
  border-collapse: collapse;
}

.provider-table th,
.provider-table td,
.usage-table th,
.usage-table td {
  border-bottom: 1px solid var(--line);
  padding: 13px 14px;
  text-align: left;
  vertical-align: middle;
}

.provider-table th,
.usage-table th {
  color: var(--muted);
  background: #f8faf9;
  font-size: 12px;
  text-transform: uppercase;
}

.provider-table td,
.usage-table td {
  font-size: 13px;
}

.provider-table small,
.usage-table small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}

.usage-table-wrap {
  overflow-x: auto;
}

.usage-table {
  min-width: 840px;
}

.usage-table th:nth-child(1),
.usage-table td:nth-child(1) {
  width: 190px;
}

.usage-table th:nth-child(3),
.usage-table td:nth-child(3),
.usage-table th:nth-child(4),
.usage-table td:nth-child(4),
.usage-table th:nth-child(5),
.usage-table td:nth-child(5) {
  white-space: nowrap;
}

.table-empty {
  padding: 22px;
  color: var(--muted);
}

.mono {
  font-variant-numeric: tabular-nums;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  border-radius: 999px;
  padding: 0 10px;
  font-size: 12px;
  font-weight: 800;
}

.status-pill.success {
  color: var(--success);
  background: #eef8f3;
}

.status-pill.failed {
  color: var(--accent);
  background: #fff1ed;
}

@media (max-width: 980px) {
  .interview-layout,
  .review-layout,
  .match-list,
  .chat-workspace,
  .usage-grid,
  .usage-panels,
  .profile-layout {
    grid-template-columns: 1fr;
  }

  .chat-sidebar,
  .chat-card {
    height: auto;
    min-height: auto;
  }

  .chat-sidebar {
    position: static;
  }

  .side-panel {
    overflow: visible;
  }

  .chat-card {
    height: min(720px, calc(100vh - 120px));
  }

  .signal-card,
  .approval-card {
    position: static;
  }

  .usage-hero {
    display: grid;
  }
}

@media (max-width: 680px) {
  .app-shell {
    padding: 14px;
  }

  .app-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .progress-nav {
    width: 100%;
    justify-content: space-between;
  }

  .progress-nav a {
    flex: 1;
    text-align: center;
    padding: 9px 6px;
  }

  .profile-facts-heading,
  .profile-fact-group-heading,
  .profile-fact-card-top {
    align-items: flex-start;
    flex-direction: column;
  }

  .profile-fact-list {
    grid-template-columns: 1fr;
  }

  .raw-data-item {
    grid-template-columns: 1fr;
  }

  .raw-data-item-meta {
    justify-content: flex-start;
  }

  .screen-copy h1 {
    font-size: 36px;
  }

  .chat-card {
    min-height: 560px;
  }

  .agentic-chat .card-heading,
  .chat-controls {
    align-items: stretch;
    flex-direction: column;
  }

  .model-picker {
    min-width: 0;
  }

  .message {
    max-width: 92%;
  }

  .composer {
    grid-template-columns: 1fr;
  }

  .draft-form {
    grid-template-columns: 1fr;
  }
}
