*{box-sizing:border-box}
.budget-page{background:#f6f8f9;color:#102638;overflow-x:hidden}
.budget-page .topbar{height:68px;padding:0 2%;gap:15px}
.budget-page .brand{min-width:245px}
.budget-page .nav-link{font-size:12px;padding:9px 7px;white-space:nowrap}
.budget-page .profile img{width:36px;height:36px;border-radius:50%;object-fit:cover}
.budget-layout{display:grid;grid-template-columns:230px minmax(510px,1fr) 305px;gap:12px;padding:10px 13px 25px;max-width:1920px;margin:auto;align-items:start}
.budget-sidebar,.budget-main,.budget-right{min-width:0}
.budget-menu{background:#fff;border:1px solid #e4ebef;border-radius:10px;padding:8px;display:grid;gap:3px}
.side-heading{font-size:17px;font-weight:750;padding:14px 12px;color:#132b39}.side-heading span{float:right;color:#53646c}
.budget-menu-item{height:40px;border:0;border-radius:7px;background:#fff;text-align:left;padding:0 12px;display:flex;align-items:center;gap:12px;font-family:inherit;font-size:14px;font-weight:500;color:#172b38;cursor:pointer}
.budget-menu-item span{width:22px;text-align:center;font-size:18px}.budget-menu-item:hover{background:#eff8f4}.budget-menu-item.active{background:linear-gradient(100deg,#0aa66e,#078e65);color:#fff;font-weight:700}
.current-project{margin-top:12px;border:1px solid #dcefe6;background:linear-gradient(180deg,#effaf4,#fff);border-radius:11px;padding:13px}
.current-project h3{font-size:14px;margin:0 0 10px;color:#087d5d}
.project-mini{display:flex;gap:9px;align-items:center}.project-mini img{width:70px;height:62px;border-radius:8px;object-fit:cover}.project-mini div{display:grid;gap:3px}.project-mini b{font-size:13px}.project-mini small{font-size:11px;color:#60717b}
.project-progress{height:6px;background:#e5eceb;border-radius:20px;margin-top:13px;overflow:hidden}.project-progress span{display:block;width:72%;height:100%;background:#0b9a70;border-radius:20px}.progress-caption{display:block;text-align:right;color:#53656d;font-size:11px;margin:4px 0 7px}
.plain-action{display:block;width:100%;text-align:left;text-decoration:none;border:0;background:transparent;padding:8px 3px;color:#253945;font-family:inherit;font-size:13px;cursor:pointer;border-radius:6px}.plain-action:hover{background:#eaf6f0}
.budget-banner{height:142px;border-radius:10px;background:linear-gradient(90deg,#f4f8f7 0%,#e8f1ef 52%,#d9e9e8 100%);position:relative;overflow:hidden;display:flex;align-items:center;padding:17px 18px;margin-bottom:11px;isolation:isolate}
.budget-banner:after{content:"";position:absolute;z-index:-1;right:0;top:0;width:44%;height:100%;background:url("assets/hero-house.jpg") center 48%/cover no-repeat;mask-image:linear-gradient(90deg,transparent 0%,#000 28%);opacity:.95}
.budget-banner h1{font-size:clamp(24px,2.15vw,34px);line-height:1.15;margin:0 0 6px;color:#102e42;letter-spacing:-.6px}.budget-banner p{font-size:14px;margin:0;color:#314e59}
.budget-script{position:absolute;right:18%;top:19px;font-family:Georgia,serif;font-style:italic;font-weight:600;line-height:1.35;color:#163f3a;text-shadow:0 1px 6px white;text-align:center;font-size:14px}
.budget-steps{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:7px;margin-bottom:12px}
.budget-step{height:41px;border:1px solid #e1e8eb;border-radius:8px;background:#fff;color:#263c49;display:flex;align-items:center;justify-content:center;gap:7px;font:600 11px inherit;cursor:pointer;white-space:nowrap}
.budget-step b{width:24px;height:24px;border-radius:50%;background:#edf1f4;display:grid;place-items:center;font-size:12px}.budget-step.active{border-color:#07966a;color:#064d3d;background:#f1fbf6;box-shadow:0 0 0 1px #d4f0e2 inset}.budget-step.active b{background:#078f67;color:#fff}
.kpi-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:9px;margin-bottom:12px}
.kpi{min-width:0;min-height:88px;border-radius:10px;padding:12px 10px;display:flex;align-items:center;gap:10px}
.kpi.green{background:#eefaf5}.kpi.blue{background:#eff6fd}.kpi.orange{background:#fff6ec}.kpi.purple{background:#f5f0ff}
.kpi-icon{flex:0 0 48px;width:48px;height:48px;border-radius:50%;display:grid;place-items:center;background:#d9f3e8;color:#078b62;font-size:27px}
.kpi.blue .kpi-icon{background:#dceeff;color:#1376d4}.kpi.orange .kpi-icon{background:#ffecd5;color:#ef8a12}.kpi.purple .kpi-icon{background:#e8ddff;color:#7846db}
.kpi div{min-width:0}.kpi small{display:block;font-size:10px;color:#425761;white-space:nowrap}.kpi strong{display:block;font-size:clamp(14px,1.3vw,20px);white-space:nowrap;color:#112c3b;margin:3px 0}.kpi em{font-size:10px;color:#657680;font-style:normal;white-space:nowrap}
.budget-visuals{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.12fr);gap:9px;margin-bottom:10px}
.house-preview{min-width:0}.preview-image{height:245px;position:relative;overflow:hidden;border-radius:9px;background:#e1e8e8}.preview-image>img{width:100%;height:100%;object-fit:cover;display:block}
.preview-tag{position:absolute;top:10px;left:10px;background:#0d3345d9;color:white;border-radius:6px;padding:7px 9px;font-size:11px;font-weight:700;line-height:1.35}.preview-tag small{font-weight:400}
.preview-expand{position:absolute;right:9px;bottom:9px;border:0;border-radius:6px;background:#0d3345c9;color:white;padding:7px 10px;cursor:pointer}
.preview-thumbs{display:flex;gap:6px;padding:6px 4px 0}.thumb{height:48px;flex:1;min-width:0;border:1px solid #dfe7e9;background:#fff;border-radius:6px;padding:3px;cursor:pointer}.thumb img{width:100%;height:100%;object-fit:cover;border-radius:4px}.thumb.active{border:2px solid #07966a;padding:2px}.add-thumb{max-width:82px;color:#536771;font-size:20px;display:flex;flex-direction:column;align-items:center;justify-content:center}.add-thumb small{font-size:9px}
.cost-chart-card{border:1px solid #e1e8eb;background:#fff;border-radius:10px;padding:12px;min-width:0}.cost-chart-card h2{font-size:17px;margin:0 0 12px}
.chart-content{display:grid;grid-template-columns:minmax(135px,.9fr) minmax(180px,1.1fr);gap:8px;align-items:center}
.donut-wrap{display:grid;place-items:center}.donut{width:min(190px,100%);aspect-ratio:1;border-radius:50%;background:conic-gradient(#1680e8 0 42%,#18b994 42% 77%,#ff9f16 77% 89%,#f04d30 89% 94%,#b447c9 94% 97%,#7bbd8b 97% 100%);display:grid;place-items:center;position:relative}
.donut:before{content:"";position:absolute;inset:18%;background:white;border-radius:50%}.donut>div{z-index:1;text-align:center;display:grid}.donut strong{font-size:27px;color:#102d40}.donut span{font-weight:700;font-size:13px}
.legend{display:grid;gap:8px}.legend-row{display:grid;grid-template-columns:12px minmax(65px,1fr) 35px minmax(88px,auto);gap:6px;align-items:center;font-size:11px}
.legend-dot{width:12px;height:12px;border-radius:50%}.legend-row b{text-align:right}.legend-row em{font-style:normal;text-align:right;border:1px solid #e5ebee;border-radius:5px;padding:7px 5px;white-space:nowrap;font-size:10px;color:#314650}
.detail-section{background:#fff;border:1px solid #e1e8eb;border-radius:10px;padding:10px;margin-bottom:10px}
.section-heading{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:7px}.section-heading h2{font-size:18px;margin:0;white-space:nowrap}.table-actions{display:flex;align-items:center;gap:6px}.table-actions>span{font-size:10px;color:#66757d;margin-right:3px}.table-actions button{border:1px solid #dce5e8;background:#fff;border-radius:6px;padding:7px 8px;font-size:10px;color:#2b424d;cursor:pointer;white-space:nowrap}.table-actions button:hover{background:#f0f8f4}.table-actions .export-btn{border-color:#07966a;color:#07845d;background:#f2fbf6;font-weight:700}
.table-wrap{overflow-x:auto}.cost-table{width:100%;border-collapse:collapse;min-width:680px;font-size:11px}.cost-table th{background:#f3f6f8;font-weight:700;white-space:nowrap}.cost-table th,.cost-table td{border:1px solid #dfe6e9;padding:7px 6px;text-align:center}.cost-table th:nth-child(2),.cost-table td:nth-child(2){text-align:left}.cost-table th button{border:0;background:transparent;font-weight:700;font-size:11px;cursor:pointer}.cost-table td:nth-child(2){min-width:180px}.cost-table tbody tr:hover{background:#f8fcfa}.cost-table td button{border:0;background:transparent;color:#1475d1;cursor:pointer;font-size:10px}.cost-table tfoot{background:#eaf8f2;color:#00563e;font-size:14px;font-weight:700}.cost-table tfoot td{padding:8px 6px}
.important-note{display:flex;gap:10px;margin-top:9px;background:#edf6ff;border-radius:8px;padding:10px;color:#164d82}.important-note>span{width:22px;height:22px;flex:0 0 22px;border-radius:50%;display:grid;place-items:center;background:#1685e6;color:white;font-weight:800}.important-note b{font-size:12px}.important-note p{font-size:10px;line-height:1.5;margin:3px 0 0;color:#405d75}
.below-panels{display:grid;grid-template-columns:1fr 1fr;gap:9px}.below-card{border:1px solid #e1e8eb;background:#fff;border-radius:10px;padding:12px}.below-card h3{font-size:14px;margin:0 0 10px}
.payment-list{display:grid;gap:6px}.payment-list>div{display:grid;grid-template-columns:1fr 42px minmax(90px,auto);gap:6px;align-items:center;font-size:11px;padding:5px 0;border-bottom:1px solid #edf0f1}.payment-list b{text-align:center;color:#07845e}.payment-list em{text-align:right;font-style:normal;color:#354b55}
.investment-options{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:7px}.investment-options button{border:1px solid #e2e8eb;border-radius:8px;background:#f9fbfc;padding:10px 4px;display:flex;flex-direction:column;align-items:center;gap:4px;cursor:pointer;color:#263d49}.investment-options button.chosen{border:1.5px solid #07966a;background:#f0faf5;box-shadow:0 0 0 1px #d8f1e4 inset}.investment-options b{font-size:11px}.investment-options strong{font-size:13px}.investment-options small{font-size:10px;color:#657680}.level-explain{font-size:10px;color:#60717a;margin:9px 0 0;line-height:1.4}
.right-card{background:#fff;border:1px solid #e2e9ec;border-radius:10px;padding:11px;margin-bottom:10px}.right-card h3{font-size:14px;margin:0 0 10px;color:#17323e}.right-title{display:flex;align-items:center;justify-content:space-between;margin-bottom:8px}.right-title h3{margin:0}.right-title button{border:0;background:none;color:#53636b;font-size:10px;cursor:pointer}
.parameters label{display:flex;align-items:center;justify-content:space-between;gap:5px;margin:6px 0;color:#304550;font-size:11px}.parameters input,.parameters select{width:125px;height:29px;border:1px solid #dce5e8;border-radius:6px;padding:4px 7px;background:#fff;color:#1b303d;font-family:inherit;font-size:11px}.parameters label span{display:flex;align-items:center;gap:4px}.parameters label span input{width:88px}.parameters.collapsed label,.parameters.collapsed .apply-button{display:none}
.apply-button{width:100%;height:34px;border:0;border-radius:7px;background:linear-gradient(100deg,#0aa66e,#078b63);color:#fff;font-weight:700;cursor:pointer;margin-top:7px;font-size:11px}
.investment-card .investment-options button{min-height:78px}.compare-options{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:6px}.compare-option{min-width:0;border:1px solid #e1e8eb;background:#fff;border-radius:7px;padding:4px;display:flex;flex-direction:column;gap:4px;align-items:stretch;cursor:pointer;color:#243b46}.compare-option.selected{border:1.5px solid #07966a;background:#fbfffd}.compare-option img{width:100%;height:66px;object-fit:cover;border-radius:5px}.compare-option b{font-size:10px}.compare-option small{font-size:9px;color:#60717a}.compare-option strong{font-size:15px}.compare-option em{font-style:normal;color:#07885e;font-size:9px}
.ai-cost-tip{display:flex;gap:7px;align-items:flex-start;background:#eef7ff;border-radius:8px;padding:8px;font-size:10px;line-height:1.45;color:#354d5b}.ai-cost-tip img{width:38px;height:38px;object-fit:contain;flex:0 0 38px}.ai-cost-card>button{width:100%;height:33px;border:0;border-radius:6px;background:#078e65;color:#fff;font-size:11px;font-weight:700;margin-top:7px;cursor:pointer}
.toast{position:fixed;bottom:22px;left:50%;transform:translate(-50%,20px);opacity:0;pointer-events:none;background:#123b36;color:#fff;padding:11px 16px;border-radius:9px;box-shadow:0 8px 25px #0002;z-index:70;font-size:13px;transition:.25s}.toast.show{opacity:1;transform:translate(-50%,0)}
.modal{display:none;position:fixed;inset:0;background:#071b25a8;z-index:80;align-items:center;justify-content:center;padding:18px}.modal.open{display:flex}.modal-box{width:min(520px,96vw);max-height:88vh;overflow:auto;background:#fff;border-radius:12px;padding:20px;position:relative;box-shadow:0 20px 60px #0003}.modal-box h2{font-size:20px;margin:0 0 7px}.modal-box p{font-size:12px;color:#64747c;line-height:1.5}.modal-close{position:absolute;right:12px;top:10px;border:0;background:#f0f3f4;border-radius:50%;width:30px;height:30px;font-size:20px;cursor:pointer}.rate-row{display:grid;grid-template-columns:1fr 90px 22px;gap:8px;align-items:center;padding:8px 0;border-bottom:1px solid #edf0f1;font-size:12px}.rate-row input{width:100%;border:1px solid #dce5e8;border-radius:6px;padding:7px}.modal-actions{display:flex;justify-content:flex-end;gap:8px;margin-top:15px}.modal-actions button{border:1px solid #dce5e8;border-radius:6px;padding:8px 14px;background:#fff;cursor:pointer}.modal-actions .apply-button{width:auto;margin:0}.item-detail-values{background:#f4faf7;border-radius:8px;padding:12px;font-size:12px;line-height:1.8}
.lightbox{display:none;position:fixed;inset:0;background:#061820ed;z-index:90;align-items:center;justify-content:center;padding:30px}.lightbox.open{display:flex}.lightbox img{max-width:95vw;max-height:88vh;object-fit:contain;border-radius:10px}.lightbox button{position:absolute;right:24px;top:20px;background:#fff;border:0;border-radius:50%;width:38px;height:38px;font-size:22px;cursor:pointer}
@media(max-width:1450px){.budget-layout{grid-template-columns:205px minmax(450px,1fr) 280px;gap:9px}.budget-page .brand{min-width:205px}.budget-page .nav-link{font-size:11px;padding:8px 5px}.preview-image{height:220px}.kpi{padding:9px 7px;gap:7px}.kpi-icon{flex-basis:40px;width:40px;height:40px}.chart-content{grid-template-columns:130px 1fr}.donut{width:130px}.legend-row{grid-template-columns:10px minmax(52px,1fr) 28px minmax(78px,auto);font-size:10px}}
@media(max-width:1120px){.budget-page .topbar{overflow-x:auto}.budget-layout{grid-template-columns:190px minmax(0,1fr)}.budget-main{grid-column:2}.budget-right{grid-column:2;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.budget-right .right-card{margin:0}.budget-sidebar{grid-row:1 / span 2}.kpi-grid{grid-template-columns:repeat(2,1fr)}}
@media(max-width:760px){.budget-page .topbar{height:auto;min-height:64px;flex-wrap:wrap;padding:7px 12px}.budget-page .brand{min-width:190px}.budget-page .brand-copy strong{font-size:23px}.budget-page .main-nav{order:3;overflow-x:auto;width:100%;flex-basis:100%;justify-content:flex-start}.budget-page .top-actions{margin-left:auto}.budget-layout{display:flex;flex-direction:column;padding:8px;width:100%}.budget-sidebar,.budget-main,.budget-right{width:100%}.budget-menu{grid-template-columns:repeat(2,minmax(0,1fr))}.side-heading{padding:8px}.current-project{display:none}.budget-banner{height:125px}.budget-script{display:none}.budget-steps{overflow-x:auto;grid-template-columns:repeat(5,minmax(125px,1fr))}.kpi-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.budget-visuals{grid-template-columns:1fr}.preview-image{height:240px}.chart-content{grid-template-columns:minmax(130px,.8fr) minmax(0,1.2fr)}.donut{width:min(180px,100%)}.section-heading{align-items:flex-start;flex-direction:column}.table-actions{flex-wrap:wrap}.budget-right{display:grid;grid-template-columns:1fr}.below-panels{grid-template-columns:1fr}}
@media(max-width:420px){.kpi{min-height:82px}.kpi-icon{width:34px;height:34px;flex-basis:34px;font-size:21px}.kpi strong{font-size:13px}.chart-content{grid-template-columns:1fr}.donut{width:155px}.legend{grid-template-columns:1fr 1fr}.legend-row{grid-template-columns:10px 1fr 24px}.legend-row em{grid-column:2/-1}.budget-menu{grid-template-columns:1fr 1fr}}
@media print{.topbar,.budget-sidebar,.budget-right,.budget-steps,.table-actions,.preview-thumbs,.toast{display:none!important}.budget-layout{display:block;padding:0}.budget-banner{height:90px}.budget-main{width:100%}.detail-section,.below-card{break-inside:avoid}.budget-page{background:white}}
.mbm-import-status{margin:10px 0 14px;padding:10px 13px;border:1px solid #cfe9dc;border-radius:8px;background:#f1faf5;color:#315b49;font-size:12px;line-height:1.5}
