/* 11/3 6PM Finley fixes */
/* Management "Last updated" readable on the dark header */
#cos .lastupd,.lastupd{color:#f1f5fa!important;background:rgba(13,27,42,.78)!important;border:1px solid rgba(201,169,110,.45);opacity:1!important;font-weight:600}
/* Search heading only on Search / By date / Map */
body.om-nohero .hero{display:none!important}
body.om-mg #filters,body.om-mg #fbtn,body.om-mg #mbar{display:none!important}
/* By date looks distinct */
body.om-date .hero{background:linear-gradient(100deg,rgba(201,169,110,.42),rgba(8,16,28,.62) 70%)!important;border:1px solid rgba(201,169,110,.7);border-left:6px solid #C9A96E}
body.om-date .hero h1::before{content:"📅 ";font-size:.8em}
.om-datesub{display:none;margin:4px 0 0;color:#f6ead2!important;font-size:13px;font-weight:600}
body.om-date .om-datesub{display:block}
body.om-date #cards .card{border-top:3px solid #C9A96E}
/* OP explanation */
.op-why{display:inline-block;font-size:11px;color:#4a5b6d;margin:2px 0 0 4px}
/* Private Owner PDFs: agents only */
.ownpdf-lock{color:#e6d3ad;font-size:12px}
/* CRM: ticker no longer under the Back button */
body.crm #marketTicker{margin-left:92px!important;width:calc(100% - 92px)!important}
body.crm .mpg-backrow{top:0!important;left:0!important;width:92px;height:46px;display:flex!important;align-items:center;justify-content:center;background:#0d1b2a;padding:0!important}
/* CRM pipeline card buttons wrap instead of running off the card */
.crmlead-acts{flex-wrap:wrap!important;gap:6px!important}
.crmlead-acts>.crmeditbtn,.crmlead-acts>.crmdelbtn{width:auto!important;flex:1 1 auto!important;min-width:0}
.crmlead-acts .crmStageSel{min-width:0!important;flex:1 1 90px!important}
/* CRM Delete / Edit normal size (not full width) */
@media(max-width:760px){
 .crmeditbtn,.crmdelbtn{width:auto!important;justify-self:start!important}
 .crmleadrow{display:flex!important;flex-wrap:wrap;gap:8px;align-items:center}
 .crmleadrow>*{flex:1 1 100%;min-width:0}
 .crmleadrow>.crmeditbtn,.crmleadrow>.crmdelbtn,.crmleadrow>.crmlead-pill,.crmleadrow>.crmdue{flex:0 0 auto!important;width:auto!important}
 .crmleadrow>.crmeditbtn,.crmleadrow>.crmdelbtn{min-height:32px;padding:5px 16px;font-size:12px}
}
#crmDelClient{width:auto!important;flex:0 0 auto!important;align-self:flex-start}
/* CRM calendar: no big empty area, compact month buttons */
.crmcalhead{grid-column:1/-1;justify-content:center!important;gap:14px!important}
#crmCalPrev,#crmCalNext{flex:0 0 auto!important;width:44px!important;min-width:44px!important;max-width:44px;padding:0!important;height:36px}
.crmcalmonth{flex:0 1 auto;text-align:center;min-width:140px}
.crmcalagenda{min-height:0!important}
.mc-noph{color:#6b7a8a;font-style:italic}
/* 11/03: CRM Clients home on phones - sidebar becomes a top strip so client cards get full width */
@media (max-width:600px){
 body:not(.crm-subpage) #crmShell.crmshell{display:block!important;grid-template-columns:1fr!important}
 body:not(.crm-subpage) #crmNavSide.crmnavside{position:static!important;width:auto!important;min-width:0!important;height:auto!important;min-height:0!important;max-height:none!important;display:flex!important;flex-direction:column;padding:8px!important;margin:0 0 10px!important;border-radius:12px;overflow:hidden}
 body:not(.crm-subpage) #crmNavSide .crmnavlist{flex-direction:row!important;flex-wrap:nowrap!important;overflow-x:auto;-webkit-overflow-scrolling:touch;gap:6px!important;width:100%}
 body:not(.crm-subpage) #crmNavSide .crmnavitem{width:auto!important;flex:0 0 auto;white-space:nowrap;min-height:40px}
 body:not(.crm-subpage) #crmNavSide .crmnavsep{display:none}
 body:not(.crm-subpage) #crmNavSide>*:not(.crmnavlist):not(.crmnavexit){display:none!important}
 body:not(.crm-subpage) #crmNavSide .crmnavexit{margin:6px 0 0!important;padding-top:6px!important}
 #v-crm .crmclient, #v-crm [class*=crmclient] a{overflow-wrap:anywhere;word-break:break-word}
}
/* 11/3 6PM: CRM client page on phones - keep detail panels inside the screen */
@media (max-width:600px){
  #crmClientDetail .crmgrid2{grid-template-columns:minmax(0,1fr)!important}
  #crmClientDetail .crmpanel{min-width:0;max-width:100%;box-sizing:border-box}
  #crmClientDetail input,#crmClientDetail select,#crmClientDetail textarea{max-width:100%;min-width:0;box-sizing:border-box}
  #crmClientDetail .crmbig{max-width:100%;white-space:normal}
  #crmClientDetail .crmparty-detail .meta{flex-wrap:wrap;min-width:0}
  #crmClientDetail .crmparty-detail .meta>*{min-width:0;max-width:100%}
}
/* 11/03 7:30PM: client list row has 6 cells (Edit + Delete); 5-col grid wrapped Delete to a full-width row on desktop */
@media(min-width:761px){.crmleadrow{grid-template-columns:minmax(0,1.4fr) minmax(0,1fr) auto auto auto auto!important}}
.crmleadrow>.crmdelbtn,.crmleadrow>.crmeditbtn{width:auto!important;max-width:120px;justify-self:end!important}
/* 11/3 8PM (Sami OK'd tonight): Finley 7:55PM items 2, 4, 9 */
/* 2. Useful forms: "Choose a form" label readable on the dark panel */
.formsidx .formpick-lab,#v-forms .formpick-lab{color:#f1f5fa!important;text-shadow:0 1px 2px rgba(0,0,0,.45)}
/* 4. Search cards: Call same height as Email, no overlap with Send to client (uifix tel padding/negative margin removed inside card buttons) */
#app .card .cacts a.cact,#app .card .cacts a.cact[href^="tel"],#app .card .cacts button.cact{display:inline-flex!important;align-items:center;justify-content:center;padding:6px 10px!important;margin:0!important;min-height:40px!important;height:auto;box-sizing:border-box;line-height:1.2}
#app .card .cacts{align-items:stretch}
/* 9. CRM on phone: Back in its own row under a full-width ticker; one Back on sub-pages; tab bar always visible */
@media(max-width:760px){
 body.crm #marketTicker{margin-left:0!important;width:100%!important}
 body.crm .mpg-backrow{position:static!important;width:auto!important;height:auto!important;display:block!important;background:none!important;padding:8px 12px 0!important}
 body.crm.crm-subpage .mpg-backrow{display:none!important}
 body.crm-subpage #crmShell.crmshell{display:block!important;grid-template-columns:1fr!important}
 body.crm-subpage #crmNavSide.crmnavside{display:flex!important;position:static!important;width:auto!important;min-width:0!important;height:auto!important;min-height:0!important;max-height:none!important;flex-direction:column;padding:8px!important;margin:0 0 10px!important;border-radius:12px;overflow:hidden}
 body.crm-subpage #crmNavSide .crmnavlist{display:flex!important;flex-direction:row!important;flex-wrap:nowrap!important;overflow-x:auto;-webkit-overflow-scrolling:touch;gap:6px!important;width:100%}
 body.crm-subpage #crmNavSide .crmnavitem{width:auto!important;flex:0 0 auto;white-space:nowrap;min-height:40px}
 body.crm-subpage #crmNavSide .crmnavsep{display:none}
 body.crm-subpage #crmNavSide>*:not(.crmnavlist){display:none!important}
}
/* 11/3 8:15PM (Sami OK'd tonight): desktop CRM Back below the ticker (not inside it) */
@media(min-width:761px){
 body.crm #marketTicker{margin-left:0!important;width:100%!important}
 body.crm .mpg-backrow{position:static!important;width:auto!important;height:auto!important;display:block!important;background:none!important;padding:8px 32px 0!important}
}
/* 11/3 8:15PM: Private Owners / FSBO PDF links readable (light buttons on the dark notice box) */
.ownpdf a,.fsbopdf a{display:inline-block;color:#0f2340!important;background:#f1f5fa!important;border-radius:8px;padding:6px 10px;margin:3px 0;font-weight:600;text-decoration:none;line-height:1.3}
.ownpdf a:hover,.fsbopdf a:hover{background:#fff!important}
.ownpdf-lock{color:#e6edf5!important}
