/* Bid Options: a readable, consistent comparison and editor at every width. */
.bo-root {
  container: bid-options / inline-size;
  --bo-muted: #53657f;
  font-size: 18px;
  line-height: 1.5;
}
.bo-root .bo-toolbar { gap: 16px; margin-bottom: 20px; }
.bo-root .bo-status { font-size: 16px; min-height: 46px; }
.bo-root .bo-actions { gap: 10px; }
.bo-root .bo-grid { gap: 20px; align-items: stretch; }
.bo-root .bo-card {
  container: bid-option / inline-size;
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.bo-root .bo-card > header {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 12px;
  padding: 22px 20px;
  min-height: 154px;
}
.bo-root .bo-kicker { font-size: 20px; font-weight: 600; }
.bo-root .bo-card h2 {
  font-size: 36px;
  line-height: 1.2;
  font-weight: 600;
  letter-spacing: -.6px;
  margin: 8px 0 6px;
  overflow-wrap: anywhere;
}
.bo-root .bo-card header small { font-size: 14px; line-height: 1.5; }
.bo-root .bo-badge {
  font-size: 14px;
  font-weight: 500;
  line-height: 1.5;
  padding: 6px 10px;
}
.bo-root .bo-totals {
  font-size: 16px;
  line-height: 1.5;
  gap: 8px;
  padding: 18px 20px;
  min-height: 156px;
  align-content: start;
}
.bo-root .bo-totals div { gap: 16px; align-items: baseline; }
.bo-root .bo-totals dt { min-width: 0; }
.bo-root .bo-totals dd { flex-shrink: 0; }
.bo-root .bo-list {
  height: clamp(440px, 52dvh, 640px);
  min-height: 0;
  max-height: none;
  flex: 1 0 auto;
  overflow-x: hidden;
  overflow-y: auto;
  scrollbar-gutter: stable;
}
.bo-root .bo-list-heading {
  font-size: 14px;
  font-weight: 500;
  line-height: 1.5;
  padding: 14px 20px;
  gap: 12px;
}
.bo-root .bo-line {
  min-height: 136px;
  padding: 18px 20px;
  gap: 16px;
  align-items: flex-start;
  line-height: 1.5;
}
.bo-root .bo-scope-name { align-items: flex-start; gap: 8px; }
.bo-root .bo-line strong {
  font-size: 18px;
  line-height: 1.4;
  font-weight: 500;
  white-space: normal;
  overflow: visible;
  text-overflow: clip;
  overflow-wrap: anywhere;
}
.bo-root .bo-line-label > small {
  font-size: 16px;
  line-height: 1.45;
  font-weight: 400;
  white-space: normal;
  overflow: visible;
  text-overflow: clip;
  overflow-wrap: anywhere;
  margin-top: 8px;
}
.bo-root .bo-line-price { font-size: 18px; line-height: 1.4; font-weight: 500; }
.bo-root .bo-line-price small { font-size: 14px; line-height: 1.5; margin-top: 8px; }
.bo-root .bo-flag { width: 20px; height: 20px; flex-basis: 20px; font-size: 14px; margin-top: 3px; }
.bo-root .bo-card > footer {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  padding: 16px 20px;
  margin-top: auto;
  border-top: 1px solid var(--bo-border);
}
.bo-root .amt195-btn {
  font-size: 16px;
  font-weight: 500;
  line-height: 1.4;
  min-height: 46px;
  padding: 10px 14px;
  white-space: normal;
}
.bo-root [data-bo-action=reload] { width: 46px; min-width: 46px; padding: 0; font-size: 24px; }
.bo-root .bo-foot, .bo-root .bo-muted { font-size: 16px; line-height: 1.5; }
.bo-root .bo-warning { font-size: 16px; line-height: 1.5; padding: 16px 20px; }
.bo-root .bo-warning summary { cursor: pointer; min-height: 44px; display: flex; align-items: center; }
.bo-root .bo-progress-copy strong { font-size: 18px; }
.bo-root .bo-progress-copy span:not(.bo-spinner) { font-size: 16px; }

/* Editors and evidence use the same scale as the comparison. */
.bo-root .bo-dialog > header { padding: 20px 24px; gap: 16px; background: var(--bo-bg); }
.bo-root .bo-dialog > header h2 {
  font-size: 24px;
  font-weight: 600;
  line-height: 1.3;
  white-space: normal;
  overflow: visible;
  overflow-wrap: anywhere;
}
.bo-root .bo-dialog [aria-label="Close editor"] { width: 46px; min-width: 46px; height: 46px; padding: 0; font-size: 26px; }
.bo-root .bo-dialog label, .bo-root .bo-label { font-size: 16px; line-height: 1.5; }
.bo-root .bo-dialog input:not([type=checkbox]),
.bo-root .bo-dialog textarea,
.bo-root .bo-dialog .amt280-select-trigger,
.bo-root .bo-dialog .amt280-select-option {
  font-size: 16px;
  line-height: 1.5;
  min-height: 46px;
}
.bo-root .bo-choice .amt280-select-trigger > span:first-child { white-space: normal; overflow: visible; text-overflow: clip; overflow-wrap: anywhere; text-align: left; }
.bo-root .bo-choice .amt280-select-option { white-space: normal; overflow-wrap: anywhere; }
.bo-root .bo-check { gap: 12px; min-height: 46px; }
.bo-root .bo-check input { width: 20px; height: 20px; flex: 0 0 20px; }
.bo-root .bo-line-evidence { background: var(--bo-soft); }
.bo-root .bo-line-evidence-title > strong, .bo-root .bo-evidence-head strong { font-size: 20px; line-height: 1.4; font-weight: 600; }
.bo-root .bo-evidence, .bo-root .bo-help, .bo-root .bo-formula { font-size: 16px; line-height: 1.6; }
.bo-root .bo-evidence-head { flex-wrap: wrap; gap: 12px; }
.bo-root .bo-evidence > p,
.bo-root .bo-evidence details,
.bo-root .bo-help { background: var(--bo-bg); color: var(--bo-muted); }
.bo-root .bo-evidence summary, .bo-root .bo-help summary {
  font-size: 16px;
  font-weight: 500;
  line-height: 1.5;
  min-height: 48px;
  padding: 14px 16px;
  color: var(--bo-ink);
  background: var(--bo-bg);
}
.bo-root .bo-evidence details[open] summary, .bo-root .bo-help[open] summary { background: var(--bo-soft); }
.bo-root .bo-evidence details p, .bo-root .bo-help p, .bo-root .bo-help ul { font-size: 16px; line-height: 1.6; }
.bo-root .bo-evidence small, .bo-root .bo-line-evidence-title > small { font-size: 14px; line-height: 1.5; }
.bo-root .bo-dialog > footer { padding: 16px 24px; font-size: 16px; background: var(--bo-bg); gap: 16px; }
.bo-root .bo-dialog > footer strong { font-size: 28px; line-height: 1.3; }
.bo-root .bo-dialog > footer .amt195-btn { font-size: 16px; min-height: 46px; }
.bo-root .bo-dialog-wide .bo-line-workspace { grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); }

@container bid-option (max-width: 420px) {
  .bo-root .bo-card > header { min-height: 194px; }
  .bo-root .bo-line { flex-direction: column; gap: 12px; min-height: 198px; }
  .bo-root .bo-line-label { flex: none; width: 100%; }
  .bo-root .bo-line-price { display: flex; align-items: baseline; gap: 10px; text-align: left; }
  .bo-root .bo-line-price small { margin: 0; }
  .bo-root .bo-list-heading > span:last-child { display: none; }
}
@container bid-options (max-width: 960px) {
  .bo-root .bo-grid { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .bo-root .bo-card > header { min-height: 0; }
  .bo-root .bo-totals { min-height: 0; }
  .bo-root .bo-list { flex: none; height: 480px; }
}
@media (max-width: 980px) {
  .bo-root .bo-dialog-wide .bo-line-workspace { grid-template-columns: minmax(0, 1fr); height: auto; }
}
@media (max-width: 640px) {
  .bo-root .bo-grid { grid-template-columns: minmax(0, 1fr); }
  .bo-root .bo-card > header, .bo-root .bo-totals, .bo-root .bo-list-heading, .bo-root .bo-line { padding-left: 16px; padding-right: 16px; }
  .bo-root .bo-card > footer { padding: 14px 16px; gap: 8px; }
  .bo-root .bo-card h2 { font-size: 32px; }
  .bo-root .bo-dialog > header, .bo-root .bo-dialog > footer { padding: 16px; }
  .bo-root .bo-line-controls, .bo-root .bo-line-evidence { padding: 20px 16px; }
}
html[data-theme-resolved=dark] .bo-root,
[data-theme=dark] .bo-root,
.dark .bo-root,
html[data-amt-theme=dark] .bo-root { --bo-muted: #b6c4d9; }
