:root{
  --bg:#0b1020;
  --panel:#0f1730;
  --panel2:#111c3a;
  --text:#e7ecff;
  --muted:#aab4da;
  --line:#22305d;
  --brand:#7aa2ff;
  --ok:#1fd18c;
  --bad:#ff5a75;
  --shadow: 0 10px 35px rgba(0,0,0,.35);
}
*{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";
  background: radial-gradient(1200px 600px at 30% 0%, rgba(122,162,255,.18), transparent 55%),
              radial-gradient(900px 500px at 85% 15%, rgba(31,209,140,.12), transparent 60%),
              var(--bg);
  color:var(--text);
  overflow-x:hidden;
}
a{color:inherit;text-decoration:none}
code,pre{font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace}
.container{
  max-width:1050px;
  width:100%;
  margin:0 auto;
  padding:0 16px;
}
.topbar{position:sticky; top:0; backdrop-filter: blur(10px); background: rgba(11,16,32,.72); border-bottom:1px solid rgba(34,48,93,.6); z-index:10}
.topbar__inner{display:flex; align-items:center; justify-content:space-between; padding:14px 0; gap:10px; flex-wrap:wrap}
.brand{font-weight:800; letter-spacing:.3px}
.brand:hover{color:var(--brand)}
.nav a{color:var(--muted)}
.nav a:hover{color:var(--text)}
.nav__sep{display:inline-block; width:10px}
.nav__logout{
  display:inline-block;
  margin:0;
}
.nav__logoutBtn{
  border-radius:999px;
  border:1px solid rgba(34,48,93,.7);
  background:rgba(17,28,58,.0);
  color:var(--muted);
  padding:6px 12px;
  font-size:13px;
  cursor:pointer;
}
.nav__logoutBtn:hover{
  border-color:rgba(255,90,117,.6);
  color:var(--bad);
  background:rgba(255,90,117,.08);
}
.langbtn{padding:6px 10px; border-radius:999px; border:1px solid rgba(34,48,93,.7); background: rgba(17,28,58,.25)}
.langbtn:hover{border-color: rgba(122,162,255,.55)}
.footer{margin-top:60px; border-top:1px solid rgba(34,48,93,.6); background: rgba(11,16,32,.55)}
.footer__inner{padding:18px 0; color:var(--muted); font-size:14px}
.muted{color:var(--muted)}
.small{font-size:13px}
.spacer{height:18px}
.hero{display:grid; grid-template-columns: 1.15fr .85fr; gap:22px; padding:28px 0 10px; align-items:flex-start}
.hero h1{font-size:clamp(28px, 5vw, 42px); line-height:1.1; margin:0 0 10px}
.actions{margin-top:14px}
.btn{
  display:inline-flex; align-items:center; justify-content:center;
  height:40px; padding:0 14px; border-radius:12px;
  border:1px solid rgba(34,48,93,.8);
  background: linear-gradient(180deg, rgba(17,28,58,.95), rgba(15,23,48,.95));
  color:var(--text); box-shadow: var(--shadow);
}
.btn:hover{border-color: rgba(122,162,255,.65); transform: translateY(-1px)}
.btn--ghost{background:transparent; box-shadow:none}
.btn--danger{background: rgba(255,90,117,.12); border-color: rgba(255,90,117,.35); box-shadow:none}
.btn--danger:hover{border-color: rgba(255,90,117,.7)}
.link{color:var(--brand)}
.link:hover{text-decoration:underline}
.card{
  border:1px solid rgba(34,48,93,.9);
  background: linear-gradient(180deg, rgba(17,28,58,.65), rgba(15,23,48,.65));
  border-radius:16px; box-shadow: var(--shadow);
}
.status{
  position:relative;
  aspect-ratio:1/1;
  width:100%;
  max-width:420px;
}
.status .card__body{
  height:calc(100% - 52px);
  overflow:auto;
}

/* Responsive tweaks */
@media (max-width: 900px){
  .topbar__inner{
    flex-direction:column;
    align-items:flex-start;
  }
  .brand{
    font-size:18px;
  }
  .nav{
    font-size:14px;
  }

  .hero{
    grid-template-columns:1fr;
    gap:18px;
  }
  .hero__left{
    order:1;
  }
  .status{
    order:2;
    max-width:420px;
    margin-inline:auto;
  }
}
.card__header{display:flex; align-items:flex-start; justify-content:space-between; padding:14px 14px 0}
.card__title{font-weight:700}
.card__body{padding:12px 14px 14px}
.topiccard .card__body{padding:14px}
.pill{
  font-size:12px; padding:6px 10px; border-radius:999px;
  border:1px solid rgba(34,48,93,.8);
  background: rgba(17,28,58,.75);
}
.pill--ok{border-color: rgba(31,209,140,.55); color: rgba(31,209,140,.95)}
.pill--bad{border-color: rgba(255,90,117,.55); color: rgba(255,90,117,.95)}
.kv{display:grid; grid-template-columns: 110px 1fr; gap:8px 12px; margin-bottom:10px}
.kv__k{color:var(--muted); font-size:13px}
.motd pre{
  margin:10px 0 0; padding:10px 12px;
  border-radius:12px; background: rgba(11,16,32,.7);
  border:1px solid rgba(34,48,93,.6);
  color: var(--text);
  overflow:auto;
  max-height: 96px;
  font-size: 12px;
  line-height: 1.35;
}
.section{padding:18px 0}
.section__header{display:flex; align-items:flex-end; justify-content:space-between; gap:14px; margin-bottom:12px; flex-wrap:wrap}
.list{display:flex; flex-direction:column; gap:10px}
.list__item{
  display:block; padding:12px 14px; border-radius:14px;
  border:1px solid rgba(34,48,93,.75);
  background: rgba(17,28,58,.28);
}
.list__item:hover{border-color: rgba(122,162,255,.55); background: rgba(17,28,58,.42)}
.list__title{font-weight:700}
.list__item--row{display:flex; align-items:center; justify-content:space-between; gap:12px}
.pagehead{padding:22px 0 12px}
.pagehead h1{margin:0 0 6px; font-size:clamp(26px, 4.4vw, 34px)}
.empty{padding:48px 18px; text-align:center; border:1px dashed rgba(34,48,93,.75); border-radius:18px; background: rgba(17,28,58,.18)}
.empty__title{font-weight:900; font-size:32px; margin-bottom:6px}
.post{padding:24px 0}
.post__title{margin:8px 0 16px; font-size:clamp(26px, 5vw, 40px); line-height:1.15}
.post__content{
  border:1px solid rgba(34,48,93,.7);
  background: rgba(17,28,58,.22);
  border-radius:16px;
  padding:18px 18px;
}
.post__content img,
.post__content video,
.post__content iframe{
  max-width:100%;
  height:auto;
  display:block;
  margin:10px auto;
}
.post__content h1,.post__content h2{margin:18px 0 8px}
.post__content p{line-height:1.7; color: rgba(231,236,255,.95)}
.post__content a{color: var(--brand)}
.post__content pre{
  padding:12px 14px; border-radius:12px;
  background: rgba(11,16,32,.75);
  border:1px solid rgba(34,48,93,.6);
  overflow:auto;
}
.comments{
  margin-top:16px;
}
.form{display:flex; flex-direction:column; gap:14px; max-width:900px}
.field{display:flex; flex-direction:column; gap:7px}
.field label{color:var(--muted); font-size:13px}
.editor{
  border-radius:14px;
  border:1px solid rgba(34,48,93,.85);
  background: rgba(11,16,32,.7);
  overflow:hidden;
}
.editor__toolbar{
  display:flex;
  align-items:center;
  gap:4px;
  padding:6px 8px;
  border-bottom:1px solid rgba(34,48,93,.9);
  background:rgba(9,14,28,.9);
}
.editor__toolbar button{
  border-radius:8px;
  border:1px solid rgba(34,48,93,.8);
  background:rgba(15,23,48,.9);
  color:var(--muted);
  font-size:11px;
  padding:3px 7px;
  cursor:pointer;
}
.editor__toolbar button:hover{
  border-color:rgba(122,162,255,.7);
  color:var(--text);
}
.editor__sep{
  width:1px;
  height:18px;
  background:rgba(34,48,93,.8);
}
.editor textarea{
  border:none;
  border-radius:0;
  background:transparent;
}
input,textarea{
  width:100%;
  border-radius:12px;
  border:1px solid rgba(34,48,93,.85);
  background: rgba(11,16,32,.7);
  color: var(--text);
  padding:10px 12px;
  outline:none;
}
textarea{resize:vertical}
input:focus,textarea:focus{border-color: rgba(122,162,255,.65)}
.row{display:flex; align-items:center; gap:10px; flex-wrap:wrap}
.row--spread{justify-content:space-between}
.checkbox{display:flex; align-items:center; gap:10px; user-select:none}
.checkbox input{width:auto}

.table{
  width:100%;
  display:flex;
  flex-direction:column;
  gap:6px;
  font-size:13px;
}
.table__head{
  font-weight:600;
  border-bottom:1px solid rgba(34,48,93,.8);
  padding-bottom:6px;
}
.table__row{
  border-bottom:1px solid rgba(34,48,93,.35);
  padding:4px 0;
}
.table__cell{
  flex:1 1 0;
  padding-right:8px;
  word-break:break-all;
}
.table__cell--wide{
  flex:2 1 0;
}

.uploadfile{
  display:flex;
  align-items:center;
  gap:10px;
}
.uploadfile__thumb{
  width:46px;
  height:46px;
  border-radius:10px;
  overflow:hidden;
  border:1px solid rgba(34,48,93,.8);
  background:rgba(11,16,32,.8);
  display:flex;
  align-items:center;
  justify-content:center;
}
.uploadfile__thumb img,
.uploadfile__thumb video{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}
.uploadfile__meta{
  min-width:0;
}
.uploadfile__name{
  font-weight:500;
  white-space:normal;
  overflow-wrap:anywhere;
  word-break:break-word;
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  overflow:hidden;
}
.filebadge{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  padding:4px 6px;
  border-radius:6px;
  background:rgba(122,162,255,.16);
  border:1px solid rgba(122,162,255,.45);
  font-size:10px;
  letter-spacing:.4px;
}

@media (max-width: 700px){
  .table__head{
    display:none;
  }
  .table__row{
    flex-direction:column;
    align-items:flex-start;
  }
  .table__cell{
    padding-right:0;
  }
}

@media (max-width: 600px){
  .container{
    padding:0 20px;
  }
}

.terminal{
  border:1px solid rgba(34,48,93,.85);
  border-radius:14px;
  overflow:hidden;
  background: rgba(11,16,32,.85);
  box-shadow: var(--shadow);
}
.terminal__bar{
  display:flex;
  align-items:center;
  gap:8px;
  padding:10px 12px;
  border-bottom:1px solid rgba(34,48,93,.85);
  background: rgba(9,14,28,.95);
}
.terminal__dot{
  width:10px;
  height:10px;
  border-radius:50%;
  display:inline-block;
}
.terminal__dot--red{background: rgba(255,90,117,.85)}
.terminal__dot--yellow{background: rgba(255,210,90,.85)}
.terminal__dot--green{background: rgba(31,209,140,.85)}
.terminal__title{
  margin-left:6px;
  font-size:12px;
  color: var(--muted);
}
.terminal__body{
  margin:0;
  padding:12px 14px;
  font-size:12px;
  line-height:1.45;
  color: rgba(231,236,255,.95);
  max-height: 70vh;
  overflow:auto;
  overflow-wrap: anywhere;
}
.terminal__log{
  display:flex;
  flex-direction:column;
  gap:6px;
  margin-bottom:12px;
}
.mc-line{
  white-space: pre-wrap;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
}
.mc-line--cmd{
  color: var(--brand);
}
.mc-line--err{
  color: rgba(255,90,117,.95);
}
.mc-line--meta{
  color: var(--muted);
  font-size:11px;
}
