:root{
  --cws-ref-blue:#0088cc;
  --cws-ref-navy:#243447;
  --cws-ref-muted:#6c7e90;
  --cws-ref-border:#dfe8ef;
  --cws-ref-soft:#f7fafc;
}
.cws-referrals-wrap{padding:8px 0 42px}
.cws-referrals-intro{display:grid;grid-template-columns:minmax(0,1.25fr) minmax(280px,.75fr);gap:18px;margin-bottom:18px}
.cws-referrals-panel,.cws-referrals-search,.cws-referrals-map-card,.cws-referral-card{background:#fff;border:1px solid var(--cws-ref-border);border-radius:16px;box-shadow:0 10px 30px rgba(31,54,79,.07)}
.cws-referrals-panel{padding:22px}
.cws-referrals-heading{display:flex;gap:13px;align-items:flex-start}
.cws-referrals-icon{width:46px;height:46px;flex:0 0 46px;display:flex;align-items:center;justify-content:center;border-radius:13px;background:#edf8fd;border:1px solid #d4edf8;color:var(--cws-ref-blue);font-size:18px}
.cws-referrals-kicker{display:block;margin-bottom:3px;color:var(--cws-ref-blue);font-size:10px;line-height:1.15;font-weight:900;letter-spacing:.09em;text-transform:uppercase}
.cws-referrals-panel h2,.cws-referrals-search h2,.cws-referrals-results-head h2,.cws-referrals-map-head h2{margin:0!important;color:var(--cws-ref-navy)!important;font-weight:900!important;letter-spacing:-.012em!important}
.cws-referrals-panel h2,.cws-referrals-search h2,.cws-referrals-map-head h2{font-size:20px!important;line-height:1.2!important}
.cws-referrals-heading p{margin:5px 0 0;color:var(--cws-ref-muted);font-size:12px;line-height:1.5}
.cws-referrals-types{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-top:18px}
.cws-referrals-type{display:flex;align-items:center;gap:9px;padding:11px 12px;border:1px solid #e5edf3;border-radius:12px;background:#fbfdfe;color:#465b6f;font-size:11px;font-weight:800;line-height:1.35}
.cws-referrals-type i{color:var(--cws-ref-blue);font-size:15px}
.cws-referrals-disclaimer{margin-top:14px;padding:12px 14px;border-radius:12px;background:#fff8eb;border:1px solid #f1d9a7;color:#796341;font-size:10px;line-height:1.5}
.cws-referrals-disclaimer strong{color:#714600}.cws-referrals-disclaimer a{color:#9a6100;font-weight:800;text-decoration:none}.cws-referrals-disclaimer a:hover{text-decoration:underline}
.cws-referrals-account{display:flex;flex-direction:column;justify-content:space-between;height:100%;min-height:100%}
.cws-referrals-account .cws-referrals-heading{margin-bottom:16px}
.cws-referrals-account-action{display:flex;align-items:center;justify-content:space-between;gap:14px;padding:15px;border-radius:13px;background:#f5fbfe;border:1px solid #d9edf7}
.cws-referrals-account-action strong{display:block;color:#2b4054;font-size:12px;font-weight:900;line-height:1.35}.cws-referrals-account-action span{display:block;margin-top:3px;color:#718293;font-size:10px;line-height:1.4}
.cws-referrals-account-action a{flex:0 0 auto;display:inline-flex;align-items:center;gap:7px;border-radius:10px;padding:9px 12px;background:var(--cws-ref-blue);color:#fff!important;font-size:10px;font-weight:900;text-transform:uppercase;letter-spacing:.03em;text-decoration:none!important;white-space:nowrap}
.cws-referrals-search{padding:20px 22px;margin-bottom:20px}
.cws-referrals-search-head{display:flex;justify-content:space-between;gap:18px;align-items:flex-end;margin-bottom:16px}.cws-referrals-search-head p{margin:4px 0 0;color:var(--cws-ref-muted);font-size:11px;line-height:1.4}
.cws-referrals-form{display:grid;grid-template-columns:minmax(150px,.8fr) minmax(150px,.8fr) minmax(220px,1.35fr) auto;gap:12px;align-items:end}
.cws-referrals-field label{display:block;margin:0 0 6px;color:#52677a;font-size:10px;font-weight:900;text-transform:uppercase;letter-spacing:.04em}
.cws-referrals-field .form-control{width:100%!important;height:42px!important;border:1px solid #d7e2ea!important;border-radius:10px!important;background:#fff!important;color:#2c4053!important;font-size:12px!important;box-shadow:none!important;padding:8px 11px!important}.cws-referrals-field .form-control:focus{border-color:#82cbe9!important;box-shadow:0 0 0 3px rgba(0,136,204,.09)!important}
.cws-referrals-submit{height:42px!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:7px!important;border-radius:10px!important;padding:0 18px!important;background:var(--cws-ref-blue)!important;border:1px solid var(--cws-ref-blue)!important;color:#fff!important;font-size:11px!important;font-weight:900!important;text-transform:uppercase!important;letter-spacing:.04em!important;box-shadow:none!important}
.cws-referrals-submit:hover{background:#0077b3!important;border-color:#0077b3!important}
.cws-referrals-map-card{overflow:hidden;margin-bottom:20px}.cws-referrals-map-head{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:16px 18px;border-bottom:1px solid #e6edf2;background:#fbfdfe}.cws-referrals-map-head span:last-child{color:#778896;font-size:10px;font-weight:700;text-align:right}.cws-referrals-map-frame{padding:10px;background:#fff}.cws-referrals-map-frame #googlemapsMarkers{height:390px!important;width:100%!important;margin:0!important;border-radius:12px;overflow:hidden}
.cws-referrals-results-head{display:flex;align-items:flex-end;justify-content:space-between;gap:16px;margin:24px 2px 12px}.cws-referrals-results-head h2{font-size:19px!important;line-height:1.2!important}.cws-referrals-results-head p{margin:4px 0 0;color:var(--cws-ref-muted);font-size:11px}.cws-referrals-count{display:inline-flex;align-items:center;justify-content:center;min-width:34px;padding:5px 9px;border-radius:999px;background:#edf8fd;border:1px solid #d3edf8;color:#0077ad;font-size:10px;font-weight:900}
.cws-referrals-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px}
.cws-referral-card{padding:17px;box-shadow:0 6px 20px rgba(31,54,79,.055);display:flex;flex-direction:column;min-width:0}.cws-referral-card-title{display:flex;align-items:flex-start;gap:10px;margin-bottom:11px}.cws-referral-avatar{width:36px;height:36px;flex:0 0 36px;border-radius:10px;display:flex;align-items:center;justify-content:center;background:#edf8fd;border:1px solid #d4edf8;color:var(--cws-ref-blue);font-size:14px}.cws-referral-card h3{margin:0!important;color:var(--cws-ref-navy)!important;font-size:14px!important;font-weight:900!important;line-height:1.3!important}.cws-referral-card-person{margin-top:2px;color:#7b8b98;font-size:10px;line-height:1.35}
.cws-referral-contact{display:grid;gap:7px;margin:2px 0 13px}.cws-referral-contact-row{display:grid;grid-template-columns:18px minmax(0,1fr);gap:7px;align-items:start;color:#556a7d;font-size:10.5px;line-height:1.4}.cws-referral-contact-row i{color:#8ba0b2;margin-top:2px;text-align:center}.cws-referral-contact-row a{color:#267da5;text-decoration:none;overflow-wrap:anywhere}.cws-referral-contact-row a:hover{text-decoration:underline}
.cws-referral-services{display:flex;gap:6px;flex-wrap:wrap;margin-top:auto;padding-top:11px;border-top:1px solid #edf1f4}.cws-referral-service{display:inline-flex;align-items:center;gap:5px;border-radius:999px;padding:5px 8px;background:#f5f8fa;border:1px solid #e3eaef;color:#657786;font-size:9px;font-weight:800}.cws-referral-service.is-yes{background:#eef9f2;border-color:#d7ecdE;color:#39714d}.cws-referral-service i{font-size:8px}.cws-referral-website{display:inline-flex;align-items:center;gap:6px;margin-top:11px;color:var(--cws-ref-blue)!important;font-size:10px;font-weight:900;text-decoration:none!important}.cws-referral-website:hover{color:#006fa7!important}
.cws-referrals-empty{margin:18px 0;padding:20px;border:1px solid #ecd5d5;border-radius:14px;background:#fff8f8;text-align:center}.cws-referrals-empty i{display:block;margin-bottom:8px;color:#c24c4c;font-size:22px}.cws-referrals-empty strong{display:block;color:#843c3c;font-size:13px}.cws-referrals-empty span{display:block;margin-top:4px;color:#9a6666;font-size:10px}
@media(max-width:991px){.cws-referrals-intro{grid-template-columns:1fr}.cws-referrals-form{grid-template-columns:repeat(2,minmax(0,1fr))}.cws-referrals-form .cws-referrals-submit{width:100%}.cws-referrals-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:575px){.cws-referrals-wrap{padding-top:2px;padding-bottom:26px}.cws-referrals-panel,.cws-referrals-search{padding:15px}.cws-referrals-intro{gap:12px;margin-bottom:12px}.cws-referrals-heading{gap:10px}.cws-referrals-icon{width:40px;height:40px;flex-basis:40px;border-radius:11px;font-size:16px}.cws-referrals-panel h2,.cws-referrals-search h2,.cws-referrals-map-head h2{font-size:17px!important}.cws-referrals-types{grid-template-columns:1fr;gap:7px;margin-top:13px}.cws-referrals-account-action{align-items:flex-start;flex-direction:column}.cws-referrals-account-action a{width:100%;justify-content:center}.cws-referrals-search-head{align-items:flex-start;flex-direction:column;gap:4px}.cws-referrals-form{grid-template-columns:1fr;gap:10px}.cws-referrals-field .form-control,.cws-referrals-submit{height:44px!important}.cws-referrals-map-head{align-items:flex-start;flex-direction:column;padding:13px 14px;gap:5px}.cws-referrals-map-head span:last-child{text-align:left}.cws-referrals-map-frame{padding:7px}.cws-referrals-map-frame #googlemapsMarkers{height:285px!important;border-radius:10px}.cws-referrals-results-head{margin-top:18px}.cws-referrals-grid{grid-template-columns:1fr;gap:10px}.cws-referral-card{padding:14px}}

/* v131: keep post-map referral results inside the mobile page gutter */
.cws-referrals-results-wrap{width:100%;min-width:0}
@media(max-width:575px){
  .cws-referrals-results-wrap{padding-left:8px;padding-right:8px}
  .cws-referrals-results-head{margin-left:0;margin-right:0}
  .cws-referrals-grid{width:100%;min-width:0}
  .cws-referral-card{width:100%;max-width:100%}
}

@media(max-width:767px){.cws-referrals-field .form-control{font-size:16px!important}}
