/* ==== Culminans.Sales: 販売管理の画面スタイル（全画面に読み込む） ==== */

/* フォームの2列グリッド（ダイアログ・伝票ヘッダ） */
/* フォームグリッド・カードはモジュール共通（シェルの app.css: alt-form-grid / alt-span2 / alt-card / alt-card-title）。 */

/* 設定・伝票ヘッダのカード */
.sales-readonly { padding: 4px 0; min-height: 1.6em; }

/* 明細表 */
.sales-lines { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.sales-lines th, .sales-lines td { padding: 4px 6px; border-bottom: 1px solid var(--alt-border); text-align: left; vertical-align: middle; }
.sales-lines th { color: var(--alt-text-sub); font-weight: 600; font-size: 0.85rem; }
.sales-num { text-align: right !important; white-space: nowrap; }

/* 合計欄 */
.sales-totals { margin: 0.8rem 0; text-align: right; display: flex; flex-direction: column; gap: 2px; }
.sales-total { font-size: 1.15rem; font-weight: 700; }

/* 状態バッジ（意味色固定） */
.sales-status { display: inline-block; padding: 1px 8px; border-radius: 999px; font-size: 0.8rem; white-space: nowrap; }
.sales-status-draft { background: #f3f4f6; color: #374151; }
.sales-status-pendingapproval { background: #dbeafe; color: #1d4ed8; }
.sales-status-approved { background: #dcfce7; color: #15803d; }
.sales-status-rejected { background: #fee2e2; color: #b91c1c; }
.sales-status-open { background: #e0f2fe; color: #0369a1; }
.sales-status-ordered, .sales-status-recorded, .sales-status-invoiced { background: #ede9fe; color: #6d28d9; }
.sales-status-issued { background: #dcfce7; color: #15803d; }
.sales-status-partiallypaid { background: #fef3c7; color: #b45309; }
.sales-status-paid { background: #dcfce7; color: #15803d; }
.sales-status-cancelled { background: #f3f4f6; color: #6b7280; }

/* 明細下のツール列（行追加・テンプレート挿入） */
.sales-line-tools { justify-content: flex-start; align-items: center; gap: 8px; }
.sales-template-pick { width: 260px; }

/* 販売設定: 帳票ロゴのプレビュー */
.sales-logo-preview { display: flex; align-items: center; gap: 12px; margin-bottom: 6px; }
.sales-logo-preview img { max-height: 48px; max-width: 240px; }
