/* The product brief: the project's statement, set above everything else on Home.
   Open rules rather than a card; purpose in the display face. Proposals a person
   can decide on use the amber "needs a person" treatment. */
.product-brief { margin:0 0 34px; padding:18px 0 20px; border-top:1px solid var(--line); border-bottom:1px solid var(--line); }
.product-head { display:flex; align-items:flex-start; justify-content:space-between; gap:12px 20px; flex-wrap:wrap; margin-bottom:10px; }
.product-more { margin-top:12px; }
.product-more>summary { width:fit-content; font-size:13px; color:var(--muted); }
.product-more[open]>summary { color:var(--ink); }
.product-title { display:flex; align-items:baseline; flex-wrap:wrap; gap:4px 14px; min-width:0; }
.product-title h2 { font-family:var(--font-ui); font-size:13px; font-weight:560; color:var(--human); outline-offset:4px; }
.product-meta { font-size:12.5px; color:var(--faint); overflow-wrap:anywhere; }
.product-head .button { min-height:32px; font-size:12.5px; }
.product-purpose { max-width:62ch; font-size:15.5px; line-height:1.55; font-weight:400; color:var(--ink); overflow-wrap:anywhere; white-space:pre-line; }
.product-placeholder { color:var(--muted); }
.product-lede { max-width:64ch; margin:12px 0 18px; color:var(--muted); font-size:14px; line-height:1.6; }
.product-audience { display:flex; flex-wrap:wrap; gap:2px 12px; max-width:72ch; margin-top:14px; font-size:15px; line-height:1.55; color:var(--ink); overflow-wrap:anywhere; }
.product-label { font-size:12.5px; font-weight:550; color:var(--muted); }
.product-audience .product-label { padding-top:2px; }
.product-lists { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:18px 36px; max-width:980px; margin-top:22px; }
.product-lists h3 { margin-bottom:8px; font-size:12.5px; font-weight:550; color:var(--muted); }
.product-statement .product-lists ul { list-style:none; margin:0; padding:0; display:grid; gap:7px; }
.product-statement .product-lists li { position:relative; padding-left:18px; font-size:14px; line-height:1.5; overflow-wrap:anywhere; }
.product-statement .product-lists li::before { content:""; position:absolute; left:0; top:.72em; width:9px; border-top:2px solid var(--human); }
.product-non-goals li { color:var(--muted); }
.product-statement .product-non-goals li::before { border-top-color:var(--line-strong); }
.product-notes { max-width:980px; margin-top:20px; }
.product-notes>summary { width:fit-content; font-size:13px; color:var(--muted); }
.product-notes[open]>summary { color:var(--ink); margin-bottom:10px; }
.product-notes .agent-message { font-size:14px; }

/* Proposals */
.product-proposals { margin-top:24px; padding:16px 18px; border-left:3px solid var(--line-strong); border-radius:var(--radius-control); background:var(--surface-subtle); }
.product-proposals.decide { border-left-color:var(--human); background:var(--human-soft); }
.product-proposals>h3 { margin-bottom:12px; font-size:14px; }
.product-proposals.decide>h3 { color:var(--human); }
.product-proposal-list { display:grid; gap:14px; }
.product-proposal { display:grid; gap:10px; padding:14px 16px; border-radius:var(--radius-control); background:var(--surface); border:1px solid var(--line); min-width:0; }
.product-proposal-head { display:flex; align-items:center; flex-wrap:wrap; gap:6px 12px; min-width:0; }
.product-proposal-head .button { min-height:30px; font-size:12.5px; margin-left:auto; }
.product-author { display:inline-flex; align-items:center; gap:8px; min-width:0; font-size:13px; overflow-wrap:anywhere; }
.product-agent-label { padding:1px 8px; border-radius:999px; font-size:12px; font-weight:550; color:var(--agent); background:var(--agent-soft); }
.product-rationale { max-width:72ch; font-size:14px; line-height:1.55; white-space:pre-wrap; overflow-wrap:anywhere; }
.product-proposal .message { margin:0; }
.product-proposal label { margin:0; }
.product-brief :is(textarea,input) { font-weight:400; }
.product-proposal textarea { min-height:0; margin-top:6px; }
.product-actions { display:flex; flex-wrap:wrap; gap:8px; }

/* Field-by-field differences */
.product-diff { display:grid; gap:10px; padding:12px 14px; border-radius:var(--radius-control); background:var(--surface-subtle); min-width:0; }
.product-diff h4 { font-size:12.5px; font-weight:550; color:var(--muted); }
.product-change { display:grid; gap:4px; min-width:0; }
.product-change ul { list-style:none; margin:0; padding:0; display:grid; gap:3px; }
.product-change :is(p,li) { position:relative; padding:2px 0 2px 20px; font-size:13.5px; line-height:1.5; white-space:pre-wrap; overflow-wrap:anywhere; }
.product-change :is(p,li)::before { position:absolute; left:4px; font-family:var(--font-mono); font-weight:600; }
.product-change ol { margin:0; padding:0 0 0 22px; display:grid; gap:3px; }
.product-change ol li { padding-left:2px; }
.product-added::before { content:"+"; color:var(--done); }
.product-removed { color:var(--muted); text-decoration:line-through; text-decoration-color:color-mix(in srgb,var(--danger) 60%,transparent); }
.product-removed::before { content:"−"; color:var(--danger); }
.product-cleared { color:var(--faint); font-style:italic; }
.product-cleared::before { content:"−"; color:var(--danger); font-style:normal; }

/* Editor */
.product-editor { display:grid; gap:14px; max-width:980px; margin-top:24px; padding:20px; border:1px solid var(--line); border-radius:var(--radius-panel); background:var(--surface); }
.product-editor h3 { font-family:var(--font-display); font-size:18px; font-weight:640; }
.product-editor>.help { margin-top:-8px; }
.product-editor>label,.product-editor fieldset { margin:0; }
.product-editor textarea { min-height:0; margin-top:6px; }
.product-help { display:block; font-weight:400; }
.product-editor .product-lists { margin-top:0; }
.product-list-editor ol { list-style:none; margin:0 0 6px; padding:0; display:grid; gap:6px; }
.product-list-editor li { display:flex; gap:6px; align-items:center; }
.product-list-editor input { min-width:0; }
.product-list-editor .quiet { flex-shrink:0; }
.product-editor .message { margin:0; }
.product-editor .message.warning { display:flex; flex-wrap:wrap; align-items:center; gap:8px 14px; }

/* History */
.product-history { max-width:980px; margin-top:20px; }
.product-history>summary { width:fit-content; font-size:13px; color:var(--muted); }
.product-history[open]>summary { color:var(--ink); }
.product-history-list { list-style:none; margin:10px 0 0; padding:0; }
.product-history-item { display:grid; gap:6px; padding:12px 0; }
.product-history-item+.product-history-item { border-top:1px solid var(--line); }
.product-history-item>.product-rationale { font-size:13px; color:var(--muted); }
.badge.product-accepted { background:var(--done-soft); color:var(--done); }
.badge.product-proposed { background:var(--human-soft); color:var(--human); }
.badge.product-declined::before,.badge.product-superseded::before { background:transparent; border:1.5px solid currentColor; }

@media (max-width:700px) {
  .product-lists { grid-template-columns:1fr; }
  .product-proposals { padding:14px 12px; }
  .product-proposal { padding:12px; }
  .product-editor { padding:16px 14px; }
  .product-proposal-head .button { margin-left:0; }
}

.product-brief { margin-top:34px; }
