*{box-sizing:border-box}
body{
  margin:0;
  font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Arial,sans-serif;
  background:radial-gradient(circle at top,#241144 0,#090b12 45%,#05060a 100%);
  color:#f4f4f7;
}
a{color:#b894ff;text-decoration:none}
.container{max-width:1180px;margin:0 auto;padding:28px}
.header{
  display:flex;justify-content:space-between;align-items:center;
  margin-bottom:26px;
}
.logo{font-size:24px;font-weight:800;letter-spacing:.3px}
.logo span{color:#b894ff}
.card{
  background:rgba(255,255,255,.07);
  border:1px solid rgba(255,255,255,.12);
  border-radius:22px;
  padding:22px;
  box-shadow:0 20px 60px rgba(0,0,0,.35);
  backdrop-filter:blur(16px);
}
.grid{display:grid;grid-template-columns:380px 1fr;gap:22px}
input{
  width:100%;padding:13px 14px;margin:8px 0;
  border-radius:14px;border:1px solid rgba(255,255,255,.14);
  background:rgba(0,0,0,.28);color:white;font-size:15px;
}
button,.btn{
  display:inline-block;border:0;border-radius:14px;
  padding:12px 16px;background:linear-gradient(135deg,#7b3ff2,#b894ff);
  color:white;font-weight:700;cursor:pointer;
}
.btn.gray,button.gray{background:rgba(255,255,255,.12)}
.btn.red,button.red{background:#d94b5b}
.list{display:flex;flex-direction:column;gap:12px}
.client{
  display:grid;grid-template-columns:1fr auto;gap:14px;align-items:center;
  padding:16px;border-radius:18px;background:rgba(255,255,255,.055);
  border:1px solid rgba(255,255,255,.09);
}
.badge{
  display:inline-block;padding:5px 10px;border-radius:999px;
  font-size:12px;font-weight:700;background:rgba(46,189,133,.18);color:#7dffbd;
}
.badge.off{background:rgba(217,75,91,.18);color:#ff8d9a}
.muted{color:#aeb0bd;font-size:14px}
pre{
  white-space:pre-wrap;word-break:break-all;
  background:rgba(0,0,0,.35);padding:16px;border-radius:16px;
  border:1px solid rgba(255,255,255,.1);
}
.login{max-width:420px;margin:10vh auto}
.qr{background:white;padding:12px;border-radius:18px}
.actions{display:flex;gap:8px;flex-wrap:wrap}
@media(max-width:850px){.grid{grid-template-columns:1fr}.container{padding:16px}}

select{
  width:100%;
  padding:13px 14px;
  margin:8px 0;
  border-radius:14px;
  border:1px solid rgba(255,255,255,.14);
  background:rgba(0,0,0,.28);
  color:white;
  font-size:15px;
}
label{
  display:block;
  margin-top:8px;
}

.form-row{margin-bottom:12px}
.segment{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:8px;
  margin:8px 0 14px;
}
.segment input{display:none}
.segment label{
  margin:0;
  text-align:center;
  padding:12px;
  border-radius:14px;
  cursor:pointer;
  background:rgba(255,255,255,.08);
  border:1px solid rgba(255,255,255,.12);
  color:#d9d6e8;
  font-weight:700;
}
.segment input:checked + label{
  background:linear-gradient(135deg,#7b3ff2,#b894ff);
  color:white;
  border-color:transparent;
}
.help{
  font-size:13px;
  color:#aeb0bd;
  line-height:1.45;
  margin-top:6px;
}

.form-field{
  margin-bottom:14px;
}

.form-field label,
.field-label{
  display:block;
  margin:0 0 7px;
  font-size:13px;
  font-weight:700;
  color:#b9b7c9;
  letter-spacing:.2px;
}

input, select{
  height:48px;
  appearance:none;
  -webkit-appearance:none;
}

select{
  background:
    linear-gradient(135deg, rgba(255,255,255,.08), rgba(255,255,255,.03)),
    url("data:image/svg+xml,%3Csvg width='14' height='8' viewBox='0 0 14 8' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1l6 6 6-6' stroke='%23b894ff' stroke-width='2' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat:no-repeat;
  background-position:right 16px center;
  padding-right:44px;
}

select:focus,
input:focus{
  outline:none;
  border-color:#9d73ff;
  box-shadow:0 0 0 3px rgba(123,63,242,.25);
}

.segment{
  background:rgba(0,0,0,.22);
  padding:5px;
  border-radius:16px;
  border:1px solid rgba(255,255,255,.1);
}

.segment label{
  height:42px;
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:14px;
}

.help{
  background:rgba(255,255,255,.045);
  border:1px solid rgba(255,255,255,.08);
  border-radius:14px;
  padding:10px 12px;
}

.card h3{
  margin-top:0;
  font-size:18px;
}

button,.btn{
  height:44px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
}

form button{
  margin-top:6px;
}


.client{
  grid-template-columns:minmax(0,1fr) 220px;
}

.client .actions{
  display:grid;
  grid-template-columns:1fr;
  gap:8px;
  width:220px;
}

.client .actions form{
  margin:0;
}

.client .actions .btn,
.client .actions button{
  width:100%;
  height:42px;
}

@media(max-width:700px){
  .client{
    grid-template-columns:1fr;
  }
  .client .actions{
    width:100%;
  }
}

.client .badge{
  margin-top:10px;
}

.client .muted{
  margin-bottom:4px;
}

.client b{
  display:block;
  margin-bottom:6px;
}


.copy-block{
  margin-bottom:22px;
}

.copy-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:14px;
  margin-bottom:10px;
}

.copy-head h3{
  margin:0;
}

.copy-btn{
  min-width:130px;
  height:42px;
  white-space:nowrap;
}

.copy-btn.ok{
  background:linear-gradient(135deg,#2ebd85,#75e6ad);
}

.qr-wrap{
  display:flex;
  justify-content:center;
  margin:10px 0 18px;
}

.info-box{
  background:rgba(0,0,0,.24);
  border:1px solid rgba(255,255,255,.09);
  border-radius:16px;
  padding:14px;
  line-height:1.8;
  color:#d9d6e8;
}

pre{
  margin-top:0;
  line-height:1.55;
}

@media(max-width:700px){
  .copy-head{
    align-items:stretch;
    flex-direction:column;
  }
  .copy-btn{
    width:100%;
  }
}

.stats-grid{
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:16px;
  margin-bottom:22px;
}

.stat-card{
  background:rgba(255,255,255,.07);
  border:1px solid rgba(255,255,255,.12);
  border-radius:20px;
  padding:18px;
  box-shadow:0 16px 40px rgba(0,0,0,.22);
}

.stat-title{
  color:#b9b7c9;
  font-size:13px;
  font-weight:700;
  margin-bottom:8px;
}

.stat-value{
  font-size:30px;
  font-weight:900;
  margin-bottom:4px;
}

.stat-sub{
  color:#aeb0bd;
  font-size:13px;
  margin-bottom:12px;
}

.bar{
  height:9px;
  background:rgba(0,0,0,.3);
  border-radius:999px;
  overflow:hidden;
  border:1px solid rgba(255,255,255,.08);
}

.bar div{
  height:100%;
  width:0%;
  border-radius:999px;
  background:linear-gradient(135deg,#7b3ff2,#b894ff);
  transition:width .35s ease;
}

@media(max-width:850px){
  .stats-grid{
    grid-template-columns:1fr;
  }
}

.status-badge{
  margin-top:10px;
}

.status-online{
  background:rgba(46,189,133,.18);
  color:#7dffbd;
}

.status-disabled{
  background:rgba(255,255,255,.12);
  color:#c8c8d2;
}

.status-offline{
  background:rgba(255,180,70,.18);
  color:#ffd18a;
}

.status-failed{
  background:rgba(217,75,91,.18);
  color:#ff8d9a;
}

.status-starting{
  background:rgba(123,63,242,.22);
  color:#d6c4ff;
}

@media(max-width:700px){
  body{
    background:#070912;
  }

  .container{
    padding:14px;
  }

  .header{
    flex-direction:column;
    align-items:stretch;
    gap:14px;
  }

  .header .actions{
    display:grid;
    grid-template-columns:1fr 1fr;
    width:100%;
  }

  .logo{
    font-size:22px;
  }

  .card{
    border-radius:18px;
    padding:16px;
  }

  .stats-grid{
    gap:10px;
  }

  .stat-card{
    padding:15px;
    border-radius:17px;
  }

  .stat-value{
    font-size:26px;
  }

  .grid{
    gap:14px;
  }

  input,
  select,
  button,
  .btn{
    width:100%;
    min-height:46px;
    font-size:15px;
  }

  .segment{
    grid-template-columns:1fr;
  }

  .client{
    padding:14px;
    gap:12px;
  }

  .client .actions{
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:8px;
  }

  .client .actions form{
    width:100%;
  }

  .client .actions button,
  .client .actions .btn{
    width:100%;
  }

  pre{
    font-size:13px;
    max-height:170px;
    overflow:auto;
  }

  .qr-wrap{
    justify-content:center;
  }

  .qr{
    max-width:100%;
    height:auto;
  }

  .copy-head{
    gap:8px;
  }

  .copy-btn{
    width:100%;
  }
}

@media(max-width:420px){
  .header .actions,
  .client .actions{
    grid-template-columns:1fr;
  }

  .stat-value{
    font-size:24px;
  }

  .logo{
    font-size:20px;
  }
}


body{
  background:linear-gradient(180deg,#0b0d16 0%,#070912 100%) !important;
}

.card,
.stat-card,
.client{
  box-shadow:none !important;
  backdrop-filter:none !important;
}

.card,
.stat-card{
  background:rgba(255,255,255,.065) !important;
}

.client{
  background:rgba(255,255,255,.05) !important;
}

@media(max-width:700px){
  body{
    background:#070912 !important;
  }

  .container{
    max-width:100%;
  }

  .card,
  .stat-card,
  .client{
    box-shadow:none !important;
  }
}


@media(max-width:700px){
  .login{
    max-width:none !important;
    width:100% !important;
    margin:24px 0 0 !important;
  }

  .container{
    padding:14px !important;
  }

  .card{
    padding:18px !important;
  }

  .header{
    margin-bottom:16px !important;
  }

  .grid{
    grid-template-columns:1fr !important;
  }

  .stats-grid{
    margin-bottom:14px !important;
  }

  h3{
    margin-bottom:12px;
  }
}

@media(max-width:420px){
  .login{
    margin-top:14px !important;
  }

  input, select, button, .btn{
    min-height:48px !important;
  }
}

