:root{--pt-brown:#4d842b;--pt-gold:#66a838;--pt-paper:#f6faf2;--pt-line:#a7c98e;--pt-dark:#26331e;--pt-green:#27653d;--pt-red:#963a32}
.pt-shell{max-width:1420px;margin:24px auto;padding:22px;color:var(--pt-dark)}
.pt-head{display:flex;align-items:center;justify-content:space-between;gap:20px;padding:22px;border:1px solid var(--pt-line);border-radius:20px;background:rgba(245,234,215,.96);box-shadow:0 10px 28px #3d271724}.pt-head p{margin:0;color:#795839;font-weight:800;letter-spacing:.12em}.pt-head h1{margin:5px 0}
.pt-head-actions{display:flex;align-items:center;justify-content:flex-end;flex-wrap:wrap;gap:9px}
.pt-tabs{display:flex;flex-wrap:wrap;gap:8px;margin:18px 0}.pt-tabs a,.pt-btn{display:inline-flex;align-items:center;justify-content:center;min-height:40px;padding:9px 14px;border:1px solid #7e552d;border-radius:10px;background:linear-gradient(#9f713e,#6b4724);color:#fff;text-decoration:none;font:inherit;font-weight:750;cursor:pointer}.pt-tabs a.active{background:#412a17;outline:3px solid #a5763f3d}.pt-btn--light{background:#f7eddc;color:#51351d}.pt-btn:disabled{opacity:.5;cursor:not-allowed}
.pt-stats{display:grid;grid-template-columns:repeat(5,1fr);gap:13px}.pt-stats article,.pt-card,.pt-grid a{padding:17px;border:1px solid var(--pt-line);border-radius:16px;background:rgba(245,234,215,.96);box-shadow:0 7px 20px #3d271717}.pt-stats span{display:block;color:#765b43}.pt-stats strong{display:block;margin-top:7px;font-size:1.45rem}.pt-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:14px;margin-top:16px}.pt-grid a{color:inherit;text-decoration:none}.pt-grid h2{margin-top:0}.pt-card{margin:16px 0}.pt-card h2{margin-top:0}.pt-add{display:flex;justify-content:flex-end;margin:15px 0}.pt-alert{padding:12px;border-radius:10px;background:#f7e3d9;border:1px solid #b76b50}
.pt-form{display:grid;grid-template-columns:repeat(3,1fr);gap:13px}.pt-form label{display:grid;gap:5px;font-weight:700}.pt-form .full{grid-column:1/-1}.pt-form input,.pt-form select,.pt-form textarea{box-sizing:border-box;width:100%;padding:10px;border:1px solid #aa865d;border-radius:8px;background:#fffdf8;color:var(--pt-dark);font:inherit}.pt-actions{display:flex;justify-content:flex-end;gap:9px}
.pt-form-section{margin:8px 0 0;padding:9px 12px;border-radius:8px;background:#66a838;color:#fff}.pt-items{display:grid;gap:8px}.pt-item-row{display:grid;grid-template-columns:minmax(260px,4fr) minmax(90px,1fr) minmax(80px,.8fr) minmax(115px,1fr) 34px;gap:7px;align-items:center}.pt-item-row input{min-width:0}.pt-items>[data-pt-add-item]{justify-self:start;margin-top:4px}
.pt-editor-switch{display:flex;align-items:center;justify-content:center;flex-wrap:wrap;gap:8px;margin:18px 0}.pt-editor-switch>span:first-child{font-weight:800}.pt-type-choice{padding:9px 20px;border:1px solid #66a838;border-radius:99px;background:#f6faf2;color:#315d22;text-decoration:none;font-weight:800}.pt-type-choice.active{background:#66a838;color:#fff}
.pt-document-editor{box-sizing:border-box;width:min(100%,210mm);margin:16px auto;padding:13mm 12mm;border:1px solid #a7c98e;background:#fff;box-shadow:0 12px 36px #20381735;color:#1f281b}.pt-editor-identity{display:flex;align-items:center;justify-content:space-between;gap:20px;margin-bottom:16px;color:#4d842b}.pt-editor-identity img{width:112px;height:auto}.pt-editor-identity>div{display:grid;text-align:right}.pt-editor-identity strong{font-size:1.12rem}.pt-editor-identity span{font-size:.88rem}.pt-document-editor>h2{margin:0 0 12px;padding:17px;background:#66a838;color:#fff;text-align:center;text-transform:capitalize;font-size:2rem}.pt-editor-help,.pt-editor-note{margin:0;padding:9px 12px;border-left:4px solid #66a838;background:#eef6e9}.pt-editor-form{margin-top:10px}.pt-editor-form .pt-form-section{text-align:center;text-transform:none;border-radius:0}.pt-editor-form input,.pt-editor-form select,.pt-editor-form textarea{border-color:#a7c98e;background:#fbfdf9}.pt-editor-form textarea{line-height:1.45}.pt-editor-actions{position:sticky;bottom:8px;padding:12px;border:1px solid #a7c98e;border-radius:10px;background:#fffffff2;box-shadow:0 5px 20px #20381730}
.pt-table-wrap{overflow:auto}.pt-table-wrap table{width:100%;min-width:880px;border-collapse:collapse}.pt-table-wrap th,.pt-table-wrap td{padding:10px;border-bottom:1px solid #c6a57780;text-align:left;vertical-align:middle}.pt-table-wrap th{background:#ddc7a2}.pt-table-wrap td small{display:block;color:#795f48}.pt-row-actions{display:flex;align-items:center;flex-wrap:wrap;gap:5px}.pt-mini{display:inline-flex;padding:5px 8px;border:1px solid #80552c;border-radius:7px;background:#f8edda;color:#4c3018;text-decoration:none;font:inherit;font-size:.82rem;cursor:pointer}.pt-inline{display:inline}.pt-delete{width:30px;height:30px;border:0;border-radius:7px;background:var(--pt-red);color:#fff;font-size:1.2rem;cursor:pointer}
.pt-info{position:relative;width:30px;height:30px;border:0;border-radius:50%;background:var(--pt-brown);color:#fff;font-weight:900;cursor:help}.pt-info [role=tooltip]{display:none;position:absolute;z-index:30;right:0;top:35px;width:260px;padding:11px;border-radius:9px;background:#2e2017;color:#fff;text-align:left;font-weight:400}.pt-info:hover [role=tooltip],.pt-info:focus [role=tooltip]{display:block}.pt-muted{color:#80664e}
.pt-status{display:inline-block;padding:4px 8px;border-radius:99px;background:#e5d5bc;font-weight:800;font-size:.82rem}.pt-status--paye,.pt-status--accepte{background:#d8efdf;color:var(--pt-green)}.pt-status--impaye,.pt-status--refuse{background:#f3dcd8;color:var(--pt-red)}
.pt-journal{margin-top:18px}.pt-journal table{min-width:760px}.pt-journal td{white-space:nowrap}.pt-journal td:nth-child(3){width:100%;white-space:normal}.pt-journal-income{color:#173f78;font-weight:800}.pt-journal-expense{color:var(--pt-red);font-weight:800}.pt-status--enregistree{background:#e7edf5;color:#334f70}
.pt-dialog{width:min(900px,calc(100vw - 30px));max-height:88vh;overflow:auto;padding:20px;border:1px solid var(--pt-line);border-radius:16px;background:var(--pt-paper);color:var(--pt-dark)}.pt-dialog::backdrop{background:#21170faa;backdrop-filter:blur(3px)}.pt-dialog-head{display:flex;align-items:center;justify-content:space-between;margin-bottom:16px}.pt-dialog-head h2{margin:0}.pt-dialog-head button{width:36px;height:36px;border:0;border-radius:50%;background:var(--pt-brown);color:#fff;font-size:1.4rem;cursor:pointer}
.pt-print-body{margin:0;background:#d7d1c8;color:#1f1b17;font:15px/1.45 Georgia,serif}.pt-print-tools{position:sticky;top:0;z-index:2;display:flex;justify-content:center;gap:10px;padding:10px;background:#33251c}.pt-print-tools button{padding:9px 14px;border:0;border-radius:7px;cursor:pointer}.pt-paper{box-sizing:border-box;width:210mm;min-height:297mm;margin:18px auto;padding:18mm;background:#fff;box-shadow:0 4px 25px #0004}.pt-paper-head,.pt-paper-parties,.pt-signatures{display:grid;grid-template-columns:1fr 1fr;gap:25px}.pt-paper-head{padding-bottom:16px;border-bottom:2px solid var(--pt-brown)}.pt-paper-head>div:last-child{text-align:right}.pt-paper h1,.pt-paper h2,.pt-paper h3{color:var(--pt-brown)}.pt-paper p{margin:4px 0}.pt-paper-parties{margin:22px 0;padding:14px;background:#f7f1e8}.pt-paper-description{white-space:normal}.pt-paper-totals{width:100%;margin-top:22px;border-collapse:collapse}.pt-paper-totals th,.pt-paper-totals td{padding:9px;border:1px solid #bda98e;text-align:left}.pt-paper-summary{width:300px;margin:12px 0 20px auto}.pt-paper-summary p{display:flex;justify-content:space-between}.pt-paper-summary .total{padding-top:8px;border-top:2px solid var(--pt-brown);font-size:1.1rem}.pt-signatures{margin-top:35px}.pt-signatures>div{min-height:90px;padding:12px;border:1px solid #bda98e}
@media(max-width:900px){.pt-stats{grid-template-columns:repeat(2,1fr)}.pt-form{grid-template-columns:repeat(2,1fr)}.pt-item-row{grid-template-columns:minmax(180px,3fr) 1fr 1fr 1fr 34px}}
@media(max-width:620px){.pt-shell{padding:10px}.pt-head{align-items:flex-start;flex-direction:column}.pt-head-actions{width:100%;justify-content:stretch}.pt-head-actions .pt-btn{width:100%}.pt-grid,.pt-form{grid-template-columns:1fr}.pt-stats{grid-template-columns:1fr 1fr}.pt-add .pt-btn{width:100%}.pt-item-row{grid-template-columns:1fr 1fr}.pt-item-row input:first-child{grid-column:1/-1}.pt-item-row .pt-delete{justify-self:end}.pt-document-editor{padding:18px 12px}.pt-editor-identity img{width:80px}.pt-editor-identity span{font-size:.72rem}.pt-editor-actions{position:static}}
@media print{.pt-print-tools{display:none}.pt-print-body{background:#fff}.pt-paper{width:auto;min-height:0;margin:0;padding:12mm;box-shadow:none}@page{size:A4;margin:0}}

.pt-task-doc{display:flex;align-items:center;flex-wrap:nowrap;gap:8px;margin:6px 0;max-width:100%;overflow-x:auto}.pt-task-doc strong,.pt-task-doc a{flex:0 0 auto;white-space:nowrap}
