:root{font-family:Inter,-apple-system,BlinkMacSystemFont,"Segoe UI","PingFang SC",sans-serif;color:#203e39;background:#f3f6f5;font-size:14px}*{box-sizing:border-box}body{margin:0}button,input,select,textarea{font:inherit}button,a,input,select,textarea{outline-offset:3px}button{border:1px solid #d7e2dd;border-radius:8px;background:white;padding:10px 15px;color:#294b42;cursor:pointer}button:hover{background:#edf5f0}button:disabled{opacity:.5;cursor:not-allowed}.primary{background:#216552;border-color:#216552;color:white}.primary:hover{background:#174d3e}.danger{color:#ab4141}.ghost{background:transparent}.layout{display:grid;grid-template-columns:235px 1fr;min-height:100vh}.sidebar{background:#153e34;color:#eaf3ee;padding:30px 20px;display:flex;flex-direction:column;gap:30px;position:sticky;top:0;height:100vh}.brand{display:flex;align-items:center;gap:10px;font-size:18px;line-height:1.35;font-weight:650}.brand-icon{width:38px;height:42px;display:grid;place-items:center;border:1px solid #729c87;border-radius:10px;color:#bddec8}.sidebar small{color:#a4c2b3;font-size:10px;letter-spacing:1.5px}.nav{display:grid;gap:8px}.nav button{text-align:left;background:transparent;border:0;color:#bad0c4;padding:13px}.nav button.active{background:#2c5547;color:white}.identity{margin-top:auto;border-top:1px solid #3d5e50;padding-top:20px;display:grid;gap:10px}.identity strong{color:white}.identity button{color:#d0e0d6;border-color:#51705e}.workspace{min-width:0}.topbar{background:#fff;border-bottom:1px solid #e3eae6;padding:20px 38px;display:flex;justify-content:space-between;align-items:center}.topbar h1{font-size:22px;margin:0}.muted{color:#71837a;font-size:13px;line-height:1.6}.tag{font-size:12px;padding:5px 10px;border-radius:20px;background:#eaf1ed;color:#536f61;white-space:nowrap}.tag.pending{background:#fff1d8;color:#96631a}.tag.returned{background:#fceae5;color:#ad624a}.tag.done{background:#e1f0e4;color:#347343}.content{padding:30px 38px;max-width:1600px;margin:auto}.banner{background:#eaf3ec;padding:13px 18px;border:1px solid #c9decc;border-radius:9px;color:#43664d;margin-bottom:22px;display:flex;align-items:center;justify-content:space-between;gap:15px}.banner.warn{background:#fff2e9;border-color:#ecd3b9;color:#886443}.metrics{display:grid;grid-template-columns:repeat(4,1fr);gap:16px;margin:22px 0}.metric{background:white;border:1px solid #e0e8e3;border-radius:12px;padding:20px}.metric strong{display:block;font-size:30px;margin-top:12px;font-weight:550}.toolbar{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin:22px 0}.toolbar input{min-width:250px;flex:1}.right{margin-left:auto}.panel{background:white;border:1px solid #e0e8e3;border-radius:12px;padding:24px;margin-bottom:20px}.panel h2{font-size:18px;margin:0 0 8px}.case-table{width:100%;border-collapse:collapse}.case-table th{text-align:left;color:#7c8a81;font-size:12px;font-weight:500;background:#f6f9f7}.case-table th,.case-table td{padding:17px 12px;border-bottom:1px solid #edf1ee}.case-table td strong{display:block;margin-bottom:5px}.case-table tbody tr:hover{background:#f8fbf9}.empty{text-align:center;padding:65px 20px;color:#82948a}.empty strong{display:block;color:#3c5f4d;font-size:18px;margin-bottom:12px}.row{display:flex;gap:12px;align-items:center;flex-wrap:wrap}.grid2{display:grid;grid-template-columns:1fr 1fr;gap:18px}.grid3{display:grid;grid-template-columns:repeat(3,1fr);gap:16px}.field{display:grid;gap:7px;margin:14px 0}.field label{font-size:12px;color:#627d6d;font-weight:550}input,select,textarea{width:100%;padding:10px 12px;border:1px solid #cfdcd3;border-radius:7px;color:#284a38;background:#fff}input:disabled,textarea:disabled,select:disabled{background:#f4f7f5;color:#708276}textarea{min-height:85px;resize:vertical;line-height:1.6}.toolbar select{width:auto}.case-head{display:flex;justify-content:space-between;gap:18px;align-items:start;margin:14px 0 22px}.case-head h2{font-size:25px;margin:0 0 10px}.back{border:0;padding-left:0;background:transparent;color:#71877a}.issue{padding:24px;border:1px solid #dce6de;border-radius:12px;background:white;margin:18px 0}.issue-head{display:flex;align-items:center;gap:10px;border-bottom:1px solid #edf1ed;padding-bottom:16px;margin-bottom:16px}.issue-head h3{margin:0;font-size:17px}.issue-number{color:#a4b7a8;font-size:12px}.compare{display:grid;grid-template-columns:1fr 1fr;gap:20px}.photo-side{padding:16px;background:#f6f9f7;border-radius:9px;border:1px solid #e4ebe5}.photo-side h4{font-size:13px;margin:0 0 14px}.photo-side h4 span{font-size:11px;margin-left:10px;font-weight:normal;color:#819184}.drop{min-height:105px;border:1.5px dashed #bfd0c0;border-radius:8px;display:grid;place-content:center;text-align:center;padding:15px;gap:5px;color:#64826c;cursor:pointer;background:#fff}.drop.drag{background:#e0efdf;border-color:#42744f}.drop input{display:none}.thumbs{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:12px}.thumb{position:relative}.thumb img{width:100px;height:78px;object-fit:cover;border-radius:6px;cursor:zoom-in}.thumb button{position:absolute;right:0;top:0;padding:1px 6px;border-radius:4px;color:#a73838}.review{background:#f4f8f4;border:1px solid #d6e4d6;border-radius:9px;padding:18px;margin-top:18px}.review h4{margin:0 0 8px;font-size:14px}.sticky-actions{position:sticky;bottom:0;background:#fffffff2;border:1px solid #dce5de;border-radius:10px;backdrop-filter:blur(8px);padding:15px 20px;display:flex;gap:12px;align-items:center;z-index:5;box-shadow:0 2px 20px #2346290a}.audit-entry{border-left:2px solid #c7dac9;margin:0 0 0 5px;padding:0 0 22px 20px}.audit-entry strong{display:block;font-size:13px}.audit-entry small{color:#8a9b8d}.audit-entry p{margin:6px 0;font-size:13px;white-space:pre-wrap}.tabs{display:flex;gap:15px;border-bottom:1px solid #dfe8e0;margin:20px 0}.tabs button{border:0;background:transparent;border-radius:0;color:#78917d}.tabs button.active{color:#276445;border-bottom:2px solid #276445}.login-page{display:grid;grid-template-columns:1fr 1fr;min-height:100vh}.login-art{background:#153e34;color:#e2f0e6;padding:10vh 10%;display:flex;flex-direction:column;justify-content:center;position:relative;overflow:hidden}.login-art:after{content:'';position:absolute;border:1px solid #568665;width:500px;height:500px;border-radius:50%;right:-260px;bottom:-180px}.login-art h1{font-size:42px;line-height:1.4;letter-spacing:-1px}.login-art p{line-height:1.9;color:#abc9b4;max-width:430px}.login-box{display:grid;place-content:center;padding:35px}.login-box>div{width:min(430px,85vw)}.login-box h2{font-size:28px;margin-bottom:8px}.login-box button.primary{width:100%;margin-top:15px}.login-box .banner{font-size:12px;margin-top:20px}#toast{position:fixed;right:25px;bottom:25px;padding:15px 20px;background:#173c2e;color:white;border-radius:10px;box-shadow:0 4px 20px #1233;z-index:100;display:none;max-width:600px;white-space:pre-wrap}#toast.error{background:#9a3d31}dialog{border:1px solid #d5e2d7;border-radius:14px;padding:25px;max-height:92vh;max-width:96vw;width:1250px}dialog::backdrop{background:#152c22aa}#formDialog{width:580px}.dialog-head{display:flex;align-items:center;justify-content:space-between;margin-bottom:15px}.image-scroll{height:55vh;overflow:auto;background:#edf2ed;border:1px solid #dce5dc;text-align:center}.image-scroll img{width:100%;transform-origin:top left;display:block}.image-scroll img.zoomed{max-width:none}.loading{padding:60px;text-align:center}.help{font-size:12px;line-height:1.7;color:#7e9182}.login-error{color:#b24335;white-space:pre-wrap}.save-state{font-size:12px;color:#6f8375}.test-switch{max-width:170px;font-size:12px}.table-scroll{overflow:auto}.user-chip{width:30px;height:30px;background:#dfece0;border-radius:50%;display:inline-grid;place-items:center;color:#45734e;font-weight:bold;margin-right:8px}.section-title{display:flex;justify-content:space-between;align-items:center}.audit-note{white-space:pre-wrap}.report-text{white-space:pre-wrap}.local-only{font-weight:600}a{color:#216552}.notice{padding:12px;background:#fff6e9;border-radius:7px;color:#8b6b39;font-size:13px;line-height:1.7}.footer-help{margin-top:24px;text-align:center;font-size:12px;color:#8a9c8f}@media(max-width:1000px){.layout{grid-template-columns:190px 1fr}.content{padding:20px}.topbar{padding:20px}.grid3{grid-template-columns:1fr}.metrics{grid-template-columns:1fr 1fr}}@media(max-width:700px){.layout{display:block}.sidebar{position:static;height:auto;padding:15px;gap:15px}.sidebar .brand{font-size:15px}.nav{display:flex}.identity{display:flex;align-items:center;margin:0;padding:10px 0 0}.identity .muted{display:none}.grid2,.compare{grid-template-columns:1fr}.login-page{display:block}.login-art{padding:35px}.login-art h1{font-size:28px}.login-box{padding:25px}.case-head{flex-direction:column}.sticky-actions{flex-wrap:wrap}.test-switch{max-width:130px}.metrics{gap:8px}.metric{padding:14px}.case-table th,.case-table td{padding:12px}.topbar h1{font-size:19px}}

/* Compact issue editor: evidence takes priority. */
.issue-meta{display:grid;grid-template-columns:1fr 1.3fr 1fr;gap:14px}.issue-details{display:grid;grid-template-columns:2fr 1fr;gap:14px;align-items:start}.issue .field{margin:6px 0 12px}.issue-details textarea{min-height:66px;height:66px}.issue{padding:20px}.issue .compare{margin-top:8px}.issue .photo-side{min-height:180px}.issue .thumb img{width:150px;height:115px}.issue .review{margin-top:16px}.issue .review>select{max-width:260px}.issue .review .field{display:inline-grid;width:calc(70% - 12px);vertical-align:top;margin:12px 12px 0 0}.issue .review .field:last-child{width:26%}@media(max-width:700px){.issue-meta{grid-template-columns:1fr 1fr}.issue-meta>.field:last-child{grid-column:1/-1}.issue-details{grid-template-columns:1fr}.issue .review .field,.issue .review .field:last-child{width:100%}.issue .thumb img{width:110px;height:90px}}

.issue .photo-side{min-height:0;padding:12px}.issue .thumb img{width:88px;height:66px}.photo-button{padding:0;border:0;background:transparent;line-height:0}.issue .drop{min-height:58px;padding:10px;font-size:12px}.issue .thumbs{margin-bottom:8px}.issue .compare{gap:14px}.issue-head h3{font-size:15px}.issue .photo-side h4{margin-bottom:10px}#photoDialog .image-scroll img{max-height:none;height:auto;margin-bottom:12px}.issue .review{padding:12px}.issue .review .field{margin-top:8px}

.zoom-controls{display:flex;gap:7px;align-items:center;flex-wrap:wrap}.zoom-controls input{width:140px;padding:0;accent-color:#216552}.zoom-controls button{padding:6px 10px}.zoom-controls output{min-width:45px;font-size:12px}.image-scroll.magnified{cursor:grab;touch-action:none}.image-scroll.panning{cursor:grabbing}.image-scroll img{user-select:none;-webkit-user-drag:none}.zoom-panel .help{margin:8px 0}
/* Small thumbnails; fit the full image in the viewer before explicit zoom. */
.issue .thumbs{gap:6px;max-height:150px;overflow:auto}.issue .thumb img{width:64px!important;height:48px!important;object-fit:cover}.issue .photo-button{width:64px;height:48px;flex:none;overflow:hidden}.issue .photo-side{padding:10px}.issue .drop{min-height:42px;padding:8px}.issue .photo-side h4{margin-bottom:8px}
#photoDialog{width:1050px;max-height:90vh;padding:18px}#photoDialog .image-scroll{height:48vh;display:flex;flex-direction:column;align-items:center;gap:10px;padding:8px}#photoDialog .image-scroll img{width:auto!important;max-width:100%!important;height:auto!important;max-height:calc(48vh - 18px)!important;object-fit:contain;flex-shrink:0;margin:0}#photoDialog .image-scroll.magnified{display:block;padding:0}#photoDialog .image-scroll.magnified img{width:var(--zoom)!important;max-width:none!important;max-height:none!important;margin-bottom:12px}.zoom-panel{min-width:0}

/* Medium, uncropped evidence thumbnails. */
.issue .thumbs{max-height:240px;gap:10px}.issue .photo-button{width:144px;height:108px;border:1px solid #d9e3db;border-radius:7px;background:#edf2ee;display:flex;align-items:center;justify-content:center}.issue .thumb img{width:144px!important;height:108px!important;object-fit:contain!important}.issue .photo-button img{width:142px!important;height:106px!important;object-fit:contain!important;border-radius:6px}@media(max-width:700px){.issue .photo-button{width:120px;height:90px}.issue .photo-button img{width:118px!important;height:88px!important}}

/* Larger side-by-side comparison viewer; list thumbnails stay medium. */
#photoDialog{width:96vw;max-width:1800px;height:94vh;max-height:94vh;padding:20px}#photoDialog .dialog-head{margin-bottom:8px}#photoDialog>.muted{margin:6px 0}#photoDialog .compare{gap:24px}#photoDialog .zoom-panel h3{margin:10px 0}#photoDialog .image-scroll{height:calc(94vh - 225px);min-height:220px}#photoDialog .image-scroll img{max-height:calc(94vh - 245px)!important}#photoDialog .image-scroll.magnified img{max-height:none!important}@media(max-width:700px){#photoDialog{width:98vw;padding:12px}#photoDialog .image-scroll{height:50vh;min-height:180px}#photoDialog .image-scroll img{max-height:calc(50vh - 18px)!important}}

/* Consistent CM review labels and comfortable spacing. */
.issue .review{padding:20px;margin-top:20px;background:#f3f7f3}.issue .review h4{margin:0 0 16px;padding-bottom:12px;border-bottom:1px solid #dce7dc}.review-fields{display:grid;grid-template-columns:minmax(160px,1fr) minmax(260px,2.5fr) minmax(100px,.7fr);gap:22px;align-items:start}.issue .review .review-fields .field,.issue .review .review-fields .field:last-child{display:grid;width:auto;margin:0;gap:9px}.review-fields label{line-height:20px}.review-fields input,.review-fields select{height:42px;width:100%;max-width:none}@media(max-width:850px){.review-fields{grid-template-columns:1fr 1fr;gap:16px}.review-fields>.field:nth-child(2){grid-column:1/-1;grid-row:2}}@media(max-width:500px){.review-fields{grid-template-columns:1fr}.review-fields>.field:nth-child(2){grid-row:auto;grid-column:auto}}

.area-overview{background:white;border:1px solid #dce6de;border-radius:12px;padding:20px;margin:20px 0}#areaSummary{display:flex;flex-wrap:wrap;gap:12px}.area-shortcut{display:flex;align-items:center;gap:12px;padding:12px 16px;text-align:left}.area-shortcut span{font-size:12px}.area-shortcut small{color:#8a753d}.area-shortcut[aria-expanded="true"]{border-color:#398260;background:#eaf4ed}.area-group{border:1px solid #dce6de;background:#fff;border-radius:12px;margin:16px 0;scroll-margin-top:20px;overflow:hidden}.area-group>summary{display:flex;gap:16px;align-items:center;padding:18px 22px;cursor:pointer;list-style:none;background:#f5f9f6}.area-group>summary::before{content:'▸';color:#467755}.area-group[open]>summary::before{content:'▾'}.area-name{font-size:16px;font-weight:650}.area-count{background:#e3eee5;border-radius:20px;padding:4px 10px;font-size:12px}.area-review{margin-left:auto;color:#718377;font-size:12px}.area-group-body{padding:0 16px}.area-group .issue{margin:16px 0}.area-group summary:hover{background:#eaf2ec}@media(max-width:600px){.area-group>summary{padding:14px;gap:8px}.area-review{font-size:11px}.area-group-body{padding:0 8px}}

.photo-tile{position:relative;display:grid;gap:4px}.photo-label{font-size:11px;color:#728475}.delete-photo{position:absolute;right:3px;top:3px;padding:3px 7px;font-size:11px;color:#a33c30;background:#fffffff2}.zoom-panel .choose-photo{width:auto;flex:1}.pairing-actions{grid-column:1/-1;border-top:1px solid #ddd;padding-top:8px;font-size:12px}.pairing-actions p{margin:5px 0}
