.team-ledger-wrap { max-width: 1180px; }
.team-ledger-heading,.team-ledger-actions { display:flex; align-items:center; justify-content:space-between; gap:12px; flex-wrap:wrap; }
.team-ledger-summary { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:12px; margin:16px 0; }
.team-ledger-summary article { padding:18px; border:1px solid #d7e1ee; background:#fff; border-radius:14px; }
.team-ledger-summary span,.team-ledger-summary strong { display:block; }
.team-ledger-summary strong { font-size:26px; margin-top:8px; overflow-wrap:anywhere; }
.team-ledger-filters { display:grid; grid-template-columns:1fr 1fr; gap:12px; margin:16px 0; }
.team-ledger-wrap label { display:grid; gap:6px; font-weight:700; }
.team-ledger-wrap input,.team-ledger-wrap select,.team-ledger-wrap textarea { box-sizing:border-box; width:100%; min-width:0; min-height:44px; padding:10px; border:1px solid #b8c8dc; border-radius:8px; font:inherit; background:white; color:#142235; }
.team-ledger-table { width:100%; border-collapse:collapse; table-layout:fixed; }
.team-ledger-table th,.team-ledger-table td { text-align:left; padding:12px 8px; border-bottom:1px solid #d7e1ee; overflow-wrap:anywhere; }
.team-ledger-table th { background:#edf3fa; }
.team-ledger-table td:last-child { text-align:right; }
.team-ledger-row-edit { background:none; border:0; padding:4px 0; color:#174dcc; text-align:left; font:inherit; cursor:pointer; text-decoration:underline; }
.team-ledger-in { color:#08764c; }
.team-ledger-out { color:#b42318; }
.team-ledger-auto { display:inline-block; background:#e5efff; color:#164fb5; border-radius:12px; padding:2px 8px; font-size:12px; margin-left:6px; }
.team-ledger-dialog { width:min(580px,calc(100% - 32px)); box-sizing:border-box; border:1px solid #c4d4e7; border-radius:16px; padding:24px; max-height:90dvh; overflow-y:auto; }
.team-ledger-dialog::backdrop { background:rgba(15,23,42,.55); }
.team-ledger-form { display:grid; gap:14px; }
.team-ledger-dialog label { display:grid; gap:5px; font-weight:700; }
.team-ledger-dialog input,.team-ledger-dialog select,.team-ledger-dialog textarea { width:100%; min-height:44px; box-sizing:border-box; padding:10px; border:1px solid #b8c8dc; border-radius:8px; font:inherit; }
.team-ledger-dialog [hidden],.team-ledger-wrap [hidden] { display:none !important; }
.team-ledger-error { color:#b42318; white-space:pre-wrap; }
.team-ledger-settings { display:grid; gap:12px; margin-top:16px; }
.team-ledger-pool-setting { display:grid; grid-template-columns:minmax(0,1fr) 180px auto; gap:12px; align-items:end; border-bottom:1px solid #d7e1ee; padding:14px 0; }
.team-ledger-pool-setting label:first-child { display:flex; align-items:center; flex-wrap:wrap; }
.team-ledger-pool-setting input[type=checkbox] { width:22px; min-height:22px; }
.ledger-payout-shortcut { display:inline-block; margin:4px 6px; font-size:12px; color:#174dcc; }
.ledger-paid-marker { color:#08764c; font-weight:700; margin:4px 6px; }
@media(max-width:650px) {
 .team-ledger-wrap { width:auto; margin:12px; padding:0; }
 .team-ledger-wrap .card { padding:14px; }
 .team-ledger-summary { grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px; }
 .team-ledger-summary article { padding:12px; }
 .team-ledger-summary strong { font-size:22px; }
 .team-ledger-table,.team-ledger-table tbody { display:block; }
 .team-ledger-table thead { display:none; }
 .team-ledger-table tr { display:grid; grid-template-columns:minmax(0,1fr) auto; padding:12px 0; border-bottom:1px solid #d7e1ee; gap:4px 8px; }
 .team-ledger-table td { display:block; border:0; padding:0; font-size:13px; }
 .team-ledger-table td:nth-child(3) { grid-column:1; grid-row:1; font-size:16px; }
 .team-ledger-table td:nth-child(5) { grid-column:2; grid-row:1; font-size:16px; }
 .team-ledger-table td:nth-child(1) { grid-column:1; grid-row:2; }
 .team-ledger-table td:nth-child(2) { grid-column:1 / -1; grid-row:3; }
 .team-ledger-table td:nth-child(4) { grid-column:1 / -1; grid-row:4; }
 .team-ledger-dialog { width:100%; max-width:100%; height:100dvh; max-height:100dvh; margin:0; border-radius:0; padding:20px; }
 .team-ledger-pool-setting { grid-template-columns:1fr; }
}
