.qhub-scan-tabs{
  margin:0 0 18px;
}

.qhub-device-panel{
  max-width:1040px;
}

.qhub-device-panel .widget-heading h2{
  margin-top:4px;
}

.qhub-device-panel .widget-heading > button{
  min-height:44px;
  padding:10px 14px;
  border:1px solid var(--border);
  border-radius:9px;
  background:transparent;
  color:var(--text);
  font:inherit;
  font-size:13px;
  font-weight:700;
}

.qhub-device-state{
  min-height:190px;
  display:grid;
  place-content:center;
  justify-items:center;
  gap:8px;
  padding:24px;
  border:1px dashed var(--border);
  border-radius:14px;
  text-align:center;
  color:var(--muted);
}

.qhub-device-state h2,
.qhub-device-state p{
  margin:0;
}

.qhub-device-state h2{
  color:var(--text);
  font-size:18px;
}

.qhub-device-state .spinner{
  width:26px;
  height:26px;
}

.qhub-device-list{
  display:grid;
  gap:12px;
}

.qhub-device-card{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:20px;
  min-width:0;
  padding:18px;
  border:1px solid var(--border);
  border-radius:14px;
  background:var(--input);
}

.qhub-device-card-main{
  min-width:0;
  flex:1;
}

.qhub-device-title{
  display:flex;
  align-items:center;
  flex-wrap:wrap;
  gap:10px;
}

.qhub-device-title h2{
  margin:0;
  overflow-wrap:anywhere;
  font-size:16px;
}

.qhub-device-status{
  display:inline-flex;
  align-items:center;
  min-height:26px;
  padding:4px 9px;
  border:1px solid var(--border);
  border-radius:999px;
  color:var(--muted);
  font-size:12px;
  font-weight:700;
}

.qhub-device-status--authorized{
  border-color:color-mix(in srgb,var(--success) 42%,var(--border));
  color:var(--success);
}

.qhub-device-status--inactive{
  border-color:var(--border);
  color:var(--muted);
}

.qhub-device-status--revoked{
  border-color:color-mix(in srgb,var(--error) 42%,var(--border));
  color:var(--error);
}

.qhub-device-details{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:12px 20px;
  margin:14px 0 0;
}

.qhub-device-details div{
  min-width:0;
}

.qhub-device-details dt{
  margin-bottom:4px;
  color:var(--muted);
  font-size:12px;
}

.qhub-device-details dd{
  margin:0;
  overflow-wrap:anywhere;
  color:var(--text);
  font-size:13px;
}

.qhub-device-revoke{
  flex:0 0 auto;
  min-height:44px;
}

.qhub-device-revoked-note{
  flex:0 0 auto;
  color:var(--muted);
  font-size:13px;
  font-weight:700;
}

.qhub-device-feedback{
  max-width:1040px;
  margin:0 0 14px;
  padding:12px 14px;
  border:1px solid var(--border);
  border-radius:10px;
  background:var(--panel);
  color:var(--success);
  font-weight:700;
}

.qhub-device-dialog{
  width:min(480px,calc(100vw - 32px));
  max-width:none;
  padding:0;
  border:1px solid var(--border);
  border-radius:18px;
  background:var(--panel);
  color:var(--text);
  box-shadow:var(--tqds-shadow-modal,0 34px 90px rgba(0,0,0,.4));
}

.qhub-device-dialog::backdrop{
  background:rgba(4,12,26,.62);
  backdrop-filter:blur(3px);
}

.qhub-device-dialog-content{
  padding:24px;
}

.qhub-device-dialog-content h2{
  margin:0 0 14px;
  font-size:21px;
}

.qhub-device-dialog-content p{
  color:var(--muted);
  line-height:1.55;
}

.qhub-device-dialog-name{
  color:var(--text)!important;
  font-weight:700;
}

.qhub-device-dialog-name span{
  color:var(--muted);
  font-size:13px;
  font-weight:500;
}

.qhub-device-dialog-error{
  color:var(--error)!important;
}

.qhub-device-dialog-actions{
  display:flex;
  justify-content:flex-end;
  flex-wrap:wrap;
  gap:10px;
  margin-top:22px;
}

.qhub-device-dialog-actions :is(button){
  min-height:44px;
  padding:10px 15px;
}

.qhub-device-dialog :is(button):focus-visible,
.qhub-device-panel :is(button,a):focus-visible{
  outline:3px solid var(--orange);
  outline-offset:3px;
}

@media(max-width:600px){
  .qhub-device-card{
    align-items:stretch;
    flex-direction:column;
    gap:14px;
    padding:15px;
  }

  .qhub-device-details{
    grid-template-columns:repeat(2,minmax(0,1fr));
  }

  .qhub-device-revoke{
    width:100%;
    min-height:44px;
  }

  .qhub-device-dialog-content{
    padding:20px;
  }

  .qhub-device-dialog-actions{
    display:grid;
    grid-template-columns:1fr;
  }
}

@media(prefers-reduced-motion:reduce){
  .qhub-device-panel :is(button,a),
  .qhub-device-dialog :is(button,a){
    transition:none!important;
  }
}
