:root{font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;color:#202b39;background:#f6f8fa;font-synthesis:none;--blue:#1766b0;--muted:#738090;--line:#e5e9ed}*{box-sizing:border-box}body{margin:0}button,input,select,textarea{font:inherit}button,a,input,select,summary{touch-action:manipulation}button{cursor:pointer}button:disabled{opacity:.5;cursor:wait}a{color:var(--blue)}header{height:88px;background:#fff;border-bottom:1px solid var(--line);display:flex;align-items:center;padding:0 max(5%,calc((100vw - 1220px)/2));gap:22px}.brand{background:#253344;border-radius:8px;padding:7px 12px;display:flex;align-items:center}.brand img{width:115px;height:36px;object-fit:contain}.header-title{font-size:17px;font-weight:650;border-left:1px solid var(--line);padding-left:22px;white-space:nowrap}.header-title span{display:block;font-size:8px;letter-spacing:1.8px;color:var(--muted);margin-top:5px}nav{margin-left:auto;display:flex;gap:18px;align-items:center}.text-button{border:0;background:none;color:var(--blue);padding:8px 0;font-size:13px}.small-button{background:#f0f5fa;color:#315779;border:0;border-radius:8px;padding:11px 20px;font-size:13px}main{max-width:1140px;margin:auto;padding:0 28px}.intro{max-width:760px;margin:64px 0 46px}.eyebrow{font-size:10px;letter-spacing:1.8px;font-weight:700;color:#62798e}h1{font-size:clamp(35px,4.5vw,55px);letter-spacing:-2.5px;line-height:1.12;font-weight:650;margin:18px 0 23px}h1 span{color:var(--blue)}.intro p{font-size:15px;color:#657181;line-height:1.75;max-width:650px;margin:10px 0}.intro strong{font-weight:550;color:#3c4b5d}.intro-footer{display:flex;gap:26px;font-size:11px;color:#758797;margin-top:24px}.workspace{display:grid;grid-template-columns:minmax(0,1fr) 290px;gap:28px;align-items:start}.card{background:#fff;border:1px solid var(--line);border-radius:18px;padding:32px;box-shadow:0 8px 24px #273e5904}.section-heading{display:flex;gap:16px;align-items:center;margin-bottom:30px}.step{font-size:12px;border:1px solid #dce8f3;background:#f5f9fd;color:#4079aa;border-radius:10px;padding:12px}h2{font-size:22px;letter-spacing:-.5px;margin:0 0 7px}h3{font-size:18px;letter-spacing:-.4px}p{line-height:1.6}.section-heading p{margin:0;color:var(--muted);font-size:12px}.grid{display:grid;gap:19px}.two{grid-template-columns:repeat(2,minmax(0,1fr))}.three{grid-template-columns:repeat(3,minmax(0,1fr))}label{display:block;font-size:12px;font-weight:550;color:#536172;margin-bottom:16px}input,select,textarea{display:block;width:100%;background:#fbfcfd;border:1px solid #dce2e8;border-radius:9px;padding:13px 12px;color:#27384a;margin-top:8px;min-height:45px;font-size:13px}input:focus,select:focus,textarea:focus{outline:3px solid #cce4fa;border-color:#6aa3d5}input[type=checkbox]{display:inline-block;width:16px;min-height:16px;margin:0;accent-color:var(--blue)}.check{display:flex;align-items:center;gap:10px;font-weight:400;line-height:1.5}.unit-input{position:relative}.unit-input input{padding-right:50px}.unit-input span{position:absolute;right:13px;top:16px;font-size:11px;color:#8c98a4}.system-note{background:#f2f7fc;color:#426687;font-size:12px;padding:13px 15px;border-radius:8px;margin:5px 0 23px;line-height:1.6}details{border-top:1px solid var(--line);padding:19px 0}summary{font-size:13px;font-weight:550;cursor:pointer;list-style:none}summary:before{content:'+';display:inline-block;width:23px;color:var(--blue)}details[open]>summary:before{content:'−'}summary span{float:right;font-size:10px;color:#95a0ab;font-weight:400}details[open]>summary{margin-bottom:20px}.hint{font-size:11px;color:#82909d;line-height:1.6}.form-end{margin-top:2px;border-top:1px solid var(--line);padding-top:16px}.primary{background:var(--blue);color:#fff;border:0;border-radius:10px;padding:15px 20px;font-weight:550;font-size:13px;transition:background .2s}.primary:hover{background:#0e5292}.form-end .primary{width:100%;display:flex;justify-content:space-between;margin-top:18px}.form-error{color:#b23434;font-size:12px}.summary-card{background:#edf3f8;border:1px solid #dfe7ee;border-radius:18px;padding:27px 25px}.summary-card h3{margin:13px 0}.roof-icon{padding:10px 0 16px}.roof-icon svg{width:100%}dl{font-size:11px;margin:0}dl div{display:flex;justify-content:space-between;margin:16px 0}dt{color:#778797}dd{margin:0;font-weight:550}.small-note{border-top:1px solid #d9e3ec;padding-top:18px;font-size:11px;line-height:1.8;color:#7e8e9d}.help-card{margin:25px 10px}.spark{color:#5994c8;font-size:26px}.help-card h3{font-size:14px;margin:9px 0}.help-card p{font-size:12px;color:#7e8b99}.help-card button{font-size:12px}footer{max-width:1140px;margin:46px auto 0;padding:27px 28px 32px;border-top:1px solid var(--line);display:flex;align-items:center;justify-content:space-between;color:#95a0a9;font-size:9px;letter-spacing:1.2px}dialog{border:1px solid var(--line);border-radius:18px;max-width:650px;width:calc(100% - 32px);padding:35px;max-height:88vh;color:#27384a;box-shadow:0 25px 100px #17273930}dialog::backdrop{background:#17273965;backdrop-filter:blur(4px)}.close{position:absolute;right:15px;top:10px;border:0;background:none;font-size:27px;color:#758595}dialog h2{margin-right:20px}dialog p{font-size:13px;color:#6d7d8c}dialog form{margin-top:24px}.tabs{display:flex;gap:18px;margin:20px 0;border-bottom:1px solid var(--line)}.tabs button{background:none;border:0;padding:10px 0;color:#7f8b98}.tabs button.active{color:var(--blue);border-bottom:2px solid var(--blue)}#toast{position:fixed;bottom:25px;left:50%;transform:translateX(-50%);background:#263a4f;color:white;padding:14px 25px;border-radius:12px;font-size:13px;display:none;z-index:100}.photos{display:flex;gap:8px;flex-wrap:wrap}.photos img{height:70px;width:90px;object-fit:cover;border-radius:7px}.results-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:28px}.metrics{display:grid;grid-template-columns:2fr 1fr 1fr;gap:18px;margin:22px 0}.metric{background:#fff;border:1px solid var(--line);border-radius:15px;padding:26px}.metric:first-child{background:#1766b0;color:#fff;border-color:#1766b0}.metric span{font-size:11px;opacity:.75}.metric strong{display:block;font-size:32px;letter-spacing:-1px;margin:12px 0 6px;font-weight:600}.metric small{font-size:10px;opacity:.7}table{width:100%;border-collapse:collapse;font-size:12px}th{text-align:left;font-size:10px;letter-spacing:.6px;color:#8491a0;font-weight:500;border-bottom:1px solid var(--line);padding:13px 9px}td{padding:17px 9px;border-bottom:1px solid #eef1f4}td small{display:block;color:#8a96a2;font-size:10px;margin-top:7px;line-height:1.5}.num{text-align:right;white-space:nowrap}.table-wrap{overflow-x:auto}.actions{display:grid;grid-template-columns:1fr 1fr;gap:20px;margin-top:25px}.action-card{border:1px solid var(--line);background:#fff;border-radius:16px;padding:25px}.action-card p{font-size:12px;color:#7d8996;min-height:38px}.secondary{background:#fff;border:1px solid #b6c9da;color:var(--blue);border-radius:10px;padding:14px 20px;font-size:13px}.alert{background:#fff8e9;border:1px solid #f2e4c7;border-radius:9px;font-size:11px;color:#8c6c32;padding:12px 15px;line-height:1.7;margin:14px 0}.status-row{display:flex;justify-content:space-between;border-bottom:1px solid var(--line);padding:12px 0;font-size:12px}.pill{background:#eef4fa;color:#4f7292;padding:4px 8px;border-radius:6px;font-size:10px}.saved-row{padding:18px 0;border-bottom:1px solid var(--line);display:flex;align-items:center;justify-content:space-between;gap:15px}.admin-field{max-width:100px;min-width:65px}.intro.hidden,.workspace.hidden{display:none}[hidden]{display:none!important}
@media(max-width:800px){header{padding:0 20px;height:76px;gap:12px}.header-title{font-size:14px;padding-left:12px}.header-title span{display:none}nav{gap:12px}nav .text-button{font-size:11px}.brand img{width:88px;height:30px}.brand{padding:5px 8px}main{padding:0 18px}.intro{margin:40px 0 30px}h1{letter-spacing:-1.4px}.workspace{grid-template-columns:1fr}.workspace aside{display:none}.card{padding:23px}.metrics{grid-template-columns:1fr 1fr}.metric:first-child{grid-column:span 2}.metric strong{font-size:28px}.actions{grid-template-columns:1fr}.three{grid-template-columns:1fr}.intro-footer{gap:14px;font-size:10px}.grid{gap:14px}summary span{font-size:9px}.results-header{align-items:flex-start;gap:15px}dialog{padding:28px 22px}footer span{font-size:8px}}
@media print{header,footer,.intro,.workspace,.actions,.no-print,dialog,#toast{display:none!important}body{background:white}main{max-width:none;padding:0}.card,.metric{box-shadow:none;break-inside:avoid}.metric:first-child{background:white;color:#202b39}.metric{padding:15px}.metrics{gap:10px}#results{display:block!important}table{font-size:10px}.table-wrap{overflow:visible}}
.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}.copilot-launch{position:fixed;right:26px;bottom:24px;z-index:40;border:1px solid #d6e2ef;border-radius:28px;background:#fff;color:#205e95;padding:14px 20px;box-shadow:0 6px 25px #24374d18;font-size:13px;font-weight:600}.copilot-panel{position:fixed;right:24px;bottom:85px;z-index:50;width:400px;max-height:calc(100dvh - 115px);background:#fff;border:1px solid #dce5ed;border-radius:20px;box-shadow:0 20px 80px #1d38562b;display:flex;flex-direction:column;overflow:hidden}.copilot-heading{display:flex;justify-content:space-between;align-items:center;padding:21px;border-bottom:1px solid #e8edf2}.copilot-heading strong{font-size:16px}.copilot-heading small{display:block;font-size:11px;color:#7c8a97;margin-top:5px}.copilot-heading button{background:none;border:0;font-size:25px;color:#8090a0}.copilot-messages{overflow-y:auto;min-height:100px;max-height:43dvh;padding:18px;overscroll-behavior:contain}.ai-message,.user-message{font-size:13px;line-height:1.65;margin-bottom:14px;white-space:pre-wrap}.ai-message>p{margin:0 0 10px}.user-message{background:#edf5fd;border-radius:13px;padding:12px;color:#345974;margin-left:25px}.user-message p{margin:0}.copilot-prompts{display:flex;gap:7px;overflow:auto;padding:0 17px 12px;flex-shrink:0}.copilot-prompts button{white-space:nowrap;border:1px solid #dce7f0;background:#f8fbfe;border-radius:16px;color:#51718d;padding:7px 10px;font-size:10px}#copilotForm{padding:0 18px 14px;overflow:auto;flex-shrink:0;max-height:40dvh}#copilotQuestion{resize:vertical;font-size:13px;max-height:160px;margin:0}.copilot-controls{display:flex;justify-content:space-between;align-items:center;margin-top:10px}.photo-attach{font-size:11px;color:var(--blue);cursor:pointer;margin:0}.copilot-controls .primary{padding:10px 16px;font-size:12px}#copilotForm .hint{font-size:9px;margin-bottom:0}#copilotError{font-size:11px;color:#9b4d25;line-height:1.6;margin-top:8px}.attachment-chip{border:0;border-radius:6px;padding:6px;font-size:10px;background:#edf3f8;color:#47647d;margin:5px 4px 0 0;max-width:100%;overflow:hidden}.ai-suggestions{white-space:normal;border:1px solid #dbe7f2;background:#f7fbff;padding:12px;border-radius:10px;margin-top:10px;font-size:11px}.ai-suggestions small{display:block;font-size:10px;color:#789}.ai-suggestions .secondary{font-size:11px;padding:9px}.ai-sources{font-size:10px;padding:9px 0}.ai-sources summary{font-size:10px}.ai-sources p{margin:6px 0;color:#789}@media(max-width:600px){.copilot-panel{right:10px;left:10px;width:auto;bottom:76px;max-height:calc(100dvh - 95px)}.copilot-launch{right:15px;bottom:16px;padding:12px 16px}footer{padding-bottom:80px}}
.term-comparison{display:grid;grid-template-columns:repeat(3,1fr);gap:12px;margin:24px 0}.term-option{background:#f6f9fc;border:1px solid #dce5ed;border-radius:12px;padding:18px 12px;text-align:center}.term-option>span{font-size:10px;letter-spacing:1px;color:#7290aa}.term-option h3{font-size:16px}.term-option>strong{font-size:21px;color:#225f95}.term-option p{font-size:11px}.term-option button{font-size:11px;padding:10px}.saved-photos{display:grid;grid-template-columns:1fr 1fr;gap:12px}.saved-photos img{width:100%;height:180px;object-fit:cover;border-radius:10px}@media(max-width:500px){.term-comparison{grid-template-columns:1fr}.term-option{text-align:left;display:grid;grid-template-columns:1fr 1fr;align-items:center;gap:4px 12px}.term-option h3,.term-option p{margin:5px 0}.term-option button{grid-column:2;grid-row:2 / 4}.saved-photos{grid-template-columns:1fr}}

.quote-actions{display:flex;align-items:center;gap:14px;flex-wrap:wrap;margin:24px 0}.quote-actions .hint{margin:0}@media(max-width:600px){.quote-actions button{flex:1}.quote-actions .hint{width:100%}}

.prep-group{padding:20px 0;border-bottom:1px solid #e3e8ef;margin-bottom:18px}.prep-group h3{margin:0 0 10px}.prep-group>label{margin-bottom:18px}

/* Persistent copilot beside both project entry and quote results. */
main{max-width:1320px}.project-layout{display:grid;grid-template-columns:minmax(0,1fr) 360px;gap:28px;align-items:stretch}.project-main{min-width:0}.workspace{display:block}.project-layout>aside{min-width:0;display:flex;flex-direction:column;gap:24px}#copilotMount{position:sticky;top:20px;margin-bottom:24px}.copilot-panel{position:relative;inset:auto;z-index:auto;width:100%;height:760px;max-height:none;border-radius:18px;box-shadow:0 8px 24px #273e5908}.copilot-messages{flex:1;min-height:220px;max-height:none}.copilot-prompts{flex-wrap:wrap;overflow:visible}.copilot-prompts button{white-space:normal;text-align:left}#copilotForm{max-height:none;overflow:visible}.copilot-heading{flex-shrink:0}.project-main .metric{padding:20px}.project-main .metric strong{font-size:27px}.project-main .results-header{flex-wrap:wrap}.project-main .results-header>.no-print{display:flex;flex-wrap:wrap;gap:8px 18px}.project-main .results-header br{display:none}
@media(max-width:1000px) and (min-width:801px){.project-layout{grid-template-columns:minmax(0,1fr) 320px;gap:20px}.project-main .metrics{grid-template-columns:1fr 1fr}.project-main .metric:first-child{grid-column:span 2}.project-main .actions{grid-template-columns:1fr}}
@media(max-width:800px){.project-layout{grid-template-columns:1fr}.project-layout>aside{display:flex}.project-layout .summary-card{display:none}#copilotMount{position:static;margin:0}.copilot-panel{position:relative;inset:auto;width:100%;height:680px;max-height:none}.copilot-messages{min-height:200px}footer{padding-bottom:32px}}
@media print{.project-layout{display:block}.project-layout>aside{display:none!important}}

.roof-caption{font-size:10px;line-height:1.5;color:#62798e;text-align:center;margin-top:4px}

/* Lead the sidebar with AI; keep the sidebar in view without covering its summary. */
@media(min-width:801px){.project-layout>aside{position:sticky;top:20px;align-self:start;max-height:calc(100dvh - 40px);overflow-y:auto;overscroll-behavior:contain}#copilotMount{position:static;margin-bottom:0;flex-shrink:0}.copilot-panel{height:min(760px,calc(100dvh - 40px))}.copilot-messages{min-height:80px}#copilotForm{flex-shrink:1;overflow-y:auto;min-height:160px}}
@media(max-width:800px){.project-layout>aside{order:-1}.copilot-panel{height:600px}}

/* Intro and live roof summary share the same columns as the builder and AI. */
.project-overview{display:grid;grid-template-columns:minmax(0,1fr) 360px;gap:28px;margin:36px 0 28px;align-items:stretch}.project-overview .intro{max-width:none;margin:0;padding:30px 32px}.project-overview h1{font-size:clamp(30px,3.2vw,44px);letter-spacing:-1.7px;margin:16px 0 20px}.project-overview .intro p{font-size:14px;line-height:1.65}.project-overview .summary-card{display:flex;flex-direction:column;justify-content:center}.project-overview .roof-icon{max-width:280px;width:100%;align-self:center}.project-overview.hidden{display:none}
@media(min-width:801px) and (max-width:1000px){.project-overview{grid-template-columns:minmax(0,1fr) 320px;gap:20px}}
@media(max-width:800px){.project-overview{grid-template-columns:1fr;margin-top:24px;gap:18px}.project-overview .intro{padding:24px}.project-overview .summary-card{display:block}.project-overview .roof-icon{max-width:240px;margin:auto}}

/* The roof form sets the row height; AI fills it without lengthening the grid. */
@media(min-width:801px){
 .project-layout>aside{position:relative;top:auto;align-self:stretch;max-height:none;overflow:visible;min-height:0}
 #copilotMount{position:absolute;inset:0;margin:0;min-height:0}
 .copilot-panel{height:100%;max-height:100%;min-height:0}
 .copilot-messages{min-height:0;overflow-y:auto}
 #copilotForm{min-height:0;flex-shrink:0}
 .project-layout:has(#results:not([hidden])) #copilotMount{position:sticky;inset:auto;top:20px;height:min(760px,calc(100dvh - 40px))}
}
@media(min-width:801px){#copilotMount .copilot-panel{position:absolute;inset:0;height:auto;max-height:none}}

.project-overview .roof-icon{max-width:320px;padding:4px 0 12px}.roof-caption{font-size:10px;line-height:1.5;text-align:center;color:#647c90}

.area-entry{min-width:0}.area-entry>label{margin-bottom:8px}.area-controls{display:flex;gap:8px}.area-controls input{min-width:0;flex:1;margin:0}.area-controls select{width:140px;margin:0}.area-entry .hint{margin:7px 0 16px}.quantity-details{margin-top:12px}.quantity-details table{font-size:12px}.quantity-details td{padding:12px 8px}.term-difference{color:#1766b0;min-height:36px;font-weight:600}@media(max-width:500px){.area-controls{flex-direction:column}.area-controls select{width:100%}.term-difference{grid-column:1/-1}.quantity-details summary span{display:none}}

/* Finish pass: consistent surfaces, readable secondary text, and tactile controls. */
:root{--muted:#5f7081;--line:#dfe6ed}body{-webkit-font-smoothing:antialiased;background:linear-gradient(145deg,#f8fafc,#f1f5f9);background-attachment:fixed}button,a,input,select,textarea,summary{-webkit-tap-highlight-color:transparent}button,a,summary{transition:background-color .16s,border-color .16s,box-shadow .16s}button:focus-visible,a:focus-visible,summary:focus-visible{outline:3px solid #88bbed;outline-offset:4px}button:disabled{cursor:not-allowed}button:not(:disabled):active{transform:translateY(1px)}.primary{background:linear-gradient(135deg,#176bb6,#125a9c);box-shadow:0 3px 8px #1260a21a;font-weight:600}.secondary{font-weight:600;border-color:#a4bcd1}.secondary:hover{background:#f1f7fc;border-color:#4e89ba}.text-button:hover{color:#104b81;text-decoration:underline;text-underline-offset:4px}.small-button:hover{background:#e2edf7}.card,.summary-card,.copilot-panel{box-shadow:0 2px 5px #1d354306,0 12px 32px #1d354305;border-color:#dfe6ed}.project-overview .intro{background:linear-gradient(135deg,#fff 65%,#f5f9fd)}.project-overview .summary-card{background:linear-gradient(145deg,#edf4fa,#e5eef6)}.project-overview h1{text-wrap:balance}.intro-footer{flex-wrap:wrap;row-gap:10px}.hint,.small-note,dt,.section-heading p,.action-card p,td small{color:#607284}.hint{font-size:12px}.small-note{font-size:12px}.intro p{color:#536578}.eyebrow{color:#526b81}.summary-card dl{font-size:12px}.summary-card dd,.metric strong,.num,.status-row strong,.term-option>strong{font-variant-numeric:tabular-nums}.roof-caption{color:#526b81}.section-heading{margin-bottom:26px}label{font-size:13px;color:#40556a}input,select,textarea{background:#fafcfe;border-color:#cbd7e2;min-height:48px;font-size:14px}input:hover,select:hover,textarea:hover{border-color:#9eb7cc}summary{min-height:24px;color:#354e63}summary span{color:#64788a}summary::-webkit-details-marker{display:none}.system-note{border:1px solid #dfebf6;border-left:3px solid #6c9fc9}.copilot-heading{background:linear-gradient(110deg,#f4f9fd,#fff);padding:22px}.copilot-heading strong:before{content:'✦';color:#2477b9;margin-right:8px}.copilot-heading small{color:#5d7487}.copilot-prompts button{font-size:11px;color:#3e6382;min-height:34px;padding:8px 11px}.copilot-prompts button:hover{background:#eaf3fb;border-color:#9cbdd8}.photo-attach{min-height:36px;display:flex;align-items:center}#copilotForm .hint{font-size:10px;color:#627588}.copilot-controls .primary{min-height:40px}.metric:first-child{background:linear-gradient(130deg,#146bb8,#134b84);border-color:#185d99;box-shadow:0 8px 24px #135c9b16}.metric span,.metric small{opacity:1}.metric:not(:first-child) span,.metric:not(:first-child) small{color:#607284}.metric:first-child small{color:#e0edf8}.project-main .metric strong{font-size:clamp(24px,2.2vw,32px)}th{color:#536c82;background:#f6f9fc;font-weight:600}td small{font-size:11px}tbody tr:hover{background:#f8fbfd}.status-row{font-size:14px}.quote-actions{gap:10px}#compareBtn{background:#eff6fd;border-color:#87afd2}#compareBtn:hover{background:#e2effa;border-color:#377eb6}.term-option{background:#f7fafd}.term-option:has(button.primary){background:#edf5fc;border-color:#5595ca;box-shadow:0 0 0 1px #5595ca}.term-option p{color:#536d82}.term-option .term-difference{color:#145e9a}.close{width:40px;height:40px;right:10px;top:8px;border-radius:50%;line-height:1}.close:hover{background:#edf3f8}#toast{max-width:calc(100vw - 32px);width:max-content;line-height:1.5}.mobile-project-nav{display:none}.saved-row>div{min-width:0;overflow-wrap:anywhere}.roof-icon svg{display:block}.form-end .primary{min-height:50px}#roofForm,#copilotMount{scroll-margin-top:76px}
@media(max-width:800px){header{height:auto;min-height:76px;flex-wrap:wrap;padding:16px 20px;gap:12px}header nav{width:100%;margin:0;justify-content:space-between;gap:12px;border-top:1px solid #edf1f5;padding-top:8px}header nav button{min-height:40px}.header-title{font-size:16px}.header-title span{display:block;font-size:8px}.mobile-project-nav{display:flex;position:sticky;top:8px;z-index:20;margin:0 0 18px;padding:6px;gap:8px;background:#ffffffed;border:1px solid #d9e4ee;border-radius:12px;box-shadow:0 5px 18px #233f5410;backdrop-filter:blur(12px)}.mobile-project-nav a{flex:1;text-align:center;padding:11px 8px;border-radius:8px;font-size:13px;font-weight:600;text-decoration:none}.mobile-project-nav a:first-child{background:#edf5fc}.project-layout>aside{order:0}.copilot-panel{height:560px}.copilot-messages{min-height:0}.project-overview .summary-card{padding:24px}.project-overview .roof-icon{max-width:230px}.quote-actions button{min-height:46px}.quote-actions #compareBtn{flex-basis:100%}.project-main .results-header{margin-top:24px!important}.project-main .results-header>.no-print{gap:8px 16px}.project-main .results-header .text-button{min-height:36px}input,select,textarea,#copilotQuestion{font-size:16px}.copilot-controls .primary{min-height:44px}.copilot-prompts button{min-height:40px}footer{gap:20px;flex-wrap:wrap}}
@media(max-width:480px){main{padding:0 14px}.card{padding:22px 18px}.project-overview .intro{padding:26px 22px}.project-overview h1{font-size:33px;letter-spacing:-1.2px}.project-overview .intro p{font-size:14px}.two{grid-template-columns:1fr}.grid{gap:2px}.area-controls{flex-direction:row}.area-controls select{width:145px;font-size:14px}.area-entry{margin-bottom:12px}.metrics{gap:10px}.project-main .metric{padding:17px 14px}.project-main .metric strong{font-size:26px}.metric span{font-size:10px}.metric small{font-size:11px}.quote-actions button{flex:1 1 auto}.results-header h2{font-size:26px}.term-option{display:block;padding:20px}.term-option button{width:100%;min-height:44px;margin-top:8px}.term-option>strong{display:block;margin:10px 0}.term-option .term-difference{min-height:0}.quantity-details summary span{display:none}dialog{padding:30px 20px}.intro-footer{font-size:10px;gap:12px}.section-heading{gap:12px}h2{font-size:21px}.check{line-height:1.6}input[type=checkbox]{flex-shrink:0}.summary-card .small-note{line-height:1.6}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{scroll-behavior:auto!important;transition:none!important;animation:none!important}}
@media print{body{background:#fff}.mobile-project-nav,.project-overview{display:none!important}.metric:first-child{background:#fff;color:#202b39;box-shadow:none}.metric:first-child small{color:#536578}th{background:#fff}}

#projectMain{scroll-margin-top:76px}

.selling-worksheet h3{margin-top:28px}.selling-worksheet .ws-metrics{grid-template-columns:1fr 1fr;margin-top:24px}.selling-worksheet [hidden]{display:none!important}.selling-worksheet .status-row{gap:16px}.selling-worksheet .status-row strong{white-space:nowrap}@media(max-width:560px){.selling-worksheet .ws-metrics{grid-template-columns:1fr}}

/* Clear, button-shaped actions throughout the app. */
.text-button,.photo-attach,.tabs button,a:not(.brand):not(.saved-photos a){display:inline-flex;align-items:center;justify-content:center;gap:6px;border:1px solid #cbd9e5;background:#f3f7fb;color:#284e70;border-radius:9px;padding:10px 14px;min-height:40px;font-size:12px;font-weight:550;text-decoration:none;cursor:pointer;line-height:1.3}
.text-button:hover,.photo-attach:hover,.tabs button:hover,a:not(.brand):not(.saved-photos a):hover{background:#e5eff8;border-color:#91b1ce;text-decoration:none}
.text-button:focus-visible,.photo-attach:focus-visible,a:focus-visible{outline:3px solid #a7cbed;outline-offset:3px}
.tabs{flex-wrap:wrap;padding-bottom:12px;gap:10px}.tabs button.active{background:#dfeefb;border:1px solid #8eb4d5;color:#204a70}
.result-utilities{display:flex;gap:8px;flex-wrap:wrap;justify-content:flex-end;max-width:290px}
.material-metrics{grid-template-columns:minmax(0,1.6fr) minmax(0,1fr)}
.selling-worksheet{margin:0 0 24px}.selling-worksheet>details{border-top:0;padding:0}.selling-worksheet>details>summary{background:#edf4fb;border:1px solid #cbdceb;border-radius:10px;padding:14px;font-size:15px;color:#294b69}.selling-worksheet>details>summary span{color:#536b7f}
@media(max-width:600px){.result-utilities{max-width:none;justify-content:flex-start}.material-metrics{grid-template-columns:minmax(0,1.3fr) minmax(0,1fr);gap:10px}.material-metrics .metric{padding:16px}.material-metrics .metric strong{font-size:25px}.material-metrics .metric span{font-size:9px}.selling-worksheet>details>summary span{float:none;display:block;margin:6px 0 0 23px}header nav{gap:6px}header nav .text-button{padding:9px 10px}.copilot-controls .photo-attach{padding:10px}}

.copilot-photo-invite{margin:14px 18px 0;padding:15px;background:#edf5fc;border:1px solid #d7e5f1;border-radius:12px;flex-shrink:0}.copilot-photo-invite strong{font-size:13px}.copilot-photo-invite p{font-size:12px;line-height:1.5;margin:7px 0 10px;color:#50677b}.copilot-photo-invite .secondary{width:100%;padding:11px;font-size:12px}.copilot-photo-invite small{display:block;font-size:10px;line-height:1.5;margin-top:8px;color:#607487}@media(max-width:900px){#copilotMount .copilot-panel{height:760px}}

.measure-dialog{width:calc(100% - 32px);max-width:1180px;padding:28px;max-height:94vh}.measure-search{display:flex;gap:10px;align-items:center}.measure-search input{margin:0;flex:1}.measure-search button{flex-shrink:0}.measure-layout{display:grid;grid-template-columns:minmax(0,2fr) minmax(240px,1fr);gap:24px}#roofMap{height:480px;border-radius:12px;background:#dce5ed;isolation:isolate}.measure-buttons{display:flex;gap:8px;flex-wrap:wrap}.measure-buttons button{padding:11px 14px}.measure-tools p,#mapStatus{font-size:12px}.measure-dialog .status-row{gap:12px}.measure-dialog .status-row button{flex-shrink:0}.measure-dialog .check{line-height:1.7;flex-wrap:wrap}.measure-dialog .leaflet-control a{padding:0;min-height:0;display:block;border-radius:0}.measure-dialog .leaflet-control-attribution{font-size:9px}#mapMatches{display:flex;gap:8px;flex-wrap:wrap}.copilot-photo-invite button+button{margin-top:8px}.copilot-photo-invite{padding:12px}.measure-tools label{margin-bottom:12px}@media(max-width:780px){.measure-layout{grid-template-columns:1fr}#roofMap{height:360px}.measure-dialog{padding:22px 16px}.measure-search{flex-wrap:wrap}.measure-search input{flex-basis:100%}.measure-search button{width:100%}.measure-dialog .status-row{align-items:flex-start}.measure-dialog .check{display:block}}

/* Sculpted controls: softly recessed finger pad inside a highlighted rim. */
:is(.primary,.secondary,.text-button,.small-button,.photo-attach,.copilot-prompts button,.tabs button,.mobile-project-nav a),#compareBtn{
 border:1px solid #bccddd;border-radius:12px;
 background:radial-gradient(ellipse at 50% 44%,#dce7f1 0%,#edf3f8 58%,#fff 100%);
 color:#254765;text-shadow:0 1px 0 #ffffffc0;
 box-shadow:inset 0 1px 0 #fff,inset 0 3px 5px #56789516,inset 0 -2px 0 #ffffffc9,0 2px 0 #b7c8d8,0 4px 7px #203e5b12;
 font-weight:600;transition:transform .12s ease,box-shadow .12s ease,border-color .12s ease,filter .12s ease;
}
button.primary,#copilotSend{
 border-color:#205a90;color:#fff;text-shadow:0 1px 1px #082e5b70;
 background:radial-gradient(ellipse at 50% 43%,#1d5591 0%,#2869a8 60%,#4688bd 100%);
 box-shadow:inset 0 1px 0 #90c8f08c,inset 0 3px 6px #062b573d,inset 0 -2px 0 #6da5d05c,0 2px 0 #123f6d,0 5px 9px #123f6d26;
}
@media(hover:hover){
 :is(.primary,.secondary,.text-button,.small-button,.photo-attach,.copilot-prompts button,.tabs button,.mobile-project-nav a):not(:disabled):hover,#compareBtn:not(:disabled):hover{filter:brightness(1.045);transform:translateY(-1px);text-decoration:none}
 .primary:hover{background:radial-gradient(ellipse at 50% 43%,#1d5591 0%,#2869a8 60%,#4688bd 100%)}
 :is(.secondary,.text-button,.small-button,.photo-attach,.copilot-prompts button,.tabs button,.mobile-project-nav a):hover,#compareBtn:hover{background:radial-gradient(ellipse at 50% 44%,#dce7f1 0%,#edf3f8 58%,#fff 100%)}
}
:is(.primary,.secondary,.text-button,.small-button,.photo-attach,.copilot-prompts button,.tabs button,.mobile-project-nav a):not(:disabled):active,#compareBtn:not(:disabled):active{
 transform:translateY(2px);filter:brightness(.98);box-shadow:inset 0 2px 5px #1b3d6133,inset 0 -1px 0 #ffffff80,0 0 0 transparent;
}
:is(.primary,.secondary,.text-button,.small-button,.photo-attach,.copilot-prompts button,.tabs button):disabled{box-shadow:inset 0 1px 2px #1b3d6112;transform:none;filter:none}
.tabs button.active{border-color:#678eaf;background:radial-gradient(ellipse,#cfdfed,#ecf4fb);box-shadow:inset 0 2px 4px #24486c25,inset 0 -1px 0 #fff}
@media(prefers-reduced-motion:reduce){:is(.primary,.secondary,.text-button,.small-button,.photo-attach,.copilot-prompts button,.tabs button,.mobile-project-nav a),#compareBtn{transition:none;transform:none!important}}

#uploadRoofReport{display:block;width:100%;margin-top:8px}#roofReportStatus{display:block;margin-top:6px}

#projectIntake{margin:24px 0 0;padding:20px 0 0;border-top:1px solid #e1e8ef}
#projectIntake .copilot-photo-invite{margin:0;padding:0;border:0;background:none;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}
#projectIntake strong,#projectIntake p,#projectIntake small{grid-column:1/-1}
#projectIntake strong{font-size:16px}
#projectIntake p{margin:0 0 5px;font-size:13px}
#projectIntake .secondary{margin:0;min-height:46px;font-size:13px}
#projectIntake #roofReportStatus{margin:0}
#projectIntake small{margin:0}
@media(max-width:650px){#projectIntake{padding:18px 0 0}#projectIntake .copilot-photo-invite{grid-template-columns:1fr}}

.roof-report-review{width:calc(100% - 32px);max-width:1240px;max-height:94dvh;padding:26px;overflow:auto}
.review-heading{display:flex;align-items:flex-start;justify-content:space-between;gap:20px;margin-bottom:18px}
.review-heading h2{margin:0 0 8px}.review-heading p{margin:0;color:#607284;font-size:13px}
.review-layout{display:grid;grid-template-columns:minmax(0,1.5fr) minmax(290px,1fr);gap:24px}
.review-document{min-width:0}.review-document>strong{display:block;overflow-wrap:anywhere}
.review-document iframe{width:100%;height:60dvh;min-height:330px;border:1px solid #dce5ed;border-radius:10px;background:#f1f4f7}
.review-pdf-toolbar{display:flex;align-items:center;flex-wrap:wrap;gap:8px;margin:12px 0}
.review-pdf-toolbar label{display:flex;align-items:center;gap:8px;margin:0;font-size:12px}
.review-pdf-toolbar input{width:65px;margin:0;padding:9px}.review-pdf-toolbar a{text-decoration:none;display:inline-flex}
.review-pdf-toolbar .secondary{font-size:12px;padding:10px}
.review-change{display:flex;align-items:flex-start;gap:12px;padding:16px;margin:0 0 10px;border:1px solid #dbe5ef;border-radius:12px;background:#f7fafd;cursor:pointer}
.review-change input{width:18px;height:18px;flex-shrink:0;margin:3px 0}
.review-change span{display:block;min-width:0}.review-change strong{display:block;font-size:14px}
.review-change span span{margin:6px 0;font-size:15px}.review-change small{display:block;font-size:12px;color:#5c7185;line-height:1.5;overflow-wrap:anywhere}
.review-error{color:#a52e36;font-size:13px}.review-apply{width:100%}
.without-report{max-width:640px}.without-report .review-layout{grid-template-columns:1fr}
@media(max-width:760px){.review-layout{grid-template-columns:1fr}.roof-report-review{padding:18px}.review-document iframe{height:42dvh;min-height:260px}.review-heading h2{font-size:21px}}

.cap-offer{margin-top:22px;padding:18px;background:#edf5fb;border:1px solid #c9ddeb;border-radius:14px;display:flex;align-items:center;gap:16px}
.cap-offer strong{display:block;font-size:16px;line-height:1.4}.project-overview .cap-offer p{margin:6px 0;font-size:13px}
.cap-offer small{font-size:11px;color:#607284}.cap-offer button{flex-shrink:0;font-size:12px}
.cap-reward{display:flex;justify-content:space-between;align-items:center;gap:20px;padding:18px 22px;margin:18px 0;border:1px solid #c9ddeb;border-radius:14px;background:#edf5fb}
.cap-reward p{font-size:13px;color:#607284;margin:6px 0 0}.cap-reward button{flex-shrink:0}
@media(max-width:1000px){.cap-offer{flex-direction:column;align-items:stretch}}
@media(max-width:600px){.cap-reward{flex-direction:column;align-items:stretch}}

header nav{flex-wrap:wrap;justify-content:flex-end}@media(max-width:800px){header nav{justify-content:flex-start}}

.measurement-reader{margin-top:16px;padding:18px;background:#f5f9fc;border:1px solid #d6e3ee;border-radius:12px}
.measurement-reader[hidden]{display:none}.measurement-reader p{font-size:13px}
.measurement-reader textarea{width:100%;margin-top:7px}
#readerMessages{margin-top:16px;max-height:480px;overflow:auto}
#readerError{color:#a52e36;font-size:13px;margin-top:10px}
#readerAttachments{display:flex;flex-wrap:wrap;gap:8px;margin:12px 0}

.roof-input-details{margin-top:24px}.roof-input-details h3{font-size:16px;margin:0 0 8px}
.solution-choices{border-top:1px solid #dfe6ed;padding-top:28px;margin-top:24px}
.solution-choices .section-heading{margin-bottom:20px}

.project-main .results-header{display:flex;flex-direction:column;align-items:stretch;gap:14px}
.project-main .results-header .result-utilities{max-width:none;width:100%;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;justify-content:start}
.project-main .results-header .result-utilities button{min-width:0;padding:10px 8px;font-size:12px;text-align:center}

.saved-report-measurements>div{display:flex;justify-content:space-between;gap:16px;padding:6px 0;border-bottom:1px solid #e7edf3}
.saved-report-measurements dd{margin:0}.report-measurements{margin-top:20px}

.primer-summary{margin:18px 0;padding:18px 20px;border:1px solid #dce5ec;border-radius:16px;background:#f7fafc}.primer-summary h3{margin:6px 0 12px}.primer-summary-item p{margin:5px 0}.primer-summary-item+.primer-summary-item{margin-top:12px;padding-top:12px;border-top:1px solid #dce5ec}

.sop-steps{display:grid;gap:12px}.sop-step{padding:18px;border:1px solid #dce5ec;border-radius:16px;background:#f8fafc}.sop-step h3{display:flex;align-items:center;gap:10px;margin:0 0 14px}.sop-number{display:inline-flex;align-items:center;justify-content:center;width:27px;height:27px;flex-shrink:0;border-radius:50%;background:#e2edf7;color:#24577c;font-size:13px}.sop-step .hint:last-child{margin-bottom:0}

.coating-choice{margin:0 0 20px;padding:18px;border:1px solid #bcd2e4;border-radius:16px;background:#eef5fb}.coating-choice h3{margin:0 0 14px}#coatingSummary p{margin:8px 0}

.ai-message ul{margin:0;padding-left:20px}.ai-message li{padding-left:3px;margin:0 0 9px;line-height:1.5}.ai-message li:last-child{margin-bottom:0}

.system-card-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px;margin-bottom:12px}.system-card{min-width:0;min-height:105px;padding:10px 5px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;border:1px solid #bacddd;border-radius:12px;background:#fff;color:#244b68;text-align:center;font-size:12px;line-height:1.25;white-space:normal}.system-card[aria-pressed=true]{border-color:#1976b8;box-shadow:0 0 0 2px #1976b8;background:#e3f2ff}.system-card small{font-size:10px;color:#65798a}.system-stack{position:relative;width:48px;height:35px;display:block}.system-stack i{position:absolute;left:5px;top:calc(3px + var(--depth)*7px);width:36px;height:20px;background:var(--layer);transform:skewY(-15deg);border:1px solid #54738c;border-radius:3px;z-index:calc(5 - var(--depth));box-shadow:2px 3px 0 #57748c55}@media(max-width:400px){.system-card-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}

.system-card{padding:6px 5px 12px;min-height:150px;gap:4px;background:linear-gradient(155deg,#fff,#eaf1f7);box-shadow:0 3px 7px #24435b12,inset 0 1px 0 #fff;transition:transform .15s,box-shadow .15s}.system-cutaway{display:block;width:100%;max-width:150px;height:auto;overflow:visible}.system-card>span{font-weight:650;font-size:12px;min-height:30px;display:flex;align-items:center;justify-content:center}.system-card:hover{transform:translateY(-2px);box-shadow:0 6px 12px #24435b20}.system-card[aria-pressed=true]{background:linear-gradient(155deg,#fff,#dbeeff);box-shadow:0 0 0 2px #1976b8,0 5px 12px #1976b824}.system-card:focus-visible{outline:3px solid #1976b8;outline-offset:3px}@media(prefers-reduced-motion:reduce){.system-card{transition:none}.system-card:hover{transform:none}}

#copilotPanel #copilotForm{padding:16px 18px;border-bottom:1px solid #e1e9f0;max-height:none;overflow:visible;flex:0 0 auto;background:#fff}#copilotPanel .copilot-controls{justify-content:flex-end}#copilotPanel .copilot-messages{flex:1 1 auto;min-height:0}

#overviewCopilot{position:relative;min-width:0;min-height:600px}#overviewCopilot #copilotMount{position:absolute;inset:0;margin:0}#overviewCopilot #copilotPanel{position:absolute;inset:0;height:100%;max-height:none}#roofPreviewAside{position:sticky;top:20px;align-self:start;max-height:none;overflow:visible}#roofPreviewAside .summary-card{display:block;width:100%;background:linear-gradient(145deg,#edf4fa,#e5eef6)}#roofPreviewAside .roof-icon{width:100%;max-width:300px;margin:auto}#roofPreviewAside #copilotMount{position:relative;inset:auto}#roofPreviewAside #copilotPanel{position:relative;inset:auto;height:650px;max-height:calc(100dvh - 40px)}#roofPreviewAside:has(#copilotMount) .summary-card{display:none}@media(max-width:800px){#overviewCopilot{min-height:540px}#roofPreviewAside{position:static;order:-1}#roofPreviewAside .summary-card{display:block}.project-layout:has(#results:not([hidden])) #roofPreviewAside .summary-card{display:none}}

/* Product choice and live description share each application-step row. */
.product-choice-row{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:16px;align-items:stretch;margin:12px 0}
.product-choice-row>label{min-width:0;margin:0}
.product-choice-row select{width:100%;min-width:0;text-overflow:ellipsis}

/* Non-production visual handoff into the ecosystem portal. */
#results[hidden]+.roll-portal-card{display:none}
.roll-portal-card{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:28px;margin:24px 0 8px;padding:28px 30px;color:#fff;background:radial-gradient(circle at 90% 0%,#4ba7d548,transparent 36%),linear-gradient(125deg,#26394b,#174f78);border:1px solid #315f7f;border-radius:18px;box-shadow:0 15px 38px #173a551c}
.roll-portal-card .eyebrow{color:#9dd7ee}
.roll-portal-card h2{margin:8px 0;color:#fff;font-size:25px;letter-spacing:-.7px}
.roll-portal-card p{max-width:720px;margin:0;color:#c9dce8;font-size:13px;line-height:1.65}
.roll-portal-card small{display:block;margin-top:10px;color:#96b3c6;font-size:10px;line-height:1.5}
.roll-portal-action{display:inline-flex;align-items:center;justify-content:space-between;gap:30px;min-width:195px;text-decoration:none;white-space:nowrap;background:linear-gradient(135deg,#218ac1,#1766a9)}
.roll-portal-action:hover{background:linear-gradient(135deg,#1d78a9,#12568f);text-decoration:none}
@media(max-width:700px){.roll-portal-card{grid-template-columns:1fr;padding:24px 22px}.roll-portal-action{width:100%}}
@media print{.roll-portal-card{display:none!important}}
.product-choice-description{min-width:0;padding:14px 16px;border:1px solid #dce5ed;border-radius:12px;background:#f5f8fb;color:#425466;font-size:13px;line-height:1.5}
.product-choice-description strong{display:block;color:#203c53;margin-bottom:5px;font-size:14px}
@media(max-width:640px){.product-choice-row{grid-template-columns:1fr;gap:8px}}
.roof-walk-entry{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:18px;margin-top:16px;padding:16px 18px;color:#244963;background:#edf6fb;border:1px solid #cfe3ef;border-radius:12px;text-decoration:none}
.roof-walk-entry:hover{color:#173e5a;background:#e4f1f8;border-color:#96bdd4}
.roof-walk-entry strong,.roof-walk-entry small{display:block}
.roof-walk-entry strong{font-size:14px}
.roof-walk-entry small{margin-top:4px;color:#607789;font-size:10px;line-height:1.45}
.roof-walk-entry b{display:grid;place-items:center;width:30px;height:30px;color:#fff;background:#1766b0;border-radius:9px}
@media(max-width:480px){.roof-walk-entry{padding:14px}.roof-walk-entry small{font-size:9px}}
