:root{
  --bg:#070c16;
  --panel:#0c152a;
  --text:#e7eefc;
  --muted:#a6b1cc;
  --border:#1c2a48;
  --accent:#7aa2ff;
  --card:#0d1a33;
  --shadow: 0 10px 40px rgba(0,0,0,.35);
}

:root.light{
  --bg:#f5f7fb;
  --panel:#ffffff;
  --text:#0b1220;
  --muted:#5b647a;
  --border:#e3e6ef;
  --accent:#2b59ff;
  --card:#ffffff;
  --shadow: 0 10px 40px rgba(0,0,0,.12);
}

*{box-sizing:border-box}
html,body{height:100%}

body{
  margin:0;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, "Noto Sans Myanmar", sans-serif;
  background:
    radial-gradient(900px 420px at 20% 0%, rgba(122,162,255,.10), transparent 60%),
    radial-gradient(900px 520px at 80% 10%, rgba(122,162,255,.09), transparent 60%),
    var(--bg);
  color:var(--text);
}

a{color:inherit}

/* ---------- topbar ---------- */
.topbar{
  position:sticky;
  top:0;
  z-index:10;
  display:flex;
  justify-content:space-between;
  gap:12px;
  padding:14px 16px;
  border-bottom:1px solid var(--border);
  background: rgba(0,0,0,.22);
  backdrop-filter: blur(14px);
}

.brand{display:flex; align-items:center; gap:12px}
.logo{
  width:42px; height:42px;
  border-radius:14px;
  display:grid; place-items:center;
  background: linear-gradient(135deg, rgba(122,162,255,1), rgba(122,162,255,.4));
  color:white;
  font-weight:900;
  box-shadow: var(--shadow);
}
.title{font-weight:900; letter-spacing:.2px}
.subtitle{font-size:12px; color:var(--muted)}

.actions{display:flex; align-items:center; gap:10px}
.search{
  width:min(440px, 55vw);
  padding:11px 12px;
  border-radius:14px;
  border:1px solid var(--border);
  background: rgba(255,255,255,.02);
  color:var(--text);
  outline:none;
}
.search::placeholder{color:var(--muted)}

.btn{
  padding:10px 12px;
  border-radius:14px;
  border:1px solid var(--border);
  background: rgba(255,255,255,.02);
  color:var(--text);
  cursor:pointer;
}
.iconbtn{width:44px; display:grid; place-items:center}

/* ---------- layout ---------- */
.layout{
  max-width:1120px;
  margin:0 auto;
  padding:16px;
  display:grid;
  grid-template-columns: 280px 1fr;
  gap:16px;
}

.sidebar{
  border:1px solid var(--border);
  background: rgba(255,255,255,.02);
  border-radius:22px;
  padding:14px;
  height: calc(100dvh - 120px);
  position:sticky;
  top:74px;
  overflow:auto;
  box-shadow: var(--shadow);
}

.section-h{
  font-size:12px;
  color:var(--muted);
  text-transform:uppercase;
  letter-spacing:.12em;
  margin-bottom:10px;
}
.mt{margin-top:18px}

/* categories */
.cat-list{display:flex; flex-direction:column; gap:8px}
.cat{
  display:flex; justify-content:space-between; align-items:center;
  padding:10px 12px;
  border-radius:16px;
  border:1px solid var(--border);
  background: rgba(0,0,0,.12);
  cursor:pointer;
  transition: .18s ease;
}
.cat:hover{
  transform: translateY(-1px);
  border-color: rgba(122,162,255,.55);
}
.badge{
  font-size:12px;
  color:var(--muted);
  border:1px solid var(--border);
  padding:2px 8px;
  border-radius:999px;
}

/* links */
.links{display:flex; flex-direction:column; gap:9px}
.links a{
  text-decoration:none;
  color:var(--text);
  padding:8px 10px;
  border-radius:14px;
  border:1px solid transparent;
}
.links a:hover{
  color:var(--accent);
  border-color: rgba(122,162,255,.35);
  background: rgba(122,162,255,.08);
}

/* tip box */
.tipbox{
  border:1px solid rgba(255,190,70,.25);
  background: rgba(255,190,70,.08);
  padding:12px;
  border-radius:18px;
}
.tiptitle{font-weight:850; margin-bottom:6px}
.tiptext{font-size:13px; color:var(--muted); line-height:1.5}

/* content */
.content{
  border:1px solid var(--border);
  background: rgba(255,255,255,.02);
  border-radius:22px;
  padding:14px;
  box-shadow: var(--shadow);
}

.content-head{
  display:flex;
  align-items:baseline;
  justify-content:space-between;
  gap:10px;
  padding:6px 8px 12px;
  border-bottom:1px solid var(--border);
}
.h1{margin:0; font-size:22px; letter-spacing:.2px}
.muted{color:var(--muted)}
.small{font-size:12px}

.cards{
  display:grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap:12px;
  padding:14px 6px 6px;
}

.card{
  border:1px solid var(--border);
  background: rgba(0,0,0,.16);
  border-radius:22px;
  padding:14px;
  cursor:pointer;
  transition: .2s ease;
  position:relative;
  overflow:hidden;
}
.card:before{
  content:"";
  position:absolute;
  inset:-40px -40px auto auto;
  width:120px;
  height:120px;
  border-radius:50%;
  background: rgba(122,162,255,.08);
  filter: blur(2px);
}
.card:hover{
  transform: translateY(-2px);
  border-color: rgba(122,162,255,.6);
}

.card h3{margin:0 0 6px; font-size:16px}
.card p{margin:0; color:var(--muted); font-size:13px; line-height:1.5}

.tagrow{display:flex; gap:8px; margin-top:12px; flex-wrap:wrap}
.tag{
  font-size:12px;
  color:var(--muted);
  border:1px solid var(--border);
  padding:3px 9px;
  border-radius:999px;
}

/* article page */
.article{padding:14px 6px}
.hidden{display:none}
.back{
  display:inline-block;
  margin-bottom:12px;
  color:var(--accent);
  text-decoration:none;
  font-weight:650;
}
.meta{color:var(--muted); font-size:13px; margin-bottom:12px}
.body{line-height:1.8}

.body h3{margin-top:18px}
.body code{
  background:rgba(122,162,255,.14);
  padding:2px 6px;
  border-radius:10px;
}
.body pre{
  overflow:auto;
  padding:12px;
  border-radius:18px;
  border:1px solid var(--border);
  background: rgba(0,0,0,.25);
}

/* tables look nicer */
.body table{
  width:100%;
  border-collapse:collapse;
  margin-top:10px;
  border-radius:16px;
  overflow:hidden;
  display:block;
}
.body th, .body td{
  border:1px solid var(--border);
  padding:10px;
}
.body th{
  background: rgba(122,162,255,.12);
}

/* footer */
.footer{
  max-width:1120px;
  margin:0 auto;
  padding:12px 16px 22px;
  display:flex;
  justify-content:space-between;
  gap:12px;
}

/* ---------- Pretty buttons & blocks for Downloads article ---------- */
.btnrow{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
  margin:12px 0 6px;
}
.kbtn{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:10px 12px;
  border-radius:16px;
  border:1px solid var(--border);
  background: rgba(0,0,0,.14);
  color:var(--text);
  text-decoration:none;
  font-weight:750;
  transition:.18s ease;
}
.kbtn:hover{
  transform: translateY(-1px);
  border-color: rgba(122,162,255,.7);
  background: rgba(122,162,255,.12);
}
.kbtn.primary{
  background: rgba(122,162,255,.18);
  border-color: rgba(122,162,255,.45);
}
.kchip{
  display:inline-block;
  font-size:12px;
  padding:3px 10px;
  border-radius:999px;
  border:1px solid var(--border);
  color: var(--muted);
}
.kblock{
  border:1px solid var(--border);
  background: rgba(0,0,0,.14);
  border-radius:20px;
  padding:12px;
  margin:12px 0;
}
.kgrid{
  display:grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap:12px;
  margin-top:10px;
}

/* responsive */
@media (max-width: 860px){
  .layout{grid-template-columns:1fr}
  .sidebar{
    height:auto;
    position:relative;
    top:auto;
  }
  .cards{grid-template-columns:1fr}
  .search{width:60vw}
  .kgrid{grid-template-columns:1fr;}
}