:root{
    --bg: #0b1220;
    --text: #0b1220;
    --muted:#6b7280;
  
    --white:#ffffff;
    --slate:#111827;
  
    --brand1:#fb923c;
    --brand2:#f97316;
    --good:#10b981;
    --warn:#f59e0b;
  
    --shadow: 0 18px 50px rgba(2,6,23,.10);
    --shadow2: 0 10px 24px rgba(2,6,23,.10);
    --radius: 20px;
  }
  
  *{box-sizing:border-box}
  html,body{height:100%}
  body{
    margin:0;
    font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Arial, "Apple Color Emoji","Segoe UI Emoji";
    color: var(--slate);
    background:
      radial-gradient(1200px 600px at 20% 0%, rgba(251,146,60,.18), transparent 60%),
      radial-gradient(900px 500px at 80% 10%, rgba(14,165,233,.10), transparent 55%),
      #f7f8fb;
  }
  
  .app{min-height:100%; display:flex; flex-direction:column}
  
  .topbar{
    position:sticky; top:0; z-index:30;
    background: rgba(255,255,255,.78);
    backdrop-filter: blur(14px);
    border-bottom: 1px solid rgba(15,23,42,.08);
    padding: 14px 16px;
    display:flex; align-items:center; justify-content:space-between;
  }
  
  .brand{display:flex; align-items:center; gap:12px}
  .badge{
    width:42px; height:42px; border-radius: 14px;
    background: linear-gradient(180deg, var(--brand1), var(--brand2));
    display:grid; place-items:center;
    color:#fff; font-weight:900;
    box-shadow: var(--shadow2);
  }
  .brand-name{font-weight:900; letter-spacing:.08em; font-size:12px}
  .brand-sub{font-size:12px; color: var(--muted); font-weight:700}
  
  .top-actions{display:flex; align-items:center; gap:10px}
  .net-status{
    font-size:12px; font-weight:800;
    color: #065f46;
    background: rgba(16,185,129,.12);
    border: 1px solid rgba(16,185,129,.22);
    padding: 8px 10px; border-radius: 999px;
  }
  
  /* v0.2 UX: Progress */
  .progress-wrap{
    width:min(1120px, calc(100% - 32px));
    margin: 10px auto 0;
  }
  .progress{
    display:flex;
    gap:10px;
    align-items:center;
    padding: 10px 12px;
    border-radius: 999px;
    background: rgba(255,255,255,.70);
    border: 1px solid rgba(15,23,42,.08);
    box-shadow: var(--shadow2);
    overflow:auto;
  }
  .step{
    display:flex; align-items:center; gap:8px;
    padding: 8px 12px;
    border-radius: 999px;
    border: 1px solid rgba(15,23,42,.08);
    background: rgba(2,6,23,.03);
    color: rgba(17,24,39,.65);
    font-weight: 1000;
    font-size: 12px;
    white-space:nowrap;
  }
  .step-dot{
    width:10px; height:10px; border-radius:999px;
    background: rgba(2,6,23,.18);
  }
  .step.active{
    background: linear-gradient(180deg, rgba(251,146,60,.16), rgba(249,115,22,.08));
    border-color: rgba(249,115,22,.20);
    color: rgba(17,24,39,.95);
  }
  .step.active .step-dot{
    background: linear-gradient(180deg, var(--brand1), var(--brand2));
  }
  
  /* v0.2 UX: Toast */
  .toast{
    position: fixed;
    left: 50%;
    bottom: 18px;
    transform: translateX(-50%);
    z-index: 50;
  }
  .toast-inner{
    background: rgba(2,6,23,.88);
    color:#fff;
    border: 1px solid rgba(255,255,255,.12);
    padding: 12px 14px;
    border-radius: 14px;
    box-shadow: 0 18px 55px rgba(2,6,23,.25);
    font-weight: 900;
    font-size: 13px;
    max-width: min(520px, calc(100vw - 24px));
  }
  
  .shell{
    width:min(1120px, calc(100% - 32px));
    margin: 14px auto 18px;
    display:grid;
    grid-template-columns: 260px 1fr;
    gap: 16px;
    align-items:start;
  }
  
  .nav{
    position:sticky; top:120px;
    border-radius: var(--radius);
    background: rgba(255,255,255,.7);
    border: 1px solid rgba(15,23,42,.08);
    box-shadow: var(--shadow);
    padding: 10px;
    overflow:hidden;
  }
  .nav-item{
    width:100%;
    border:0;
    background:transparent;
    padding: 12px 12px;
    border-radius: 14px;
    text-align:left;
    font-weight:900;
    color: #0b1220;
    display:flex; align-items:center; gap:10px;
    cursor:pointer;
  }
  .nav-item:hover{background: rgba(2,6,23,.04)}
  .nav-item.active{
    background: linear-gradient(180deg, rgba(251,146,60,.16), rgba(249,115,22,.08));
    border: 1px solid rgba(249,115,22,.20);
  }
  .dot{
    width:10px;height:10px;border-radius:999px;
    background: rgba(2,6,23,.12);
  }
  .nav-item.active .dot{background: linear-gradient(180deg, var(--brand1), var(--brand2))}
  
  .content{display:grid; gap: 16px}
  
  .card{
    background: rgba(255,255,255,.86);
    border: 1px solid rgba(15,23,42,.08);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 18px;
  }
  
  h1{margin:0 0 8px; font-size:28px}
  h2{margin:0; font-size:22px}
  .muted{color: var(--muted); font-weight:700}
  .small{font-size:12px}
  
  .grid{display:grid; gap: 12px; margin-top: 12px}
  .field span{display:block; font-size:12px; font-weight:900; margin-bottom:6px}
  .field input{
    width:100%;
    height: 46px;
    border-radius: 16px;
    border: 1px solid rgba(15,23,42,.10);
    background:#fff;
    padding: 0 14px;
    font-weight:800;
    outline:none;
  }
  .field input:focus{box-shadow: 0 0 0 6px rgba(251,146,60,.14); border-color: rgba(249,115,22,.35)}
  
  .row{display:flex; gap:10px; align-items:center; margin-top: 14px}
  .row.wrap{flex-wrap:wrap}
  
  .btn{
    border:0;
    cursor:pointer;
    height: 46px;
    padding: 0 16px;
    border-radius: 16px;
    font-weight:900;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    gap:10px;
    text-decoration:none;
  }
  .btn:active{transform: scale(.99)}
  .btn-primary{
    color:#fff;
    background: linear-gradient(180deg, var(--brand1), var(--brand2));
    box-shadow: 0 18px 40px rgba(249,115,22,.22);
  }
  .btn-ghost{
    background:#fff;
    border: 1px solid rgba(15,23,42,.12);
    box-shadow: 0 10px 24px rgba(2,6,23,.06);
    color: var(--slate);
  }
  .btn-subtle{
    background: rgba(2,6,23,.04);
    border: 1px solid rgba(15,23,42,.10);
    color: var(--slate);
  }
  .btn-full{width:100%; height:54px; border-radius: 18px; font-size:15px}
  
  /* v0.2 UX: disabled buttons look intentional */
  .btn:disabled{
    opacity: .55;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
  }
  
  .divider{height:1px; background: rgba(15,23,42,.10); margin: 16px 0}
  
  .hint{
    border-radius: 16px;
    padding: 12px;
    background: rgba(2,6,23,.03);
    border: 1px solid rgba(15,23,42,.08);
    font-weight:800;
  }
  
  .screen-head{display:grid; gap:6px; margin-bottom: 12px}
  
  .kpis{
    display:grid;
    grid-template-columns: repeat(3, minmax(0,1fr));
    gap: 10px;
    margin: 12px 0 14px;
  }
  .kpi{
    border-radius: 18px;
    padding: 12px;
    background: rgba(255,255,255,.92);
    border: 1px solid rgba(15,23,42,.08);
  }
  .kpi-label{font-size:12px; font-weight:900; color: var(--muted)}
  .kpi-value{font-size:22px; font-weight:1000; margin-top:4px}
  
  .panel{
    border-radius: 18px;
    overflow:hidden;
    border: 1px solid rgba(15,23,42,.08);
    background: rgba(255,255,255,.88);
  }
  .panel-title{
    padding: 12px 14px;
    font-weight:1000;
    background: rgba(2,6,23,.03);
    border-bottom: 1px solid rgba(15,23,42,.08);
  }
  .panel-body{padding: 14px}
  
  .scan-box{
    height: 210px;
    border-radius: 18px;
    background:
      radial-gradient(900px 300px at 50% 0%, rgba(251,146,60,.22), transparent 55%),
      linear-gradient(180deg, rgba(2,6,23,.06), rgba(2,6,23,.03));
    border: 1px solid rgba(15,23,42,.12);
    position:relative;
    overflow:hidden;
    display:grid; place-items:center;
    margin-bottom: 12px;
  }
  .scan-overlay{
    position:absolute; inset: 16px 18px;
    border-radius: 16px;
    border: 2px dashed rgba(249,115,22,.35);
    box-shadow: inset 0 0 0 6px rgba(255,255,255,.30);
  }
  .scan-text{text-align:center; padding: 0 14px}
  .scan-big{font-weight:1000}
  .scan-small{margin-top:6px; color: var(--muted); font-weight:800; font-size:12px}
  
  .pill{
    display:inline-flex; align-items:center; gap:8px;
    padding: 8px 10px;
    border-radius: 999px;
    font-weight:1000;
    font-size: 12px;
    border: 1px solid rgba(15,23,42,.10);
    background: rgba(255,255,255,.90);
  }
  .pill-warn{
    border-color: rgba(245,158,11,.25);
    background: rgba(245,158,11,.10);
    color:#7c2d12;
  }
  .pill-good{
    border-color: rgba(16,185,129,.25);
    background: rgba(16,185,129,.10);
    color:#065f46;
  }
  .pill-brand{
    border-color: rgba(249,115,22,.25);
    background: rgba(249,115,22,.10);
    color:#7c2d12;
  }
  .pill-dark{
    background: rgba(2,6,23,.80);
    border-color: rgba(255,255,255,.10);
    color:#fff;
  }
  
  .list{display:grid; gap: 10px; margin: 14px 0}
  .item{
    border-radius: 18px;
    padding: 12px;
    border: 1px solid rgba(15,23,42,.08);
    background: rgba(255,255,255,.90);
    display:grid;
    grid-template-columns: 1fr auto;
    gap: 10px;
  }
  .item-title{font-weight:1000}
  .item-meta{display:flex; gap:8px; flex-wrap:wrap; margin-top:6px}
  .item-right{display:flex; flex-direction:column; align-items:flex-end; gap:8px}
  .tag{
    font-size:11px; font-weight:1000;
    padding: 6px 9px;
    border-radius: 999px;
    border: 1px solid rgba(15,23,42,.10);
    background: rgba(2,6,23,.03);
    color: var(--slate);
  }
  .tag.high{border-color: rgba(249,115,22,.25); background: rgba(249,115,22,.10); color:#7c2d12}
  .tag.issue{border-color: rgba(245,158,11,.25); background: rgba(245,158,11,.10); color:#7c2d12}
  
  .map-mock{
    border-radius: 18px;
    border: 1px solid rgba(15,23,42,.10);
    background:
      radial-gradient(800px 260px at 70% 0%, rgba(14,165,233,.10), transparent 60%),
      radial-gradient(900px 300px at 20% 0%, rgba(251,146,60,.18), transparent 60%),
      #ffffff;
    overflow:hidden;
    padding: 12px;
  }
  .map-top{display:flex; gap:8px; justify-content:space-between; align-items:center}
  .map-grid{
    position:relative;
    height: 240px;
    margin-top: 12px;
    border-radius: 16px;
    background:
      linear-gradient(90deg, rgba(15,23,42,.06) 1px, transparent 1px) 0 0 / 18px 18px,
      linear-gradient(0deg, rgba(15,23,42,.06) 1px, transparent 1px) 0 0 / 18px 18px;
    border: 1px solid rgba(15,23,42,.08);
  }
  .map-line{
    position:absolute; inset: 22px;
    border-radius: 14px;
    border: 2px solid rgba(249,115,22,.35);
    transform: rotate(-6deg);
    opacity:.55;
  }
  .map-pin{
    position:absolute; width:10px; height:10px; border-radius: 999px;
    background: linear-gradient(180deg, var(--brand1), var(--brand2));
    box-shadow: 0 10px 18px rgba(249,115,22,.20);
  }
  .map-pin.p1{left:24px; top:34px}
  .map-pin.p2{left:75%; top:18%}
  .map-pin.p3{left:60%; top:66%}
  .map-pin.p4{left:35%; top:52%}
  .map-pin.p5{left:18%; top:72%}
  .map-note{margin-top:10px; font-size:12px; color: var(--muted); font-weight:800}
  
  .drive-card{
    display:grid;
    grid-template-columns: 1.4fr .9fr;
    gap: 14px;
  }
  .drive-left{display:grid; gap: 12px}
  .drive-hud{display:flex; gap:10px; flex-wrap:wrap}
  .hud-pill{
    background: rgba(255,255,255,.92);
    border: 1px solid rgba(15,23,42,.12);
    padding: 10px 12px;
    border-radius: 999px;
    font-weight:1000;
    font-size: 12px;
  }
  .hud-warn{border-color: rgba(249,115,22,.25); background: rgba(249,115,22,.10); color:#7c2d12}
  .drive-job{
    border-radius: 18px;
    border: 1px solid rgba(15,23,42,.10);
    background: rgba(255,255,255,.92);
    padding: 14px;
  }
  .drive-title{font-size:22px; font-weight:1000}
  .drive-meta{display:flex; gap:8px; flex-wrap:wrap; margin-top:10px}
  .drive-address{margin-top:10px; color: var(--muted); font-weight:800}
  .drive-actions{display:flex; gap:10px; margin-top: 14px; flex-wrap:wrap}
  
  .drive-right{
    border-radius: 18px;
    border: 1px solid rgba(15,23,42,.10);
    background: rgba(255,255,255,.92);
    padding: 14px;
    display:flex;
    flex-direction:column;
    gap: 10px;
  }
  .mini-list-title{font-weight:1000}
  .mini-list{display:grid; gap: 10px; flex:1; overflow:auto; padding-right:4px}
  .mini{
    border-radius: 16px;
    border: 1px solid rgba(15,23,42,.08);
    padding: 10px;
    background: rgba(2,6,23,.03);
  }
  .mini .t{font-weight:1000}
  .mini .s{font-size:12px; color: var(--muted); font-weight:800; margin-top:4px}
  
  .footer{
    width:min(1120px, calc(100% - 32px));
    margin: 14px auto 22px;
    display:flex; justify-content:space-between; align-items:center;
    color: rgba(17,24,39,.75);
    font-weight:900;
    font-size:12px;
  }
  
  @media (max-width: 920px){
    .shell{grid-template-columns: 1fr}
    .nav{position:relative; top:0}
    .drive-card{grid-template-columns: 1fr}
    .progress-wrap{margin-top: 8px}
  }