/* «Покупатели» in Заказы и обращения (unlayered, like the tidy files). */
.cu-layout { display: grid; grid-template-columns: minmax(300px, 380px) minmax(0, 1fr); gap: 14px; align-items: start; padding: 12px 16px 16px; }
.cu-list { position: sticky; top: 12px; display: flex; flex-direction: column; gap: 8px; min-width: 0; max-height: calc(100vh - 150px); }
.cu-tools { display: flex; gap: 6px; }
.cu-search { position: relative; flex: 1; min-width: 0; }
.cu-search svg { position: absolute; top: 50%; left: 10px; width: 16px; height: 16px; color: #7a848b; transform: translateY(-50%); pointer-events: none; }
.cu-search input { width: 100%; padding-left: 32px !important; }
.cu-tools select { width: 150px; flex: none; }
.cu-filters { display: flex; flex-wrap: wrap; gap: 4px; }
.cu-filters button { min-height: 28px; padding: 0 9px; border: 1px solid #dfe4e7; border-radius: 999px; background: #fff; color: #46525a; font: 600 12px Inter, "Segoe UI", Arial, sans-serif; cursor: pointer; }
.cu-filters button b { margin-left: 2px; color: #7a848b; }
.cu-filters button[aria-pressed="true"] { border-color: #c9470a; background: #fff3ec; color: #c9470a; }
.cu-rows { display: flex; flex-direction: column; gap: 4px; overflow-y: auto; padding-right: 2px; }
.cu-row { display: flex; justify-content: space-between; gap: 10px; width: 100%; padding: 9px 10px; border: 1px solid #e3e6e8; border-radius: 10px; background: #fff; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.cu-row:hover { border-color: #c4ccd1; }
.cu-row[aria-pressed="true"] { border-color: #c9470a; box-shadow: 0 0 0 2px rgba(201, 71, 10, 0.12); }
.cu-row__main { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.cu-row__main b { overflow: hidden; font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }
.cu-row__main small, .cu-row__sum small { color: #5f6972; font-size: 12px; }
.cu-row__sum { display: flex; flex-direction: column; align-items: flex-end; flex: none; text-align: right; }
.cu-row__sum b { font-size: 13px; white-space: nowrap; }
.cu-row__badges { display: flex; flex-wrap: wrap; gap: 4px; }
.cu-row__badges:empty { display: none; }
.cu-badge { display: inline-flex; align-items: center; min-height: 18px; padding: 0 6px; border-radius: 999px; background: #eef1f3; color: #46525a; font-size: 11px; font-weight: 700; }
.cu-badge.is-wholesale { background: #e8f0fb; color: #2759a5; }
.cu-badge.is-discount { background: #fff3ec; color: #c9470a; }
.cu-badge.is-open { background: #fdf3dc; color: #8a5a00; }
.cu-more { align-self: center; margin: 4px 0; }
.cu-empty { margin: 8px 2px; color: #5f6972; font-size: 13px; }
.cu-detail { display: flex; flex-direction: column; gap: 12px; min-width: 0; padding: 16px; border: 1px solid #e3e6e8; border-radius: 12px; background: #fff; }
.cu-placeholder { display: grid; place-items: center; gap: 6px; min-height: 260px; color: #7a848b; }
.cu-placeholder svg { width: 28px; height: 28px; }
.cu-head { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; }
.cu-head h3 { margin: 0 0 2px; font-size: 20px; }
.cu-head p { margin: 0 0 6px; color: #5f6972; font-size: 13px; }
.cu-head .button { flex: none; }
.cu-contacts { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 13px; }
.cu-contacts a, .cu-contacts span { display: inline-flex; align-items: center; gap: 6px; color: #1f262b; text-decoration: none; }
.cu-contacts a:hover { color: #c9470a; }
.cu-contacts svg { width: 15px; height: 15px; color: #7a848b; }
.cu-tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.cu-tile { display: flex; flex-direction: column; gap: 2px; padding: 10px 12px; border: 1px solid #e3e6e8; border-radius: 10px; background: #fafbfb; }
.cu-tile span { color: #5f6972; font-size: 12px; }
.cu-tile b { font-size: 18px; line-height: 1.2; }
.cu-tile small { color: #7a848b; font-size: 11px; }
.cu-profile { display: flex; flex-direction: column; gap: 10px; padding: 12px; border: 1px solid #f0dccf; border-radius: 10px; background: #fffaf6; }
.cu-profile__row { display: flex; flex-wrap: wrap; gap: 12px 24px; align-items: flex-start; }
.cu-check { display: flex; gap: 10px; align-items: flex-start; cursor: pointer; font-size: 13px; }
.cu-check input { margin-top: 2px; }
.cu-check b { display: block; }
.cu-check small { display: block; color: #5f6972; font-size: 12px; }
.cu-field { display: flex; flex-direction: column; gap: 4px; }
.cu-field > span { color: #46525a; font-size: 12px; font-weight: 650; }
.cu-field small { color: #7a848b; font-size: 11px; }
.cu-field--discount input { width: 120px; }
.cu-field textarea { width: 100%; resize: vertical; }
.cu-hint { margin: 0; color: #5f6972; font-size: 12px; }
.cu-profile__foot { display: flex; gap: 12px; align-items: center; }
.cu-profile__foot small { color: #5f6972; font-size: 12px; }
.cu-history { font-size: 12px; color: #46525a; }
.cu-history summary { cursor: pointer; font-weight: 650; }
.cu-history p { margin: 6px 0 0; padding-left: 10px; border-left: 2px solid #e3e6e8; }
.cu-section h4 { margin: 0 0 6px; font-size: 14px; }
.cu-section h4 small { color: #7a848b; font-weight: 600; }
.cu-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.cu-table th { padding: 4px 6px; border-bottom: 1px solid #e3e6e8; color: #5f6972; font-size: 11px; font-weight: 650; text-align: left; text-transform: uppercase; letter-spacing: 0.03em; }
.cu-table td { padding: 6px; border-bottom: 1px solid #f0f2f3; vertical-align: middle; }
.cu-table td small { display: block; color: #7a848b; font-size: 11px; }
.cu-table tr.is-cancelled td { color: #9aa3a9; }
.cu-num { text-align: right; white-space: nowrap; font-weight: 650; }
.cu-paid { display: inline-flex; align-items: center; gap: 4px; color: #22744a; font-size: 12px; font-weight: 650; }
.cu-paid svg { width: 14px; height: 14px; }
.cu-products, .cu-inquiries { display: flex; flex-direction: column; gap: 4px; margin: 0; padding: 0; list-style: none; font-size: 13px; }
.cu-products li { display: flex; justify-content: space-between; gap: 12px; padding: 4px 0; border-bottom: 1px solid #f0f2f3; }
.cu-inquiries li { display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: baseline; padding: 4px 0; border-bottom: 1px solid #f0f2f3; }
.cu-inquiries small { flex-basis: 100%; color: #5f6972; font-size: 12px; }
@media (max-width: 1100px) {
  .cu-layout { grid-template-columns: minmax(0, 1fr); }
  .cu-list { position: static; max-height: 420px; }
  .cu-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 600px) {
  .cu-layout { padding: 8px; }
  .cu-head { flex-direction: column; }
  .cu-table th:nth-child(2), .cu-table td:nth-child(2) { display: none; }
}
.cu-tools select { width: 128px; }
.cu-field textarea { min-height: 84px; height: 96px; font-size: 14px; }
