/* Personas in a cell (2026-10-08) — the decision profiles and personas of a cell (profiles.js), the heat table's cell panel */
.prof-tab { display: grid; gap: 16px; margin-bottom: 16px; }
.prof-tab[hidden] { display: none; }
.prof-panel { margin: 0; }
.prof-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 10px; flex-wrap: wrap; }
.prof-head__title { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.prof-head__n { font-weight: 700; font-variant-numeric: tabular-nums; display: inline-flex; align-items: center; gap: 6px; }
.prof-bar { display: flex; height: 14px; border-radius: 7px; overflow: hidden; background: #EFEFEF; gap: 2px; margin-bottom: 12px; }
.prof-bar__part { height: 100%; min-width: 2px; }
.prof-bar__part--rest { background: #E4E4E4; flex: 1 1 auto; }
.prof-list { display: grid; gap: 2px; }
.prof-item { border-bottom: 1px solid var(--line, #EAEAEA); padding: 8px 0; }
.prof-row { display: flex; align-items: center; gap: 10px; }
.prof-row--rest { padding: 8px 0; color: var(--text-muted, #6B6B6B); }
.prof-row--rest .prof-row__name { flex: 1 1 auto; display: inline-flex; align-items: center; gap: 6px; font-weight: 400; }
.prof-dot { width: 10px; height: 10px; border-radius: 50%; flex: 0 0 auto; background: #111; }
.prof-dot--rest { background: #E4E4E4; }
.prof-row__main { flex: 1 1 auto; min-width: 0; }
.prof-row__name { font-weight: 600; overflow-wrap: anywhere; }
.prof-row__sub { font-size: 0.86rem; color: var(--text-muted, #6B6B6B); overflow-wrap: anywhere; }
.prof-row__share { font-variant-numeric: tabular-nums; white-space: nowrap; font-weight: 600; display: inline-flex; align-items: center; gap: 6px; margin-left: auto; }
.prof-row__acts { display: inline-flex; gap: 6px; flex: 0 0 auto; }
.prof-edit, .prof-again { margin-top: 10px; }
/* (2026-10-09) a persona starts with the person: the common core, the opened card, the matrix */
.prof-core { margin: 10px 0 12px; padding: 10px 12px; border: 1px solid var(--border, #E5E5E5); border-radius: 10px; }
.prof-core__head { display: flex; align-items: center; gap: 6px; margin-bottom: 6px; }
.prof-core__list { margin: 0; padding-left: 18px; font-size: 0.9rem; }
.prof-core__list li { margin: 2px 0; }
/* (2026-10-12) how the people of a group decide — one short line after “Who”; what a share was before the cell was built again */
.prof-deciding { margin-top: 8px; font-size: 0.9rem; }
.prof-deciding .tip-icon { margin-left: 6px; vertical-align: middle; }
.prof-was { font-weight: 400; font-size: 0.8rem; color: var(--text-muted, #6B6B6B); }
.prof-row__main--open { cursor: pointer; }
.prof-row__main--open:hover .prof-row__name { text-decoration: underline; }
.prof-sections { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 24px; margin: 10px 0 6px; padding: 12px; background: var(--bg-soft, #FAFAFA); border-radius: 10px; }
.prof-sec__head { display: flex; align-items: center; gap: 6px; margin-bottom: 6px; }
.prof-mark--hyp { background: transparent; border: 1px dashed var(--border, #CFCFCF); color: var(--text-muted, #6B6B6B); }
.prof-dl { margin: 0; font-size: 0.86rem; }
.prof-dl dt { color: var(--text-muted, #6B6B6B); margin-top: 6px; }
.prof-dl dd { margin: 0; overflow-wrap: anywhere; }
.prof-matrix { margin: 14px 0 6px; }
.prof-matrix .prof-across__table { min-width: 640px; }
.prof-matrix__col { white-space: normal !important; min-width: 130px; max-width: 200px; vertical-align: bottom; }
.prof-matrix__group { margin-top: 2px; font-size: .74rem; font-weight: 400; color: var(--text-gray); line-height: 1.25; }
.prof-matrix__axis { color: var(--text-muted, #6B6B6B); font-weight: 400 !important; white-space: nowrap; vertical-align: top; }
@media (max-width: 720px) { .prof-sections { grid-template-columns: minmax(0, 1fr); } }
/* (2026-10-10) the five sections of a persona, the confidence marks, the editing window, found data */
.prof-sec--purchase { grid-column: 1 / -1; }
.prof-sec--purchase .prof-dl { columns: 2; column-gap: 24px; }
.prof-sec--purchase .prof-dl dt { break-after: avoid; }
.prof-sec--purchase .prof-dl dd { break-inside: avoid; }
@media (max-width: 720px) { .prof-sec--purchase .prof-dl { columns: 1; } }
.prof-dl dt { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.prof-trait { display: flex; align-items: center; gap: 6px; margin-top: 4px !important; }
.prof-conf { display: inline-flex; align-items: center; gap: 3px; font-size: 0.72rem; font-weight: 600; line-height: 1.2; padding: 1px 6px; border-radius: 999px; border: 1px solid var(--border, #CFCFCF); color: var(--text-muted, #6B6B6B); background: var(--white, #fff); }
.prof-conf--high { border-color: var(--primary, #111); color: var(--primary, #111); }
.prof-conf--low { border-style: dashed; }
.prof-core__edit { margin-left: auto; }
.prof-ed__group { margin: 0 0 18px; }
.prof-ed__title { margin: 0 0 8px; font-size: 0.92rem; font-weight: 700; }
.prof-ed__grid--purchase, .prof-ed__grid--character { grid-template-columns: minmax(0, 1fr) 150px; }
.prof-ed__grid--character { grid-template-columns: 220px minmax(0, 1fr); }
.prof-ed__grid--core { grid-template-columns: minmax(0, 1fr); }
.prof-ed__none { margin: 0; grid-column: 1 / -1; }
.prof-ed .prof-area, .prof-area { resize: none; overflow: hidden; min-height: 38px; height: auto; }
.prof-found { margin: 12px 0 4px; padding: 10px 12px; border: 1px solid var(--border, #E5E5E5); border-radius: 10px; }
.prof-found__none { margin: 8px 0 0; font-size: 0.86rem; }
@media (max-width: 720px) { .prof-ed__grid--purchase, .prof-ed__grid--character { grid-template-columns: minmax(0, 1fr); } }
.prof-note, .prof-rest { font-size: 0.86rem; color: var(--text-muted, #6B6B6B); display: flex; align-items: center; gap: 6px; margin: 8px 0; }
.prof-note[data-questions-of] { flex-direction: column; align-items: flex-start; gap: 2px; }
.prof-acts { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; align-items: center; }
.prof-buy { display: inline-flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.prof-buy__lack { font-size: 0.86rem; color: var(--danger, #B42318); }
.prof-personas { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-top: 10px; }
@media (max-width: 1100px) { .prof-personas { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 680px) { .prof-personas { grid-template-columns: minmax(0, 1fr); } }
/* (2026-10-11) the card: the arrow in the top right corner opens it over the whole row; the share is a link; Talk is a pill */
.prof-persona { min-width: 0; }
.prof-persona--open { grid-column: 1 / -1; }
.prof-persona__top > b { min-width: 0; overflow-wrap: anywhere; }
.prof-persona__top .fold-btn { width: 26px; height: 26px; margin: -4px -6px -4px 0; }
.prof-share-link { margin-left: auto; padding: 0; border: 0; background: none; font: inherit; font-weight: 600; color: inherit; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.prof-share-link:hover { color: var(--accent-dark); }
.prof-talk { display: inline-flex; align-items: center; padding: 2px 12px; border: 1px solid var(--border-gray); border-radius: 999px; font-size: .8rem; font-weight: 600; color: inherit; text-decoration: none; }
.prof-talk:hover { border-color: var(--primary); background: var(--light-gray); }
.prof-share-fld { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; column-gap: 12px; }
.prof-share-fld .fld__head { margin: 0; }
.prof-share-fld .fld__label { white-space: nowrap; }
.prof-share-fld .fld__ctl { display: flex; align-items: center; gap: 12px; }
.prof-share-fld .fld__ctl > .ac-input { width: 96px; flex: none; }
.prof-share-fld .fld__hint { grid-column: 1 / -1; }
.prof-share-rest { white-space: nowrap; color: var(--text-gray); font-size: .9rem; font-variant-numeric: tabular-nums; }
/* (2026-10-13) The percent of a draft's row opens the same one-line editor; the two thresholds of a build — one quiet line. */
.prof-row__share > .prof-share-link, .prof-th .prof-share-link { margin-left: 0; }
.prof-th { flex-wrap: wrap; margin: 6px 0 8px; }
/* (second round) The make-up of the segment, one window: a row per origin group — its families, the pass rate, its part of the segment. */
.prof-mk__row { display: flex; align-items: center; justify-content: space-between; gap: 8px 16px; flex-wrap: wrap; padding: 8px 0; border-bottom: 1px solid var(--border, #E5E5E5); }
.prof-mk__row:last-child { border-bottom: 0; }
.prof-mk__name { display: flex; flex-direction: column; min-width: 150px; flex: 1 1 150px; }
.prof-mk__fld { flex: 0 0 auto; margin: 0; }
.prof-mk__seg { white-space: nowrap; color: var(--text-gray); font-size: .9rem; font-variant-numeric: tabular-nums; min-width: 132px; }
.prof-first { margin: 8px 0 4px; max-width: 760px; }
.prof-first .prof-source { max-width: none; margin: 0; }
.prof-persona { border: 1px solid var(--line, #E5E5E5); border-radius: 10px; padding: 12px; display: grid; gap: 6px; align-content: start; }
.prof-persona__top { display: flex; align-items: center; gap: 8px; }
.prof-persona__who, .prof-persona__sum { font-size: 0.86rem; color: var(--text-muted, #6B6B6B); }
.prof-persona__profile { font-weight: 600; display: flex; align-items: center; gap: 6px; }
.prof-persona__char { font-size: 0.86rem; }
.prof-persona__char .tip-icon { margin-left: 6px; vertical-align: middle; }
.prof-next { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.prof-next__name { display: inline-flex; gap: 10px; align-items: baseline; flex-wrap: wrap; margin-right: auto; }
.prof-progress { margin: 0; }
/* Twins by decision profile (2026-10-08): the group's line in a persona's card, the marks, "Create twins". */
.prof-persona__twins { font-size: 0.86rem; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.prof-mark, .ctest-mark { display: inline-flex; align-items: center; gap: 4px; font-size: 0.78rem; font-weight: 500; line-height: 1.2; padding: 2px 7px; border-radius: 999px; background: var(--surface-2, #F4F4F4); color: var(--text-muted, #6B6B6B); white-space: nowrap; }
.ctest-mark--given { background: #FFF1EB; color: var(--accent, #FF5A1F); }
.prof-twins { margin-top: 12px; grid-template-columns: 200px max-content; align-items: start; }
.prof-twins .btn { white-space: nowrap; }
/* (2026-11-04) twins per persona: the own number under the choice (twins-count.js) */
.twc .fld__ctl { display: flex; flex-direction: column; gap: 6px; }
.twc .twc-own[hidden] { display: none; }
.fld--action .fld__ctl > .prof-buy > .btn { height: var(--ac-control-h); padding-top: 0; padding-bottom: 0; }
/* The test of a hypothesis in a cell: the table by profile with the cell's row. */
.ctest-meaning { font-weight: 600; margin: 0 0 10px; }
.ctest-table td, .ctest-table th { vertical-align: top; }
.ctest-num { text-align: right; white-space: nowrap; }
.ctest-who { display: grid; gap: 2px; min-width: 180px; }
.ctest-who__profile { font-size: 0.86rem; }
.ctest-marks { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 2px; }
.ctest-lead { font-weight: 700; }
.ctest-whole td { border-top: 2px solid var(--text, #111); }
.ctest-range { display: block; font-size: 0.8rem; color: var(--text-muted, #6B6B6B); font-weight: 400; }
.ctest-foot { font-size: 0.86rem; margin: 8px 0 0; }
.ctest-stale { display: flex; align-items: center; gap: 10px; margin-top: 10px; font-size: 0.9rem; }
.ctest-dlg { margin-top: 10px; }
.ctest-dlg__price { margin: 8px 0 0; font-size: 0.9rem; }
.ctest-told__one { border-top: 1px solid var(--line, #E5E5E5); padding: 8px 0; }
.ctest-told__one > .fold-details__head { cursor: pointer; font-weight: 600; }
.ctest-told__text { white-space: pre-wrap; font: inherit; font-size: 0.86rem; color: var(--text-muted, #6B6B6B); margin: 8px 0 0; }
.asst-test__sub { font-size: 0.86rem; margin: 2px 0 8px; }
.asst-card--test .ctest-table { font-size: 0.9rem; }
.prof-cell__nums { display: flex; gap: 18px; flex-wrap: wrap; font-variant-numeric: tabular-nums; color: var(--text-muted, #6B6B6B); font-size: 0.92rem; }
.mkt-cellpanel { margin-top: 12px; border: 1px solid var(--line, #E5E5E5); border-radius: 10px; padding: 14px 16px; }
.mkt-cellpanel[hidden] { display: none; }
.mkt-heat__cell--pick { cursor: pointer; position: relative; }
.mkt-heat__cell--pick:hover, .mkt-heat__cell--pick:focus-visible, .mkt-heat__cell--pick.is-open { outline: 2px solid #111; outline-offset: -2px; }
.mkt-heat__exp { font-size: 11px; font-weight: 400; line-height: 1.3; opacity: 0.85; white-space: nowrap; }
.mkt-heat__legend { margin: 8px 0 0; font-size: 0.86rem; color: var(--text-muted, #6B6B6B); }
.prof-cell__exp { color: var(--text, #111); font-weight: 600; }
.mkt-heat__mark { display: inline-block; margin-left: 6px; vertical-align: middle; }
.mkt-heat__mark--best { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.mkt-heat__mark--has { font-size: 11px; font-weight: 700; line-height: 16px; min-width: 16px; padding: 0 4px; border-radius: 8px; background: #111; color: #fff; text-align: center; }
.asst-cells { display: grid; gap: 6px; margin-top: 8px; }
.asst-cells__row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; width: 100%; text-align: left; font: inherit; font-size: 14px; color: inherit; background: var(--white, #fff);
    border: 1px solid var(--line, #E5E5E5); border-radius: 8px; padding: 8px 10px; text-decoration: none; }
button.asst-cells__row, a.asst-cells__row { cursor: pointer; }
button.asst-cells__row:hover, a.asst-cells__row:hover { border-color: #BDBDBD; }
.asst-cells__row.is-picked { border-color: #111; box-shadow: inset 0 0 0 1px #111; }
.asst-cells__row--rest { color: var(--text-muted, #6B6B6B); border-style: dashed; }
.asst-cells__name { display: inline-flex; gap: 8px; align-items: baseline; flex-wrap: wrap; min-width: 0; font-weight: 600; overflow-wrap: anywhere; }
.asst-cells__name .cell-muted { font-weight: 400; }
.asst-cells__n { font-variant-numeric: tabular-nums; white-space: nowrap; }
.asst-card--profiles .prof { margin-top: 4px; }
.asst-profiles__line { display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap; }
.later-note { margin: 0; }

/* The assistant's card of numbers by cell or profile (2026-10-09). */
.asst-rows { font-size: 14px; margin-top: 6px; }
.asst-rows td, .asst-rows th { padding: 6px 8px; }
.asst-rows__name { overflow-wrap: anywhere; }
.asst-rows__mark { display: inline-block; margin-left: 8px; padding: 1px 7px; border: 1px solid var(--border, #E0E0E0); border-radius: 999px; font-size: 12px; color: var(--text-muted, #6B6B6B); white-space: nowrap; }
.asst-rows__whole td { border-top: 1px solid #111; font-weight: 600; }

/* Ad messages and materials in a cell: who wins where (2026-10-09). */
.msg-cellmx { margin-top: 10px; }
.msg-cellmx__share { font-weight: 400; }
.msg-cellmx__win { padding: 1px 6px; border-radius: 4px; background: #111; color: #fff; }
.msg-cellmx__for, .msg-cellmx__serves { margin-left: 8px; }
.msg-cellmx__lines { margin: 10px 0 4px; padding-left: 18px; font-size: 14px; display: grid; gap: 4px; }
.msg-cellmx__at { font-size: 0.86rem; margin: 6px 0 0; }

/* Transfer (2026-10-09): the source cell of a build, the outcome marks, the table "profile × country" */
.prof-source { max-width: 420px; margin: 8px 0 4px; }
.prof-next__source { flex: 0 0 100%; }
.prof-next .prof-source { margin: 0; }
/* (2026-11-03, ARCHITECTURE 3.7) where the personas of a new country's cell come from: the cells with personas, their rows */
.prof-source-choice { flex: 0 0 100%; margin: 8px 0 4px; max-width: 760px; }
.prof-carry { margin: 10px 0; padding-top: 8px; border-top: 1px solid var(--border-gray); }
.prof-carry__head { display: flex; flex-wrap: wrap; gap: 8px; align-items: baseline; margin-bottom: 4px; }
.asst-cells__source { margin-top: 8px; }
.prof-row__name .prof-mark, .prof-persona__profile .prof-mark { margin-left: 8px; vertical-align: middle; }
.prof-mark--changed { background: var(--accent-wash, #FFEFE8); color: var(--accent-dark, #C2410C); }
.prof-mark--new { background: var(--primary, #111); color: var(--white, #fff); }
.prof-mark--absent { text-decoration: line-through; }
.prof-across__head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 14px; margin-bottom: 8px; }
.prof-across__line { font-size: 0.9rem; color: var(--text-muted, #6B6B6B); display: inline-flex; align-items: center; gap: 6px; }
.prof-across__scroll { overflow-x: auto; }
.prof-across__table { width: 100%; border-collapse: collapse; font-size: 0.88rem; }
.prof-across__table th { text-align: left; font-weight: 600; padding: 6px 10px 6px 0; border-bottom: 1px solid var(--border, #E5E5E5); white-space: nowrap; }
.prof-across__table td { padding: 7px 10px 7px 0; border-bottom: 1px solid var(--border, #EFEFEF); vertical-align: top; }
.prof-across__name { max-width: 320px; overflow-wrap: anywhere; }
.prof-across__share { margin-left: 8px; font-variant-numeric: tabular-nums; }
.prof-across__res { display: block; margin-top: 3px; font-size: 0.8rem; color: var(--text-muted, #6B6B6B); }
.msg-carry__line { margin: 8px 0; font-weight: 600; }
.msg-carry__table td .prof-mark { margin: 0; }

/* The questions of a cell (2026-10-11): the own-question field under a created cell, the marks of a group against its
   expected option, the line of a cell persona's twins. */
.prof-own { margin-top: 10px; max-width: 520px; }
.prof-qedit { display: flex; flex-direction: column; gap: 8px; }
.prof-qedit__row { display: flex; align-items: center; gap: 8px; min-width: 0; }
.prof-qedit__num { flex: none; width: 22px; color: var(--text-gray); text-align: right; }
.prof-qedit__fld { flex: 1 1 auto; min-width: 0; margin: 0; }
.prof-qedit__row > .icon-only { flex: none; }
.asst-qlist { margin: 0 0 10px; padding-left: 22px; }
.asst-twins { max-width: 220px; margin: 4px 0 10px; }
.asst-qlist li { margin: 2px 0; }
.ctest-mark--expected { color: var(--ok, #1a7f37); }
.ctest-mark--another { color: var(--accent); font-weight: 600; }
.stimulus__expected { font-size: .82rem; }
.hyp__earlier { margin: 2px 0 6px; font-size: .82rem; }
.twins-ofcell__mark { display: inline-flex; align-items: center; padding: 1px 8px; border: 1px solid var(--border-gray); border-radius: 999px; font-size: .74rem; color: inherit; white-space: nowrap; }
.twins-ofcell__mark .tip-icon { margin-left: 4px; }

/* A hypothesis drafted as the foundation of a message: the mark at a quote (unprompted / prompted). */
.hyp__said,
.hyp__evidence cite.hyp__said {
    font-weight: 400;
    color: var(--text-gray);
}

.hyp__mended {
    margin-top: 10px;
}

/* A hypothesis from the talks (the main motive, barrier, condition of its groups): the card of every hypothesis; its
   own part is the fold "Chosen among N …" — a row per item, the text on the left and a switch on the right. */
.prio__sum { margin-bottom: 4px; }
.prio-card__meta { margin: 0; font-size: .82rem; }
.prio-main { display: flex; flex-direction: column; gap: 6px; }
.prio-main__row { margin: 0; overflow-wrap: anywhere; }
.prio-main__who { font-weight: 700; }
.prio-among__list { display: flex; flex-direction: column; gap: 8px; margin: 10px 0 0; padding: 0; list-style: none; }
.prio-among__row { display: flex; align-items: center; gap: 12px; font-size: .88rem; }
.prio-among__text { flex: 1 1 auto; min-width: 0; overflow-wrap: anywhere; }
.prio-among__row[data-on="0"] .prio-among__text { color: var(--text-gray); }
.prio-among__row--for { align-items: flex-start; }
.prio-among__for { display: block; font-size: .78rem; color: var(--text-gray); }
/* (2026-10-19: the wording of an item opens its window — the card in the conversation) */
.prio-among__text--edit { cursor: pointer; }
.prio-among__text--edit:hover { text-decoration: underline; text-decoration-style: dotted; }
.prio-among__row--add button { border: 0; padding: 0; background: none; font: inherit; color: var(--text-gray); cursor: pointer; }
.prio-among__row--add button:hover { color: inherit; }
.hyp__evidence summary .tip-icon { margin-left: 6px; vertical-align: middle; }
/* (the persona where there is room — name, age, one short line: one line, cut with an ellipsis) */
.hyp__evidence cite.hyp__who { display: block; margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.test-dlg__group--full { flex-wrap: nowrap; }
.test-dlg__group--full .ac-check { flex: 1 1 auto; min-width: 0; }
.test-dlg__group--full .ac-check__label { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.test-dlg__group--full .test-dlg__count { flex: none; white-space: nowrap; }
/* the buttons of a card stay in one row */
.hyp__acts { gap: 5px; }
.hyp__acts .btn { flex: 0 0 auto; white-space: nowrap; padding: 6px 7px; font-size: .8rem; gap: 4px; }
.hyp__acts .btn .icon { margin-right: 0; }

/* A switch (controls.js toggle): a knob that slides right when on. */
.ac-switch { position: relative; display: inline-flex; flex: none; cursor: pointer; }
.ac-switch input { position: absolute; opacity: 0; width: 0; height: 0; }
.ac-switch__track { position: relative; width: 34px; height: 20px; border-radius: 999px; background: var(--border-strong); transition: background .15s; }
.ac-switch__track::after { content: ""; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: var(--white); box-shadow: 0 1px 2px rgba(0, 0, 0, .25); transition: transform .15s; }
.ac-switch input:checked + .ac-switch__track { background: var(--primary); }
.ac-switch input:checked + .ac-switch__track::after { transform: translateX(14px); }
.ac-switch input:focus-visible + .ac-switch__track { box-shadow: 0 0 0 3px var(--accent-ring); }
.ac-switch:has(input:disabled) { cursor: default; }
.ac-switch input:disabled + .ac-switch__track { opacity: .4; }

/* A dialog never lets its content out: what is inside is as wide as the window at most (a form with a minimum width
   used to stick out of the 440 px window, and of a phone's). */
.ac-dialog { box-sizing: border-box; max-width: 100%; overflow-x: hidden; }
.ac-dialog__body { min-width: 0; }
.ac-dialog__body > * { max-width: 100%; min-width: 0; box-sizing: border-box; }
.ac-dialog__body :is(.fld, .ac-input, .ac-select, textarea, input) { max-width: 100%; min-width: 0; box-sizing: border-box; }
@media (max-width: 480px) {
    .ac-dialog__back { padding: 12px; }
    .ac-dialog { padding: 18px 16px 14px; }
    .ac-dialog__foot { flex-wrap: wrap; }
}
.prio--chat { margin: 6px 0 0; }
.prio--chat .hyp { padding: 12px 14px; gap: 6px; }
.prio--chat .prio-card__for { margin: 0; color: var(--text-gray); }
.prio--chat .prio-card__res { margin: 0; }
.prio--chat .prio-card__res[data-outcome="confirmed"] { font-weight: 600; }
.prio--chat .prio-card__status { margin: 0; font-size: .8rem; color: var(--text-gray); }
@media (max-width: 480px) { .hyp__acts { flex-wrap: wrap; } }
@media (max-width: 640px) {
    .test-dlg__group--full { flex-wrap: wrap; }
    .test-dlg__group--full .ac-check { flex: 1 1 100%; }
}
/* the header of a card: kind → status → evidence label → confidence → the page link; what does not fit wraps, left-aligned */
.hyp__head .badge, .hyp__head .hyp__page, .hyp__head .badge + .hyp__page { margin-left: 0; }

/* Ad messages from the basis (2026-10-13): the tables of the basis, what to write, a message's pick */
.msg-basis .msg-bar h2 .tip-icon { margin-left: 6px; vertical-align: middle; }
.msg-basis__kind { margin-top: 18px; }
.msg-basis__cap { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; margin-bottom: 8px; font-size: 0.82rem; }
.msg-basis__table { width: 100%; }
.msg-basis__table th.num .tip-icon { margin-left: 4px; vertical-align: middle; }
.msg-basis__tick { width: 34px; }
.msg-basis__tick .ac-check { gap: 0; }
.msg-basis__tick .ac-check__label:empty { display: none; }
.msg-basis__item { min-width: 220px; }
.msg-basis__item .tip-icon { margin-left: 6px; vertical-align: middle; }
.msg-basis__pred { margin-left: 6px; }
.msg-basis__untested { margin-top: 14px; }
.msg-write { margin-top: 20px; }
.msg-write .msg-form.fgrid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.msg-write__count { font-weight: 600; font-size: 0.88rem; }
.msg-pick { margin-top: 14px; }
.msg-pick__head { margin: 0 0 8px; font-size: 0.82rem; overflow-wrap: anywhere; }
.msg-pick__err { margin: 0 0 8px; font-size: 0.84rem; }
.msg-card__head .hyp__kind { flex: 0 0 auto; }
.msg-card__for .chips { align-items: center; }
.msg-card__niche { margin: 0; }
.msg-card__foot .msg-card__test { margin-left: auto; }
.msg-card .hyp__evidence .hyp__field { margin-top: 8px; }
.msg-card .hyp__evidence .hyp__field p { margin: 2px 0 0; overflow-wrap: anywhere; }
.msg-dlg-for { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.msg-dlg-for .ac-check { min-width: 0; }
.msg-dlg-for .ac-check__label { overflow-wrap: anywhere; min-width: 0; }
.msg-dlg-for .ac-check__note { white-space: nowrap; }
.msg-dlg-desc .ac-input--area { width: 100%; }
.msg-cellmx__own { margin-left: 8px; }
@media (max-width: 720px) {
    .msg-write .msg-form.fgrid { grid-template-columns: minmax(0, 1fr); }
    .msg-card__foot .msg-card__test { margin-left: 0; }
}
.msg-basis__table th, .msg-basis__table td { padding: 10px 10px; }
.msg-basis__table td.msg-basis__item { white-space: normal; overflow-wrap: anywhere; }
@media (max-width: 720px) {
    .msg-list .msg-cards { grid-template-columns: minmax(0, 1fr); }
}

/* Ad messages: one block per cell (2026-10-13) */
.msg-filter { margin: 0 0 14px; }
.msg-cell__head { display: flex; align-items: flex-start; gap: 12px; }
.msg-cell__title { flex: 1 1 auto; min-width: 0; }
.msg-cell__title h2 { font-size: 1.1rem; font-weight: 700; margin: 0; overflow-wrap: anywhere; }
.msg-cell__title h2 .tip-icon { margin-left: 6px; vertical-align: middle; }
.msg-cell__def { margin: 4px 0 0; font-size: 0.84rem; }
.msg-cell .msg-basis__cap { margin-bottom: 8px; }
.msg-cell .msg-basis__cap > .cell-muted { flex: 1 1 200px; min-width: 0; }
.msg-cell .msg-basis__kind.is-folded .msg-basis__cap, .msg-cell .msg-list.is-folded > .msg-bar, .msg-cell .msg-test.is-folded > .msg-bar, .msg-pick.is-folded .msg-pick__head { margin-bottom: 0; }
.msg-cell .msg-list, .msg-cell .msg-test, .msg-cell .msg-questions { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--border-gray); }
.msg-cell .msg-list > .msg-bar > .cell-muted, .msg-cell .msg-test > .msg-bar > .cell-muted { flex: 1 1 auto; min-width: 0; }
.msg-pick__head { display: flex; align-items: flex-start; gap: 10px; margin: 0 0 8px; font-size: 0.82rem; }
.msg-pick__head > .cell-muted { flex: 1 1 auto; min-width: 0; overflow-wrap: anywhere; }
.msg-questions__field { margin-top: 12px; max-width: 760px; }
.msg-questions__line { display: flex; gap: 12px; align-items: flex-start; }
.msg-questions__line .ac-input--area { flex: 1 1 auto; min-width: 0; }
.msg-questions__skip { flex: 0 0 auto; margin-top: 8px; }
.msg-questions .msg-bar h2 .tip-icon { margin-left: 6px; vertical-align: middle; }

/* Ad messages 2026-10-14: the double's number beside the switch; a writing's own button; the archive of a cell */
.msg-list__acts { margin: -4px 0 6px; }
.msg-archive { margin-top: 18px; }
.msg-archive__item { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--border-gray); }
.msg-archive__item .msg-bar { margin-bottom: 6px; }
.msg-archive .msg-cards { margin-top: 14px; }
/* Ad messages, 2026-10-14: the order of a message's items; the archive button at the right of the test line */
.msg-card__order { margin: 4px 0 6px; padding-left: 20px; font-size: 0.85rem; color: var(--text-gray); }
.msg-card__order li + li { margin-top: 2px; }
.msg-test__row .msg-archive__toggle { margin-left: auto; }
.msg-cell__tests > .msg-archive { margin-top: 10px; }
.msg-test__modes .ac-select { min-width: 220px; max-width: 100%; }
.msg-scores { margin-top: 14px; }
.msg-scores table { min-width: 560px; }
/* Ad messages, 2026-10-14 (third edition): the Re-generate window about 2/3 of a wide one; the links to the tests of a
   message; the rows of the Tests table open their test */
.ac-dialog--wide.msg-regen-dlg { width: min(694px, 100%); }
.msg-card__tests { display: flex; flex-wrap: wrap; gap: 4px 12px; margin: 8px 0 2px; font-size: 0.85rem; }
.msg-tabs { margin: 4px 0 14px; }
.msg-tests__row { cursor: pointer; }
.msg-tests__row:hover td { background: var(--hover-bg, rgba(0, 0, 0, 0.03)); }
.msg-tests__result { min-width: 220px; }
.msg-testpage > .pot-status, .msg-testpage > .msg-headline { margin-bottom: 14px; }
.msg-take__table td .btn { white-space: nowrap; }
.msg-tests__table th, .msg-tests__table td { white-space: normal; }
.msg-tests__table td:nth-child(2) { white-space: nowrap; }
.msg-tests__table td:first-child, .msg-tests__table td:last-child { white-space: nowrap; }
.msg-tests__table td:nth-child(3) { min-width: 180px; }
.msg-cell > .msg-cell__tests { margin: 8px 0 14px; }
/* the results table of a test (2026-10-14): the message's three lines; the icon "Take to creatives", filled when taken */
.msg-cellmx__line1 { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.msg-cellmx__line1 .msg-take { margin-left: auto; }
.msg-take--on { color: var(--accent); }
.msg-take--on svg, .msg-take--on svg path { fill: currentColor; }
.msg-cellmx__thought { display: flex; align-items: center; gap: 4px; margin: 2px 0 4px; max-width: 420px; }
.msg-cellmx__clip { flex: 1 1 auto; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.msg-cellmx__person { white-space: nowrap; }
.msg-testpage #cellMessagesResult table { min-width: 680px; }
/* (2026-10-14) the persona filter of a cell, in the head of its block */
.msg-cell__head .msg-cell__filter { margin: 0; flex: 0 0 260px; }
@media (max-width: 720px) { .msg-cell__head { flex-wrap: wrap; } .msg-cell__head .msg-cell__filter { flex: 1 1 100%; order: 3; } }
.msg-table th.msg-cellmx__creatives, .msg-table td.msg-cellmx__creatives { width: 10%; text-align: center; }
.msg-take:disabled.msg-take--on { opacity: 1; cursor: default; }
a.badge.msg-in-creatives { text-decoration: none; }
.msg-testpage .msg-cellmx__thought { max-width: 300px; }
.msg-testpage th.msg-cellmx__creatives, .msg-testpage td.msg-cellmx__creatives { padding-left: 8px; padding-right: 12px; }
/* (2026-10-14) the taken message's link to Creatives; the icon of "Take to creatives" larger */
a.msg-in-creatives { color: var(--accent); text-decoration: none; margin-left: 6px; }
a.msg-in-creatives:hover { text-decoration: underline; }
.msg-take { width: 36px; height: 36px; }
.msg-take svg { width: 22px; height: 22px; }
/* (2026-10-14) the tabs Messages / Tests on the line of the page title, at the right; under it on a narrow screen */
.run-head.msg-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px 20px; flex-wrap: wrap; }
.run-head.msg-head .msg-tabs { margin: 0; flex: 0 0 auto; }
/* (2026-10-14) Creatives: a block per cell with the table of its messages or of its creatives; the pages of a message,
   a creative and a test */
.val-cell__bar { align-items: center; margin: 10px 0 8px; }
.val-cell__bar .test-link { font-size: 0.85rem; }
.val-msgs__msg { min-width: 260px; }
.val-msgs__act, .val-mats td:first-child { white-space: nowrap; }
.val-table .msg-card__tests { margin: 0; }
.val-table .chips { flex-wrap: wrap; }
.val-creative { grid-template-columns: minmax(0, 720px); }
@media (max-width: 720px) { .val-cards { grid-template-columns: minmax(0, 1fr); } }
.val-set .msg-bar [data-act="add-creative"]:not(.btn-sm) { min-height: 44px; }
.val-mats th:first-child, .val-mats td:first-child { width: 1%; padding-right: 4px; }
.val-mats__title { margin-left: 8px; }
.val-msgs__who { white-space: normal; }
/* “The product is for” (recipient.js): one line, the site's sentence under it, the buttons — inside the card it stands in */
.rcp__line { margin: 0; line-height: 1.45; }
.rcp__src { margin-top: 4px; }
.rcp__form { margin-top: 10px; }
.rcp .asst-card__acts { margin-top: 10px; }
/* “How often it is bought” (afford.js, 2026-11-03): under whom the product is for */
.afd-live { margin-top: 10px; }

/* The reason a button cannot be pressed (SA_TIP.why): in any row of buttons it takes its own full-width line BELOW the
   buttons, left-aligned — it never stretches the buttons or pushes the row out of its container. (Last in the file:
   the row's own nowrap rules come earlier.) */
.why-off { display: block; order: 99; flex: 0 0 100%; align-self: auto; min-width: 0; margin: 0; text-align: left; line-height: 1.35; overflow-wrap: anywhere; white-space: normal; }
:has(> .why-off) { flex-wrap: wrap; }
