/*! © 2026 Cyber Affinity LLC. All rights reserved. Use is subject to https://www.cyber-affinity.com/terms — copying or redistributing this code is not permitted. */
/* Business Case & ROI Builder — builds on /styles.css tokens */
.bc-wrap { max-width: 1320px; }
.bc-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 24px; align-items: start; margin-top: 16px; }
.bc-left { display: grid; gap: 16px; min-width: 0; }

/* Tips */
.bc-tips summary { cursor: pointer; color: var(--accent-2); font-weight: 600; }
.bc-tips[open] summary { margin-bottom: 8px; }
.bc-tips .feat { margin: 0; }
.bc-tips .feat strong { color: var(--text); }

/* Inputs */
.bc-form { gap: 16px; }
.bc-sec { display: grid; gap: 14px; }
.page .bc-sec h2 { font-size: 18px; margin: 0; color: var(--accent-2); }
.bc-sec > .small { margin-top: -8px; }
.bc-sub { font-size: 14px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); margin: 6px 0 -4px; }
.bc-rows { display: grid; gap: 10px; }
.bc-item { border: 1px solid var(--line); border-radius: 10px; padding: 12px; display: grid; gap: 10px; }
.bc-item-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.bc-item-head b { font-size: 14px; color: var(--muted); }
.bc-item-head .rr-x { padding: 0 8px; }
.bc-sec label { font-size: 13px; }
.bc-sec input, .bc-sec select, .bc-sec textarea { padding: 8px 10px; font-size: 14px; }
.bc-sec .row, .bc-sec .row3 { gap: 10px; }
.bc-grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.bc-grid-4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; align-items: end; }
.bc-risk { display: grid; gap: 8px; border: 1px dashed var(--line); border-radius: 10px; padding: 10px 12px; }
.bc-live { margin: 0; font-size: 13px; color: var(--accent); }
.bc-li { display: flex; gap: 8px; align-items: end; }
.bc-grow { flex: 1 1 auto; min-width: 0; }
.bc-sec > .btn { justify-self: start; }
.bc-item .flag { justify-self: start; }

/* Output panel */
.bc-out { position: sticky; top: 84px; max-height: calc(100vh - 100px); overflow-y: auto; display: grid; gap: 12px; }
.bc-out-head .panel-title { margin-top: 0; }
.bc-out-head .out-actions { margin-top: 8px; }
.bc-basis { margin: 8px 0 0; display: flex; flex-wrap: wrap; align-items: center; gap: 4px 0; }
.bc-basis legend { font-size: 14px; float: left; margin: 0 14px 0 0; color: var(--muted); font-weight: 600; }
.bc-upsell-links { display: flex; flex-wrap: wrap; gap: 8px; }

/* The brief: a white "paper" so the preview matches the printout */
.bc-paper { background: #fff; color: #1a2433; border-radius: 10px; padding: 28px 30px; font-size: 14px; line-height: 1.5; display: grid; gap: 16px; min-width: 0; }
.page .bc-paper p, .page .bc-paper li { color: #1a2433; }
.bc-paper p { margin: 0; }
.bc-empty { color: #52627a !important; text-align: center; padding: 40px 12px; }
.bc-head { border-bottom: 2px solid #1a2433; padding-bottom: 10px; }
.bc-kicker { font-size: 12px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: #0f766e !important; }
.page .bc-head h2 { font-size: 26px; margin: 2px 0; color: #0b1422; letter-spacing: -0.01em; }
.bc-meta { font-size: 13px; color: #52627a !important; }
.bc-pre { white-space: pre-line; }

.bc-summary { border: 1px solid #99f6e4; background: #f0fdfa; border-radius: 10px; padding: 14px 16px; display: grid; gap: 12px; break-inside: avoid; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
.bc-ask { font-size: 15px; }
.bc-tiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.bc-tile { background: #fff; border: 1px solid #ccfbf1; border-radius: 8px; padding: 8px 10px; display: grid; gap: 1px; min-width: 0; }
.bc-tile-k { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: #115e59; }
.bc-tile b { font-size: 19px; color: #0b1422; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; line-height: 1.25; }
.bc-tile b.neg { color: #b91c1c; }
.bc-tile small { font-size: 11px; color: #52627a; }
.bc-basis-note { font-size: 12.5px; color: #334155 !important; }

.bc-block { display: grid; gap: 8px; break-inside: avoid; min-width: 0; }
.bc-block h3 { font-size: 13px; text-transform: uppercase; letter-spacing: 0.06em; color: #0b1422; margin: 0; border-bottom: 1px solid #d5dde8; padding-bottom: 4px; }
.bc-note { font-size: 12.5px; color: #52627a !important; }
.bc-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.bc-table th { background: #eef2f7; color: #334155; font-size: 12px; padding: 6px 8px; border-bottom: 1px solid #cbd5e1; text-align: left; }
.bc-table td { padding: 6px 8px; border-bottom: 1px solid #e2e8f0; color: #1a2433; }
.bc-table tr { break-inside: avoid; }
.bc-table tfoot th, .bc-table tfoot td { font-weight: 700; border-top: 2px solid #cbd5e1; border-bottom: 0; background: transparent; color: #0b1422; }
.bc-table .bc-num { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.bc-table .bc-num.neg { color: #b91c1c; }
.bc-years th:not(:first-child) { text-align: right; }
.bc-paper ul { margin: 0; padding-left: 20px; }
.bc-paper li { margin: 3px 0; }
.bc-foot { font-size: 12px; color: #52627a !important; border-top: 1px solid #d5dde8; padding-top: 8px; }

/* Chart (SVG built in JS; styled here so no inline styles are needed) */
.bc-chart-wrap { display: grid; gap: 4px; }
.bc-chart { width: 100%; height: auto; max-height: 260px; display: block; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
.bc-bar.pos { fill: #0d9488; }
.bc-bar.neg { fill: #f87171; }
.bc-line { fill: none; stroke: #0b1422; stroke-width: 1.5; stroke-dasharray: 4 3; }
.bc-axis { stroke: #1a2433; stroke-width: 1.2; }
.bc-grid { stroke: #e2e8f0; stroke-width: 1; }
.bc-tick { fill: #52627a; font-size: 11px; font-family: var(--font); }
.bc-val { fill: #0b1422; font-size: 11px; font-weight: 700; font-family: var(--font); }

@media (max-width: 1060px) {
  .bc-layout { grid-template-columns: 1fr; }
  .bc-out { position: static; max-height: none; overflow: visible; }
}
@media (max-width: 560px) {
  .bc-grid-4 { grid-template-columns: 1fr 1fr; }
  .bc-grid-3 { grid-template-columns: 1fr; }
  .bc-tiles { grid-template-columns: 1fr 1fr; }
  .bc-paper { padding: 20px 16px; }
  .bc-paper .bc-table { font-size: 12px; }
  .bc-paper .bc-table th, .bc-paper .bc-table td { padding: 5px 4px; overflow-wrap: anywhere; }
  .bc-paper .bc-table .bc-num { white-space: normal; }
  .bc-paper, .bc-out { min-width: 0; }
  .bc-paper .bc-block { overflow-x: auto; }
}
@media (max-width: 420px) { .bc-grid-4 { grid-template-columns: 1fr; } }

@media print {
  .bc-page { padding: 0; }
  .bc-wrap { max-width: none; padding: 0; }
  .bc-layout { display: block; margin: 0; }
  .bc-out { position: static; max-height: none; overflow: visible; background: #fff !important; border: 0 !important; padding: 0; display: block; }
  .bc-paper { padding: 0; border-radius: 0; font-size: 11.5px; gap: 10px; }
  .page .bc-head h2 { font-size: 20px; }
  .bc-summary { background: #f0fdfa !important; border-color: #99f6e4 !important; }
  .bc-tile { background: #fff !important; border-color: #ccfbf1 !important; }
  .bc-tile b { font-size: 15px; }
  .bc-table th { background: #eef2f7 !important; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .bc-table .bc-num.neg, .bc-tile b.neg { color: #b91c1c !important; }
  .bc-chart { max-height: 190px; }
}
