:root{
  --bg:#0b0f17;
  --card:#0f1624;
  --text:#e8eefc;
  --muted:#9fb0d0;
  --line:rgba(255,255,255,.08);
  --accent:#5aa7ff;
  --accent2:#7c5cff;
  --danger:#ff5a7a;
  --ok:#47d18c;
  --shadow: 0 10px 40px rgba(0,0,0,.45);
  --radius: 14px;
  --radius2: 18px;
  --font: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial;
}

*{box-sizing:border-box}
html,body{height:100%}
body{
  margin:0;
  font-family:var(--font);
  color:var(--text);
  background:
    radial-gradient(1200px 600px at 20% -10%, rgba(90,167,255,.25), transparent 60%),
    radial-gradient(900px 500px at 110% 10%, rgba(124,92,255,.18), transparent 55%),
    radial-gradient(800px 600px at 40% 120%, rgba(71,209,140,.10), transparent 60%),
    var(--bg);
}

a{color:inherit}
code{color:rgba(232,238,252,.9)}

.container{
  width: min(1180px, 100%);
  margin: 0 auto;
}

.form{display:flex;flex-direction:column;gap:10px}
.label{font-size:12px;color:var(--muted);margin-top:6px}

.input{
  width:100%;
  padding:12px 12px;
  border-radius: 12px;
  border:1px solid var(--line);
  outline:none;
  background: rgba(0,0,0,.25);
  color:var(--text);
}
.input:focus{border-color: rgba(90,167,255,.55); box-shadow: 0 0 0 4px rgba(90,167,255,.12);}

.btn{
  width:100%;
  padding:12px 14px;
  border-radius: 12px;
  border:1px solid rgba(90,167,255,.35);
  background: linear-gradient(135deg, rgba(90,167,255,.95), rgba(124,92,255,.90));
  color: #081022;
  font-weight:800;
  cursor:pointer;
}
.btn:hover{filter:brightness(1.03)}
.btn:disabled{opacity:.5; cursor:not-allowed}

.btn.ghost{
  width:auto;
  background: rgba(0,0,0,.25);
  color: var(--text);
  border:1px solid var(--line);
}

.msg{
  min-height:18px;
  font-size:12px;
  margin-top:6px;
  color: var(--danger);
}
.msg.ok{color:var(--ok)}

.footnote{
  margin-top:14px;
  font-size:12px;
  color: var(--muted);
  text-align:center;
}

.topbar{
  position:sticky; top:0;
  display:flex;
  justify-content:space-between;
  align-items:center;
  padding:14px 18px;
  border-bottom:1px solid var(--line);
  backdrop-filter: blur(10px);
  background: rgba(11,15,23,.55);
}
.topbar-left{display:flex; align-items:center; gap:10px}
.topbar-title{font-weight:800; letter-spacing:.2px}
.topbar-right{display:flex; gap:10px; align-items:center}

.logo{
  width:44px; height:44px;
  border-radius:14px;
  display:flex;
  align-items:center;
  justify-content:center;
  font-weight:800;
  background: linear-gradient(135deg, rgba(90,167,255,.9), rgba(124,92,255,.9));
  box-shadow: 0 10px 25px rgba(90,167,255,.15);
}
.logo.sm{width:32px;height:32px;border-radius:12px;font-weight:800}

.chip{
  padding:8px 10px;
  border-radius: 999px;
  border:1px solid var(--line);
  background: rgba(0,0,0,.25);
  color: var(--muted);
  font-size:12px;
}

.page{padding:18px}

.grid{
  display:grid;
  grid-template-columns: 1fr 1fr;
  gap:14px;
  align-items:start;
}
@media (max-width: 980px){
  .grid{grid-template-columns: 1fr}
}

.panel{
  background: rgba(255,255,255,.04);
  border:1px solid var(--line);
  border-radius: var(--radius);
  padding:16px;
  box-shadow: 0 10px 30px rgba(0,0,0,.25);
}
.panel-title{font-weight:800;margin-bottom:10px}

.hint{color:var(--muted);font-size:13px;line-height:1.5}

.kvs{display:flex; flex-direction:column; gap:8px}
.kv{display:flex; justify-content:space-between; gap:10px}
.k{color:var(--muted); font-size:13px}
.v{font-weight:800}

.row2{
  display:grid;
  grid-template-columns: 1fr 1fr;
  gap:10px;
}
@media (max-width: 520px){
  .row2{grid-template-columns:1fr}
}

.list{display:flex;flex-direction:column;gap:10px}
.item{
  width:100%;
  text-align:left;
  padding:12px;
  border-radius: 12px;
  border:1px solid var(--line);
  background: rgba(0,0,0,.20);
  color: var(--text);
  cursor:pointer;
}
.item:hover{border-color: rgba(90,167,255,.35)}
.item-title{font-weight:800}
.item-sub{margin-top:4px;color:var(--muted);font-size:12px}

.split{
  display:grid;
  grid-template-columns: 1fr 1fr;
  gap:12px;
  align-items:start;
}
@media (max-width: 980px){
  .split{grid-template-columns:1fr}
}

.subpanel{
  background: rgba(0,0,0,.18);
  border:1px solid var(--line);
  border-radius: 12px;
  padding:12px;
}

.thumbs{
  margin-top:10px;
  display:grid;
  grid-template-columns: repeat(4, 1fr);
  gap:10px;
}
@media (max-width: 980px){
  .thumbs{grid-template-columns: repeat(3, 1fr)}
}
@media (max-width: 520px){
  .thumbs{grid-template-columns: repeat(2, 1fr)}
}

.thumb{
  display:block;
  border:1px solid var(--line);
  border-radius: 12px;
  overflow:hidden;
  background: rgba(0,0,0,.25);
}
.thumb img{
  width:100%;
  height:92px;
  object-fit:cover;
  display:block;
}
