:root{
  --bg:#0b1020;
  --card:#101a33;
  --muted:#9fb1d1;
  --text:#e9efff;
  --line:rgba(255,255,255,.12);
  --brand:#7aa2ff;
  --danger:#ff5c74;
  --shadow:0 10px 40px rgba(0,0,0,.35);
  --radius:14px;
  --mono:ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  --sans:ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Apple Color Emoji", "Segoe UI Emoji";
}
*{box-sizing:border-box}
html,body{height:100%}
body{
  margin:0;
  font-family:var(--sans);
  color:var(--text);
  background:radial-gradient(800px 400px at 20% 0%, rgba(122,162,255,.25), transparent 60%),
             radial-gradient(700px 500px at 80% 10%, rgba(255,92,116,.18), transparent 55%),
             var(--bg);
}
.top{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  padding:18px 18px 10px;
  max-width:980px;
  margin:0 auto;
}
.brand{display:flex; align-items:center; gap:12px; min-width:0}
.logo{
  width:40px; height:40px;
  border-radius:12px;
  display:grid; place-items:center;
  background:rgba(122,162,255,.18);
  border:1px solid var(--line);
  font-weight:800;
}
.name{font-weight:800; letter-spacing:.2px}
.tag{color:var(--muted); font-size:13px; margin-top:2px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; max-width:680px}
.actions{display:flex; gap:10px; flex-wrap:wrap; justify-content:flex-end}

.wrap{max-width:980px; margin:0 auto; padding:10px 18px 28px}
.card{
  background:linear-gradient(180deg, rgba(255,255,255,.03), rgba(255,255,255,.01));
  border:1px solid var(--line);
  border-radius:var(--radius);
  box-shadow:var(--shadow);
  padding:16px;
}
.grid{
  display:grid;
  grid-template-columns:1fr;
  gap:12px;
}
.field{display:flex; flex-direction:column; gap:8px}
.field > span{font-size:13px; color:var(--muted)}
textarea{
  width:100%;
  resize:vertical;
  min-height:46px;
  background:rgba(0,0,0,.18);
  border:1px solid var(--line);
  border-radius:12px;
  padding:10px 12px;
  color:var(--text);
  outline:none;
  font-family:var(--mono);
  font-size:13px;
  line-height:1.45;
}
textarea:focus{border-color:rgba(122,162,255,.5); box-shadow:0 0 0 3px rgba(122,162,255,.12)}
.meta{display:flex; justify-content:flex-end; color:var(--muted); font-size:12px}

.opts{
  display:grid;
  grid-template-columns:1fr;
  gap:10px;
  padding:12px;
  border:1px dashed rgba(255,255,255,.16);
  border-radius:12px;
}
.rad{display:flex; flex-wrap:wrap; gap:10px; align-items:center}
.lbl{color:var(--muted); font-size:13px; margin-right:8px}
.chk{display:inline-flex; gap:8px; align-items:center; font-size:13px; color:var(--text)}
.chk input{accent-color:var(--brand)}

.rowBtns{display:flex; gap:10px; flex-wrap:wrap}
.btn{
  border:1px solid var(--line);
  background:rgba(122,162,255,.18);
  color:var(--text);
  border-radius:12px;
  padding:10px 12px;
  cursor:pointer;
  font-weight:700;
}
.btn:hover{filter:brightness(1.08)}
.btn.ghost{background:rgba(255,255,255,.04)}
.btn.danger{background:rgba(255,92,116,.18)}
.btn:disabled{opacity:.55; cursor:not-allowed}

.errors{margin-top:10px; color:#ffd1d8; font-size:13px}
.hint{margin:10px 2px 0; color:var(--muted); font-size:13px; line-height:1.5}

@media (min-width: 860px){
  .grid{grid-template-columns:1fr 1fr}
  .field:nth-child(3){grid-column:1 / -1}
  .opts{grid-column:1 / -1; grid-template-columns:1fr 1fr}
  .rowBtns{grid-column:1 / -1}
}
