.pilot-wrap{max-width:1160px}.pilot-grid{display:grid;grid-template-columns:minmax(300px,.9fr) minmax(0,1.2fr);gap:22px}.pilot-preview{width:100%;height:auto;display:block;border:1px solid var(--line);touch-action:none}.pilot-notice{margin-bottom:22px}.pilot-form label{display:block;font-size:13px;margin:14px 0 6px}.pilot-form input:not([type=checkbox]):not([type=file]),.pilot-form select,.pilot-form textarea{width:100%;padding:11px;border:1px solid #cbdadf;border-radius:8px;font:inherit}.pilot-form textarea{min-height:85px}.pilot-form .check{display:flex;align-items:flex-start;gap:8px;line-height:1.6}.pilot-form .check input{margin-top:4px}.pilot-actions{display:flex;flex-wrap:wrap;gap:9px;margin-top:18px}.pilot-auth{max-width:450px;margin:35px auto}.pilot-file{overflow-wrap:anywhere;font-size:12px;color:#607487}.pilot-status{white-space:pre-wrap;line-height:1.8}.pilot-results{margin-top:22px}.pilot-history button{margin-top:8px}.pilot-grid .panel{min-width:0}.pilot-preview-tools{margin:12px 0}.pilot-point-list{font-size:12px;line-height:1.8;word-break:break-word}.pilot-title{margin:8px 0 14px;font-size:28px}@media(max-width:760px){.pilot-grid{grid-template-columns:1fr}.pilot-title{font-size:24px}.header .brand{font-size:20px}.pilot-wrap{padding-bottom:40px}}

.pilot-form input[type=file]{display:none}

.measurement-details{margin:18px 0;padding:16px 20px;background:#edf5f7;border:1px solid #d3e4e8;border-radius:12px}
.measurement-details h2{margin:0 0 12px;font-size:18px}
.measurement-details dl{display:grid;grid-template-columns:repeat(auto-fit,minmax(190px,1fr));gap:12px;margin:0}
.measurement-details dt{color:#526978;font-size:13px}
.measurement-details dd{margin:3px 0 0;font-weight:600;overflow-wrap:anywhere}

.pilot-wrap .report-new{margin-top:20px}.pilot-wrap .report-section{margin:16px 0;padding:16px;border:1px solid #cbd5e1;border-radius:12px}.pilot-wrap .report-section label{display:block;margin:10px 0}.pilot-wrap input:not([type=checkbox]),.pilot-wrap select,.pilot-wrap textarea{max-width:100%;min-width:0}.pilot-wrap .report-details dd{overflow-wrap:anywhere}.header .nav{flex-wrap:wrap}#quota-strip{overflow-wrap:anywhere}

@font-face {
 font-family: "IBM Plex Sans Thai";
 src: url("/fonts/IBMPlexSansThai-Regular.ttf") format("truetype");
 font-weight: 400;
 font-display: swap;
}
@font-face {
 font-family: "IBM Plex Sans Thai";
 src: url("/fonts/IBMPlexSansThai-Medium.ttf") format("truetype");
 font-weight: 500;
 font-display: swap;
}
@font-face {
 font-family: "IBM Plex Sans Thai";
 src: url("/fonts/IBMPlexSansThai-SemiBold.ttf") format("truetype");
 font-weight: 600;
 font-display: swap;
}
@font-face {
 font-family: "IBM Plex Sans Thai";
 src: url("/fonts/IBMPlexSansThai-Bold.ttf") format("truetype");
 font-weight: 700;
 font-display: swap;
}

:root {
 --portal-navy: #062744;
 --portal-surface: #f4f4ef;
 --portal-card: #fffefa;
 --portal-accent: #ffc400;
 --portal-notice: #fff2c6;
 --portal-ink: #082944;
 --portal-focus: #164b83;
 --muted: #42566a;
 --line: #cbcfc9;
 --teal: var(--portal-ink);
 --shadow: 0 6px 22px #0627440d;
 font-family: "IBM Plex Sans Thai", Tahoma, sans-serif;
 color: var(--portal-ink);
 background: var(--portal-surface);
 color-scheme: light;
}

.header {
 background: var(--portal-navy);
 color: var(--portal-card);
 border-color: var(--portal-navy);
 gap: clamp(12px, 3vw, 36px);
 padding-inline: max(20px, calc((100vw - 1160px) / 2));
}
.header .brand, .header .nav button { color: var(--portal-card); }
.header .nav button:hover { background: #ffffff20; }
.header .header-end button {
 background: transparent;
 color: var(--portal-card);
 border-color: #ffffff70;
}
.header .nav { border-color: #ffffff33; }
.pill.amber { background: var(--portal-notice); color: var(--portal-ink); }
.panel, button, .pilot-form :is(input,select,textarea) { background: var(--portal-card); }
.primary, .download-row .download-primary {
 background: var(--portal-accent);
 color: var(--portal-ink);
 border-color: var(--portal-accent);
}
.primary:not(:disabled):hover, .download-row .download-primary:hover { background: #edb600; }
.pilot-actions button, .header button, .download-row a { min-height: 44px; }
.notice, .result-number { background: var(--portal-notice); color: var(--portal-ink); }
.notice { border-color: #e4cb76; font-size: 14px; }
.pilot-title { line-height: 1.4; }
.pilot-form label { font-size: 14px; font-weight: 500; }
.pilot-form :is(input,select,textarea) { accent-color: var(--portal-navy); }
.hint, .pilot-file, .upload small, .upload>span:not(.upload-icon), .measurement-details dt {
 color: var(--muted);
 font-size: 13px;
}
.upload { background: var(--portal-surface); border-color: #7a8990; }
.upload:hover, .upload.dragging { background: var(--portal-notice); border-color: var(--portal-navy); }
.upload strong { font-weight: 700; }
.measurement-details { background: var(--portal-surface); border-color: var(--line); }
.measurement-details dl { grid-template-columns: repeat(auto-fit,minmax(min(100%,190px),1fr)); }
.result-number strong { color: var(--portal-ink); overflow-wrap: anywhere; }
.download-row a { border-color: #7a8990; font-weight: 600; }
.download-row a:hover { background: var(--portal-notice); }
.pilot-wrap :is(button,a,input,select,textarea,[tabindex]):focus-visible {
 outline: 3px solid var(--portal-focus);
 outline-offset: 2px;
}
.header button:focus-visible { outline-color: var(--portal-accent); }

@media (max-width: 420px) {
 .header { padding-inline: 15px; }
 .header .brand { gap: 6px; }
 .header .brand .pill { padding-inline: 8px; }
 .header-end button { padding-inline: 10px; }
 .area-grid { grid-template-columns: repeat(3,minmax(0,1fr)); }
 .pilot-auth { margin-top: 16px; }
}

.standard-preview{grid-column:2;grid-row:1 / span 2;align-self:start}.standard-details{grid-column:1}.standard-preview canvas[hidden]{display:none}.standard-preview canvas{touch-action:auto}@media(max-width:760px){.standard-preview{grid-column:1;grid-row:auto}}

/* Customer intake, wait and result screens */
.header .eapp-logo { width: auto; height: 65px; max-width: 156px; display:block; object-fit: contain; background: white; border-radius: 8px; }
.standard-intake { align-items: start; grid-template-columns: minmax(0,1.15fr) minmax(0,1fr); }
.standard-details { grid-column: auto; }
.customer-drop { cursor: default; }
.customer-drop>* { max-width: 100%; }
.customer-drop #preview { width: auto; max-width: 100%; max-height: 580px; object-fit: contain; touch-action: auto; }
.customer-drop #preview-status, .customer-drop #filename { margin: 0; overflow-wrap: anywhere; }
.customer-drop #page-controls { display: flex; align-items: center; gap: 10px; }
.customer-drop #page-controls label { margin: 0; }
.customer-drop #page-controls select { width: auto; }
.file-picker { display: grid; gap: 6px; width: 100%; white-space: normal; }
#pick-label { display: grid; gap: 2px; }
#pick-label span { font-size: 13px; font-weight: 500; }
#submit-feedback:empty { display: none; }
.queue-card,.queue-reading,.coming-soon { max-width: 860px; margin: 0 auto 22px; }
.queue-file { font-weight: 600; overflow-wrap: anywhere; }
.queue-card #status { border-bottom: 1px solid var(--line); padding-bottom: 12px; }
.queue-card #queue-note { font-size: 16px; }
.queue-card #actions { margin: 16px 0 10px; }
#result { width: 100%; padding: 14px; font-size: 17px; }
.queue-reading h2 { margin: 8px 0 12px; }
.service-banner { background: var(--portal-navy); color: white; border-radius: 14px; padding: 24px; }
.service-banner h3 { margin: 0; }
.service-banner p { margin: 7px 0 16px; }
.action-link { display: inline-block; border: 1px solid #9aa9b4; border-radius: 9px; padding: 10px 16px; text-align: center; font-weight: 600; }
.action-link.primary { border-color: var(--portal-accent); }
.customer-result { display: grid; gap: 16px; grid-template-columns: minmax(0,1.35fr) minmax(0,1fr); align-items: start; margin-block: 16px; }
.customer-result>.panel { text-align: center; }
.customer-result .preview-image { max-height: 740px; object-fit: contain; }
.customer-result .measurement-details { margin: 0; }
.customer-result .measurement-details dl { margin-block: 0; }
.customer-result .notice { margin-bottom: 0; font-size: 13px; }
.customer-result .deed-side-table p { font-size: 16px; }
.result-disclaimer p { line-height: 1.8; margin-bottom: 0; }
.result-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
#property-value-link { margin-left: auto; }
@media(max-width:760px) {
 .standard-intake,.customer-result { grid-template-columns: minmax(0,1fr); }
 .header .eapp-logo { height: 52px; max-width: 124px; }
 #property-value-link { margin-left: 0; }
}
@media(max-width:420px) {
 .result-actions>* { flex-grow: 1; }
 .service-banner { padding: 18px; }
}

/* Keep the map and the entered values within reach on a phone. */
.pilot-compact { padding-top: 14px; }
.pilot-private { margin: 0 0 4px; font-size: 13px; color: var(--portal-ink); }
.pilot-compact #quota-strip { margin: 0 0 12px; padding: 5px 10px; display: inline-block; }
.pilot-compact .pilot-title { margin: 4px 0; }
.customer-result .measurement-details { padding: 0; background: transparent; border: 0; border-radius: 0; }
.customer-result .measurement-details dl { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 10px 14px; }
.customer-result .measurement-details dl>div:first-child { grid-column: 1 / -1; }
.customer-result .measurement-details dd { margin-top: 1px; }
.customer-drop.has-file { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 8px 10px; padding: 12px; }
.customer-drop.has-file #choose-file { grid-column: 2; grid-row: 1; width: auto; padding: 6px 10px; }
.customer-drop.has-file #filename { grid-column: 1; grid-row: 1; text-align: left; min-width: 0; }
.customer-drop.has-file #short-limits { grid-column: 1; text-align: left; margin: 0; }
.customer-drop.has-file #page-controls { grid-column: 2; justify-content: end; }
.customer-drop.has-file #page-controls select { padding: 5px; }
.customer-drop.has-file #preview, .customer-drop.has-file #preview-status,
.customer-drop.has-file #upload-error { grid-column: 1 / -1; justify-self: center; }
.customer-drop.has-file .preview-local-note { grid-column: 1 / -1; grid-row: 6; margin: 0; }
#file-progress:empty,#parcel-progress:empty { display:none; }
@media(max-width:760px) {
 .customer-result,.customer-result .stack { gap: 10px; }
 .customer-result .pad,.result-disclaimer { padding: 14px; }
 .customer-result .panel h2 { margin-bottom: 9px; }
}
@media(max-width:359px) {
 .customer-drop.has-file #short-limits,.customer-drop.has-file #page-controls { grid-column: 1 / -1; justify-content: center; text-align: center; }
}

.header .brand { border-radius: 8px; }
.header .site-home {
 color: var(--portal-card);
 font-size: 14px;
 line-height: 1.4;
 padding-block: 10px;
 white-space: nowrap;
 text-decoration: underline;
 text-underline-offset: .2em;
}
.header .brand + .site-home { margin-inline-start: auto; }
.header a:focus-visible {
 outline: 3px solid var(--portal-accent);
 outline-offset: 3px;
}
@media (max-width: 600px) {
 .header .site-home { margin-inline-start: auto; }
 .header .header-end { order: 4; flex-wrap: wrap; justify-content: flex-end; }
}

.header .nav button{font-weight:700;background:#fff8e3;color:var(--portal-navy);border-color:#efcf63}
.header .nav button:hover{background:#ffeab0}
.header .nav :is(#new,#history),.header .header-end #logout{font-size:15px;line-height:1.4;min-height:48px;padding:10px 16px}
.header .nav [aria-current="location"]{box-shadow:inset 0 -3px var(--portal-navy)}
.header .nav #new{background:#f8d66c;border-color:#f8d66c}
.header .nav #new:hover{background:#ffe490}
.header .header-end button{font-weight:500}
.header .header-end #logout{background:transparent;color:var(--portal-card);border-color:#ffffff55}
.header .header-end #logout:hover{background:#ffffff20}
#queue-connection:empty{margin:0}
#job-progress:not([hidden]){display:block;width:100%;height:14px;accent-color:var(--portal-accent);margin-block:16px}
.job-details{font-size:14px;color:#425868;margin-block:12px}
.result-ready{box-shadow:0 0 0 3px #f1c95055,0 4px 20px #cf9a2640}
.ready-badge{display:inline-block;background:#e8f5e9;color:#194e26;font-weight:700;font-size:12px;border-radius:20px;padding:3px 8px;margin-inline:6px}
.wait-banner{padding:18px;border:1px solid var(--line);border-radius:14px;background:var(--portal-card)}
.wait-banner img{display:block;width:100%;height:auto;border-radius:10px}
.banner-title{font-size:20px;margin:12px 0 5px}
.banner-controls:not([hidden]){display:flex;align-items:center;gap:8px;margin-top:10px}
.banner-controls button{min-height:44px}
.comparison-result{max-width:860px;margin-inline:auto}
.comparison-result .preview-image{width:100%;height:auto}


.history-jobs { margin-block: 8px 12px; }
.history-jobs > h2 { margin-block: 0; }
.history-job { display: grid; grid-template-columns: minmax(0,1fr) auto; align-items: center; gap: 12px 24px; }
.history-job-active { border-inline-start: 4px solid var(--portal-accent); }
.history-job h3 { overflow-wrap: anywhere; margin: 0; }
.history-job p { margin-block: 5px; }
.history-job-status { font-weight: 700; }
.completion-time { color: var(--portal-ink); }
.history-job .action-link, .queue-history { display: inline-flex; align-items: center; min-height: 48px; justify-content: center; }
.history-job .result-ready { min-height: 54px; font-size: 17px; padding-inline: 24px; }
@media (max-width: 600px) {
 .history-job { grid-template-columns: minmax(0,1fr); }
 .history-job .action-link { width: 100%; }
}
