:root{
  --navy:#041b52;
  --navy-2:#0a2d74;
  --blue:#2458d3;
  --green:#239847;
  --green-soft:#eaf8ee;
  --yellow:#ea9b07;
  --yellow-soft:#fff7df;
  --red:#ef2d31;
  --red-soft:#fff0f0;
  --line:#d7e1ef;
  --text:#13254b;
  --muted:#5f7190;
  --bg:#f6f8fc;
  --card:#ffffff;
  --shadow:0 6px 18px rgba(12,33,75,.05);
}
*{box-sizing:border-box}
body{margin:0;font-family:Arial,Helvetica,sans-serif;background:var(--bg);color:var(--text)}
.top-nav{background:linear-gradient(90deg,var(--navy),#082862);color:#fff;height:84px;padding:0 26px;display:flex;align-items:center;gap:20px}
.brand{display:flex;align-items:center;gap:16px;text-decoration:none;color:#fff;font-size:22px;font-weight:800;white-space:nowrap}
.brand-logo{width:44px;height:44px;display:grid;place-items:center;border:3px solid rgba(255,255,255,.9);border-radius:3px;font-size:28px;line-height:1;font-family:Georgia,serif;font-weight:700}
.nav-links{display:flex;align-items:center;gap:10px;width:100%}
.nav-links>a,.logout{color:#fff;text-decoration:none;padding:13px 16px;border-radius:9px;font-weight:700;white-space:nowrap}
.nav-links>a.active,.nav-links>a:hover{background:rgba(255,255,255,.14)}
.nav-spacer{flex:1}
.lang-switch{display:flex;border:1px solid rgba(255,255,255,.35);border-radius:10px;overflow:hidden}
.lang-switch a{padding:12px 14px;color:#fff;text-decoration:none;font-weight:700}
.lang-switch a.active{background:#0b55d9}
.user-icon{width:40px;height:40px;border-radius:50%;border:1px solid rgba(255,255,255,.4);display:grid;place-items:center}
.logout{border:1px solid rgba(255,255,255,.35)}
.nav-toggle{display:none}
.page{padding:26px 34px 30px}
.page h1{font-size:34px;line-height:1.05;margin:2px 0 18px}
.subtext{color:var(--muted);font-size:17px;margin-top:-4px}
.kpis{display:grid;gap:18px;margin:10px 0 20px}
.kpis.three{grid-template-columns:repeat(3,1fr)}
.kpis.four{grid-template-columns:repeat(4,1fr)}
.kpi-card{background:var(--card);border:1px solid var(--line);border-radius:14px;box-shadow:var(--shadow);min-height:108px;padding:18px 22px;display:flex;align-items:center;gap:20px}
.kpi-icon{width:86px;height:78px;border-radius:18px;display:grid;place-items:center;font-size:36px;font-weight:900;line-height:1}
.kpi-card span{display:block;font-size:17px;font-weight:800;margin-bottom:5px}
.kpi-card strong{display:block;font-size:44px;line-height:1}
.kpi-card.blueicon .kpi-icon{background:#eef3ff;color:var(--blue)}
.kpi-card.blueicon span,.kpi-card.blueicon strong{color:var(--blue)}
.kpi-card.green .kpi-icon{background:#eef8ef;color:var(--green)}
.kpi-card.green span,.kpi-card.green strong{color:var(--green)}
.kpi-card.yellow .kpi-icon{background:#fff7df;color:var(--yellow)}
.kpi-card.yellow span,.kpi-card.yellow strong{color:var(--yellow)}
.kpi-card.red .kpi-icon{background:#ffe8e8;color:var(--red)}
.kpi-card.red span,.kpi-card.red strong{color:var(--red)}
.kpi-card.purple .kpi-icon{background:#f1eaff;color:#6d28d9}
.kpi-card.purple span,.kpi-card.purple strong{color:#6d28d9}

.table-card,.entry-card,.panel-card{background:#fff;border:1px solid var(--line);border-radius:14px;box-shadow:var(--shadow)}
.table-card{overflow:hidden}
.app-table{width:100%;border-collapse:collapse;table-layout:fixed}
.app-table th{padding:15px 16px;text-align:left;font-size:16px;border-bottom:1px solid var(--line);height:54px}
.app-table td{padding:13px 16px;border-bottom:1px solid #e9eff7;font-size:15px;font-weight:600;height:44px;vertical-align:middle}
.app-table tr:last-child td{border-bottom:0}
.production-table th:nth-child(1), .production-table td:nth-child(1){width:110px}
.production-table th:nth-child(2), .production-table td:nth-child(2){width:80px}
.production-table th:nth-child(3), .production-table td:nth-child(3){width:180px}
.production-table th:nth-child(5), .production-table td:nth-child(5){width:160px}
.production-table th:nth-child(6), .production-table td:nth-child(6){width:170px}
.production-table th:nth-child(7), .production-table td:nth-child(7){width:130px}
.row-urgent{background:#fff4f4}.row-urgent td:first-child{border-left:4px solid var(--red)}
.row-warning{background:#fffbf0}.row-warning td:first-child{border-left:4px solid var(--yellow)}
.row-safe{background:#f4fbf5}.row-safe td:first-child{border-left:4px solid var(--green)}
.wo-num{font-weight:800}
.urgency-pill{display:inline-flex;align-items:center;justify-content:center;padding:7px 12px;border-radius:8px;font-size:14px;font-weight:800;min-width:120px;white-space:nowrap;color:#fff}
.urgency-pill.urgent{background:var(--red)}
.urgency-pill.warning{background:var(--yellow)}
.urgency-pill.safe{background:var(--green)}
.status-pill{display:inline-flex;min-width:120px;justify-content:center;padding:7px 10px;border-radius:8px;font-size:12px;font-weight:800}
.status-pill.waiting{background:#fff4df;color:#bc7300;border:1px solid #ffd48a}
.status-pill.scheduled{background:#eef8ef;color:#11732e;border:1px solid #c6e8cf}
.note-cell{font-size:12px;line-height:1.35;color:#274164}
.btn{border:0;border-radius:10px;padding:12px 18px;font-weight:800;text-decoration:none;cursor:pointer;display:inline-flex;align-items:center;justify-content:center;gap:6px;background:#fff}
.btn.primary{background:#0b55d9;color:#fff}
.btn.green{background:#148437;color:#fff}
.btn.secondary{background:#eef2f7;color:#334;border:1px solid #cad5e4}
.btn.outline{background:#fff;color:#0b55d9;border:1px solid #0b55d9}
.btn.tiny{font-size:12px;padding:7px 12px;border-radius:8px;background:#fff;color:#0f8a31;border:1px solid #1aa042}
.btn.mini{font-size:12px;padding:6px 10px;border-radius:8px;margin:2px}
.btn.mini.primary{background:#0b55d9;color:#fff}
.btn.mini.green{background:#148437;color:#fff}
.inline-form{display:inline}
.empty-state{text-align:center;color:var(--muted);padding:32px !important}
.form-page{max-width:1180px}
.entry-card{padding:24px 28px}
.form-grid{display:grid;gap:20px}
.form-grid.three-cols{grid-template-columns:repeat(3,1fr)}
label{font-weight:800;color:#0b1e44;display:block}
input,select,textarea{width:100%;padding:12px 13px;margin-top:8px;border:1px solid #c6d3e4;border-radius:8px;font:inherit;background:#fff}
input[readonly]{background:#f3f6fa}
small{color:var(--muted);font-weight:600;display:block;margin-top:6px}
.rush-box{margin:24px 0;border:1px solid #70a6ff;border-radius:10px;padding:18px 20px;display:grid;grid-template-columns:1fr 1fr;gap:24px}
.segmented{display:flex;margin-top:12px;border:1px solid #c6d3e4;border-radius:9px;overflow:hidden;max-width:230px}.segmented label{flex:1;text-align:center;padding:10px;margin:0;cursor:pointer}.segmented input{display:none}.segmented label:has(input:checked){background:var(--navy);color:#fff}
.service-checks{display:grid;grid-template-columns:repeat(5,1fr);gap:12px;margin-top:14px}
.service-option{border:1px solid #c6d3e4;border-radius:10px;padding:12px;display:flex;gap:10px;align-items:center}.service-option input{width:auto;margin:0}
.notes-label{margin-top:20px}.notes-label textarea{height:90px}.actions{display:flex;justify-content:center;gap:16px;margin-top:20px}
.alert{padding:12px 16px;border-radius:10px;margin:14px 0;font-weight:700}.alert.success{background:#e8f7e9;color:#0f6d2d}.alert.error{background:#ffe5e7;color:#a6121b}
.login-body{min-height:100vh;display:grid;place-items:center;background:#f5f8fc}.login-card{width:min(440px,92vw);background:#fff;border:1px solid var(--line);border-radius:16px;box-shadow:var(--shadow);padding:34px}.login-card h1{margin:0 0 8px;font-size:32px}.login-card .btn{width:100%;margin-top:18px}
.security-grid{display:grid;grid-template-columns:1.1fr 1fr;gap:24px}.users-card{grid-column:1}.history-card{grid-column:2}.login-card{grid-column:1}.card-head{display:flex;justify-content:space-between;align-items:center}.simple-table{width:100%;border-collapse:collapse;margin-top:18px}.simple-table th,.simple-table td{text-align:left;padding:14px;border-bottom:1px solid var(--line)}.settings-row{display:flex;justify-content:space-between;align-items:center;padding:20px 8px;border-bottom:1px solid var(--line);font-size:18px}.help-note{color:var(--muted);background:#f8fbff;border:1px solid var(--line);border-radius:10px;padding:14px}
.modal{position:fixed;inset:0;background:rgba(4,16,35,.35);z-index:50;display:none;align-items:center;justify-content:center;padding:20px}.modal.show{display:flex}.modal-card{position:relative;width:min(520px,95vw);background:#fff;border:1px solid var(--line);border-radius:14px;box-shadow:0 20px 50px rgba(0,0,0,.22);padding:24px}.modal-close{position:absolute;right:14px;top:10px;background:none;border:0;font-size:28px;cursor:pointer;color:#234}.modal-card textarea{height:100px}
@media(max-width:1080px){.kpis.four{grid-template-columns:repeat(2,1fr)}.service-checks{grid-template-columns:repeat(3,1fr)}.security-grid{grid-template-columns:1fr}}
@media(max-width:900px){.top-nav{height:auto;min-height:74px;align-items:flex-start;flex-wrap:wrap;padding:14px}.nav-toggle{display:block;margin-left:auto;background:#fff;color:var(--navy);border:0;border-radius:8px;padding:10px 14px;font-weight:800}.nav-links{display:none;flex-direction:column;align-items:stretch;width:100%}.top-nav.open .nav-links{display:flex}.kpis.three,.kpis.four,.form-grid.three-cols,.rush-box{grid-template-columns:1fr}.page{padding:20px 12px}.page h1{font-size:30px}.app-table,.app-table thead,.app-table tbody,.app-table th,.app-table td,.app-table tr{display:block}.app-table thead{display:none}.app-table tr{border-bottom:1px solid var(--line);padding:10px}.app-table td{height:auto;border:0;padding:7px 6px}.app-table td:before{content:attr(data-label);font-weight:800;color:var(--muted);display:block;font-size:12px}.service-checks{grid-template-columns:1fr 1fr}.action-cell{min-width:unset}}


/* Clean Backup Page */
.backup-page{max-width:1380px}
.backup-summary{display:grid;grid-template-columns:repeat(4,1fr);gap:18px;margin:18px 0 24px}
.backup-stat{background:#fff;border:1px solid var(--line);border-radius:14px;box-shadow:var(--shadow);padding:18px;display:flex;align-items:center;gap:16px}
.backup-stat-icon{width:52px;height:52px;border-radius:14px;background:#eef3ff;display:grid;place-items:center;font-size:26px}
.backup-stat span{display:block;color:var(--muted);font-size:14px;font-weight:800}
.backup-stat strong{display:block;color:var(--navy);font-size:32px;line-height:1.1;margin-top:4px}
.backup-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:22px}
.backup-action-card{padding:26px;min-height:240px;display:flex;flex-direction:column;justify-content:space-between}
.backup-card-head{display:flex;gap:16px;align-items:flex-start}
.backup-card-head h2{margin:0 0 8px;font-size:22px;color:var(--text)}
.backup-card-head p{margin:0;color:var(--muted);line-height:1.45}
.round-icon{width:54px;height:54px;border-radius:16px;display:grid;place-items:center;font-size:26px;font-weight:900;flex:0 0 auto}
.round-icon.blue{background:#eef3ff;color:var(--blue)}
.round-icon.green{background:#eef8ef;color:var(--green)}
.round-icon.yellow{background:#fff7df;color:var(--yellow)}
.round-icon.red{background:#ffe8e8;color:var(--red)}
.backup-btn{margin-top:22px;width:fit-content;min-width:210px}
.mini-note{margin:14px 0 0;color:var(--muted);font-size:14px;font-weight:700}
.warning-text{color:#b45a00}
.restore-form{margin-top:20px}
.file-drop{display:block;border:1px dashed #9fb7d7;background:#f8fbff;border-radius:12px;padding:18px;margin-bottom:16px}
.file-drop span{display:block;color:var(--text);font-weight:800;margin-bottom:8px}
.file-drop input{margin:0;padding:0;border:0;background:transparent}
.backup-checklist{display:grid;gap:12px;margin-top:20px;color:#274164;font-weight:700;line-height:1.35}
@media(max-width:1000px){.backup-summary,.backup-grid{grid-template-columns:1fr 1fr}}
@media(max-width:700px){.backup-summary,.backup-grid{grid-template-columns:1fr}.backup-btn{width:100%}}


/* Backup total boxes without icons */
.backup-stat{justify-content:center;text-align:center;min-height:110px}
.backup-stat strong{font-size:38px}
.backup-stat-icon{display:none}

.kpis.five{grid-template-columns:repeat(5,1fr)}
@media(max-width:1200px){.kpis.five{grid-template-columns:repeat(3,1fr)}}
@media(max-width:900px){.kpis.five{grid-template-columns:1fr}}


/* Update v8: Production Board table spacing and readability */
.production-table{
  table-layout:fixed;
}

.production-table th,
.production-table td{
  font-size:17px;
  font-weight:800;
  padding:14px 18px;
}

.production-table th{
  font-size:16px;
  font-weight:900;
}

.production-table td{
  height:58px;
}

.production-table th:nth-child(1),
.production-table td:nth-child(1){
  width:8%;
}

.production-table th:nth-child(2),
.production-table td:nth-child(2){
  width:5%;
  text-align:center;
}

.production-table th:nth-child(3),
.production-table td:nth-child(3){
  width:18%;
}

.production-table th:nth-child(4),
.production-table td:nth-child(4){
  width:33%;
}

.production-table th:nth-child(5),
.production-table td:nth-child(5){
  width:15%;
}

.production-table th:nth-child(6),
.production-table td:nth-child(6){
  width:13%;
}

.production-table th:nth-child(7),
.production-table td:nth-child(7){
  width:8%;
  text-align:center;
}

.production-table .urgency-pill{
  min-width:118px;
  padding:8px 12px;
  font-size:14px;
  font-weight:900;
}

.production-table .btn.tiny{
  min-width:86px;
  padding:7px 9px;
  font-size:12px;
  line-height:1.1;
}

.production-table td:nth-child(4){
  white-space:normal;
}

.production-table td:nth-child(5){
  white-space:nowrap;
}

.compact-table-card{
  margin-top:18px;
}

@media (min-width: 1200px){
  .production-table th,
  .production-table td{
    font-size:18px;
  }

  .production-table th{
    font-size:16px;
  }
}



/* Update v9: History edit layout */
.history-table th,
.history-table td{
  font-size:15px;
  padding:12px 14px;
}

.history-table th:nth-child(1), .history-table td:nth-child(1){width:8%}
.history-table th:nth-child(2), .history-table td:nth-child(2){width:5%;text-align:center}
.history-table th:nth-child(3), .history-table td:nth-child(3){width:16%}
.history-table th:nth-child(4), .history-table td:nth-child(4){width:20%}
.history-table th:nth-child(5), .history-table td:nth-child(5){width:11%}
.history-table th:nth-child(6), .history-table td:nth-child(6){width:12%}
.history-table th:nth-child(7), .history-table td:nth-child(7){width:16%}
.history-table th:nth-child(8), .history-table td:nth-child(8){width:8%}
.history-table th:nth-child(9), .history-table td:nth-child(9){width:6%;text-align:center}

.large-modal{
  width:min(980px,96vw);
  max-height:90vh;
  overflow:auto;
}

.history-edit-form .form-grid.three-cols{
  grid-template-columns:repeat(3,1fr);
}

.history-services{
  margin-top:20px;
}

.history-edit-form .notes-label textarea{
  height:110px;
}

@media(max-width:900px){
  .history-edit-form .form-grid.three-cols{
    grid-template-columns:1fr;
  }
}



/* Update v10: History search box */
.history-search-card{
  background:#fff;
  border:1px solid var(--line);
  border-radius:14px;
  box-shadow:var(--shadow);
  padding:22px 24px;
  margin:18px 0 22px;
  display:grid;
  grid-template-columns:320px 1fr;
  gap:24px;
  align-items:center;
}

.history-search-card h2{
  margin:0 0 6px;
  font-size:22px;
  color:var(--text);
}

.history-search-card p{
  margin:0;
  color:var(--muted);
  font-weight:600;
  line-height:1.35;
}

.history-search-form{
  display:flex;
  gap:12px;
  align-items:center;
}

.history-search-form input{
  margin:0;
  min-height:46px;
  font-size:16px;
}

.history-search-form .btn{
  min-height:46px;
  white-space:nowrap;
}

.search-results-note{
  background:#eef3ff;
  border:1px solid #c8d7ff;
  color:#12336f;
  border-radius:10px;
  padding:12px 16px;
  margin:-8px 0 18px;
  font-weight:700;
}

@media(max-width:900px){
  .history-search-card{
    grid-template-columns:1fr;
  }
  .history-search-form{
    flex-direction:column;
    align-items:stretch;
  }
}


/* Portal and Water Damage Board */
.portal-page{text-align:center;max-width:1160px;margin:0 auto}
.portal-page h1{font-size:54px;margin-top:46px}
.portal-cards{display:grid;grid-template-columns:1fr 1fr;gap:34px;margin:42px auto;max-width:900px}
.portal-card{background:#fff;border:1px solid var(--line);border-radius:16px;box-shadow:var(--shadow);padding:38px 34px;text-align:center}
.portal-icon{width:120px;height:120px;border-radius:60px;background:#eef3ff;color:var(--navy);display:grid;place-items:center;font-size:56px;margin:0 auto 24px}
.portal-icon.water{color:#087b9a}
.portal-card h2{font-size:30px;margin:0 0 14px;color:var(--text)}
.portal-card p{font-size:18px;color:var(--muted);line-height:1.45;min-height:56px}
.portal-btn{width:100%;margin-top:18px;font-size:18px}
.water-head{display:flex;justify-content:space-between;gap:20px;align-items:center}
.water-steps{background:#fff;border:1px solid var(--line);border-radius:14px;box-shadow:var(--shadow);padding:18px;display:grid;grid-template-columns:repeat(10,1fr);gap:8px;margin:20px 0}
.water-step{text-align:center;font-size:12px;color:var(--text);position:relative}
.water-step span{display:grid;place-items:center;width:34px;height:34px;background:#eaf3ff;color:#075eea;border-radius:50%;font-weight:900;margin:0 auto 8px}
.water-step strong{font-size:12px;line-height:1.2;display:block}
.water-kpis{grid-template-columns:repeat(6,1fr)}
.water-kpis .kpi-card{min-height:90px;padding:18px}
.water-kpis .kpi-card span{font-size:14px}
.water-kpis .kpi-card strong{font-size:34px}
.water-table th,.water-table td{font-size:14px;padding:12px 14px}
.water-pill{display:inline-flex;align-items:center;justify-content:center;padding:7px 10px;border-radius:8px;font-size:12px;font-weight:900;background:#eef3ff;color:#075eea}
.step-demo,.step-repairs{background:#fff7df;color:#b26900}
.step-drying,.step-approval,.step-completed{background:#e8f7e9;color:#087f2b}
.step-adjuster_review{background:#ffe8e8;color:#b91c1c}
.step-xactimate,.step-hcp_invoice,.step-final_invoice{background:#f1eaff;color:#6d28d9}
.water-entry-steps{margin:24px 0;padding:18px;border:1px solid var(--line);border-radius:14px;background:#f8fbff}
.water-entry-steps h2{margin:0 0 14px}
.water-entry-steps div{display:flex;align-items:center;gap:12px;padding:8px 0;border-bottom:1px solid #e6eef8}
.water-entry-steps div:last-child{border-bottom:0}
.water-entry-steps span{width:28px;height:28px;border-radius:50%;background:#eaf3ff;color:#075eea;display:grid;place-items:center;font-weight:900}
@media(max-width:1100px){.water-steps{grid-template-columns:repeat(5,1fr)}.water-kpis{grid-template-columns:repeat(3,1fr)}}
@media(max-width:800px){.portal-cards{grid-template-columns:1fr}.water-head{display:block}.water-steps,.water-kpis{grid-template-columns:1fr}}


/* Division navigation update */
.top-nav .brand span:last-child{max-width:360px;overflow:hidden;text-overflow:ellipsis}
.nav-links>a[href="water.php"],
.nav-links>a[href="index.php"]{
  white-space:nowrap;
}
.portal-page h1{font-size:52px}


/* Water Damage completed step checklist */
.water-entry-steps .mini-note{
  margin:0 0 14px;
}
.water-step-check{
  display:flex !important;
  align-items:center;
  gap:12px;
  padding:9px 0;
  border-bottom:1px solid #e6eef8;
  font-weight:800;
}
.water-step-check input{
  width:auto;
  margin:0;
}
.water-step-check span{
  width:28px;
  height:28px;
  border-radius:50%;
  background:#eaf3ff;
  color:#075eea;
  display:grid;
  place-items:center;
  font-weight:900;
  flex:0 0 auto;
}
.edit-steps{
  margin-top:20px;
}


/* Final top nav and board labels update */
.top-nav .brand span:last-child{max-width:380px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.nav-links a{white-space:nowrap}
.muted-inline{display:inline-block;margin-top:4px;color:var(--muted);font-size:13px;font-weight:700}
.portal-page{text-align:center;max-width:1160px;margin:0 auto}
.portal-page h1{font-size:52px;margin-top:46px}
.portal-cards{display:grid;grid-template-columns:1fr 1fr;gap:34px;margin:42px auto;max-width:900px}
.portal-card{background:#fff;border:1px solid var(--line);border-radius:16px;box-shadow:var(--shadow);padding:38px 34px;text-align:center}
.portal-icon{width:120px;height:120px;border-radius:60px;background:#eef3ff;color:var(--navy);display:grid;place-items:center;font-size:56px;margin:0 auto 24px}
.portal-icon.water{color:#087b9a}
.portal-card h2{font-size:30px;margin:0 0 14px;color:var(--text)}
.portal-card p{font-size:18px;color:var(--muted);line-height:1.45;min-height:56px}
.portal-btn{width:100%;margin-top:18px;font-size:18px}
@media(max-width:800px){.portal-cards{grid-template-columns:1fr}}


/* Water Board visual polish */
.top-nav .brand span:last-child{max-width:320px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.nav-links a{display:flex;align-items:center;gap:8px;white-space:nowrap}
.nav-ico{font-size:21px;line-height:1;display:inline-grid;place-items:center;min-width:20px}
.water-head .btn.primary{padding:14px 22px;border-radius:12px;font-size:17px;font-weight:900}
.enhanced-steps{background:#fff;border:1px solid var(--line);border-radius:18px;box-shadow:var(--shadow);padding:26px 18px;display:grid;grid-template-columns:repeat(10,1fr);gap:10px;margin:20px 0 26px}
.enhanced-steps .water-step{text-align:center;position:relative;padding:2px 8px 0}
.step-number{display:grid;place-items:center;width:30px;height:30px;background:#e9f0ff;color:#1954d5;border-radius:50%;font-size:15px;font-weight:900;margin:0 auto 12px}
.step-icon-circle{display:grid;place-items:center;width:54px;height:54px;border-radius:50%;background:#eef3ff;color:#0a57d9;font-size:26px;font-weight:900;margin:0 auto 12px}
.enhanced-steps .water-step strong{display:block;font-size:14px;line-height:1.25;color:#132a57;font-weight:800}
.step-arrow{position:absolute;right:-16px;top:55px;color:#7a8fb4;font-size:28px;font-weight:700}
.visual-water-kpis{display:grid;grid-template-columns:repeat(6,1fr);gap:18px;margin-bottom:26px}
.water-kpi{display:flex;align-items:center;gap:16px;padding:20px 18px;min-height:110px;border-radius:18px}
.kpi-icon-box{width:68px;height:68px;border-radius:14px;display:grid;place-items:center;background:rgba(255,255,255,.72);font-size:30px;flex:0 0 auto;box-shadow:inset 0 0 0 1px rgba(9,31,78,.04)}
.water-kpi span{display:block;font-size:15px;font-weight:900;margin-bottom:6px}
.water-kpi strong{font-size:52px;line-height:1;font-weight:900}
.water-table th,.water-table td{font-size:16px;padding:18px 20px;vertical-align:middle}
.water-table td{font-weight:800;color:#142b58}
.water-pill{padding:12px 14px;border-radius:12px;font-size:15px;font-weight:900}
.progress-wrap{display:flex;align-items:center;gap:14px}
.progress-ring{--p:0%;width:44px;height:44px;border-radius:50%;background:conic-gradient(#1d5fe8 var(--p), #e7eef8 0);display:grid;place-items:center;flex:0 0 auto}
.progress-ring span{width:28px;height:28px;border-radius:50%;background:#fff;display:block}
.progress-copy strong{display:block;color:#132a57;font-size:15px;line-height:1.1}
.progress-copy .muted-inline{margin-top:5px;font-size:14px}
.water-page .table-card{border-radius:18px}
@media(max-width:1300px){.enhanced-steps{grid-template-columns:repeat(5,1fr)}.step-arrow{display:none}.visual-water-kpis{grid-template-columns:repeat(3,1fr)}}
@media(max-width:900px){.visual-water-kpis,.enhanced-steps{grid-template-columns:1fr}.water-kpi{min-height:96px}.kpi-icon-box{width:58px;height:58px;font-size:26px}}


/* Water job update screen */
.large-modal{
  width:min(1180px,96vw);
  max-height:90vh;
  overflow:auto;
}
.update-client-card,
.water-progress-update,
.construction-options-card{
  background:#f8fbff;
  border:1px solid var(--line);
  border-radius:14px;
  padding:18px;
  margin-top:18px;
}
.update-client-card h3,
.water-progress-update h3,
.construction-options-card h3{
  margin:0 0 8px;
  color:var(--text);
  font-size:20px;
}
.form-grid.four-cols{
  grid-template-columns:repeat(4,1fr);
}
.update-status-grid{
  margin-top:18px;
}
.progress-note-row{
  display:grid;
  grid-template-columns:300px 1fr;
  gap:14px;
  align-items:center;
  padding:10px 0;
  border-bottom:1px solid #e5edf8;
}
.progress-note-row:last-child{
  border-bottom:0;
}
.step-check-inline{
  display:flex;
  align-items:center;
  gap:10px;
  margin:0;
  font-weight:900;
}
.step-check-inline input{
  width:auto;
  margin:0;
}
.step-check-inline span{
  width:28px;
  height:28px;
  border-radius:50%;
  background:#eaf3ff;
  color:#075eea;
  display:grid;
  place-items:center;
  font-weight:900;
  flex:0 0 auto;
}
.progress-note-row input{
  margin:0;
}
.construction-options-grid{
  display:grid;
  grid-template-columns:repeat(4,1fr);
  gap:12px;
  margin-top:14px;
}
.construction-option{
  display:flex;
  align-items:center;
  gap:10px;
  border:1px solid #cbd8eb;
  background:#fff;
  border-radius:12px;
  padding:12px;
  margin:0;
}
.construction-option input{
  width:auto;
  margin:0;
}
.construction-option span{
  font-weight:900;
}
.water-table .btn.mini.primary{
  min-width:88px;
}
@media(max-width:900px){
  .form-grid.four-cols,
  .progress-note-row,
  .construction-options-grid{
    grid-template-columns:1fr;
  }
}


/* Water search and history */
.water-search-card{
  background:#fff;
  border:1px solid var(--line);
  border-radius:16px;
  box-shadow:var(--shadow);
  padding:18px;
  margin:18px 0 22px;
}
.water-search-form{
  display:flex;
  gap:12px;
  align-items:center;
}
.water-search-form input{
  margin:0;
  min-height:46px;
  font-size:16px;
}
.water-search-form .btn{
  min-height:46px;
  white-space:nowrap;
}
.water-history-table th,
.water-history-table td{
  font-size:15px;
  padding:14px 16px;
}
.water-history-table th:nth-child(1),
.water-history-table td:nth-child(1){
  width:18%;
}
.water-history-table th:nth-child(2),
.water-history-table td:nth-child(2){
  width:16%;
}
.water-history-table th:nth-child(3),
.water-history-table td:nth-child(3){
  width:20%;
}
.water-history-table th:nth-child(4),
.water-history-table td:nth-child(4){
  width:46%;
}
@media(max-width:800px){
  .water-search-form{
    flex-direction:column;
    align-items:stretch;
  }
}


/* Final Water History, notes, and visual update */
.water-search-card{
  background:#fff;
  border:1px solid var(--line);
  border-radius:16px;
  box-shadow:var(--shadow);
  padding:18px;
  margin:18px 0 22px;
}
.water-search-form{
  display:flex;
  gap:12px;
  align-items:center;
}
.water-search-form input{
  margin:0;
  min-height:46px;
  font-size:16px;
}
.water-search-form .btn{
  min-height:46px;
  white-space:nowrap;
}
.section-title{
  margin:0;
  padding:18px 20px 0;
  color:var(--text);
  font-size:22px;
}
.log-card{
  margin-top:26px;
}
.large-modal{
  width:min(1180px,96vw);
  max-height:90vh;
  overflow:auto;
}
.update-client-card,
.water-progress-update,
.construction-options-card,
.general-notes-history{
  background:#f8fbff;
  border:1px solid var(--line);
  border-radius:14px;
  padding:18px;
  margin-top:18px;
}
.update-client-card h3,
.water-progress-update h3,
.construction-options-card h3,
.general-notes-history h3{
  margin:0 0 8px;
  color:var(--text);
  font-size:20px;
}
.form-grid.four-cols{
  grid-template-columns:repeat(4,1fr);
}
.update-status-grid{
  margin-top:18px;
}
.progress-note-row{
  display:grid;
  grid-template-columns:300px 1fr;
  gap:14px;
  align-items:center;
  padding:10px 0;
  border-bottom:1px solid #e5edf8;
}
.progress-note-row:last-child{
  border-bottom:0;
}
.step-check-inline{
  display:flex;
  align-items:center;
  gap:10px;
  margin:0;
  font-weight:900;
}
.step-check-inline input{
  width:auto;
  margin:0;
}
.step-check-inline span{
  width:28px;
  height:28px;
  border-radius:50%;
  background:#eaf3ff;
  color:#075eea;
  display:grid;
  place-items:center;
  font-weight:900;
  flex:0 0 auto;
}
.progress-note-row input{
  margin:0;
}
.modal-two-col{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:18px;
}
.notes-timeline{
  max-height:260px;
  overflow:auto;
  display:grid;
  gap:10px;
  margin:12px 0 16px;
}
.note-entry{
  border-left:4px solid var(--blue);
  background:#fff;
  padding:10px 12px;
  border-radius:10px;
}
.note-entry strong{
  color:var(--navy);
  display:block;
  margin-bottom:5px;
}
.note-entry p{
  margin:0;
  color:var(--text);
  line-height:1.35;
}
.construction-options-grid{
  display:grid;
  grid-template-columns:repeat(2,1fr);
  gap:12px;
  margin-top:14px;
}
.construction-option{
  display:flex;
  align-items:center;
  gap:10px;
  border:1px solid #cbd8eb;
  background:#fff;
  border-radius:12px;
  padding:12px;
  margin:0;
}
.construction-option input{
  width:auto;
  margin:0;
}
.construction-option span{
  font-weight:900;
}
.btn.danger{
  background:#e12d39;
  color:#fff;
}
.delete-form{
  border-top:1px solid var(--line);
  margin-top:18px;
  padding-top:16px;
  text-align:right;
}
.water-history-table th,
.water-history-table td,
.water-log-table th,
.water-log-table td{
  font-size:15px;
  padding:14px 16px;
}
@media(max-width:900px){
  .form-grid.four-cols,
  .progress-note-row,
  .modal-two-col,
  .construction-options-grid{
    grid-template-columns:1fr;
  }
  .water-search-form{
    flex-direction:column;
    align-items:stretch;
  }
}


/* FINAL MERGED VISUAL STYLE FOR WATER BOARD */
.top-nav{
  min-height:78px;
  background:linear-gradient(90deg,#061d49,#082b6b);
  box-shadow:0 2px 12px rgba(0,0,0,.12);
}
.top-nav .brand{
  font-size:22px;
  gap:12px;
}
.top-nav .brand span:last-child{
  max-width:360px;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}
.brand-logo{
  width:42px;
  height:42px;
  font-size:26px;
}
.nav-links a{
  display:flex;
  align-items:center;
  gap:8px;
  white-space:nowrap;
  border-radius:10px;
  padding:12px 14px;
  font-weight:900;
}
.nav-links a.active{
  background:#164a9c;
}
.nav-ico{
  font-size:22px;
  line-height:1;
  display:inline-grid;
  place-items:center;
  min-width:22px;
}
.water-page{
  padding-top:28px;
}
.water-head h1{
  font-size:36px;
  letter-spacing:-.5px;
}
.water-head .btn.primary{
  padding:16px 24px;
  border-radius:12px;
  font-size:18px;
  font-weight:900;
  box-shadow:0 10px 20px rgba(0,84,216,.18);
}
.water-search-card{
  background:transparent;
  border:0;
  box-shadow:none;
  padding:0;
  margin:20px 0 24px;
}
.water-search-form{
  display:flex;
  gap:12px;
  align-items:center;
  max-width:560px;
}
.water-search-form input{
  min-height:50px;
  border-radius:12px;
  font-size:16px;
  padding-left:18px;
  background:#fff;
  box-shadow:var(--shadow);
}
.enhanced-steps{
  background:#fff;
  border:1px solid var(--line);
  border-radius:18px;
  box-shadow:var(--shadow);
  padding:26px 18px;
  display:grid;
  grid-template-columns:repeat(13,1fr);
  gap:8px;
  margin:20px 0 26px;
}
.enhanced-steps .water-step{
  text-align:center;
  position:relative;
  padding:2px 6px 0;
}
.step-number{
  display:grid;
  place-items:center;
  width:28px;
  height:28px;
  background:#e9f0ff;
  color:#1954d5;
  border-radius:50%;
  font-size:14px;
  font-weight:900;
  margin:0 auto 10px;
}
.step-icon-circle{
  display:grid;
  place-items:center;
  width:58px;
  height:58px;
  border-radius:50%;
  background:#eef3ff;
  color:#0a57d9;
  font-size:27px;
  font-weight:900;
  margin:0 auto 12px;
  border:1px solid #c8d9ff;
}
.enhanced-steps .water-step:nth-child(2) .step-icon-circle{background:#fff1e3;color:#dd6b00;border-color:#ffd5a7}
.enhanced-steps .water-step:nth-child(3) .step-icon-circle{background:#e7f8e8;color:#159947;border-color:#bae7c0}
.enhanced-steps .water-step:nth-child(6) .step-icon-circle{background:#e4fbfb;color:#088c8c;border-color:#a9e9e9}
.enhanced-steps .water-step:nth-child(7) .step-icon-circle,
.enhanced-steps .water-step:nth-child(8) .step-icon-circle,
.enhanced-steps .water-step:nth-child(10) .step-icon-circle{background:#f4eaff;color:#812fd8;border-color:#dfc4ff}
.enhanced-steps .water-step:nth-child(9) .step-icon-circle,
.enhanced-steps .water-step:nth-child(13) .step-icon-circle{background:#e8f7e9;color:#159947;border-color:#bdebc2}
.enhanced-steps .water-step:nth-child(11) .step-icon-circle{background:#fff8df;color:#d49400;border-color:#ffe9a6}
.enhanced-steps .water-step strong{
  display:block;
  font-size:12px;
  line-height:1.2;
  color:#132a57;
  font-weight:900;
}
.step-arrow{
  position:absolute;
  right:-15px;
  top:58px;
  color:#9aadcc;
  font-size:24px;
  font-weight:900;
}
.visual-water-kpis{
  display:grid;
  grid-template-columns:repeat(6,1fr);
  gap:18px;
  margin-bottom:26px;
}
.water-kpi{
  display:flex;
  align-items:center;
  gap:16px;
  padding:20px 18px;
  min-height:118px;
  border-radius:18px;
}
.kpi-icon-box{
  width:68px;
  height:68px;
  border-radius:50%;
  display:grid;
  place-items:center;
  background:rgba(255,255,255,.72);
  font-size:30px;
  flex:0 0 auto;
  box-shadow:inset 0 0 0 1px rgba(9,31,78,.04);
}
.water-kpi span{
  display:block;
  font-size:15px;
  font-weight:900;
  margin-bottom:6px;
}
.water-kpi strong{
  font-size:50px;
  line-height:1;
  font-weight:900;
}
.water-table th,
.water-table td{
  font-size:16px;
  padding:18px 20px;
  vertical-align:middle;
}
.water-table td{
  font-weight:800;
  color:#142b58;
}
.water-pill{
  padding:12px 14px;
  border-radius:12px;
  font-size:15px;
  font-weight:900;
}
.progress-wrap{
  display:flex;
  align-items:center;
  gap:14px;
}
.progress-ring{
  --p:0%;
  width:48px;
  height:48px;
  border-radius:50%;
  background:conic-gradient(#1d5fe8 var(--p), #e7eef8 0);
  display:grid;
  place-items:center;
  flex:0 0 auto;
}
.progress-ring span{
  width:30px;
  height:30px;
  border-radius:50%;
  background:#fff;
  display:block;
}
.progress-copy strong{
  display:block;
  color:#132a57;
  font-size:15px;
  line-height:1.1;
}
.progress-copy .muted-inline{
  margin-top:5px;
  font-size:14px;
}
.water-page .table-card{
  border-radius:18px;
}
@media(max-width:1500px){
  .enhanced-steps{grid-template-columns:repeat(7,1fr)}
  .step-arrow{display:none}
}
@media(max-width:1300px){
  .visual-water-kpis{grid-template-columns:repeat(3,1fr)}
}
@media(max-width:900px){
  .visual-water-kpis,.enhanced-steps{grid-template-columns:1fr}
  .water-kpi{min-height:96px}
  .kpi-icon-box{width:58px;height:58px;font-size:26px}
}


/* FINAL CLEAN WATER HISTORY LAYOUT */
.clean-history-page{
  max-width:1600px;
}
.history-head{
  margin-bottom:20px;
}
.history-summary-cards{
  display:grid;
  grid-template-columns:repeat(4,1fr);
  gap:18px;
  margin:20px 0 22px;
}
.history-summary-card{
  background:#fff;
  border:1px solid var(--line);
  border-radius:18px;
  box-shadow:var(--shadow);
  padding:20px;
  display:flex;
  gap:16px;
  align-items:center;
}
.history-summary-card .history-icon{
  width:62px;
  height:62px;
  border-radius:50%;
  display:grid;
  place-items:center;
  font-size:28px;
  background:#eef3ff;
}
.history-summary-card span{
  display:block;
  font-size:15px;
  font-weight:900;
  margin-bottom:5px;
}
.history-summary-card strong{
  font-size:42px;
  line-height:1;
  font-weight:900;
}
.history-summary-card.blue span,.history-summary-card.blue strong{color:#075eea}
.history-summary-card.green span,.history-summary-card.green strong{color:#159947}
.history-summary-card.yellow span,.history-summary-card.yellow strong{color:#d49400}
.history-summary-card.purple span,.history-summary-card.purple strong{color:#812fd8}
.history-search-panel{
  background:#fff;
  border:1px solid var(--line);
  border-radius:18px;
  box-shadow:var(--shadow);
  padding:18px;
  margin:0 0 22px;
}
.history-search-form-clean{
  display:flex;
  gap:12px;
  align-items:center;
}
.search-input-wrap{
  flex:1;
  position:relative;
}
.search-input-wrap span{
  position:absolute;
  left:16px;
  top:50%;
  transform:translateY(-50%);
  color:#617394;
  font-size:22px;
}
.search-input-wrap input{
  margin:0;
  min-height:50px;
  padding-left:48px;
  border-radius:12px;
  font-size:16px;
}
.history-board-card{
  background:#fff;
  border:1px solid var(--line);
  border-radius:18px;
  box-shadow:var(--shadow);
  margin-top:22px;
  overflow:hidden;
}
.history-card-head{
  display:flex;
  justify-content:space-between;
  align-items:center;
  padding:22px 24px 12px;
  border-bottom:1px solid #edf2f8;
}
.history-card-head h2{
  margin:0;
  color:var(--text);
  font-size:24px;
}
.history-card-head p{
  margin:6px 0 0;
  color:var(--muted);
  font-weight:700;
}
.clean-history-table th,
.clean-history-table td,
.clean-log-table th,
.clean-log-table td{
  font-size:15px;
  padding:16px 18px;
  vertical-align:middle;
}
.clean-history-table td{
  font-weight:800;
}
.clean-history-table .btn{
  min-width:118px;
}
.log-action-pill{
  display:inline-flex;
  padding:7px 10px;
  border-radius:999px;
  background:#eef3ff;
  color:#075eea;
  font-weight:900;
}
.polished-update-modal{
  width:min(1240px,96vw);
  max-height:92vh;
  overflow:auto;
}
.polished-update-modal > h2{
  font-size:26px;
  margin-bottom:4px;
}
.modal-section{
  background:#fff;
  border:1px solid var(--line);
  border-radius:16px;
  padding:18px;
  margin-top:16px;
  box-shadow:0 6px 18px rgba(6,29,73,.05);
}
.numbered-section{
  display:grid;
  grid-template-columns:36px 1fr;
  gap:14px;
  align-items:flex-start;
}
.section-number{
  width:30px;
  height:30px;
  border-radius:50%;
  background:#075eea;
  color:#fff;
  display:grid;
  place-items:center;
  font-weight:900;
}
.section-content h3{
  margin:0 0 14px;
  color:var(--text);
  font-size:18px;
}
.form-grid.four-cols{
  grid-template-columns:repeat(4,1fr);
}
.update-status-grid{
  margin-bottom:16px;
}
.step-notes-grid{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:0 22px;
  border-top:1px solid #edf2f8;
  padding-top:12px;
}
.progress-note-row{
  display:grid;
  grid-template-columns:250px 1fr;
  gap:12px;
  align-items:center;
  padding:9px 0;
  border-bottom:1px solid #edf2f8;
}
.step-check-inline{
  display:flex;
  align-items:center;
  gap:10px;
  margin:0;
  font-weight:900;
}
.step-check-inline input{
  width:auto;
  margin:0;
}
.step-check-inline span{
  width:26px;
  height:26px;
  border-radius:50%;
  background:#eaf3ff;
  color:#075eea;
  display:grid;
  place-items:center;
  font-weight:900;
  flex:0 0 auto;
}
.progress-note-row input{
  margin:0;
  min-height:38px;
}
.modal-two-col{
  display:grid;
  grid-template-columns:1.1fr .9fr;
  gap:18px;
}
.notes-timeline{
  max-height:260px;
  overflow:auto;
  display:grid;
  gap:10px;
  margin:12px 0 16px;
}
.note-entry{
  border-left:4px solid var(--blue);
  background:#f8fbff;
  padding:10px 12px;
  border-radius:10px;
}
.note-entry strong{
  color:var(--navy);
  display:block;
  margin-bottom:5px;
}
.note-entry p{
  margin:0;
  color:var(--text);
  line-height:1.35;
}
.construction-options-grid{
  display:grid;
  grid-template-columns:repeat(2,1fr);
  gap:12px;
  margin-top:10px;
}
.construction-option{
  display:flex;
  align-items:center;
  gap:10px;
  border:1px solid #cbd8eb;
  background:#fff;
  border-radius:12px;
  padding:12px;
  margin:0;
}
.construction-option input{
  width:auto;
  margin:0;
}
.construction-option span{
  font-weight:900;
}
.sticky-modal-actions{
  position:sticky;
  bottom:0;
  background:#fff;
  padding:16px 0 4px;
  z-index:2;
}
.btn.danger{
  background:#e12d39;
  color:#fff;
}
.delete-form{
  border-top:1px solid var(--line);
  margin-top:18px;
  padding-top:16px;
  text-align:right;
}
@media(max-width:1200px){
  .history-summary-cards{grid-template-columns:repeat(2,1fr)}
  .step-notes-grid,.modal-two-col{grid-template-columns:1fr}
}
@media(max-width:900px){
  .history-summary-cards,
  .form-grid.four-cols,
  .progress-note-row,
  .construction-options-grid{
    grid-template-columns:1fr;
  }
  .history-search-form-clean{
    flex-direction:column;
    align-items:stretch;
  }
}


/* TRUE FINAL SVG POLISH TO MATCH APPROVED MOCKUPS */
.app-svg{
  width:1em;
  height:1em;
  display:block;
  flex:0 0 auto;
}
.top-nav{
  height:86px;
  min-height:86px;
  padding:0 20px;
  background:linear-gradient(90deg,#051944,#082763);
  box-shadow:0 3px 14px rgba(6,29,73,.18);
}
.top-nav .brand{
  gap:12px;
  min-width:300px;
}
.top-nav .brand span:last-child{
  max-width:330px;
  white-space:normal;
  line-height:1.05;
  font-size:22px;
}
.brand-logo{
  width:48px;
  height:48px;
  border-radius:4px;
  font-size:30px;
}
.nav-links{
  gap:8px;
}
.nav-links a{
  height:58px;
  display:flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  padding:0 16px;
  border-radius:12px;
  font-size:15px;
  font-weight:900;
}
.nav-links a.active{
  background:#173e86;
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.06);
}
.nav-ico{
  width:25px;
  height:25px;
  font-size:25px;
  display:grid;
  place-items:center;
  color:#fff;
}
.user-icon{
  width:44px;
  height:44px;
  display:grid;
  place-items:center;
  border-radius:50%;
  border:1px solid rgba(255,255,255,.35);
  color:#fff;
  font-size:24px;
}
.logout{
  height:48px !important;
  border:1px solid rgba(255,255,255,.35);
  border-radius:10px !important;
  padding:0 16px !important;
}
.water-page{
  max-width:1720px;
  padding:30px 34px 60px;
}
.water-head{
  margin-bottom:12px;
}
.water-head h1{
  font-size:34px;
  line-height:1.1;
  letter-spacing:-.4px;
  margin-bottom:8px;
}
.water-head .subtext{
  font-size:16px;
}
.water-head .btn.primary{
  padding:16px 24px;
  border-radius:10px;
  font-size:18px;
  min-width:190px;
  box-shadow:0 10px 22px rgba(0,84,216,.20);
}
.water-search-card{
  background:transparent;
  border:0;
  box-shadow:none;
  padding:0;
  margin:18px 0 22px;
}
.water-search-form{
  max-width:520px;
  display:flex;
  gap:10px;
}
.water-search-form input{
  min-height:48px;
  border-radius:12px;
  font-size:16px;
  padding:0 18px;
  background:#fff;
  box-shadow:0 8px 20px rgba(6,29,73,.06);
}
.water-search-form .btn{
  min-height:48px;
  border-radius:10px;
  padding:0 20px;
}
.enhanced-steps{
  background:#fff;
  border:1px solid #d7e2f1;
  border-radius:18px;
  box-shadow:0 10px 26px rgba(6,29,73,.07);
  padding:28px 24px 26px;
  display:grid;
  grid-template-columns:repeat(13,1fr);
  gap:8px;
  margin:22px 0 26px;
}
.enhanced-steps .water-step{
  position:relative;
  text-align:center;
  min-height:132px;
  padding-top:0;
}
.step-number{
  display:grid;
  place-items:center;
  width:29px;
  height:29px;
  background:#e8f1ff;
  color:#075eea;
  border-radius:50%;
  font-size:14px;
  font-weight:900;
  margin:0 auto 10px;
}
.step-icon-circle{
  display:grid;
  place-items:center;
  width:58px;
  height:58px;
  border-radius:50%;
  background:#edf4ff;
  color:#075eea;
  border:1px solid #bdd3ff;
  font-size:28px;
  margin:0 auto 11px;
}
.step-icon-circle .app-svg{
  width:30px;
  height:30px;
}
.enhanced-steps .water-step:nth-child(2) .step-icon-circle{background:#fff1e3;color:#e06b00;border-color:#ffc98f}
.enhanced-steps .water-step:nth-child(3) .step-icon-circle{background:#e7f8e8;color:#159947;border-color:#bdebc2}
.enhanced-steps .water-step:nth-child(6) .step-icon-circle{background:#e3fbfb;color:#008b8b;border-color:#aee8e8}
.enhanced-steps .water-step:nth-child(7) .step-icon-circle,
.enhanced-steps .water-step:nth-child(8) .step-icon-circle,
.enhanced-steps .water-step:nth-child(10) .step-icon-circle{background:#f2e8ff;color:#7d29d8;border-color:#dcc0ff}
.enhanced-steps .water-step:nth-child(9) .step-icon-circle,
.enhanced-steps .water-step:nth-child(13) .step-icon-circle{background:#e7f8e8;color:#159947;border-color:#bdebc2}
.enhanced-steps .water-step:nth-child(11) .step-icon-circle{background:#fff7df;color:#d09000;border-color:#ffe6a0}
.enhanced-steps .water-step:nth-child(12) .step-icon-circle{background:#eaf2ff;color:#075eea;border-color:#c4d8ff}
.enhanced-steps .water-step strong{
  display:block;
  color:#071d49;
  font-size:13px;
  font-weight:900;
  line-height:1.18;
}
.step-arrow{
  position:absolute;
  right:-15px;
  top:58px;
  color:#9db0ce;
  font-size:26px;
  font-weight:800;
}
.visual-water-kpis{
  display:grid;
  grid-template-columns:repeat(6,1fr);
  gap:18px;
  margin:0 0 26px;
}
.water-kpi{
  background:#fff;
  border:1px solid #d7e2f1;
  border-radius:18px;
  box-shadow:0 10px 26px rgba(6,29,73,.07);
  padding:18px 20px;
  min-height:110px;
  display:flex;
  align-items:center;
  gap:18px;
}
.kpi-icon-box{
  width:70px;
  height:70px;
  border-radius:50%;
  display:grid;
  place-items:center;
  background:#eef4ff;
  color:#075eea;
  border:1px solid #d3e2ff;
  font-size:32px;
}
.kpi-icon-box .app-svg{
  width:34px;
  height:34px;
}
.water-kpi.yellow .kpi-icon-box{background:#fff3e6;color:#df6b00;border-color:#ffd6ad}
.water-kpi.purple .kpi-icon-box{background:#f2e8ff;color:#7d29d8;border-color:#dcc0ff}
.water-kpi.green .kpi-icon-box{background:#e8f7e9;color:#159947;border-color:#c4ebca}
.water-kpi.teal .kpi-icon-box{background:#e2f6f6;color:#0d8d8b;border-color:#b8eaea}
.water-kpi span{
  display:block;
  font-size:15px;
  font-weight:900;
  margin-bottom:5px;
}
.water-kpi strong{
  display:block;
  font-size:42px;
  line-height:1;
  font-weight:900;
}
.water-table{
  table-layout:fixed;
}
.water-table th,
.water-table td{
  font-size:15px;
  padding:17px 18px;
  vertical-align:middle;
}
.water-table th{
  font-weight:900;
  color:#0b1e44;
}
.water-table td{
  font-weight:800;
  color:#102959;
}
.water-table th:nth-child(1),.water-table td:nth-child(1){width:7%}
.water-table th:nth-child(2),.water-table td:nth-child(2){width:10%}
.water-table th:nth-child(3),.water-table td:nth-child(3){width:10%}
.water-table th:nth-child(4),.water-table td:nth-child(4){width:10%}
.water-table th:nth-child(5),.water-table td:nth-child(5){width:15%}
.water-table th:nth-child(6),.water-table td:nth-child(6){width:17%}
.water-table th:nth-child(7),.water-table td:nth-child(7){width:10%}
.water-table th:nth-child(8),.water-table td:nth-child(8){width:10%}
.water-table th:nth-child(9),.water-table td:nth-child(9){width:8%}
.water-table th:nth-child(10),.water-table td:nth-child(10){width:8%}
.water-pill{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:10px 14px;
  border-radius:10px;
  font-size:14px;
  line-height:1.1;
  font-weight:900;
}
.step-adjuster_review{background:#ffe4e7;color:#d3212f}
.step-mitigation_approval{background:#dff8f8;color:#078a8a}
.step-repair_estimate,.step-approval,.step-repairs{background:#f0e4ff;color:#7d29d8}
.step-payment_1,.step-payment_2{background:#e8f7e9;color:#159947}
.progress-wrap{
  display:flex;
  align-items:center;
  gap:12px;
}
.progress-ring{
  --p:0%;
  width:48px;
  height:48px;
  border-radius:50%;
  background:conic-gradient(#075eea var(--p), #e5edf8 0);
  display:grid;
  place-items:center;
  flex:0 0 auto;
}
.progress-ring span{
  width:30px;
  height:30px;
  border-radius:50%;
  background:#fff;
  display:block;
}
.progress-copy strong{
  font-size:14px;
  line-height:1.1;
  display:block;
  color:#071d49;
}
.progress-copy .muted-inline{
  font-size:13px;
  margin-top:4px;
  color:#526686;
}
.water-table .btn.mini.primary{
  min-width:92px;
  min-height:36px;
  border-radius:8px;
  font-size:13px;
  box-shadow:0 6px 14px rgba(0,84,216,.18);
}
@media(max-width:1500px){
  .enhanced-steps{grid-template-columns:repeat(7,1fr)}
  .step-arrow{display:none}
  .visual-water-kpis{grid-template-columns:repeat(3,1fr)}
}
@media(max-width:900px){
  .enhanced-steps,.visual-water-kpis{grid-template-columns:1fr}
  .top-nav{height:auto}
}


/* New Water Job polished form */
.water-entry-page{
  max-width:1500px;
}
.polished-new-job-form{
  background:#fff;
  border:1px solid var(--line);
  border-radius:18px;
  box-shadow:var(--shadow);
  padding:22px;
}
.polished-new-job-form .modal-section{
  background:#fff;
}
.polished-new-job-form textarea{
  min-height:150px;
}
.polished-new-job-form .sticky-modal-actions{
  justify-content:flex-end;
  border-top:1px solid var(--line);
  margin-top:20px;
}


/* Water date fields update */
.polished-new-job-form .form-grid.four-cols,
.polished-update-modal .form-grid.four-cols{
  grid-template-columns:repeat(4,1fr);
}
.clean-history-table th,
.clean-history-table td{
  font-size:14px;
}
@media(max-width:1200px){
  .polished-new-job-form .form-grid.four-cols,
  .polished-update-modal .form-grid.four-cols{
    grid-template-columns:repeat(2,1fr);
  }
}
@media(max-width:800px){
  .polished-new-job-form .form-grid.four-cols,
  .polished-update-modal .form-grid.four-cols{
    grid-template-columns:1fr;
  }
}


/* =========================================================
   WATER DAMAGE CLEAN REBUILD
   Scoped visual system so it no longer depends on rug layout
   ========================================================= */
.app-svg{width:1em;height:1em;display:block;flex:0 0 auto}
.clean-top-nav{
  height:84px !important;
  min-height:84px !important;
  padding:0 18px !important;
  background:linear-gradient(90deg,#061b49,#082760) !important;
  box-shadow:0 3px 14px rgba(6,29,73,.18) !important;
}
.clean-brand{gap:12px !important;min-width:300px !important}
.clean-brand .brand-logo{width:48px !important;height:48px !important;border-radius:4px !important;font-size:30px !important}
.clean-brand span:last-child{font-size:22px !important;line-height:1.05 !important;white-space:normal !important;max-width:310px !important}
.clean-nav-links{gap:7px !important}
.clean-nav-links a{
  height:56px !important;
  display:flex !important;
  align-items:center !important;
  justify-content:center !important;
  gap:8px !important;
  padding:0 14px !important;
  border-radius:12px !important;
  font-size:15px !important;
  font-weight:900 !important;
  white-space:nowrap !important;
}
.clean-nav-links a.active{background:#164a9c !important}
.clean-nav-links .nav-ico{font-size:23px !important;width:23px !important;height:23px !important;display:grid !important;place-items:center !important}
.clean-nav-links .logout{border:1px solid rgba(255,255,255,.35) !important;border-radius:10px !important}
.clean-nav-links .user-icon{width:44px;height:44px;display:grid;place-items:center;border-radius:50%;border:1px solid rgba(255,255,255,.35)}
.clean-nav-links .lang-switch a{height:48px !important;border-radius:0 !important;padding:0 16px !important}

.wd-page{
  max-width:1720px;
  margin:0 auto;
  padding:30px 34px 70px;
  color:#071d49;
}
.wd-head{display:flex;justify-content:space-between;align-items:flex-start;gap:20px;margin-bottom:18px}
.wd-head h1{font-size:34px;line-height:1.1;letter-spacing:-.4px;margin:0 0 8px;color:#071d49}
.wd-head p{font-size:16px;margin:0;color:#526686;font-weight:600}
.wd-btn{
  border:0;
  border-radius:10px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  text-decoration:none;
  font-weight:900;
  cursor:pointer;
  min-height:44px;
  padding:0 18px;
  font-size:15px;
  line-height:1;
}
.wd-primary{background:#075eea;color:#fff;box-shadow:0 8px 18px rgba(0,84,216,.18)}
.wd-secondary{background:#fff;color:#071d49;border:1px solid #d3ddeb}
.wd-danger{background:#e12d39;color:#fff}
.wd-small{min-height:36px;min-width:92px;font-size:13px;padding:0 14px}
.wd-head .wd-primary{min-width:195px;min-height:58px;font-size:19px;border-radius:10px}

.wd-search-panel{background:transparent;border:0;box-shadow:none;margin:10px 0 22px;padding:0}
.wd-search{display:flex;align-items:center;gap:10px;max-width:620px}
.wd-search-box{position:relative;flex:1;min-width:0}
.wd-search-box .app-svg{position:absolute;left:16px;top:50%;transform:translateY(-50%);width:22px;height:22px;color:#476080}
.wd-search-box input{
  width:100%;
  min-height:48px;
  margin:0;
  padding:0 18px 0 48px;
  border:1px solid #cbd8eb;
  border-radius:12px;
  background:#fff;
  font-size:16px;
  box-shadow:0 8px 20px rgba(6,29,73,.06);
}

.wd-steps{
  background:#fff;
  border:1px solid #d7e2f1;
  border-radius:18px;
  box-shadow:0 10px 26px rgba(6,29,73,.07);
  padding:28px 24px 26px;
  display:grid;
  grid-template-columns:repeat(13,1fr);
  gap:8px;
  margin:22px 0 26px;
}
.wd-step{position:relative;text-align:center;min-height:132px}
.wd-step-num{
  display:grid;place-items:center;
  width:29px;height:29px;margin:0 auto 10px;
  border-radius:50%;
  background:#e8f1ff;color:#075eea;
  font-size:14px;font-weight:900
}
.wd-step-icon{
  display:grid;place-items:center;
  width:58px;height:58px;margin:0 auto 11px;
  border-radius:50%;
  background:#edf4ff;color:#075eea;border:1px solid #bdd3ff;
}
.wd-step-icon .app-svg{width:30px;height:30px}
.wd-step strong{display:block;color:#071d49;font-size:13px;font-weight:900;line-height:1.18}
.wd-step-arrow{position:absolute;right:-15px;top:58px;color:#9db0ce;font-size:26px;font-weight:800}
.wd-step-demo{background:#fff1e3;color:#e06b00;border-color:#ffc98f}
.wd-step-drying{background:#e7f8e8;color:#159947;border-color:#bdebc2}
.wd-step-mitigation_approval{background:#e3fbfb;color:#008b8b;border-color:#aee8e8}
.wd-step-repair_estimate,.wd-step-approval,.wd-step-repairs{background:#f2e8ff;color:#7d29d8;border-color:#dcc0ff}
.wd-step-payment_1,.wd-step-payment_2{background:#e7f8e8;color:#159947;border-color:#bdebc2}
.wd-step-certificate_completion{background:#fff7df;color:#d09000;border-color:#ffe6a0}
.wd-step-hcp_final_invoice_sent{background:#eaf2ff;color:#075eea;border-color:#c4d8ff}

.wd-kpis{
  display:grid;
  grid-template-columns:repeat(6,1fr);
  gap:18px;
  margin:0 0 26px;
}
.wd-history-kpis{grid-template-columns:repeat(4,1fr)}
.wd-kpi{
  background:#fff;
  border:1px solid #d7e2f1;
  border-radius:18px;
  box-shadow:0 10px 26px rgba(6,29,73,.07);
  padding:18px 20px;
  min-height:112px;
  display:flex;
  align-items:center;
  gap:18px;
}
.wd-kpi-icon{
  width:70px;height:70px;border-radius:50%;
  display:grid;place-items:center;
  background:#eef4ff;color:#075eea;border:1px solid #d3e2ff;
  flex:0 0 auto;
}
.wd-kpi-icon .app-svg{width:34px;height:34px}
.wd-kpi span{display:block;font-size:15px;font-weight:900;margin-bottom:5px}
.wd-kpi strong{display:block;font-size:42px;line-height:1;font-weight:900}
.wd-blue span,.wd-blue strong{color:#075eea}
.wd-orange span,.wd-orange strong{color:#e06b00}.wd-orange .wd-kpi-icon{background:#fff1e3;color:#e06b00;border-color:#ffc98f}
.wd-purple span,.wd-purple strong{color:#7d29d8}.wd-purple .wd-kpi-icon{background:#f2e8ff;color:#7d29d8;border-color:#dcc0ff}
.wd-green span,.wd-green strong{color:#159947}.wd-green .wd-kpi-icon{background:#e7f8e8;color:#159947;border-color:#bdebc2}
.wd-yellow span,.wd-yellow strong{color:#d09000}.wd-yellow .wd-kpi-icon{background:#fff7df;color:#d09000;border-color:#ffe6a0}
.wd-teal span,.wd-teal strong{color:#0d8d8b}.wd-teal .wd-kpi-icon{background:#e2f6f6;color:#0d8d8b;border-color:#b8eaea}

.wd-table-card{
  background:#fff;
  border:1px solid #d7e2f1;
  border-radius:18px;
  box-shadow:0 10px 26px rgba(6,29,73,.07);
  overflow:hidden;
  margin-top:20px;
}
.wd-card-head{padding:22px 24px 12px;border-bottom:1px solid #edf2f8}
.wd-card-head h2{margin:0;color:#071d49;font-size:24px}
.wd-card-head p{margin:6px 0 0;color:#526686;font-weight:700}
.wd-table{width:100%;border-collapse:collapse;table-layout:fixed}
.wd-table th,.wd-table td{padding:17px 18px;border-bottom:1px solid #edf2f8;text-align:left;vertical-align:middle;font-size:15px}
.wd-table th{font-weight:900;color:#071d49}
.wd-table td{font-weight:800;color:#102959}
.wd-table small{display:block;font-size:12px;color:#526686;font-weight:800;margin-top:4px}
.wd-table tr:last-child td{border-bottom:0}
.wd-table th:nth-child(1),.wd-table td:nth-child(1){width:6%}
.wd-table th:nth-child(2),.wd-table td:nth-child(2){width:9%}
.wd-table th:nth-child(3),.wd-table td:nth-child(3){width:9%}
.wd-table th:nth-child(4),.wd-table td:nth-child(4){width:10%}
.wd-table th:nth-child(5),.wd-table td:nth-child(5){width:9%}
.wd-table th:nth-child(6),.wd-table td:nth-child(6){width:13%}
.wd-table th:nth-child(7),.wd-table td:nth-child(7){width:15%}
.wd-table th:nth-child(8),.wd-table td:nth-child(8){width:10%}
.wd-table th:nth-child(9),.wd-table td:nth-child(9){width:11%}
.wd-table th:nth-child(10),.wd-table td:nth-child(10){width:11%}
.wd-table th:nth-child(11),.wd-table td:nth-child(11){width:7%}
.wd-history-table th,.wd-history-table td{font-size:14px}

.wd-step-badge{
  display:inline-flex;align-items:center;justify-content:center;
  padding:10px 14px;border-radius:10px;
  font-size:14px;line-height:1.1;font-weight:900;
  background:#eaf2ff;color:#075eea;
}
.wd-badge-adjuster_review{background:#ffe4e7;color:#d3212f}
.wd-badge-mitigation_approval{background:#dff8f8;color:#078a8a}
.wd-badge-repair_estimate,.wd-badge-approval,.wd-badge-repairs{background:#f0e4ff;color:#7d29d8}
.wd-badge-payment_1,.wd-badge-payment_2{background:#e8f7e9;color:#159947}
.wd-badge-certificate_completion{background:#fff7df;color:#d09000}
.wd-progress-cell{display:flex;align-items:center;gap:12px}
.wd-ring{
  --p:0%;
  width:48px;height:48px;border-radius:50%;
  background:conic-gradient(#075eea var(--p), #e5edf8 0);
  display:grid;place-items:center;flex:0 0 auto;
}
.wd-ring span{
  width:32px;height:32px;border-radius:50%;background:#fff;
  display:grid;place-items:center;
  font-size:10px;font-weight:900;color:#071d49;
}
.wd-progress-cell strong{display:block;font-size:14px;line-height:1.1;color:#071d49}
.wd-progress-cell small{font-size:13px;margin-top:3px}
.wd-pay{
  display:inline-flex;align-items:center;justify-content:center;
  padding:8px 12px;border-radius:8px;font-size:13px;font-weight:900;
}
.wd-pay-paid{background:#e8f7e9;color:#159947}
.wd-pay-warning{background:#fff4df;color:#d27400}
.wd-pay-past-due{background:#ffe4e7;color:#d3212f}
.wd-pay-neutral{background:#f0f3f8;color:#526686}

.wd-entry-form,
.wd-modal{
  background:#fff;
  border:1px solid #d7e2f1;
  border-radius:18px;
  box-shadow:0 18px 50px rgba(6,29,73,.16);
  padding:22px;
}
.wd-modal{width:min(1240px,96vw);max-height:92vh;overflow:auto}
.wd-modal>h2{font-size:26px;color:#071d49;margin:0 0 4px}
.wd-modal>p{color:#526686;font-weight:700;margin:0 0 18px}
.wd-form-section{
  background:#fff;
  border:1px solid #d7e2f1;
  border-radius:16px;
  padding:18px;
  margin-top:16px;
  display:grid;
  grid-template-columns:36px 1fr;
  gap:14px;
}
.wd-section-num{
  width:30px;height:30px;border-radius:50%;
  background:#075eea;color:#fff;
  display:grid;place-items:center;
  font-weight:900;
}
.wd-section-body h3{margin:0 0 14px;color:#071d49;font-size:19px}
.wd-help{margin:0 0 14px;color:#526686;font-weight:700}
.wd-form-grid{display:grid;gap:14px}
.wd-four{grid-template-columns:repeat(4,1fr)}
.wd-two{grid-template-columns:repeat(2,1fr)}
.wd-form-section label,
.wd-payment-card label{font-weight:900;color:#071d49}
.wd-form-section input,.wd-form-section select,.wd-form-section textarea,
.wd-payment-card input,.wd-payment-card select,.wd-payment-card textarea{
  width:100%;margin-top:8px;border:1px solid #cbd8eb;border-radius:10px;
  min-height:42px;padding:10px 12px;background:#fff;font:inherit;
}
.wd-form-section textarea,.wd-payment-card textarea{min-height:92px}
.wd-step-note-grid{display:grid;grid-template-columns:1fr 1fr;gap:0 22px;border-top:1px solid #edf2f8;padding-top:10px}
.wd-step-note-row{display:grid;grid-template-columns:250px 1fr;gap:12px;align-items:center;padding:9px 0;border-bottom:1px solid #edf2f8}
.wd-step-check{display:flex!important;align-items:center;gap:10px;margin:0!important}
.wd-step-check input{width:auto!important;margin:0!important;min-height:unset!important}
.wd-step-check span{width:26px;height:26px;border-radius:50%;background:#eaf3ff;color:#075eea;display:grid;place-items:center;font-weight:900;flex:0 0 auto}
.wd-step-note-row input{margin:0!important}
.wd-payment-grid{display:grid;grid-template-columns:1fr 1fr;gap:18px}
.wd-payment-card{border:1px solid #d7e2f1;border-radius:14px;background:#f8fbff;padding:16px}
.wd-payment-card h4{margin:0 0 14px;color:#071d49;font-size:18px}
.wd-two-panels{display:grid;grid-template-columns:1.1fr .9fr;gap:18px}
.wd-notes-history{max-height:240px;overflow:auto;display:grid;gap:10px;margin:10px 0 14px}
.wd-note-entry{border-left:4px solid #075eea;background:#f8fbff;border-radius:10px;padding:10px 12px}
.wd-note-entry strong{display:block;color:#071d49;margin-bottom:5px}
.wd-note-entry p{margin:0;color:#102959;line-height:1.35}
.wd-options-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:12px}
.wd-option{display:flex!important;align-items:center;gap:10px;border:1px solid #cbd8eb;background:#fff;border-radius:12px;padding:12px;margin:0!important}
.wd-option input{width:auto!important;margin:0!important;min-height:unset!important}
.wd-option span{font-weight:900}
.wd-modal-actions{display:flex;justify-content:flex-end;gap:12px;position:sticky;bottom:0;background:#fff;padding:18px 0 4px;margin-top:14px;border-top:1px solid #edf2f8}
.wd-delete-form{text-align:right;border-top:1px solid #edf2f8;margin-top:14px;padding-top:14px}
.wd-log-card{margin-top:26px}
.wd-log-pill{display:inline-flex;padding:7px 10px;border-radius:999px;background:#eef3ff;color:#075eea;font-weight:900}

@media(max-width:1500px){
  .wd-steps{grid-template-columns:repeat(7,1fr)}
  .wd-step-arrow{display:none}
  .wd-kpis{grid-template-columns:repeat(3,1fr)}
  .wd-table{table-layout:auto}
}
@media(max-width:1100px){
  .wd-four,.wd-two,.wd-payment-grid,.wd-step-note-grid,.wd-two-panels{grid-template-columns:1fr}
  .wd-step-note-row{grid-template-columns:1fr}
}
@media(max-width:900px){
  .clean-top-nav{height:auto!important;padding:14px!important}
  .wd-page{padding:20px 12px 50px}
  .wd-head{display:block}
  .wd-head .wd-btn{margin-top:16px;width:100%}
  .wd-steps,.wd-kpis,.wd-history-kpis{grid-template-columns:1fr}
  .wd-search{max-width:none;flex-direction:column;align-items:stretch}
  .wd-table,.wd-table thead,.wd-table tbody,.wd-table th,.wd-table td,.wd-table tr{display:block}
  .wd-table thead{display:none}
  .wd-table tr{padding:12px;border-bottom:1px solid #edf2f8}
  .wd-table td{border:0;padding:8px 6px}
  .wd-table td:before{content:attr(data-label);display:block;color:#526686;font-size:12px;font-weight:900}
}


/* =========================================================
   FINAL WATER DAMAGE BOARD WITHOUT PROGRESS BAR
   Job type, current step, payment balances, days owed
   ========================================================= */
.app-svg{width:1em;height:1em;display:block;flex:0 0 auto}
.clean-top-nav{
  height:84px !important;
  min-height:84px !important;
  padding:0 18px !important;
  background:linear-gradient(90deg,#061b49,#082760) !important;
  box-shadow:0 3px 14px rgba(6,29,73,.18) !important;
}
.clean-brand{gap:12px !important;min-width:300px !important}
.clean-brand .brand-logo{width:48px !important;height:48px !important;border-radius:4px !important;font-size:30px !important}
.clean-brand span:last-child{font-size:22px !important;line-height:1.05 !important;white-space:normal !important;max-width:310px !important}
.clean-nav-links{gap:7px !important}
.clean-nav-links a{
  height:56px !important;
  display:flex !important;
  align-items:center !important;
  justify-content:center !important;
  gap:8px !important;
  padding:0 14px !important;
  border-radius:12px !important;
  font-size:15px !important;
  font-weight:900 !important;
  white-space:nowrap !important;
}
.clean-nav-links a.active{background:#164a9c !important}
.clean-nav-links .nav-ico{font-size:23px !important;width:23px !important;height:23px !important;display:grid !important;place-items:center !important}
.clean-nav-links .logout{border:1px solid rgba(255,255,255,.35) !important;border-radius:10px !important}
.clean-nav-links .user-icon{width:44px;height:44px;display:grid;place-items:center;border-radius:50%;border:1px solid rgba(255,255,255,.35)}
.clean-nav-links .lang-switch a{height:48px !important;border-radius:0 !important;padding:0 16px !important}

.wd-page{
  max-width:1720px;
  margin:0 auto;
  padding:30px 34px 70px;
  color:#071d49;
}
.wd-head{display:flex;justify-content:space-between;align-items:flex-start;gap:20px;margin-bottom:22px}
.wd-head h1{font-size:34px;line-height:1.1;letter-spacing:-.4px;margin:0 0 8px;color:#071d49}
.wd-head p{font-size:16px;margin:0;color:#526686;font-weight:600}
.wd-btn{
  border:0;border-radius:10px;display:inline-flex;align-items:center;justify-content:center;gap:8px;
  text-decoration:none;font-weight:900;cursor:pointer;min-height:44px;padding:0 18px;font-size:15px;line-height:1;
}
.wd-primary{background:#075eea;color:#fff;box-shadow:0 8px 18px rgba(0,84,216,.18)}
.wd-secondary{background:#fff;color:#071d49;border:1px solid #d3ddeb}
.wd-danger{background:#e12d39;color:#fff}
.wd-small{min-height:36px;min-width:92px;font-size:13px;padding:0 14px}
.wd-head .wd-primary{min-width:195px;min-height:58px;font-size:19px;border-radius:10px}

.wd-search-panel{background:transparent;border:0;box-shadow:none;margin:10px 0 22px;padding:0}
.wd-search{display:flex;align-items:center;gap:10px;max-width:520px}
.wd-search-box{position:relative;flex:1;min-width:0}
.wd-search-box .app-svg{position:absolute;left:16px;top:50%;transform:translateY(-50%);width:22px;height:22px;color:#476080}
.wd-search-box input{
  width:100%;min-height:48px;margin:0;padding:0 18px 0 48px;border:1px solid #cbd8eb;
  border-radius:12px;background:#fff;font-size:16px;box-shadow:0 8px 20px rgba(6,29,73,.06);
}

.wd-large-kpis{
  display:grid;
  grid-template-columns:repeat(6,1fr);
  gap:22px;
  margin:0 0 28px;
}
.wd-kpi{
  background:#fff;
  border:1px solid #d7e2f1;
  border-radius:14px;
  box-shadow:0 10px 26px rgba(6,29,73,.07);
  padding:22px 18px;
  min-height:180px;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  text-align:center;
  gap:10px;
}
.wd-kpi-icon{
  width:70px;height:70px;border-radius:50%;display:grid;place-items:center;
  background:#eef4ff;color:#075eea;border:1px solid #d3e2ff;
}
.wd-kpi-icon .app-svg{width:34px;height:34px}
.wd-kpi span{display:block;font-size:16px;font-weight:900;margin-top:2px}
.wd-kpi strong{display:block;font-size:38px;line-height:1;font-weight:900}
.wd-kpi small{display:block;color:#075eea;font-size:14px;font-weight:900;margin-top:6px}
.wd-blue span,.wd-blue strong{color:#075eea}
.wd-orange span,.wd-orange strong{color:#e06b00}.wd-orange .wd-kpi-icon{background:#fff1e3;color:#e06b00;border-color:#ffc98f}
.wd-purple span,.wd-purple strong{color:#7d29d8}.wd-purple .wd-kpi-icon{background:#f2e8ff;color:#7d29d8;border-color:#dcc0ff}
.wd-green span,.wd-green strong{color:#159947}.wd-green .wd-kpi-icon{background:#e7f8e8;color:#159947;border-color:#bdebc2}
.wd-yellow span,.wd-yellow strong{color:#d09000}.wd-yellow .wd-kpi-icon{background:#fff7df;color:#d09000;border-color:#ffe6a0}
.wd-teal span,.wd-teal strong{color:#0d8d8b}.wd-teal .wd-kpi-icon{background:#e2f6f6;color:#0d8d8b;border-color:#b8eaea}

.wd-table-card{background:#fff;border:1px solid #d7e2f1;border-radius:14px;box-shadow:0 10px 26px rgba(6,29,73,.07);overflow:hidden;margin-top:20px}
.wd-card-head{padding:22px 24px 12px;border-bottom:1px solid #edf2f8}
.wd-card-head h2{margin:0;color:#071d49;font-size:24px}
.wd-card-head p{margin:6px 0 0;color:#526686;font-weight:700}
.wd-table{width:100%;border-collapse:collapse;table-layout:fixed}
.wd-table th,.wd-table td{padding:15px 18px;border-bottom:1px solid #edf2f8;text-align:left;vertical-align:middle;font-size:15px}
.wd-table th{font-weight:900;color:#071d49}
.wd-table td{font-weight:500;color:#071d49}
.wd-table tr:last-child td{border-bottom:0}
.wd-simple-board th:nth-child(1),.wd-simple-board td:nth-child(1){width:6%}
.wd-simple-board th:nth-child(2),.wd-simple-board td:nth-child(2){width:13%}
.wd-simple-board th:nth-child(3),.wd-simple-board td:nth-child(3){width:13%}
.wd-simple-board th:nth-child(4),.wd-simple-board td:nth-child(4){width:14%}
.wd-simple-board th:nth-child(5),.wd-simple-board td:nth-child(5){width:15%}
.wd-simple-board th:nth-child(6),.wd-simple-board td:nth-child(6){width:15%}
.wd-simple-board th:nth-child(7),.wd-simple-board td:nth-child(7){width:10%}
.wd-simple-board th:nth-child(8),.wd-simple-board td:nth-child(8){width:8%}
.wd-simple-board th:nth-child(9),.wd-simple-board td:nth-child(9){width:9%}
.wd-simple-board th:nth-child(10),.wd-simple-board td:nth-child(10){width:8%}
.wd-bold-cell,.wd-balance{font-weight:900!important}
.wd-type,.wd-step-badge,.wd-status,.wd-pay{
  display:inline-flex;align-items:center;justify-content:center;
  padding:8px 12px;border-radius:8px;font-size:14px;line-height:1.1;font-weight:900;
}
.wd-type-orange{background:#fff1e3;color:#e06b00}
.wd-type-blue{background:#eaf2ff;color:#075eea}
.wd-type-purple{background:#f2e8ff;color:#7d29d8}
.wd-badge-blue{background:#eaf2ff;color:#075eea}
.wd-badge-purple{background:#f2e8ff;color:#7d29d8}
.wd-badge-orange{background:#fff1e3;color:#e06b00}
.wd-badge-red{background:#ffe4e7;color:#d3212f}
.wd-badge-green{background:#e8f7e9;color:#159947}
.wd-pay{margin-bottom:4px}
.wd-pay-paid{background:#e8f7e9;color:#159947}
.wd-pay-warning{background:#fff1e3;color:#e06b00}
.wd-pay-due{background:#fff1e3;color:#e06b00}
.wd-pay-waiting{background:#eaf2ff;color:#075eea}
.wd-pay-neutral{background:#f0f3f8;color:#526686}
.wd-payment-cell small{display:block;font-size:13px;font-weight:800;margin-top:3px}
.wd-payment-cell .paid-text{color:#159947}
.wd-payment-cell .due-text{color:#d3212f}
.wd-payment-cell .muted{color:#526686}
.wd-days-red{color:#e12d39!important;font-weight:900!important}
.wd-status-orange{background:#fff1e3;color:#e06b00}
.wd-status-green{background:#e8f7e9;color:#159947}
.wd-status-blue{background:#eaf2ff;color:#075eea}

.wd-entry-form,.wd-modal{background:#fff;border:1px solid #d7e2f1;border-radius:14px;box-shadow:0 18px 50px rgba(6,29,73,.12);padding:20px}
.wd-modal{width:min(1500px,96vw);max-height:92vh;overflow:auto}
.wd-modal>h2{font-size:32px;color:#071d49;margin:0 0 4px}
.wd-modal>p{color:#526686;font-weight:700;margin:0 0 18px}
.wd-clean-update-modal{background:#fff}
.wd-form-section{background:#fff;border:1px solid #d7e2f1;border-radius:12px;padding:18px;margin-top:16px;display:grid;grid-template-columns:36px 1fr;gap:14px}
.wd-section-num{width:30px;height:30px;border-radius:50%;background:#075eea;color:#fff;display:grid;place-items:center;font-weight:900}
.wd-section-body h3{margin:0 0 16px;color:#071d49;font-size:18px}
.wd-help{margin:0 0 14px;color:#526686;font-weight:700}
.wd-form-grid{display:grid;gap:14px}
.wd-four{grid-template-columns:repeat(4,1fr)}
.wd-wide{grid-column:span 2}
.wd-form-section label{font-weight:700;color:#071d49;font-size:14px}
.wd-form-section input,.wd-form-section select,.wd-form-section textarea{
  width:100%;margin-top:8px;border:1px solid #cbd8eb;border-radius:8px;
  min-height:42px;padding:10px 12px;background:#fff;font:inherit;font-weight:500;
}
.wd-form-section textarea{min-height:100px}
.wd-red-input{color:#e12d39!important;font-weight:900!important}
.wd-two-panels{display:grid;grid-template-columns:1fr 1fr;gap:18px}
.wd-notes-history{max-height:260px;overflow:auto;display:grid;gap:10px;margin:10px 0 14px}
.wd-note-entry{border-left:4px solid #075eea;background:#f8fbff;border-radius:8px;padding:10px 12px}
.wd-note-entry strong{display:block;color:#071d49;margin-bottom:5px}
.wd-note-entry p{margin:0;color:#102959;line-height:1.35}
.wd-options-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:12px}
.wd-option{display:flex!important;align-items:center;gap:10px;border:1px solid #cbd8eb;background:#fff;border-radius:8px;padding:12px;margin:0!important}
.wd-option input{width:auto!important;margin:0!important;min-height:unset!important}
.wd-option span{font-weight:800}
.wd-modal-actions{display:flex;justify-content:flex-end;gap:12px;position:sticky;bottom:0;background:#fff;padding:18px 0 4px;margin-top:14px;border-top:1px solid #edf2f8}
.wd-delete-form{text-align:right;border-top:1px solid #edf2f8;margin-top:14px;padding-top:14px}
.wd-log-card{margin-top:26px}
.wd-log-pill{display:inline-flex;padding:7px 10px;border-radius:999px;background:#eef3ff;color:#075eea;font-weight:900}

@media(max-width:1500px){
  .wd-large-kpis{grid-template-columns:repeat(3,1fr)}
  .wd-table{table-layout:auto}
}
@media(max-width:1100px){
  .wd-four,.wd-two-panels{grid-template-columns:1fr}
  .wd-wide{grid-column:auto}
  .wd-options-grid{grid-template-columns:repeat(2,1fr)}
}
@media(max-width:900px){
  .clean-top-nav{height:auto!important;padding:14px!important}
  .wd-page{padding:20px 12px 50px}
  .wd-head{display:block}
  .wd-head .wd-btn{margin-top:16px;width:100%}
  .wd-large-kpis{grid-template-columns:1fr}
  .wd-search{max-width:none;flex-direction:column;align-items:stretch}
  .wd-table,.wd-table thead,.wd-table tbody,.wd-table th,.wd-table td,.wd-table tr{display:block}
  .wd-table thead{display:none}
  .wd-table tr{padding:12px;border-bottom:1px solid #edf2f8}
  .wd-table td{border:0;padding:8px 6px}
  .wd-table td:before{content:attr(data-label);display:block;color:#526686;font-size:12px;font-weight:900}
}


/* KPI detail filter functionality */
.wd-kpis a.wd-kpi{
  text-decoration:none;
  color:inherit;
  transition:transform .12s ease, box-shadow .12s ease, border-color .12s ease;
}
.wd-kpis a.wd-kpi:hover{
  transform:translateY(-2px);
  box-shadow:0 14px 30px rgba(6,29,73,.12);
}
.wd-kpi.active-filter{
  border:2px solid #075eea;
  box-shadow:0 14px 30px rgba(7,94,234,.16);
}
.wd-active-filter{
  background:#eef5ff;
  border:1px solid #bdd3ff;
  border-radius:12px;
  padding:14px 18px;
  margin:0 0 16px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
}
.wd-active-filter strong{
  display:block;
  color:#075eea;
  font-size:18px;
  font-weight:900;
}
.wd-active-filter span{
  display:block;
  margin-top:4px;
  color:#526686;
  font-weight:800;
}
@media(max-width:900px){
  .wd-active-filter{
    flex-direction:column;
    align-items:stretch;
  }
}

/* Water board detail dropdown rows */
.wd-detail-row[hidden]{display:none !important}
.wd-action-group{display:flex;align-items:center;gap:8px}
.wd-detail-toggle{min-width:36px;height:36px;border:1px solid #d3ddeb;background:#fff;color:#071d49;border-radius:8px;font-size:18px;font-weight:900;cursor:pointer;line-height:1}
.wd-detail-toggle.open{background:#eef5ff;border-color:#8cb3ff;color:#075eea;transform:rotate(180deg)}
.wd-detail-row td{background:#fbfdff;padding:0!important}
.wd-detail-panels{display:grid;grid-template-columns:1fr 1.25fr 1fr;gap:18px;padding:18px;border-top:1px solid #edf2f8}
.wd-detail-panel{background:#fff;border:1px solid #e4ebf5;border-radius:12px;padding:14px 16px;min-height:140px}
.wd-detail-panel h4{margin:0 0 12px;color:#071d49;font-size:16px;font-weight:900}
.wd-follow-last strong{display:block;font-size:15px;color:#071d49}
.wd-follow-last span{display:block;margin-top:4px;color:#526686;font-size:13px;font-weight:800}
.wd-follow-last p{margin:7px 0 0;color:#102959;font-size:14px;line-height:1.35}
.wd-detail-note{font-weight:600}
.wd-mini-entry{padding:10px 0;border-top:1px solid #edf2f8}
.wd-mini-entry:first-of-type{border-top:0;padding-top:0}
.wd-mini-entry strong{display:block;font-size:13px;color:#071d49;margin-bottom:4px}
.wd-mini-entry p{margin:0;color:#102959;font-size:14px;line-height:1.35}
.wd-mini-tag{display:inline-flex;align-items:center;justify-content:center;padding:4px 8px;border-radius:999px;background:#eef5ff;color:#075eea;font-size:12px;font-weight:900;margin-right:4px}
.wd-empty-mini{margin:0;color:#6b7d98;font-weight:700;font-size:14px}
.wd-two-panels .wd-form-grid.wd-two{display:grid;grid-template-columns:1fr 1fr;gap:14px}
@media(max-width:1100px){.wd-detail-panels{grid-template-columns:1fr}.wd-two-panels .wd-form-grid.wd-two{grid-template-columns:1fr}}
@media(max-width:900px){.wd-action-group{justify-content:flex-start}.wd-detail-row td{padding:12px!important}.wd-detail-panels{padding:12px}.wd-detail-toggle{min-width:32px;height:32px}}


/* Final simple balance water board */
.wd-five-kpis{
  grid-template-columns:repeat(5,1fr) !important;
}
.wd-simple-board th:nth-child(5),.wd-simple-board td:nth-child(5){width:16%}
.wd-simple-board th:nth-child(6),.wd-simple-board td:nth-child(6){width:11%}
.wd-simple-board th:nth-child(7),.wd-simple-board td:nth-child(7){width:11%}
.wd-simple-board th:nth-child(8),.wd-simple-board td:nth-child(8){width:8%}
.wd-simple-board th:nth-child(9),.wd-simple-board td:nth-child(9){width:9%}
.wd-simple-board th:nth-child(10),.wd-simple-board td:nth-child(10){width:8%}
.wd-detail-row[hidden]{display:none !important}
@media(max-width:1500px){
  .wd-five-kpis{grid-template-columns:repeat(3,1fr) !important}
}
@media(max-width:900px){
  .wd-five-kpis{grid-template-columns:1fr !important}
}


/* Inline quick update controls on Water Board */
.wd-inline-form{margin:0;display:flex;flex-direction:column;align-items:flex-start;gap:4px}
.wd-inline-select{
  border:0;
  border-radius:8px;
  padding:8px 28px 8px 12px;
  font-weight:900;
  font-size:14px;
  cursor:pointer;
  max-width:190px;
}
.wd-type-select.wd-type-orange{background:#fff1e3;color:#e06b00}
.wd-type-select.wd-type-purple{background:#f2e8ff;color:#7d29d8}
.wd-type-select.wd-type-blue{background:#eaf2ff;color:#075eea}
.wd-step-select.wd-badge-blue{background:#eaf2ff;color:#075eea}
.wd-step-select.wd-badge-purple{background:#f2e8ff;color:#7d29d8}
.wd-step-select.wd-badge-orange{background:#fff1e3;color:#e06b00}
.wd-step-select.wd-badge-red{background:#ffe4e7;color:#d3212f}
.wd-step-select.wd-badge-green{background:#e8f7e9;color:#159947}
.wd-payment-select.wd-pay-paid{background:#e8f7e9;color:#159947}
.wd-payment-select.wd-pay-warning{background:#fff1e3;color:#e06b00}
.wd-payment-select.wd-pay-due{background:#fff1e3;color:#e06b00}
.wd-payment-select.wd-pay-waiting{background:#eaf2ff;color:#075eea}
.wd-payment-select.wd-pay-neutral{background:#f0f3f8;color:#526686}
.wd-kpi{min-height:145px!important}
.wd-large-kpis{gap:18px!important}

/* More Details and Water Collections */
.wd-more-details{
  min-width:118px !important;
  white-space:nowrap;
}
.wd-action-group{
  display:flex;
  align-items:center;
  gap:8px;
  flex-wrap:nowrap;
}
.wd-inline-date{
  border:1px solid #d3ddeb;
  border-radius:8px;
  min-height:38px;
  padding:7px 10px;
  font-weight:800;
  color:#071d49;
  max-width:145px;
}
.wd-age-pill{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  padding:8px 14px;
  border-radius:999px;
  font-weight:900;
  font-size:14px;
}
.wd-age-green{background:#e8f7e9;color:#159947}
.wd-age-yellow{background:#fff7df;color:#d09000}
.wd-age-red{background:#ffe4e7;color:#d3212f}
.wd-collections-table th:nth-child(4),.wd-collections-table td:nth-child(4){width:13%}
.wd-collections-table th:nth-child(6),.wd-collections-table td:nth-child(6){width:10%}
.wd-collections-table th:nth-child(7),.wd-collections-table td:nth-child(7){width:10%}
.wd-collections-table th:nth-child(9),.wd-collections-table td:nth-child(9){width:14%}
.wd-collections-table th:nth-child(10),.wd-collections-table td:nth-child(10){width:15%}
@media(max-width:1100px){
  .wd-action-group{flex-wrap:wrap}
}


/* More Details layout fix */
.wd-action-group{
  display:flex !important;
  align-items:center !important;
  gap:8px !important;
  flex-wrap:nowrap !important;
  min-width:220px !important;
}
.wd-action-group .wd-btn{
  flex:0 0 auto !important;
}
.wd-more-details{
  min-width:120px !important;
  max-width:140px !important;
  padding-left:12px !important;
  padding-right:12px !important;
  white-space:nowrap !important;
  overflow:visible !important;
}
.wd-simple-board th:nth-child(10),
.wd-simple-board td:nth-child(10){
  width:170px !important;
  min-width:170px !important;
}
.wd-collections-table th:nth-child(10),
.wd-collections-table td:nth-child(10){
  width:210px !important;
  min-width:210px !important;
}
.wd-table-card{
  overflow-x:auto !important;
}
.wd-table{
  min-width:1320px;
}
@media(max-width:1400px){
  .wd-action-group{
    flex-direction:column !important;
    align-items:flex-start !important;
    min-width:130px !important;
  }
  .wd-simple-board th:nth-child(10),
  .wd-simple-board td:nth-child(10),
  .wd-collections-table th:nth-child(10),
  .wd-collections-table td:nth-child(10){
    width:150px !important;
    min-width:150px !important;
  }
  .wd-more-details{
    min-width:120px !important;
  }
}
@media(max-width:900px){
  .wd-table{
    min-width:0 !important;
  }
  .wd-action-group{
    flex-direction:row !important;
    flex-wrap:wrap !important;
    min-width:0 !important;
  }
}


/* Final layout cleanup: no extra More Details button in table */
.wd-six-kpis{
  grid-template-columns:repeat(6,1fr) !important;
}
.wd-action-group{
  min-width:90px !important;
  width:auto !important;
}
.wd-action-group .wd-btn{
  min-width:88px !important;
}
.wd-simple-board th:nth-child(10),
.wd-simple-board td:nth-child(10){
  width:105px !important;
  min-width:105px !important;
}
.wd-collections-table th:nth-child(10),
.wd-collections-table td:nth-child(10){
  width:110px !important;
  min-width:110px !important;
}
.wd-table{
  min-width:1180px !important;
}
.wd-kpi{
  min-height:132px !important;
  padding:16px 12px !important;
}
.wd-kpi-icon{
  width:58px !important;
  height:58px !important;
}
.wd-kpi-icon .app-svg{
  width:28px !important;
  height:28px !important;
}
.wd-kpi strong{
  font-size:32px !important;
}
.wd-kpi span{
  font-size:14px !important;
}
@media(max-width:1500px){
  .wd-six-kpis{grid-template-columns:repeat(3,1fr) !important}
}
@media(max-width:900px){
  .wd-six-kpis{grid-template-columns:1fr !important}
  .wd-table{min-width:0 !important}
}


/* Water Collections More Details restore */
.wd-action-stack{
  flex-direction:column !important;
  align-items:flex-start !important;
  gap:7px !important;
  min-width:126px !important;
}
.wd-action-stack .wd-btn{
  width:118px !important;
  min-width:118px !important;
}
.wd-action-stack .wd-more-details{
  font-size:12px !important;
  padding-left:8px !important;
  padding-right:8px !important;
}
.wd-collections-table th:nth-child(10),
.wd-collections-table td:nth-child(10){
  width:145px !important;
  min-width:145px !important;
}
.wd-detail-row[hidden]{
  display:none !important;
}
.wd-detail-row td{
  background:#fbfdff !important;
  padding:0 !important;
}
.wd-detail-panels{
  display:grid;
  grid-template-columns:1fr 1.25fr 1fr;
  gap:18px;
  padding:18px;
  border-top:1px solid #edf2f8;
}
.wd-detail-panel{
  background:#fff;
  border:1px solid #e4ebf5;
  border-radius:12px;
  padding:14px 16px;
  min-height:130px;
}
.wd-detail-panel h4{
  margin:0 0 12px;
  color:#071d49;
  font-size:16px;
  font-weight:900;
}
.wd-detail-panel p{
  margin:6px 0;
  color:#102959;
}
.wd-mini-entry{
  padding:10px 0;
  border-top:1px solid #edf2f8;
}
.wd-mini-entry:first-of-type{
  border-top:0;
  padding-top:0;
}
.wd-mini-entry strong{
  display:block;
  font-size:13px;
  color:#071d49;
  margin-bottom:4px;
}
.wd-mini-entry p{
  margin:0;
  color:#102959;
  font-size:14px;
  line-height:1.35;
}
.wd-mini-tag{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  padding:4px 8px;
  border-radius:999px;
  background:#eef5ff;
  color:#075eea;
  font-size:12px;
  font-weight:900;
  margin-right:4px;
}
.wd-empty-mini{
  margin:0;
  color:#6b7d98;
  font-weight:700;
  font-size:14px;
}
@media(max-width:1100px){
  .wd-detail-panels{
    grid-template-columns:1fr;
  }
}


/* Water Board and Collections More Details unified layout */
.wd-action-stack{
  flex-direction:column !important;
  align-items:flex-start !important;
  gap:7px !important;
  min-width:126px !important;
}
.wd-action-stack .wd-btn{
  width:118px !important;
  min-width:118px !important;
}
.wd-action-stack .wd-more-details{
  font-size:12px !important;
  padding-left:8px !important;
  padding-right:8px !important;
  white-space:nowrap !important;
}
.wd-simple-board th:nth-child(10),
.wd-simple-board td:nth-child(10),
.wd-collections-table th:nth-child(10),
.wd-collections-table td:nth-child(10){
  width:145px !important;
  min-width:145px !important;
}
.wd-detail-row[hidden]{
  display:none !important;
}
.wd-detail-row td{
  background:#fbfdff !important;
  padding:0 !important;
}
.wd-detail-panels{
  display:grid;
  grid-template-columns:1fr 1.25fr 1fr;
  gap:18px;
  padding:18px;
  border-top:1px solid #edf2f8;
}
.wd-detail-panel{
  background:#fff;
  border:1px solid #e4ebf5;
  border-radius:12px;
  padding:14px 16px;
  min-height:130px;
}
.wd-detail-panel h4{
  margin:0 0 12px;
  color:#071d49;
  font-size:16px;
  font-weight:900;
}
.wd-detail-panel p{
  margin:6px 0;
  color:#102959;
}
@media(max-width:1100px){
  .wd-detail-panels{
    grid-template-columns:1fr;
  }
}


/* Combined client name and split payment amounts */
.wd-form-grid .wd-wide input[readonly]{
  background:#f8fbff;
}
.wd-payment-breakdown small{
  display:block;
  font-size:12px;
  color:#526686;
  font-weight:800;
}


/* Mobile dropdown visibility fix */
.wd-inline-select,
.wd-payment-select,
.wd-step-select,
.wd-type-select{
  color:inherit !important;
  min-height:38px !important;
  height:auto !important;
  line-height:1.2 !important;
  white-space:normal !important;
  overflow:visible !important;
  text-overflow:clip !important;
}
.wd-inline-form{
  min-width:0 !important;
  width:100% !important;
}
.wd-table td[data-label="Job Type"] .wd-inline-select,
.wd-table td[data-label="Current Step"] .wd-inline-select,
.wd-table td[data-label="Balance / Payment"] .wd-inline-select,
.wd-table td[data-label="Collection Status"] .wd-inline-select{
  width:100% !important;
  max-width:220px !important;
}
@media(max-width:900px){
  .wd-table td{
    overflow:visible !important;
  }
  .wd-table td[data-label="Job Type"] .wd-inline-select,
  .wd-table td[data-label="Current Step"] .wd-inline-select,
  .wd-table td[data-label="Balance / Payment"] .wd-inline-select,
  .wd-table td[data-label="Collection Status"] .wd-inline-select{
    display:block !important;
    width:100% !important;
    max-width:100% !important;
    min-height:44px !important;
    font-size:15px !important;
    padding:10px 38px 10px 12px !important;
    appearance:auto !important;
    -webkit-appearance:menulist !important;
    background-image:none !important;
  }
  .wd-payment-cell small{
    font-size:13px !important;
    margin-top:6px !important;
  }
}


/* Mobile selected value visibility fix */
.wd-selected-value{
  display:inline-flex !important;
  align-items:center !important;
  justify-content:center !important;
  padding:7px 11px !important;
  border-radius:8px !important;
  font-size:13px !important;
  line-height:1.15 !important;
  font-weight:900 !important;
  margin-bottom:5px !important;
  max-width:100% !important;
  white-space:normal !important;
}
.wd-type-selected.wd-type-orange{background:#fff1e3 !important;color:#e06b00 !important}
.wd-type-selected.wd-type-purple{background:#f2e8ff !important;color:#7d29d8 !important}
.wd-type-selected.wd-type-blue{background:#eaf2ff !important;color:#075eea !important}
.wd-step-selected.wd-badge-blue{background:#eaf2ff !important;color:#075eea !important}
.wd-step-selected.wd-badge-purple{background:#f2e8ff !important;color:#7d29d8 !important}
.wd-step-selected.wd-badge-orange{background:#fff1e3 !important;color:#e06b00 !important}
.wd-step-selected.wd-badge-red{background:#ffe4e7 !important;color:#d3212f !important}
.wd-step-selected.wd-badge-green{background:#e8f7e9 !important;color:#159947 !important}
.wd-payment-selected.wd-pay-paid{background:#e8f7e9 !important;color:#159947 !important}
.wd-payment-selected.wd-pay-warning{background:#fff1e3 !important;color:#e06b00 !important}
.wd-payment-selected.wd-pay-due{background:#fff1e3 !important;color:#e06b00 !important}
.wd-payment-selected.wd-pay-waiting{background:#eaf2ff !important;color:#075eea !important}
.wd-payment-selected.wd-pay-neutral{background:#f0f3f8 !important;color:#526686 !important}
.wd-inline-select{
  background:#ffffff !important;
  color:#071d49 !important;
  border:1px solid #cbd8eb !important;
  font-weight:800 !important;
}
@media(max-width:900px){
  .wd-selected-value{
    display:flex !important;
    width:100% !important;
    justify-content:flex-start !important;
    font-size:15px !important;
    padding:10px 12px !important;
  }
  .wd-inline-select{
    display:block !important;
    width:100% !important;
    max-width:100% !important;
    min-height:44px !important;
    color:#071d49 !important;
    background:#ffffff !important;
    border:1px solid #cbd8eb !important;
    opacity:1 !important;
    visibility:visible !important;
  }
  .wd-inline-select option{
    color:#071d49 !important;
    background:#ffffff !important;
  }
}
