/* A project's Client tab (client-portal.js, docs/CLIENT-PORTAL.md §8): one person outside at a time, their page's
   groups and items, the tasks they see, their comments. Flat: hairlines between rows, no boxed cards; theme tokens
   only; one column on a phone. */
.cpp-page { max-width: 980px; }
.cpp-sec { padding: 18px 0 10px; }
.cpp-sec + .cpp-sec { border-top: 1px solid var(--line); margin-top: 8px; }
.cpp-sec h2 { margin: 0; font-size: 15px; }
.cpp-h { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; margin-bottom: 4px; }
.cpp-small { font-size: 13px; margin: 2px 0 0; }
.cpp-err { color: var(--bad-2); font-size: 13px; margin: 6px 0 0; }
.cpp-row { display: flex; align-items: center; gap: 8px 10px; flex-wrap: wrap; }
.cpp-row .sp { flex: 1; }
.cpp-row .grow, .cpp-row label.grow { flex: 1; min-width: 180px; }
.cpp-people { display: flex; gap: 8px; overflow-x: auto; padding: 14px 0 4px; scrollbar-width: none; }
.cpp-people .chip { display: inline-flex; align-items: center; gap: 7px; white-space: nowrap; }
.cpp-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--text-3); opacity: .5; }
.cpp-dot.on { background: var(--ok); opacity: 1; }
.cpp-lk svg { width: 14px; height: 14px; vertical-align: -2px; }
.cpp-link { margin: 8px 0 4px; }
.cpp-link input { min-width: 0; font: 13px var(--mono, ui-monospace, monospace); }
.cpp-exp { padding: 14px 0 6px; border-top: 1px solid var(--line); margin-top: 10px; }
.cpp-et { font-size: 15px; }
.cpp-state { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; color: var(--text-3); }
.cpp-state svg { width: 15px; height: 15px; }
.cpp-state.on { color: var(--ok); }
.cpp-items { list-style: none; margin: 8px 0 0; padding: 0; }
.cpp-item { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 12px; padding: 10px 0; border-top: 1px solid var(--line); }
.cpp-item:first-child { border-top: 0; }
.cpp-th { width: 96px; height: 60px; border-radius: 6px; border: 1px solid var(--line); object-fit: cover; object-position: top; background: var(--ink-2); display: block; }
.cpp-th.g { display: grid; place-items: center; color: var(--text-3); }
.cpp-th.g svg { width: 24px; height: 24px; }
.cpp-im { min-width: 0; }
.cpp-im p { overflow-wrap: anywhere; }
.cpp-acts { margin-top: 8px; }
.cpp-tick { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--text-2); }
.cpp-scs { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 8px; align-items: flex-start; }
.cpp-sc { display: grid; gap: 2px; width: 104px; }
.cpp-sc img { width: 104px; height: 64px; border-radius: 6px; border: 1px solid var(--line); object-fit: cover; object-position: top; background: var(--ink-2); }
.cpp-sc .linkbtn { font-size: 12.5px; justify-self: start; }
.cpp-addsc { display: grid; place-items: center; width: 104px; height: 64px; border: 1px dashed var(--line); border-radius: 6px; cursor: pointer; font-size: 12.5px; color: var(--text-2); text-align: center; }
.cpp-addsc svg { width: 14px; height: 14px; vertical-align: -2px; }
.cpp-form { display: grid; gap: 10px; margin: 12px 0 4px; }
.cpp-form label { display: flex; flex-direction: column; gap: 5px; font-size: 12.5px; color: var(--text-2); }
.cpp-form input, .cpp-form select, .cpp-form textarea { background: var(--ink-2); border: 1px solid var(--control); border-radius: 4px; padding: 8px 10px; color: var(--text); font: 14px var(--sans); min-height: 36px; }
.cpp-fold { margin-top: 10px; }
.cpp-fold summary { cursor: pointer; color: var(--text-2); font-size: 13.5px; }
.cpp-list { list-style: none; margin: 6px 0 0; padding: 0; }
.cpp-list > li { display: flex; gap: 10px; align-items: flex-start; padding: 10px 0; border-top: 1px solid var(--line); }
.cpp-list > li:first-child { border-top: 0; }
.cpp-li { flex: 1; min-width: 0; display: grid; gap: 2px; }
.cpp-pill { font-size: 12px; padding: 3px 8px; border-radius: 999px; background: var(--ink-3); color: var(--text-2); }
.cpp-pill.done { color: var(--ok); }
.cpp-pill.doing, .cpp-pill.planned { color: var(--warn); }
.cpp-note { margin: 6px 0 0; white-space: pre-wrap; overflow-wrap: anywhere; padding-left: 10px; border-left: 2px solid var(--line); }
.cpp-note span { display: block; }
.cpp-note.them { border-left-color: var(--warn); }
.cpp-reply { margin-top: 8px; }
.cpp-reply textarea { min-height: 38px; }
.cpp-sec h2 + .cpp-tick { margin-top: 8px; }
.cpp-pill.checking, .cpp-pill.sent { color: var(--text-2); }
.cpp-h .btn svg { width: 16px; height: 16px; vertical-align: -3px; margin-right: 4px; }
.cpp-need { width: 7px; height: 7px; border-radius: 50%; background: var(--warn); }
/* "Bea wants to add a passkey" (§6a): a hairline row, the key in the accent colour. */
.cpp-ask { display: flex; gap: 10px; align-items: flex-start; flex-wrap: wrap; padding: 10px 0; margin: 6px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.cpp-ask > svg { flex: none; color: var(--warn); margin-top: 2px; }
.cpp-ask .cpp-li { min-width: 200px; }
/* Proposals an agent made (§8a): held, so drawn quieter, with who proposed them. */
.cpp-state.prop { color: var(--text-2); }
.cpp-item.prop .cpp-th, .cpp-item.prop b { opacity: .78; }
.cpp-held { margin-top: 10px; padding-top: 8px; border-top: 1px dashed var(--line); }
.cpp-held > p { display: flex; gap: 6px; align-items: center; margin: 0; color: var(--text-2); }
.cpp-held .cpp-row { gap: 10px; }
.cpp-frombuild { display: grid; gap: 4px; align-self: center; }
.cpp-frombuild select { background: var(--ink-2); border: 1px solid var(--control); border-radius: 4px; padding: 6px 8px; color: var(--text); font: 13px var(--sans); max-width: 200px; }
/* Their page as they see it: the page itself in a frame, phone width on a phone, wider on a desktop. */
.cpp-preview { margin: 10px 0 6px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.cpp-preview iframe { display: block; width: 100%; height: 640px; border: 0; background: transparent; }
@media (max-width: 600px) { .cpp-item { grid-template-columns: 72px minmax(0, 1fr); } .cpp-th { width: 72px; height: 46px; } }
/* Installs (§3): the pick and the Release button under the item, on one line when it fits. */
.cpp-pick { margin-top: 8px; align-items: flex-end; }
.cpp-pick select { max-width: 320px; }

/* Watch it live (CLIENT-PORTAL §5 layer 3): where the app is live on their page. */
.cpp-live { display: flex; align-items: center; gap: 6px; color: var(--text-2); }
.cpp-live svg { width: 14px; height: 14px; flex: none; }
.cpp-live.on { color: var(--text); }
