:root{font-family:system-ui,-apple-system,sans-serif;color:#142e3d;background:#eef3f6;font-size:18px}*{box-sizing:border-box}body{margin:0}header,main,aside,nav,footer{padding:12px;max-width:820px;margin:auto}header{background:#164c64;color:white}h1{font-size:1.35rem}small{font-size:.8rem}aside{background:#fff1cf;font-size:.9rem}nav{display:flex;gap:5px;flex-wrap:wrap;position:sticky;top:0;background:#eef3f6;z-index:2}button,input,select,textarea{font:inherit}button{min-height:48px;padding:8px 14px;border:1px solid #8297a4;border-radius:9px;background:white;color:#123b50;cursor:pointer}button.primary{background:#155a79;color:white}button:disabled{opacity:.55}input,select,textarea{width:100%;min-height:48px;padding:8px;border:1px solid #8297a4;border-radius:6px;background:white;color:#142e3d}input[type=checkbox]{width:26px;min-height:26px;vertical-align:middle;margin-right:10px}label{display:block;margin:12px 0}textarea{min-height:90px}.grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(230px,1fr));gap:0 15px}.card{background:white;border-radius:10px;padding:15px;margin:15px 0;box-shadow:0 1px 4px #bccbd5}h2{font-size:1.25rem}h3{font-size:1.1rem}.warn{color:#8a3600;background:#fff1cf;padding:10px}.error{color:#991c1c}#message{white-space:pre-wrap;font-weight:600}.photos{display:flex;gap:10px;flex-wrap:wrap}.photos figure{margin:5px;max-width:130px}.photos img{width:110px;height:95px;object-fit:contain}.photos figcaption{font-size:.8rem;overflow-wrap:anywhere}.pairs{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:4px 12px}.pairs div{border-bottom:1px solid #d3dfe5;padding:8px;overflow-wrap:anywhere}.pairs b{display:block;font-size:.85rem;color:#486778}.pairs span{white-space:pre-wrap}.status{font-weight:bold;color:#155a79}.audit{font-size:.85rem;white-space:pre-wrap;overflow-wrap:anywhere}footer{font-size:.8rem}.actions{display:flex;gap:10px;flex-wrap:wrap}.hint{font-size:.85rem;color:#51616b}fieldset{border:1px solid #9bb0bd;border-radius:8px;margin:15px 0}a{color:#155a79}input:focus,button:focus,select:focus,textarea:focus{outline:3px solid #e5ab39}@media(max-width:400px){.pairs{grid-template-columns:1fr}nav button{padding:8px;font-size:.9rem}} 
:root{--ocr-border:#679eb5}.ocr-panel{border:2px solid var(--ocr-border);padding:12px;margin:16px 0;border-radius:8px;overflow-wrap:anywhere}.ocr-raw{white-space:pre-wrap;overflow-wrap:anywhere;font-size:1.1rem;background:#eef3f6;padding:10px}.ocr-panel button{margin:6px 0}.ocr-panel h3{margin-top:0}
:root{--source-photo-width:100%}.ocr-source{width:var(--source-photo-width);height:auto}
:root{--ocr-action-gap:16px}.ocr-settings-actions{display:grid;gap:var(--ocr-action-gap)}.ocr-setting-action{border:1px solid #b7cbd7;border-radius:8px;padding:12px;min-width:0}.ocr-setting-action button{display:block;width:100%;min-height:48px;position:relative;touch-action:manipulation}.ocr-setting-action button[data-busy=true]{background:#155a79;color:white;opacity:1}.ocr-action-result{white-space:pre-wrap;overflow-wrap:anywhere;margin:12px 0 0;scroll-margin-top:120px}.ocr-action-result[data-status=success]{color:#155a42;font-weight:600}.ocr-action-result[data-status=warning]{background:#fff1cf;color:#8a3600;padding:8px}.ocr-action-result[data-status=busy]{font-weight:600}
:root{--capture-border:#b7cbd7}.capture-card{border:1px solid var(--capture-border);border-radius:10px;padding:12px;margin:16px 0}.capture-grid{display:grid;grid-template-columns:100px minmax(0,1fr);gap:12px;align-items:center}.capture-card img,.identity img,#trip details img{width:100px;height:85px;object-fit:contain;background:#eef3f6}.capture-grid label{min-width:0}.camera-choice{padding:8px;background:#eef3f6;border-radius:8px}.camera-choice input{max-width:100%;font-size:.85rem}.batch-check{background:#fff1cf;padding:14px}#saveResult{white-space:pre-wrap;overflow-wrap:anywhere;scroll-margin-top:125px}#trip button{margin:8px 0;max-width:100%}#trip input[type=checkbox]{width:26px}#draftStatus{font-weight:600}.identity{border:2px solid #679eb5;padding:10px}#trip pre{max-height:250px;overflow:auto}#trip [hidden]{display:none}
.activity-buttons{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin:12px 0}.operations [aria-pressed=true]{background:#155a79;color:white}#activityResult,#profileStatus,#workError,#backupResult,#restorePreview{white-space:pre-wrap;overflow-wrap:anywhere;font-weight:600}#supportHistory img{width:100px;height:90px;object-fit:contain}#supportHistory pre{max-height:200px;overflow:auto}#operations{max-width:820px}#operations button{margin:6px 0}#profileSetup input{font-size:1.1rem}@media print{header,aside,nav,footer,#operations,main>label,#message,button,input,select,textarea{display:none!important}body{background:white;color:black;font-size:11pt}.card{box-shadow:none;border:1px solid #bbb;break-inside:avoid;padding:8px}.pairs{grid-template-columns:repeat(3,minmax(0,1fr))}main{max-width:none;padding:0}}
