:root{--h5-header-h:56px;--h5-tabbar-h:62px;--h5-safe-bottom:env(safe-area-inset-bottom,0px);--h5-primary:#00c56e;--h5-bg:#f6f8fa;--h5-card:#fff;--h5-line:#e5e8ec;--h5-muted:#6b7280}
.dx-mobile-header,.dx-mobile-tabbar,.dx-mobile-more,.dx-treasure-switch,.h5-only,.h5-unassigned-card{display:none}
@media (max-width:1023px){
  html{background:var(--h5-bg)}body{display:block!important;min-width:0!important;padding-left:0!important;background:var(--h5-bg)!important}
  #dxSidebar,#dxSidebarRoot,.sidebar,.dx-sidebar,#dxMobileMenuBtn,#dxSidebarShade{display:none!important}.main-area{width:100%!important;min-height:100dvh!important;margin:0!important;padding:var(--h5-header-h) 0 calc(var(--h5-tabbar-h) + var(--h5-safe-bottom))!important;overflow:visible!important}
  body.dx-h5-ready{padding-top:var(--h5-header-h)!important;padding-bottom:calc(var(--h5-tabbar-h) + var(--h5-safe-bottom) + 8px)!important}body.dx-h5-ready.dx-h5-treasure-page{padding-top:calc(var(--h5-header-h) + 48px)!important}
  .topbar,body.dx-h5-ready>.top{display:none!important}.content{padding:12px 14px 24px!important;overflow:visible!important}.h5-only{display:block}
  .h5-unassigned-card{display:block}
  .dx-mobile-header{position:fixed;z-index:90;top:0;left:0;right:0;height:var(--h5-header-h);display:grid;grid-template-columns:44px 1fr 44px;align-items:center;padding:0 8px;background:rgba(255,255,255,.96);border-bottom:1px solid var(--h5-line);backdrop-filter:blur(12px)}
  .dx-h5-logo{width:34px;height:34px;border-radius:10px;background:#d92323;color:#fff;display:flex;align-items:center;justify-content:center;font-size:11px;font-weight:800}
  .dx-mobile-header h1{font-size:18px;line-height:1.2;text-align:center;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.dx-h5-icon{width:44px;height:44px;border:0;background:transparent;border-radius:12px;font-size:20px;color:#111827}.dx-h5-icon:active{background:#eef1f4}
  .dx-mobile-tabbar{position:fixed;z-index:90;left:0;right:0;bottom:0;display:grid;grid-template-columns:repeat(5,1fr);height:calc(var(--h5-tabbar-h) + var(--h5-safe-bottom));padding-bottom:var(--h5-safe-bottom);background:rgba(255,255,255,.97);border-top:1px solid var(--h5-line);box-shadow:0 -5px 18px rgba(17,24,39,.06)}
  .dx-mobile-tabbar a{min-width:0;min-height:56px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:2px;color:#7b8491;text-decoration:none;font-size:11px}.dx-mobile-tabbar .dx-tab-icon{font-size:20px;line-height:1}.dx-mobile-tabbar a.active{color:var(--h5-primary);font-weight:750}
  .dx-treasure-switch{display:grid;position:fixed;z-index:89;top:var(--h5-header-h);left:0;right:0;height:48px;grid-template-columns:repeat(3,1fr);gap:6px;padding:6px 12px;background:#fff;border-bottom:1px solid var(--h5-line)}.dx-treasure-switch a{display:flex;align-items:center;justify-content:center;border-radius:10px;color:#667085;text-decoration:none;font-size:14px;font-weight:700}.dx-treasure-switch a.active{background:#e9fbf2;color:#009b57}
  .dx-mobile-more{display:none;position:fixed;z-index:110;inset:0;background:rgba(17,24,39,.38)}.dx-mobile-more.open{display:block}.dx-mobile-more-panel{position:absolute;left:0;right:0;bottom:0;max-height:78dvh;overflow:auto;padding:16px 14px calc(18px + var(--h5-safe-bottom));background:#fff;border-radius:18px 18px 0 0}.dx-mobile-more-head{display:flex;align-items:center;justify-content:space-between;margin-bottom:12px}.dx-mobile-more-head h2{font-size:18px}.dx-mobile-more-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:10px}.dx-mobile-more-grid a{min-height:76px;padding:10px 6px;border-radius:14px;background:#f6f8fa;color:#374151;text-decoration:none;text-align:center;font-size:12px}.dx-mobile-more-grid span{display:block;font-size:24px;margin-bottom:5px}
  button,input,select,textarea{font-size:16px}.btn,.form-input{min-height:44px}.drawer-mask{z-index:119!important}.drawer{z-index:120!important;top:0!important;right:-100%!important;width:100%!important;max-width:none!important;height:100dvh!important;border-radius:0!important}.drawer.open{right:0!important}.dw-head{position:sticky;top:0;z-index:2;background:#fff}.dw-body{padding:14px!important}.dw-foot{position:sticky;bottom:0;background:#fff;padding-bottom:calc(12px + var(--h5-safe-bottom))!important}.form-row{grid-template-columns:1fr!important}.type-radios{grid-template-columns:repeat(2,minmax(0,1fr))!important}
  .dx-filter-drawer{position:fixed;z-index:105;inset:0;display:none;background:rgba(17,24,39,.4)}.dx-filter-drawer.open{display:block}.dx-filter-panel{position:absolute;left:0;right:0;bottom:0;padding:18px 14px calc(16px + var(--h5-safe-bottom));background:#fff;border-radius:18px 18px 0 0}.dx-filter-actions{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-top:16px}.dx-filter-actions button{min-height:46px;border:0;border-radius:12px;font-weight:750}.dx-filter-confirm{background:var(--h5-primary);color:#fff}
}
@media (max-width:767px){
  .content{padding-left:12px!important;padding-right:12px!important}.filter-row{margin-bottom:12px!important;display:block!important}.time-tabs{width:100%;overflow-x:auto;justify-content:flex-start;scrollbar-width:none}.time-tabs::-webkit-scrollbar{display:none}.ttab{flex:0 0 auto;min-height:40px;padding:7px 14px!important}.filter-right{display:none!important}.deal-ticker{height:40px!important;margin-bottom:10px!important}.deal-ticker::before{padding-left:10px!important;padding-right:8px!important}.ticker-track{padding-left:100px!important}
  #captureWrap{padding:0!important;background:transparent!important}#periodTitle{font-size:19px!important;margin:6px 2px 12px!important}.stats-row{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:10px!important;margin-bottom:14px!important}.stat-card{min-height:116px!important;padding:15px!important;border-radius:14px!important}.stat-card:hover{transform:none!important}.stat-card.with-actions .sc-main{padding:15px!important}.stat-card.with-actions .sc-actions{display:none!important}.sc-icon{width:32px!important;height:32px!important}.sc-label{font-size:12px!important}.sc-num{font-size:20px!important;white-space:nowrap}
  .rank-section,.chart-card{border-radius:14px!important;overflow:hidden!important;margin-bottom:12px!important}.rank-head{padding:14px!important}.rh-title{font-size:16px!important}.rh-more,.rh-tabs{display:none!important}.rank-table{display:block!important;padding:0 10px 10px}.rank-table thead{display:none!important}.rank-table tbody{display:grid;gap:9px}.rank-table tr{position:relative;display:grid!important;grid-template-columns:46px minmax(0,1fr) auto;grid-template-areas:'rank name money' 'rank count ratio';align-items:center;min-height:74px;padding:12px;border:1px solid #eef0f3;border-radius:13px;background:#fff;box-shadow:0 1px 2px rgba(17,24,39,.04)}.rank-table td{padding:2px 4px!important;border:0!important;background:transparent!important;overflow:visible!important}.rank-table td:nth-child(1){grid-area:rank;text-align:center;font-size:18px}.rank-table td:nth-child(2){grid-area:name;font-weight:750;color:#111827}.rank-table td:nth-child(3){grid-area:money;text-align:right;color:#008f52;font-weight:800}.rank-table td:nth-child(4){grid-area:count;color:var(--h5-muted);font-size:12px}.rank-table td:nth-child(4)::before{content:'成交 '}.rank-table td:nth-child(4)::after{content:' 套'}.rank-table td:nth-child(5){grid-area:ratio;text-align:right!important;font-size:12px}.rank-table tr.unassigned-performance{background:#fff7ed!important;border-color:#fed7aa!important}
  .charts-row{display:grid!important;grid-template-columns:1fr!important;gap:12px!important}.chart-card{padding:14px!important}.chart-title{font-size:16px!important}.chart-wrap{height:250px!important}.type-chart-layout{grid-template-columns:1fr!important;min-height:0!important}.type-chart-canvas{min-height:260px!important}.type-summary{margin-top:8px!important}.type-chart-leaders{display:none!important}
  #personDash{padding:12px!important}.pd-grid{grid-template-columns:1fr!important}.pageRank-records{display:none!important}
}

/* H5 phase 2: 房源、客源、洗盘共用适配。PC 端不命中这些规则。 */
@media (max-width:1023px){
  body.dx-h5-ready .wrap{width:100%!important;max-width:none!important;margin:0!important;padding:12px 12px 24px!important}
  body.dx-h5-ready .scroll{padding:12px 12px 24px!important;overflow:visible!important}
  body.dx-h5-ready>.tabbar{display:none!important}
  body.dx-h5-ready .xq-list{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:10px!important}
  body.dx-h5-ready .xq-card{min-height:108px!important;padding:14px!important;border-radius:14px!important;box-shadow:0 2px 8px rgba(17,24,39,.05)!important}
  body.dx-h5-ready .rank-card{border-radius:14px!important;box-shadow:0 2px 8px rgba(17,24,39,.05)!important}

  body.dx-h5-ready .inbound-panel{display:none!important}
  body.dx-h5-ready .list-meta{position:sticky;top:calc(var(--h5-header-h) + 2px);z-index:20;margin:0 -12px 10px!important;padding:9px 12px!important;background:rgba(246,248,250,.96);overflow-x:auto!important;box-shadow:0 1px 0 var(--h5-line)}
  body.dx-h5-ready .list-meta h1{display:none!important}
  body.dx-h5-ready .list-meta #sub{font-size:12px!important}
  body.dx-h5-ready .list-meta .pagerbtn,body.dx-h5-ready .list-meta label,body.dx-h5-ready .verify-btn{display:none!important}
  body.dx-h5-ready #mobileToggle{display:flex!important;width:100%;min-height:44px;align-items:center;justify-content:center;margin:0 0 10px!important;border:1px solid var(--h5-line)!important;border-radius:12px!important;background:#fff!important;color:#374151!important}
  body.dx-h5-ready .bar.open{display:grid!important;grid-template-columns:1fr 1fr;gap:9px;padding:12px;margin-bottom:12px;border:1px solid var(--h5-line);border-radius:14px;background:#fff;overflow:visible!important}
  body.dx-h5-ready .bar.open .q{grid-column:1/-1;max-width:none!important;width:100%!important}
  body.dx-h5-ready .bar.open>span{grid-column:1/-1;flex-wrap:wrap!important}
  body.dx-h5-ready .cardgrid{grid-template-columns:1fr!important;gap:10px!important}
  body.dx-h5-ready .card{padding:13px!important;border-radius:14px!important;box-shadow:0 2px 8px rgba(17,24,39,.04);content-visibility:auto;contain-intrinsic-size:auto 176px}
  body.dx-h5-ready .cbtns button{min-height:40px!important}
  body.dx-h5-ready .mask{z-index:120!important;padding:0!important;align-items:flex-end!important}
  body.dx-h5-ready .mask .modal{width:100%!important;max-width:none!important;max-height:92dvh!important;margin:0!important;padding:18px 14px calc(18px + var(--h5-safe-bottom))!important;border-radius:20px 20px 0 0!important;border-top:0!important}

  body.dx-h5-ready .infobar{margin-bottom:10px!important;padding:12px!important;border-radius:12px!important}
  body.dx-h5-ready .bldgrid{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:10px!important}
  body.dx-h5-ready .bldcard{min-width:0!important;padding:13px!important;border-radius:12px!important}
  body.dx-h5-ready .floorwrap{padding:0!important;border:0!important;background:transparent!important;overflow:visible!important}
  body.dx-h5-ready .floorzones{display:block!important}
  body.dx-h5-ready .floorzone{padding:0!important;border:0!important}
  body.dx-h5-ready .floorzone+.floorzone{margin-top:14px!important;border-left:0!important}
  body.dx-h5-ready .zone-title{position:sticky;top:calc(var(--h5-header-h) + 48px);z-index:12;padding:9px 6px!important;background:var(--h5-bg);font-size:13px!important}
  body.dx-h5-ready .frow{align-items:stretch!important;border:0!important;margin-bottom:8px!important}
  body.dx-h5-ready .flab{width:38px!important;padding-right:6px!important;border-right:0!important;justify-content:center!important}
  body.dx-h5-ready .fcells{grid-template-columns:repeat(4,minmax(0,1fr))!important;gap:8px!important;padding:0!important}
  body.dx-h5-ready .cell{width:auto!important;height:74px!important;padding:17px 3px 4px!important;border-radius:10px!important}
  body.dx-h5-ready .cell .zx{top:-5px!important;left:-4px!important;width:24px!important;height:24px!important;border-radius:7px!important;font-size:12px!important}
  body.dx-h5-ready .cell .contact-count{top:-5px!important;right:-4px!important;min-width:24px!important;height:24px!important;padding:0 5px!important;font-size:11px!important}

  body.dx-h5-ready #adminView>.panel,body.dx-h5-ready #staffView>.panel{padding:14px!important;border-radius:14px!important}
  body.dx-h5-ready #adminView .bar{display:grid!important;grid-template-columns:1fr 1fr;gap:9px!important}
  body.dx-h5-ready #adminView .bar .q{grid-column:1/-1;max-width:none!important;width:100%!important}
  body.dx-h5-ready #adminView .quickbox{grid-column:1/-1;flex-wrap:wrap!important}
  body.dx-h5-ready .listbox{max-height:48dvh!important;border-radius:12px!important}
  body.dx-h5-ready .listbox table{min-width:720px!important}
  body.dx-h5-ready .staffbox{max-height:170px;overflow:auto;padding:4px}
  body.dx-h5-ready .radiorow{align-items:stretch!important}
  body.dx-h5-ready .actrow{display:grid!important;grid-template-columns:1fr!important}
  body.dx-h5-ready .actrow button,body.dx-h5-ready .actrow select{width:100%!important;min-height:46px!important}

  body.dx-h5-ready .app-shell{height:auto!important;min-height:100dvh!important}
  body.dx-h5-ready .content-scroll{overflow:visible!important;padding:12px!important}
  body.dx-h5-ready .page-head{align-items:center!important;margin-bottom:14px!important}
  body.dx-h5-ready .page-head h1{font-size:22px!important}
  body.dx-h5-ready .page-head .subtitle{font-size:12px!important}
  body.dx-h5-ready .head-actions{margin-left:auto!important}
  body.dx-h5-ready .head-actions .btn{padding:0 12px!important}
  body.dx-h5-ready .filterbar{margin:0 -12px 14px;padding:0 12px 4px!important}
  body.dx-h5-ready .grid{grid-template-columns:1fr!important;gap:12px!important}
  body.dx-h5-ready .project-card{border-radius:14px!important;content-visibility:auto;contain-intrinsic-size:auto 270px}
  body.dx-h5-ready .cover-wrap{height:142px!important}
  body.dx-h5-ready .project-body{padding:14px!important}
  body.dx-h5-ready .card-actions{display:grid!important;grid-template-columns:1fr 1fr 1fr}
  body.dx-h5-ready .card-actions .btn{width:100%!important;margin:0!important}
  body.dx-h5-ready .detail-hero{grid-template-columns:1fr!important;padding:12px!important;gap:14px!important}
  body.dx-h5-ready .detail-cover{height:220px!important}
  body.dx-h5-ready .detail-summary,body.dx-h5-ready .info-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}
  body.dx-h5-ready .detail-tabs{top:calc(var(--h5-header-h) + 2px)!important}
  body.dx-h5-ready .detail-content{padding:16px!important;min-height:180px!important}
  body.dx-h5-ready .gallery{grid-template-columns:repeat(2,minmax(0,1fr))!important}
  body.dx-h5-ready .gallery img{height:150px!important}
  body.dx-h5-ready .editor-layout{display:flex!important;flex-direction:column!important}
  body.dx-h5-ready .meta-panel{order:0!important;padding:14px!important}
  body.dx-h5-ready .paper{padding:12px!important}
  body.dx-h5-ready .project-switch{align-items:stretch!important;flex-direction:column!important}
  body.dx-h5-ready .title-input{font-size:24px!important}
  body.dx-h5-ready .project-picker{max-width:none!important}
  body.dx-h5-ready .toolbar{flex-wrap:nowrap!important;overflow-x:auto!important}
  body.dx-h5-ready .rich{min-height:42dvh!important;padding:16px!important}
  body.dx-h5-ready .hft-mobile-bar{bottom:calc(var(--h5-tabbar-h) + var(--h5-safe-bottom) + 8px)!important}
  body.dx-h5-ready #filterbar{bottom:calc(var(--h5-tabbar-h) + var(--h5-safe-bottom) + 10px)!important}
  body.dx-h5-ready #panel,body.dx-h5-ready #bldPanel{max-height:calc(100dvh - var(--h5-header-h) - var(--h5-tabbar-h) - 82px)!important}
}
@media (max-width:420px){
  body.dx-h5-ready .xq-list{grid-template-columns:1fr!important}
  body.dx-h5-ready .bldgrid{grid-template-columns:1fr!important}
  body.dx-h5-ready .fcells{grid-template-columns:repeat(4,minmax(0,1fr))!important;gap:6px!important}
  body.dx-h5-ready .cell{height:70px!important}
}
