/* ComponentERP beta, T2794 B1 Companies & contacts records (CR-1..CR-20): styles for ce-crm.js / companies.js / contacts.js. */
/* attributed notes (design record-notes: "Author · date") */
.note-attribution{display:block;color:var(--muted);font-size:11px;margin:4px 0 2px;overflow-wrap:anywhere}
.record-note p{white-space:pre-wrap;margin:6px 0 0;overflow-wrap:anywhere}
.crm-notes .record-note:first-child p{margin-top:0}
.crm-notes{max-height:240px}
.crm-note-flag{display:inline-block;font-size:10px;font-weight:700;letter-spacing:.3px;text-transform:uppercase;color:light-dark(#8e4714,#ffbe91);margin-bottom:2px}
.crm-note-flag:before{content:'★ '}
.record-note.is-priority{border-left:3px solid light-dark(#d89a3a,#ffc75c);padding-left:8px}
.crm-note-meta{margin:0 0 10px;font-size:12px}
/* editable company rating */
.crm-rating{display:inline-flex;gap:0}
.crm-rating button{min-height:0;padding:0 1px;font-size:18px;line-height:1;color:var(--muted);font-weight:400}
.crm-rating button.is-on{color:light-dark(#ad6d00,#ffc75c)}
.crm-rating button:hover:not(:disabled){color:light-dark(#ad6d00,#ffc75c)}
/* domains / aliases as chips */
.crm-chips{list-style:none;margin:0;padding:0;display:flex;flex-wrap:wrap;gap:6px}
.crm-chips li{display:inline-flex;align-items:center;gap:4px;padding:3px 8px;border:1px solid var(--line);border-radius:12px;background:var(--stripe);font-size:12px;max-width:100%;overflow-wrap:anywhere}
.crm-chips .badge{padding:0 4px}
.crm-x{min-height:0;padding:0 2px;font-size:11px;color:var(--muted)}
.crm-x:hover:not(:disabled){color:light-dark(#a92e30,#ffb0b0)}
.crm-flagline{display:flex;flex-wrap:wrap;gap:6px;margin:10px 0 0}
/* dialogs */
.crm-flags{margin-top:12px}
.crm-danger{color:light-dark(#a92e30,#ffb0b0)}
dialog .crm-danger[type=submit]{background:light-dark(#a92e30,#7a2224);border-color:light-dark(#a92e30,#7a2224);color:#fff}
.crm-confirm p{color:var(--text)}
.crm-confirm-check{margin-top:6px;white-space:normal}
.crm-warn{border-left:3px solid light-dark(#d89a3a,#ffc75c);background:var(--stripe);padding:6px 12px;margin-bottom:12px;border-radius:4px}
.crm-warn p{margin:6px 0;font-size:12px}
.crm-pick{display:grid;gap:6px;max-height:300px;overflow:auto;margin-top:10px;padding:2px}
.crm-pick .check{white-space:normal}
.crm-prompt-list{display:grid;gap:8px}
.crm-domains table,.crm-small-table{min-width:0}
.crm-domains td,.crm-domains th{vertical-align:middle}
#crm-autoroute .tablewrap{min-height:0;max-height:240px}
.record-section .crm-small-table{min-width:0}
.record-section .tablewrap:has(.crm-small-table){min-height:0}
/* T2827: page content follows the width #content has (container "main", base.css), not the viewport; the @media copy keeps dialogs/menus outside #content on the viewport */
@container main (max-width:736px){
 .crm-rating button{font-size:22px;padding:2px}
 .crm-pick{max-height:45vh}
}
@media (max-width:760px){.crm-rating button:where(:not(#content *)){font-size:22px;padding:2px}.crm-pick:where(:not(#content *)){max-height:45vh}}
.contact-heading .crm-rating button{font-size:20px}
