
:root{
  --bg-1:#060b12;--bg-2:#0d1b2a;--bg-3:#1b3b5a;--accent:#2f80ed;--accent-soft:#9ec9f5;
  --text:#f8fbff;--muted:#93a4b8;--muted-2:#6f8094;--border:rgba(255,255,255,.10);--card:rgba(13,27,42,.72)
}
*{box-sizing:border-box}html,body{margin:0;padding:0;font-family:Inter,system-ui,Arial,sans-serif;background:radial-gradient(circle at top left,var(--accent) 0%,var(--bg-3) 25%,var(--bg-2) 60%,var(--bg-1) 100%);color:var(--text)}body{min-height:100vh}
button,input,select,textarea{font:inherit}button{cursor:pointer}
.layout{display:flex;min-height:100vh}.sidebar{width:280px;flex-shrink:0;background:#0b1018;border-right:1px solid var(--border);display:flex;flex-direction:column}
.brand{padding:24px;border-bottom:1px solid var(--border)}.brand-row{display:flex;align-items:center;gap:12px}.brand-mark{width:44px;height:44px;border-radius:16px;background:var(--accent);display:flex;align-items:center;justify-content:center;font-weight:800}.brand-title{font-size:18px;font-weight:700}.brand-sub{font-size:13px;color:#f48a8a}
.nav{padding:16px}.nav-btn,.btn{border:1px solid rgba(47,128,237,.3);background:#0d1b2a;color:var(--accent-soft);padding:10px 14px;border-radius:16px;font-weight:500}.nav-btn{width:100%;display:flex;align-items:center;gap:12px;text-align:left;margin-bottom:8px}.nav-btn.active,.btn.active{background:var(--accent);border-color:var(--accent);color:#fff}
.main{flex:1;min-width:0}.topbar{position:sticky;top:0;z-index:20;border-bottom:1px solid var(--border);background:rgba(8,16,27,.90);backdrop-filter:blur(12px)}.topbar-inner{display:flex;gap:12px;align-items:center;padding:16px 24px}
.search{position:relative;flex:1}.search input{width:100%;height:48px;border-radius:18px;border:1px solid var(--border);background:rgba(255,255,255,.05);color:#fff;padding:0 16px 0 44px;outline:none}.search-icon{position:absolute;left:16px;top:50%;transform:translateY(-50%);color:#64748b}
.avatar{width:44px;height:44px;border-radius:16px;border:1px solid var(--border);display:flex;align-items:center;justify-content:center;background:rgba(255,255,255,.05);font-weight:700}
.content{padding:24px}.container{max-width:1600px;margin:0 auto}.hero{display:flex;justify-content:space-between;gap:16px;align-items:flex-end;margin-bottom:24px}.hero h1{margin:8px 0 0;font-size:42px;line-height:1.05}.hero p{margin:12px 0 0;max-width:900px;color:var(--accent-soft)}.badge-line{display:flex;gap:8px;align-items:center;color:#5fa8e3;font-size:14px}.hero-actions{display:flex;gap:10px;flex-wrap:wrap}
.card{background:var(--card);backdrop-filter:blur(10px);border:1px solid var(--border);border-radius:24px}.box{padding:20px}.section-head{padding:16px 20px;border-bottom:1px solid var(--border);font-weight:700;font-size:18px}
.stats{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:16px;margin:18px 0 24px}.stat-card{padding:20px}.stat-title{font-size:14px;color:var(--muted)}.stat-value{font-size:34px;font-weight:700;margin-top:8px}.stat-sub{font-size:14px;color:var(--muted-2);margin-top:4px}
.tabs{display:flex;gap:8px;flex-wrap:wrap;padding:8px;border:1px solid var(--border);border-radius:18px;background:rgba(255,255,255,.05);margin-bottom:24px}
.house-layout{display:grid;grid-template-columns:320px minmax(0,1fr);gap:20px}.filters-head{padding:16px 20px;border-bottom:1px solid var(--border);font-weight:700;font-size:18px}.filters-body{padding:20px;display:grid;gap:24px}.filter-title{font-size:14px;color:var(--muted);margin-bottom:12px}.chip-wrap,.actions,.hero-actions,.tag-wrap{display:flex;flex-wrap:wrap;gap:8px}
.toolbar{padding:16px}.toolbar-row{display:flex;justify-content:space-between;gap:12px;align-items:center;flex-wrap:wrap}.text-muted{color:var(--muted)}
.results-grid,.grid-2,.grid-3,.dashboard-grid{display:grid;gap:16px}.results-grid{grid-template-columns:repeat(3,minmax(0,1fr))}.grid-2{grid-template-columns:repeat(2,minmax(0,1fr))}.grid-3{grid-template-columns:repeat(3,minmax(0,1fr))}.dashboard-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
.house-card img{width:100%;height:176px;object-fit:cover;display:block}.house-card-body{padding:16px}.house-meta{display:flex;justify-content:space-between;gap:12px}
.metric-grid{margin-top:16px;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}.metric-chip{border:1px solid var(--border);background:rgba(255,255,255,.05);border-radius:14px;padding:10px 12px;font-size:14px;color:#dbe7f4}
.pill{border-radius:999px;padding:6px 12px;font-size:12px;font-weight:600;display:inline-flex;align-items:center}.pill.high,.pill.available,.pill.active{background:rgba(52,211,153,.15);color:#86efac}.pill.medium,.pill.sold-stc,.pill.warning,.pill.past-due{background:rgba(245,158,11,.15);color:#fcd34d}.pill.failed,.pill.critical,.pill.suspended{background:rgba(251,113,133,.15);color:#fda4af}.pill.info,.pill.trial,.pill.sold{background:rgba(56,189,248,.15);color:#7dd3fc}
.tag{border:1px solid var(--border);background:rgba(255,255,255,.05);border-radius:999px;padding:6px 12px;font-size:12px;color:#cbd5e1}
.table-wrap{overflow:auto}table{width:100%;border-collapse:collapse}th,td{padding:12px 16px;border-bottom:1px solid rgba(255,255,255,.05);vertical-align:top}thead tr{background:rgba(255,255,255,.05)}th{font-weight:600;color:var(--muted);text-align:left}
.empty{padding:32px;text-align:center;color:#cbd5e1}.simple-list{display:grid;gap:12px}.simple-item{padding:14px 16px;border-radius:18px;border:1px solid var(--border);background:rgba(0,0,0,.12)}
.bar-wrap{margin-top:8px}.bar-line{display:flex;justify-content:space-between;font-size:14px;color:#cbd5e1;margin-bottom:8px}.bar-bg{height:8px;border-radius:999px;background:rgba(255,255,255,.10)}.bar-fill{height:8px;border-radius:999px;background:var(--accent)}
.alert{padding:14px 16px;border-radius:18px;background:rgba(47,128,237,.10);border:1px solid rgba(47,128,237,.2);color:var(--accent-soft);margin-bottom:16px}.alert.error{border-color:rgba(251,113,133,.2);background:rgba(251,113,133,.10);color:#fda4af}
.pagination{display:flex;gap:8px;align-items:center;flex-wrap:wrap;margin-top:16px}
.overlay{position:fixed;inset:0;background:rgba(0,0,0,.5);backdrop-filter:blur(4px);z-index:60;display:flex;justify-content:flex-end}.panel{width:min(860px,100%);height:100%;overflow:auto;background:#0b111a;border-left:1px solid var(--border)}.panel-head{position:sticky;top:0;z-index:5;background:rgba(11,17,26,.95);display:flex;justify-content:space-between;gap:12px;align-items:center;padding:20px;border-bottom:1px solid var(--border)}.panel-body{padding:20px}.panel-body img{width:100%;height:288px;object-fit:cover;border-radius:24px}
.detail-grid,.form-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}.field{display:grid;gap:8px}.field label{font-size:14px;color:var(--muted)}.field input,.field textarea,.field select{width:100%;min-height:46px;border-radius:16px;border:1px solid var(--border);background:rgba(255,255,255,.05);color:#fff;padding:12px 14px;outline:none}.field textarea{min-height:120px;resize:vertical}.mono{font-family:ui-monospace,SFMono-Regular,Menlo,Consolas,monospace}
.compare-tray{position:fixed;left:16px;right:16px;bottom:16px;z-index:40}.compare-inner{max-width:1200px;margin:0 auto;padding:16px;border:1px solid var(--border);border-radius:24px;background:rgba(12,20,32,.95);backdrop-filter:blur(12px)}
@media (max-width:1280px){.sidebar{display:none}.house-layout,.dashboard-grid,.results-grid,.grid-3,.grid-2,.form-grid{grid-template-columns:1fr}.stats{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media (max-width:900px){.content,.topbar-inner{padding-left:16px;padding-right:16px}.hero{flex-direction:column;align-items:flex-start}.hero h1{font-size:34px}.stats,.detail-grid{grid-template-columns:1fr}}

.chart-list{display:flex;flex-direction:column;gap:10px;margin-top:16px}
.chart-row,.dual-chart-row{display:grid;grid-template-columns:minmax(110px,180px) minmax(0,1fr) minmax(80px,130px);gap:10px;align-items:center}
.chart-label{font-size:13px;color:var(--muted);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.chart-track{height:12px;border-radius:999px;background:rgba(255,255,255,.08);overflow:hidden;border:1px solid var(--border)}
.chart-fill{height:100%;border-radius:999px;background:linear-gradient(90deg,rgba(61,130,246,.95),rgba(45,212,191,.85))}
.muted-fill .chart-fill{background:linear-gradient(90deg,rgba(148,163,184,.85),rgba(203,213,225,.75))}
.chart-value{font-size:13px;color:var(--text);font-weight:700;text-align:right}
.dual-bars{display:flex;flex-direction:column;gap:5px}
.scatter-wrap{margin-top:16px;border:1px solid var(--border);border-radius:18px;background:rgba(255,255,255,.03);padding:12px}
.scatter-wrap svg{width:100%;height:auto;max-height:330px}
.scatter-wrap line{stroke:rgba(148,163,184,.55);stroke-width:1}
.scatter-wrap circle{fill:rgba(45,212,191,.85);stroke:rgba(255,255,255,.85);stroke-width:1;cursor:pointer}
.scatter-wrap text{fill:var(--muted);font-size:10px}
@media(max-width:720px){.chart-row,.dual-chart-row{grid-template-columns:1fr;gap:6px}.chart-value{text-align:left}}
