/* 共通レイアウトは ../shared/intake.css。請求書固有の原本・支払い予定表だけを補う。 */
.invoice-demo{overflow-anchor:none}
.invoice-demo #review-title,.invoice-demo #output-title{scroll-margin-top:12px}
.invoice-demo #review-list h3{font-size:14px;margin:0 0 8px}
.invoice-demo #review-list>p{font-size:12px}
.invoice-demo #review-list #filter-note{margin:8px 0}
.invoice-demo #rows .property-values{white-space:normal}
.invoice-demo .empty-list{padding:12px!important;font-size:13px}
.invoice-demo .source-card{margin:0 0 14px}
.invoice-demo .source-caption{font-weight:600;font-size:13px;margin:0 0 6px}
.invoice-demo .source .paper-button{border:0;padding:0;background:transparent;width:100%;font-size:12px;text-align:left;font-weight:400}
.invoice-demo .source .paper-button img{margin-top:6px}
.paper{display:block;position:relative}.highlight{position:absolute;left:6%;width:83%;background:#ffe15970;pointer-events:none}.highlight-bank{top:85.5%;height:2.8%}.highlight-total{top:31.1%;height:3.9%}.highlight-number{left:56%;width:38%;top:17.4%;height:2.8%}.paper[data-invoice="i2"] .highlight-total,.paper[data-invoice="i8"] .highlight-total{left:42%;width:42%;top:34.5%;height:5.6%}.paper[data-page="2"] .highlight{display:none}
.invoice-demo .attachment .paper-button{padding:0;border:0;background:transparent;font-size:12px;text-align:left}
.invoice-demo .attachment .paper-button img{margin:0}
.invoice-demo .mail-time{flex:0 0 88px;white-space:nowrap}
.invoice-demo .comparison{min-width:0;padding:10px;margin:0}
.invoice-demo .comparison h4{font-size:14px}
.invoice-demo .comparison p{font-size:12px;line-height:1.5;margin:6px 0}
.invoice-demo .comparison .duplicate-compare{font-size:13px}
.invoice-demo .comparison .duplicate-compare th,.invoice-demo .comparison .duplicate-compare td{min-width:0;padding:7px 9px;white-space:normal}
.invoice-demo .comparison .duplicate-compare tr>:first-child{width:5em}
.invoice-demo .comparison-options{gap:5px;flex-wrap:nowrap}
.invoice-demo .comparison-options button{flex:1;min-width:0;white-space:normal;font-size:12px;padding:6px;margin:0}
.invoice-demo .comparison-options [aria-pressed="true"]{background:#17382f;color:#fff;border-color:#17382f}
.invoice-demo .reason{font-size:12px;line-height:1.5;margin:8px 0;padding:6px 8px}
.invoice-demo .reason .status{margin:0}
.invoice-demo .detail-foot{margin:0}
.invoice-demo .detail-meta{flex-wrap:wrap}
.invoice-demo .confirm-error{grid-column:1/-1;margin:0;padding:6px 10px;border-left:4px solid #b4471c;background:#fff3ec;color:#7a2e10;font-size:13px}
.invoice-demo .review-details{margin-top:12px;font-size:13px}
.invoice-demo .review-details summary{font-size:12px}
.invoice-demo .values{display:grid;grid-template-columns:1fr 1.4fr;margin:8px 0;font-size:13px}
.invoice-demo .values dt,.invoice-demo .values dd{padding:7px;margin:0;border-bottom:1px solid var(--line);overflow-wrap:anywhere}
.invoice-demo .checks{padding-left:18px}.invoice-demo .checks li{margin:7px 0}.good{color:#165136}.warn-text{color:#835619}
.invoice-demo .totals-list{display:flex;gap:8px;flex-wrap:wrap}
.invoice-demo .total{border:1px solid var(--line);border-radius:8px;background:#fff;padding:8px 14px;font-size:13px}
.invoice-demo .total strong{display:block;font-size:16px}
.invoice-demo #totals{margin:8px 0 14px}
.invoice-demo #totals-note{font-size:13px;margin:4px 0 8px}
.invoice-demo #output-area>h3{font-size:18px;margin:12px 0 4px}
/* 先頭4列で、いつ・どこに・いくらを表示。詳細だけを右に送る。 */
.invoice-demo .sheet-window{margin-top:8px}
.invoice-demo .sheet-toolbar{font-size:13px;line-height:1.5}
.invoice-demo .sheet-window table{min-width:2980px;table-layout:fixed;font-size:13px}
.invoice-demo .sheet th,.invoice-demo .sheet td{padding:12px;white-space:normal;min-width:0;overflow-wrap:anywhere}
.invoice-demo #sheet-table thead th:nth-child(1){width:210px}.invoice-demo #sheet-table thead th:nth-child(2){width:210px}.invoice-demo #sheet-table thead th:nth-child(3){width:240px}.invoice-demo #sheet-table thead th:nth-child(4){width:170px}
.invoice-demo #sheet-table thead th:nth-child(6){width:250px}.invoice-demo #sheet-table thead th:nth-last-child(2){width:350px}.invoice-demo #sheet-table thead th:last-child{width:120px}
.invoice-demo #sheet-table [data-key="total"],.invoice-demo #sheet-table [data-key^="net"],.invoice-demo #sheet-table [data-key^="tax"]{text-align:right}
.invoice-demo #sheet-table [data-key="total"]{font-size:15px;font-weight:700;white-space:nowrap}
.invoice-demo .sheet-added td:first-child::before{content:none}
.invoice-demo .added-label{display:table;margin-top:6px;padding:2px 5px;border:1px solid #779566;border-radius:4px;font-size:11px;color:#245815}
.invoice-demo .date-adjustment{font-size:11px;line-height:1.6;color:#525c55}
.invoice-demo #sheet-table .date-subtotal{background:#edf3ef;font-weight:700}.invoice-demo #sheet-table .date-subtotal td{text-align:right}
.invoice-demo [data-holiday]{font:inherit;padding:7px;min-height:44px;border:1px solid #9dad9f;border-radius:5px;background:#fff}
@media(max-width:1100px){.invoice-demo #detail{padding:0;border:0}.invoice-demo #review-list>.table-wrap{max-height:30dvh;overflow:auto}.invoice-demo .detail-head{scroll-margin-top:var(--review-progress-height,43px)}}
@media(max-width:600px){
  .invoice-demo .mail-heading{flex-basis:calc(100% - 126px)}
  .invoice-demo .detail-meta{flex-wrap:wrap}
  .invoice-demo .detail-meta .actions{margin-left:auto}
  .invoice-demo .detail-meta .read-attempt{font-size:10px}
  .invoice-demo .comparison{padding:6px}
  .invoice-demo .comparison h4{font-size:13px}
  .invoice-demo .comparison p{font-size:11px;margin:4px 0}
  .invoice-demo .comparison .duplicate-compare{font-size:12px}
  .invoice-demo .comparison .duplicate-compare th,.invoice-demo .comparison .duplicate-compare td{padding:5px 6px}
  .invoice-demo .comparison .duplicate-compare thead th{font-size:12px}
  .invoice-demo .comparison .duplicate-compare tr>:first-child{width:4.5em}
  .invoice-demo .comparison-options button{font-size:11px}
  .invoice-demo .footer-main{flex-wrap:nowrap}
  .invoice-demo .footer-main .review-check{white-space:normal}
  .invoice-demo #rows{display:table;table-layout:fixed;width:100%}.invoice-demo #rows tbody{display:table-row-group}
  .invoice-demo #totals .total{flex:1;min-width:145px}
}

/* 不動産のモバイル一覧と同じく、1件を1つのまとまりにする。 */
@media(max-width:600px){
 .invoice-demo .sheet-window table{display:block;min-width:0;table-layout:auto}
 .invoice-demo #sheet-table thead{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}
 .invoice-demo #sheet-table tbody{display:block}
 .invoice-demo #sheet-table .payment-row{display:grid;grid-template-columns:minmax(0,1fr) auto;border-bottom:2px solid #aebdb4}
 .invoice-demo #sheet-table .payment-row td:not([data-key="transferDate"],[data-key="vendor"],[data-key="bank"],[data-key="total"],[data-key="content"]){display:none}
 .invoice-demo #sheet-table .payment-row [data-key="transferDate"]{grid-column:1;grid-row:1}
 .invoice-demo #sheet-table .payment-row [data-key="total"]{grid-column:2;grid-row:1;text-align:right}
 .invoice-demo #sheet-table .payment-row [data-key="vendor"],.invoice-demo #sheet-table .payment-row [data-key="bank"],.invoice-demo #sheet-table .payment-row [data-key="content"]{grid-column:1/-1;padding-top:4px;padding-bottom:4px}
 .invoice-demo #sheet-table td{display:block;min-width:0;width:auto;border:0;padding:8px 12px;text-align:left;white-space:normal}
 .invoice-demo #sheet-table .payment-row td::before{content:attr(data-label);display:block;font-size:11px;font-weight:400;color:#525c55;margin-bottom:3px}
 .invoice-demo #sheet-table .payment-row td:first-child::before{content:'振込予定日'}
 .invoice-demo #sheet-table [data-key="transferDate"]{font-size:18px}
 .invoice-demo #sheet-table [data-key="total"]{font-size:18px}
 .invoice-demo #sheet-table .payment-row [data-key="content"]{padding-bottom:12px}
 .invoice-demo #sheet-table [data-key="vendor"] .added-label{display:inline-block;margin:0 0 0 6px}
 .invoice-demo #sheet-table .date-subtotal{display:flex;justify-content:space-between;align-items:center;padding:10px 0}
 .invoice-demo #sheet-table .date-subtotal th{white-space:normal;padding:8px 12px}
 .invoice-demo #sheet-table .date-subtotal td:last-child{display:none}
}

/* 振込直前に見る欄に、確認済みでも変更の印を残す。 */
.invoice-demo .bank-warning{display:block;margin-top:5px;padding:3px 5px;background:#fff0be;color:#684500;border:1px solid #a77715;border-radius:4px;font-size:11px}
.invoice-demo #sheet-table .bank-subtotal td{text-align:left;background:#f3f6f4;font-size:12px}
.invoice-demo .bank-subtotal small{display:block;color:#525c55}
.invoice-demo .grand-total{border:2px solid #17382f;background:#edf3ef}
.invoice-demo .date-adjustment{display:block;white-space:normal;overflow-wrap:anywhere;text-align:left;min-height:44px;max-width:100%;margin:6px 0 0;padding:6px;border:1px solid #799684;border-radius:5px;background:#f3f7f4;color:#214d36;text-decoration:underline;text-underline-offset:3px;font-weight:500}
.invoice-demo #vendor-settings-link{display:inline-block;min-height:44px;padding:10px 0}
.invoice-demo #vendor-dialog{width:min(1080px,calc(100% - 24px));max-width:calc(100% - 24px);max-height:90dvh;box-sizing:border-box;padding:20px;border:1px solid #799684;border-radius:12px;overflow:auto;color:#21382b;background:#fff}
.invoice-demo #vendor-dialog::backdrop{background:#102b23aa}
.invoice-demo .vendor-bar{display:flex;align-items:flex-start;gap:12px;justify-content:space-between;position:sticky;top:-20px;z-index:1;background:#fff;padding:10px 0}
.invoice-demo .vendor-bar h2{font-size:20px;margin:0}
.invoice-demo #vendor-close{min-height:44px;flex-shrink:0}
.invoice-demo #vendor-dialog p{font-size:13px;line-height:1.7}
.invoice-demo .vendor-table-wrap{overflow:auto}
.invoice-demo #vendors-popup{width:100%;font-size:13px}
.invoice-demo #vendors-popup th,.invoice-demo #vendors-popup td{white-space:normal;min-width:0;padding:10px}
.invoice-demo .vendor-current{background:#eef6e6;outline:3px solid #557b30;outline-offset:-3px}
.invoice-demo :is(.date-adjustment,[data-holiday],#vendor-close,#vendor-settings-link):focus-visible{outline:3px solid #246dba;outline-offset:3px}
@media(max-width:600px){
 .invoice-demo #vendor-dialog{padding:12px}
 .invoice-demo .vendor-bar{top:-12px}
 .invoice-demo .vendor-bar h2{font-size:17px}
 .invoice-demo #vendors-popup,.invoice-demo #vendors-popup tbody{display:block}
 .invoice-demo #vendors-popup thead{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}
 .invoice-demo #vendors-popup tr{display:block;padding:10px;border-bottom:1px solid #aebdb4}
 .invoice-demo #vendors-popup td{display:block;padding:4px 6px;border:0;overflow-wrap:anywhere}
 .invoice-demo #vendors-popup td::before{content:attr(data-label);display:block;font-size:11px;color:#525c55}
 .invoice-demo #vendors-popup select{width:100%}
 .invoice-demo #sheet-table .date-subtotal{width:100%;border-bottom:1px solid #aebdb4}
 .invoice-demo #sheet-table .date-subtotal th{border:0;flex:1;min-width:0}
 .invoice-demo #sheet-table .bank-subtotal{display:block;width:100%}
 .invoice-demo #sheet-table .bank-subtotal td{width:100%;box-sizing:border-box}
 .invoice-demo #sheet-table .payment-row{grid-template-columns:minmax(0,1fr) 116px}
 .invoice-demo #sheet-table .payment-row [data-key="transferDate"]{padding-right:0}
 .invoice-demo #sheet-table .date-adjustment{font-size:12px}
}

/* 初期設定から振込予定日が変わった行だけに表示。読み上げにも残す。 */
.invoice-demo .date-change{display:block;margin-top:5px;padding:3px 5px;background:#fff0be;color:#684500;border:1px solid #a77715;border-radius:4px;font-size:12px;white-space:normal;overflow-wrap:anywhere}
