/* Isolated Ticket & Statement workspace. Existing navigation and pages keep their styles. */
#ticket-statement{color:#142443;min-width:0;width:100%}
#ticket-statement *{box-sizing:border-box}
#ticket-statement .ts-workspace{width:100%;max-width:none;margin:0;container-type:inline-size;min-width:0;font:14px/1.5 Inter,ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif}
#ticket-statement .ts-header{margin:0 0 15px}
#ticket-statement .ts-header h1{margin:0 0 2px;font-size:clamp(28px,1.8vw,36px);line-height:1.3;font-weight:800;letter-spacing:-.6px;color:#101d3b}
#ticket-statement .ts-header p{margin:0;color:#6c788d;font-size:15px}
#ticket-statement .ts-icon,.nav-link[data-view=ticket-statement] svg{display:inline-block;width:20px;height:20px;vertical-align:middle;flex:none}
#ticket-statement .ts-pdf-icon{display:block;width:34px;height:41px;flex:none;filter:drop-shadow(0 2px 3px #e62d4220)}
#ticket-statement .ts-upload-grid{display:grid;grid-template-columns:1fr 1.05fr;gap:13px;align-items:stretch}
#ticket-statement .ts-upload-card,#ticket-statement .ts-filters,#ticket-statement .ts-summaries>article{min-width:0;border:1px solid #e5ebf4;border-radius:11px;background:#ffffffed;box-shadow:0 3px 14px #214f822f}
#ticket-statement .ts-upload-card{padding:16px 16px 17px;min-height:174px}
#ticket-statement .ts-upload-card>header{display:flex;align-items:flex-start;gap:12px;margin-bottom:16px;min-width:0}
#ticket-statement .ts-upload-card>header>div{flex:1;min-width:0}
#ticket-statement .ts-step{display:grid;place-items:center;flex:none;width:35px;height:35px;border-radius:50%;background:linear-gradient(135deg,#e3efff,#d5edfc);color:#1769dd;font-size:19px;font-weight:700}
#ticket-statement h2{margin:0;color:#192b49;font-size:16px;line-height:1.4;font-weight:750}
#ticket-statement .ts-upload-card header p{margin:2px 0 0;color:#708096;font-size:12px;line-height:1.5}
#ticket-statement button,#ticket-statement input,#ticket-statement select{font-family:inherit}
#ticket-statement button{cursor:pointer}
#ticket-statement button:disabled{opacity:.5;cursor:not-allowed}
#ticket-statement .ts-outline,#ticket-statement .ts-source-link{display:inline-flex;align-items:center;justify-content:center;gap:7px;min-height:34px;padding:7px 11px;border:1px solid #6b9bdb;border-radius:5px;background:#fff;color:#1965c7;font-size:12px;font-weight:600;line-height:1.3;text-decoration:none;white-space:normal}
#ticket-statement .ts-outline:hover:not(:disabled),#ticket-statement .ts-source-link:hover:not(:disabled){background:#eff6ff;border-color:#1762ce}
#ticket-statement .ts-outline .ts-icon,#ticket-statement .ts-source-link .ts-icon{width:16px;height:16px}
#ticket-statement .ts-file-row{position:relative;display:flex;align-items:center;gap:12px;min-width:0;padding:10px 12px;margin-top:8px;border:1px solid #e4e9f1;border-radius:6px;background:#fff}
#ticket-statement .ts-file-info{flex:1;min-width:0}
#ticket-statement .ts-file-info strong{display:block;color:#1d2f4f;font-size:12px;line-height:1.5;font-weight:650;overflow-wrap:anywhere}
#ticket-statement .ts-file-info small{display:block;margin-top:2px;color:#7d8899;font-size:11px;line-height:1.4}
#ticket-statement .ts-passenger-badge{flex:none;padding:3px 9px;border-radius:16px;background:#e8f2ff;color:#2570cb;font-size:11px;white-space:nowrap}
#ticket-statement .ts-file-state{display:grid;place-items:center;flex:none;width:23px;height:23px;border-radius:50%;background:#fff2db;color:#a05b08;font-weight:800}
#ticket-statement .ts-file-state.is-ready{background:#daf3e8;color:#258362}
#ticket-statement .ts-file-state.is-reading{background:#e8f1ff;color:#2874d7}
#ticket-statement .ts-file-state .ts-icon{width:15px;height:15px}
#ticket-statement .ts-file-menu{position:relative;flex:none}
#ticket-statement .ts-file-menu summary{display:grid;place-items:center;width:26px;min-height:32px;font-size:22px;line-height:1;color:#46617e;cursor:pointer;list-style:none}
#ticket-statement .ts-file-menu summary::-webkit-details-marker{display:none}
#ticket-statement .ts-file-menu>div{position:absolute;right:0;top:35px;z-index:20;display:grid;width:154px;padding:5px;border:1px solid #d9e4f4;border-radius:8px;background:#fff;box-shadow:0 8px 20px #1b3b652b}
#ticket-statement .ts-file-menu button{min-height:36px;padding:6px 10px;text-align:left;border:0;border-radius:4px;background:#fff;color:#245182;font-size:12px}
#ticket-statement .ts-file-menu button:hover{background:#eef5ff}
#ticket-statement .ts-file-menu [data-ts-remove]{color:#b03043}
#ticket-statement .ts-empty-upload{display:flex;align-items:center;justify-content:flex-start;gap:16px;width:100%;min-height:76px;padding:14px;border:1px dashed #bfcee3;border-radius:7px;background:#f9fcff;color:#2968b5;text-align:left;font-size:13px}
#ticket-statement .ts-empty-upload small{display:block;margin-top:3px;color:#7b8ba3;font-size:11px}
#ticket-statement .ts-empty-tickets{margin:23px 0 10px;color:#8a97aa;font-size:12px;text-align:center}
#ticket-statement .ts-filters{margin:12px 0;padding:14px 18px 10px}
#ticket-statement .ts-filter-fields{display:grid;grid-template-columns:1fr 1fr 1.08fr;gap:24px;align-items:start}
#ticket-statement .ts-filter-fields label{display:block;min-width:0;margin:0;color:#273755;font-size:12px;font-weight:650}
#ticket-statement .ts-filter-fields input{display:block;width:100%;min-width:0;height:38px;margin-top:5px;padding:7px 12px;border:1px solid #d9e0eb;border-radius:5px;background:#fff;color:#263c5d;font-size:14px;font-weight:400;box-shadow:0 1px 2px #1a3c5710 inset}
#ticket-statement .ts-filter-fields small{display:block;margin-top:4px;font-size:10px;font-weight:400;color:#8592a4;line-height:1.4}
#ticket-statement .ts-optional{font-weight:400}
#ticket-statement .ts-primary{display:flex;align-items:center;justify-content:center;gap:12px;min-height:41px;margin-top:21px;padding:10px 13px;border:1px solid #1667e4;border-radius:5px;background:linear-gradient(180deg,#146ef4,#1154d4);color:white;font-size:13px;font-weight:650;box-shadow:0 2px 5px #1c61c21f}
#ticket-statement .ts-primary:hover:not(:disabled){background:#1052c8}
#ticket-statement .ts-primary .ts-icon{width:19px;height:19px}
#ticket-statement .ts-filter-help{display:flex;align-items:flex-start;gap:8px;margin:7px 0 0;color:#7c899a;font-size:11px;line-height:1.5}
#ticket-statement .ts-filter-help .ts-icon{width:16px;height:16px}
#ticket-statement .ts-filter-fields .ts-field-error{color:#bb3044}
#ticket-statement .ts-notice{padding:7px 2px;font-size:12px;color:#46735d;line-height:1.6}
#ticket-statement .ts-notice.ts-error{color:#b43c40}
#ticket-statement .ts-summaries{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px;margin:13px 0}
#ticket-statement .ts-summaries>article{display:flex;align-items:center;gap:14px;min-height:81px;padding:14px 18px}
#ticket-statement .ts-summary-icon{display:grid;place-items:center;flex:none;width:45px;height:45px;border-radius:50%;background:linear-gradient(120deg,#f5f9ff,#edf4fd);color:#45638c}
#ticket-statement .ts-summary-icon .ts-icon{width:24px;height:24px}
#ticket-statement .ts-summaries article>div{min-width:0}
#ticket-statement .ts-summaries strong{display:block;font-size:26px;line-height:1.25;color:#142443;font-weight:800}
#ticket-statement .ts-summaries article>div>span{display:block;margin-top:2px;color:#6f7f96;font-size:12px;line-height:1.5;overflow-wrap:anywhere}
#ticket-statement .ts-missing{margin-top:12px;padding:17px 17px 14px;border:1px solid #ed8b94;border-left:6px solid #f1394d;border-radius:7px;background:linear-gradient(100deg,#fff8f8,#fff3f5);box-shadow:0 2px 8px #bd213c08}
#ticket-statement .ts-missing-top{display:flex;align-items:flex-start;gap:18px}
#ticket-statement .ts-alert-mark{display:grid;place-items:center;flex:none;width:34px;height:34px;border-radius:50%;background:#e42f3d;color:white;font-size:25px;font-weight:700;line-height:1}
#ticket-statement .ts-missing-top>div{flex:1;min-width:0}
#ticket-statement .ts-missing h2{color:#b73037;font-size:17px;font-weight:750}
#ticket-statement .ts-missing h3{margin:5px 0 8px;font-size:clamp(26px,1.7vw,34px);line-height:1.25;color:#a91f30;font-weight:850;letter-spacing:-.5px;overflow-wrap:anywhere}
#ticket-statement .ts-missing .ts-source-link{margin-top:8px;min-height:38px}
#ticket-statement .ts-missing-meta{display:flex;flex-wrap:wrap;gap:8px;margin-left:52px;margin-top:2px}
#ticket-statement .ts-missing-meta>span{display:inline-flex;align-items:center;gap:7px;min-width:0;max-width:100%;padding:6px 9px;border-radius:4px;background:#f4f0f4;color:#66768e;font-size:11px;line-height:1.5;overflow-wrap:anywhere}
#ticket-statement .ts-missing-meta .ts-icon{width:16px;height:16px;color:#45618a}
#ticket-statement .ts-missing-meta b,#ticket-statement .ts-missing-meta bdi{color:#30445e;font-weight:550;overflow-wrap:anywhere}
#ticket-statement .ts-review{margin-top:11px;border:1px solid #dce5f1;border-radius:7px;background:#fff;min-width:0}
#ticket-statement .ts-review>summary{display:flex;align-items:center;gap:13px;min-height:49px;padding:10px 16px;cursor:pointer;list-style:none;color:#45617f}
#ticket-statement .ts-review>summary::-webkit-details-marker{display:none}
#ticket-statement .ts-review>summary>div{flex:1;min-width:0}
#ticket-statement .ts-review strong{font-size:14px;font-weight:700;line-height:1.5}
#ticket-statement .ts-review summary small{display:block;font-size:11px;line-height:1.5;opacity:.8}
#ticket-statement .ts-review-mark{display:grid;place-items:center;flex:none;width:25px;height:25px;border-radius:50%;background:#e6edf8;font-size:17px;font-weight:800;line-height:1}
#ticket-statement .ts-chevron{margin-left:auto;font-size:18px}
#ticket-statement .ts-review[open] .ts-chevron{transform:rotate(180deg)}
#ticket-statement .ts-amber{border-color:#efdfb2;background:#fff9ed}
#ticket-statement .ts-amber>summary{color:#a36613}
#ticket-statement .ts-amber .ts-review-mark{background:#e9a511;color:white;border-radius:5px}
#ticket-statement .ts-green{border-color:#d2e9df;background:#f1faf6}
#ticket-statement .ts-green>summary{color:#238061}
#ticket-statement .ts-green .ts-review-mark{color:white;background:#198260}
#ticket-statement .ts-review-body{border-top:1px solid #e6eaf0;padding:0 15px;background:#ffffffb3;border-radius:0 0 7px 7px}
#ticket-statement .ts-reading-warning{padding:0;background:#fff8e9;border-color:#ecdba4}
#ticket-statement .ts-reading-warning summary{color:#9b5b14;flex-wrap:wrap}
#ticket-statement .ts-reading-warning>div{padding:0 15px 10px}
#ticket-statement .ts-reading-warning p{font-size:12px;color:#8c611d;overflow-wrap:anywhere}
#ticket-statement .ts-result-row{display:flex;align-items:flex-start;justify-content:space-between;gap:15px;min-width:0;padding:13px 0;border-bottom:1px solid #e5ebf2;content-visibility:auto;contain-intrinsic-size:auto 100px}
#ticket-statement .ts-result-row:last-child{border-bottom:0}
#ticket-statement .ts-result-row>div{min-width:0;flex:1}
#ticket-statement .ts-result-row p{margin:3px 0 5px;color:#7c899b;font-size:11px;line-height:1.6;overflow-wrap:anywhere}
#ticket-statement .ts-result-row strong{display:block;color:#243853;font-size:13px;overflow-wrap:anywhere}
#ticket-statement .ts-comparison-row>div{flex:1 1 45%}
#ticket-statement .ts-comparison-row>div+div{border-left:1px solid #e5ebf2;padding-left:16px}
#ticket-statement .ts-row-label{display:block;margin-bottom:3px;color:#8490a5;font-size:10px;font-weight:700;text-transform:uppercase;letter-spacing:.06em}
#ticket-statement .ts-match-reason{display:block;margin-top:6px;color:#a26b24;font-size:11px}
#ticket-statement .ts-green .ts-match-reason{color:#288664}
#ticket-statement .ts-duplicate h3{font-size:13px;margin:12px 0 0;color:#986318}
#ticket-statement .ts-row-count,#ticket-statement .ts-list-empty{margin:12px 0;color:#79879b;font-size:12px}
#ticket-statement .ts-incomplete{margin-top:12px;padding:14px 17px;border:1px solid #e6bd61;border-radius:8px;background:#fff3d7;color:#86521c}
#ticket-statement .ts-incomplete p{font-size:12px;margin:4px 0 0}
#ticket-statement .ts-no-missing{display:flex;align-items:center;gap:13px;margin-top:12px;padding:14px 17px;border:1px solid #cde7da;border-radius:8px;background:#f1faf6;color:#258164}
#ticket-statement .ts-no-missing p{margin:3px 0 0;color:#6c897f;font-size:12px}
#ticket-statement .ts-result-empty{text-align:center;padding:33px 16px 24px;color:#8b98ad}
#ticket-statement .ts-result-empty>.ts-icon{width:32px;height:32px;margin-bottom:8px}
#ticket-statement .ts-result-empty strong{display:block;font-size:15px;color:#5d7497}
#ticket-statement .ts-result-empty p{margin:6px 0;font-size:12px}
#ticket-statement .ts-footer{display:flex;justify-content:space-between;gap:20px;flex-wrap:wrap;margin-top:18px;padding:0 2px 6px;color:#8b9bb2;font-size:10px;line-height:1.6}
#ticket-statement .ts-initial{padding:30px;font-size:14px;color:#52769f}
#ticket-statement button:focus-visible,#ticket-statement summary:focus-visible,#ticket-statement input:focus-visible,#ticket-statement select:focus-visible{outline:3px solid #88b6f6;outline-offset:3px}
#ticket-statement .ts-viewer{position:fixed;inset:0;width:min(1050px,calc(100vw - 24px));height:min(92vh,1400px);max-width:calc(100vw - 24px);max-height:92vh;margin:auto;padding:0;border:1px solid #b8cceb;border-radius:12px;background:#f5f8fe;color:#1d3357;box-shadow:0 20px 70px #09224855;overflow:hidden}
#ticket-statement .ts-viewer[open]{display:flex;flex-direction:column}
#ticket-statement .ts-viewer::backdrop{background:#0e244977}
#ticket-statement .ts-viewer>header{display:flex;align-items:flex-start;justify-content:space-between;gap:14px;padding:13px 16px;border-bottom:1px solid #dce5f3;background:#fff;flex:none}
#ticket-statement .ts-viewer>header>div{min-width:0}
#ticket-statement .ts-viewer>header strong{display:block;font-size:13px;overflow-wrap:anywhere}
#ticket-statement .ts-viewer>header span{display:block;font-size:11px;color:#6e86a7;margin-top:3px}
#ticket-statement .ts-viewer-tools{display:flex;align-items:center;justify-content:center;gap:12px;flex-wrap:wrap;padding:9px 12px;flex:none}
#ticket-statement .ts-viewer-tools label{display:flex;gap:6px;align-items:center;margin:0;font-size:12px}
#ticket-statement .ts-viewer-tools input{width:64px;min-height:32px;padding:4px 6px;border:1px solid #c8d6eb;border-radius:5px}
#ticket-statement .ts-viewer-tools select{max-width:115px;min-height:32px;padding:4px 6px;border:1px solid #c8d6eb;border-radius:5px;background:#fff;color:#375577}
#ticket-statement .ts-viewer>p{flex:none;padding:0 10px;margin:0 0 8px;text-align:center;color:#6c84a4;font-size:11px}
#ticket-statement .ts-viewer-canvas{display:block;flex:1;min-height:0;padding:8px;overflow:auto;background:#e5ecf7}
#ticket-statement canvas{display:block;flex:none;box-shadow:0 2px 12px #1a3c5e30;background:white}
@media(max-width:1100px){#ticket-statement .ts-file-row{gap:8px;padding:9px}#ticket-statement .ts-passenger-badge{font-size:10px;padding:3px 6px}#ticket-statement .ts-summaries>article{padding:12px;gap:9px}#ticket-statement .ts-summary-icon{width:35px;height:35px}#ticket-statement .ts-filter-fields{gap:14px}}
@media(max-width:800px){#ticket-statement .ts-upload-grid{grid-template-columns:1fr}#ticket-statement .ts-summaries{grid-template-columns:repeat(2,minmax(0,1fr))}#ticket-statement .ts-filter-fields{grid-template-columns:1fr 1fr}#ticket-statement .ts-primary{grid-column:1/-1;margin-top:0}#ticket-statement .ts-missing-top{flex-wrap:wrap;gap:10px}#ticket-statement .ts-missing-top>.ts-source-link{margin-left:44px}#ticket-statement .ts-missing-meta{margin-left:0;margin-top:10px}#ticket-statement .ts-missing h3{font-size:24px}#ticket-statement .ts-header h1{font-size:26px}}
@media(max-width:450px){#ticket-statement .ts-upload-card{padding:13px}#ticket-statement .ts-upload-card header{gap:8px}#ticket-statement h2{font-size:14px}#ticket-statement .ts-upload-card header p{font-size:11px}#ticket-statement .ts-step{width:29px;height:29px;font-size:17px}#ticket-statement .ts-upload-card header .ts-outline{font-size:11px;padding:6px 8px}#ticket-statement .ts-pdf-icon{width:27px;height:34px}#ticket-statement .ts-file-row{flex-wrap:wrap}#ticket-statement .ts-file-info{flex:1 1 calc(100% - 95px)}#ticket-statement .ts-passenger-badge{order:5;margin-left:35px}#ticket-statement .ts-file-menu{margin-left:auto}#ticket-statement .ts-filter-fields{grid-template-columns:1fr}#ticket-statement .ts-primary{grid-column:auto}#ticket-statement .ts-filters{padding:13px}#ticket-statement .ts-summaries{gap:9px}#ticket-statement .ts-summaries>article{padding:11px 9px;gap:7px}#ticket-statement .ts-summary-icon{width:30px;height:30px}#ticket-statement .ts-summaries strong{font-size:23px}#ticket-statement .ts-summaries article>div>span{font-size:10px}#ticket-statement .ts-missing{padding:13px 11px;border-left-width:5px}#ticket-statement .ts-missing h2{font-size:14px}#ticket-statement .ts-missing h3{font-size:24px}#ticket-statement .ts-comparison-row{flex-direction:column}#ticket-statement .ts-comparison-row>div+div{border-left:0;border-top:1px solid #e4e9f2;padding:10px 0 0;width:100%}#ticket-statement .ts-result-row:not(.ts-comparison-row){flex-direction:column;gap:6px}#ticket-statement .ts-missing-top>.ts-source-link{margin-left:0}#ticket-statement .ts-viewer-tools{gap:6px}#ticket-statement .ts-viewer-tools .ts-outline{font-size:10px;padding:6px 8px}}
@media(prefers-reduced-motion:reduce){#ticket-statement *{scroll-behavior:auto}}

#ticket-statement .ts-upload-card.ts-drag-over{outline:3px solid #6eaff5;outline-offset:2px;background:#f1f8ff}
#ticket-statement .ts-result-tools{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;margin-top:12px;color:#74849b;font-size:11px}
#ticket-statement .ts-copy-fallback{white-space:pre-wrap;overflow-wrap:anywhere;padding:12px;border:1px solid #b8cae5;border-radius:6px;background:#fff;color:#274365;font:12px/1.6 inherit}

/* Use the full app content area only while this workspace is open. */
@media(min-width:821px){body:has(#ticket-statement.active) .content{width:calc(100% - clamp(32px,3vw,64px));max-width:none}}
#ticket-statement .ts-file-info strong{font-size:13px}
#ticket-statement .ts-file-info small{font-size:12px}
#ticket-statement .ts-filter-fields label{font-size:13px}
#ticket-statement .ts-viewer-sheet{position:relative;flex:none;margin:0 auto;max-width:none}
#ticket-statement #tsViewerHighlights{position:absolute;inset:0;pointer-events:none}
#ticket-statement .ts-row-highlight{position:absolute;border:1px solid #d68a00;border-radius:3px;background:#ffde473d;box-shadow:0 0 0 1px #fff9;pointer-events:none}
#ticket-statement .ts-viewer>p{overflow-wrap:anywhere;line-height:1.5}
@container(max-width:760px){
 #ticket-statement .ts-upload-grid{grid-template-columns:1fr}
 #ticket-statement .ts-summaries{grid-template-columns:repeat(2,minmax(0,1fr))}
 #ticket-statement .ts-filter-fields{grid-template-columns:1fr 1fr;gap:14px}
 #ticket-statement .ts-primary{grid-column:1/-1;margin-top:0}
 #ticket-statement .ts-missing-top{flex-wrap:wrap;gap:10px}
 #ticket-statement .ts-missing-top>.ts-source-link{margin-left:44px}
 #ticket-statement .ts-missing-meta{margin-left:0;margin-top:10px}
}
@container(max-width:440px){#ticket-statement .ts-filter-fields{grid-template-columns:1fr}#ticket-statement .ts-primary{grid-column:auto}#ticket-statement .ts-missing-top>.ts-source-link{margin-left:0}}
@media(max-width:600px){
 #ticket-statement .ts-missing h3{font-size:24px;color:#a91f30}
 #ticket-statement .ts-outline,#ticket-statement .ts-source-link{min-height:40px;font-size:12px}
 #ticket-statement .ts-primary{min-height:44px;font-size:14px}
 #ticket-statement .ts-filter-fields input,#ticket-statement .ts-viewer-tools input,#ticket-statement .ts-viewer-tools select{font-size:16px;min-height:44px}
 #ticket-statement .ts-file-menu summary{width:36px;min-height:44px}
 #ticket-statement .ts-file-info small{font-size:11px}
}
