:root{
  --bg:#0b1220;
  --card:#111a2e;
  --muted:#a9b3c7;
  --text:#eef2ff;
  --line:rgba(255,255,255,.10);
  --btn:#1f2b4a;
  --btn2:#25345c;
  --accent:#89a7ff;
  --ok:#7CFFB2;
  --warn:#ffd67a;
  --shadow: 0 18px 60px rgba(0,0,0,.45);
  --radius: 18px;
  --radius2: 14px;
  --max: 1040px;
  --font: 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(--font);
  background:
    radial-gradient(1200px 700px at 20% 0%, rgba(137,167,255,.20), transparent 60%),
    radial-gradient(900px 600px at 80% 10%, rgba(124,255,178,.12), transparent 55%),
    var(--bg);
  color:var(--text);
  line-height:1.5;
}
a{color:inherit}

/* ========== Safety first: Logo must NEVER become huge ========== */
.site-logo{
  height:44px !important;
  width:auto !important;
  max-width:none !important;
  display:block !important;
  object-fit:contain !important;
}
@media (max-width:768px){
  .site-logo{ height:36px !important; }
}
/* If someone accidentally uses logo-main.png elsewhere */
img[src*="logo-main.png"]{
  max-width:220px !important;
  height:auto !important;
}

/* ========== Layout ========== */
.wrap{max-width:var(--max); margin:0 auto; padding:26px 18px 58px;}
.topbar{
  display:flex; align-items:center; justify-content:space-between;
  padding:8px 2px 18px; gap:16px; flex-wrap:wrap;
}
.brand{display:flex; align-items:center; gap:12px; letter-spacing:.2px}
.brand h1{font-size:14px; margin:0; font-weight:800}
.brand small{display:block; color:var(--muted); font-weight:550; margin-top:2px}

.nav{display:flex; gap:10px; flex-wrap:wrap; align-items:center;}
.nav a{
  text-decoration:none;
  border:1px solid var(--line);
  background: rgba(255,255,255,.04);
  padding:8px 12px;
  border-radius:999px;
  color:var(--muted);
  font-size:13px;
  font-weight:700;
}
.nav a.active{
  color:var(--text);
  background: rgba(137,167,255,.16);
  border-color: rgba(137,167,255,.26);
}

.pill{
  border:1px solid var(--line);
  background: rgba(255,255,255,.05);
  padding:8px 12px;
  border-radius:999px;
  color:var(--muted);
  font-size:12px;
}

/* ========== Cards / Grids ========== */
.card{
  border:1px solid var(--line);
  background: rgba(17,26,46,.78);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow:hidden;
}
.inner{padding:22px 22px 18px}

.hero{
  display:grid;
  grid-template-columns: 1.2fr .8fr;
  gap:18px;
  align-items:stretch;
}
@media (max-width:900px){ .hero{grid-template-columns:1fr} }

h2{margin:0 0 10px; font-size:34px; line-height:1.12; letter-spacing:-.3px}
@media (max-width:520px){ h2{font-size:28px} }
.lead{color:var(--muted); font-size:15px; margin:0 0 16px; max-width:65ch}

.btnRow{display:flex; gap:10px; flex-wrap:wrap; margin-top:10px}
.btn{
  border:1px solid var(--line);
  background: var(--btn);
  color:var(--text);
  padding:11px 14px;
  border-radius: 14px;
  text-decoration:none;
  font-weight:750;
  font-size:14px;
  display:inline-flex;
  align-items:center;
  gap:8px;
  cursor:pointer;
  transition: transform .05s ease, background .15s ease;
  user-select:none;
}
.btn:hover{background: var(--btn2)}
.btn:active{transform: translateY(1px)}
.btn.primary{
  background: rgba(137,167,255,.22);
  border-color: rgba(137,167,255,.30);
}
.btn.primary:hover{background: rgba(137,167,255,.26)}
.btn.secondary{
  background: rgba(124,255,178,.14);
  border-color: rgba(124,255,178,.22);
}
.btn.secondary:hover{background: rgba(124,255,178,.18)}
.btn.small{padding:9px 12px; font-size:13px}

.section{margin-top:14px}
.section h3{margin:0 0 10px; font-size:16px}
.muted{color:var(--muted)}

.grid2{display:grid; grid-template-columns:1fr 1fr; gap:14px; margin-top:14px;}
@media (max-width:900px){ .grid2{grid-template-columns:1fr;} }

.list{margin:0; padding:0; list-style:none; display:grid; gap:10px}
.li{
  display:flex; gap:10px; align-items:flex-start;
  border:1px solid var(--line);
  background: rgba(255,255,255,.04);
  padding:12px;
  border-radius: var(--radius2);
}
.dot{
  width:10px; height:10px; border-radius:999px; margin-top:6px;
  background: rgba(137,167,255,.85);
  box-shadow: 0 0 0 6px rgba(137,167,255,.14);
  flex: 0 0 auto;
}
.dot.ok{background: rgba(124,255,178,.9); box-shadow: 0 0 0 6px rgba(124,255,178,.12)}
.dot.warn{background: rgba(255,214,122,.95); box-shadow: 0 0 0 6px rgba(255,214,122,.12)}
.li b{display:block; margin-bottom:4px}
.li p{margin:0; color:var(--muted); font-size:13px}

.kpi{display:grid; gap:10px}
.kpi .box{
  border:1px solid var(--line);
  background: rgba(255,255,255,.04);
  padding:12px;
  border-radius: var(--radius2);
}
.kpi .box b{display:block; font-size:12px; color:var(--muted); font-weight:750; margin-bottom:6px}
.kpi .box div{font-size:14px; font-weight:820}
.hint{font-size:12px; color:var(--muted); margin-top:10px}

/* ========== Footer ========== */
.footer{
  margin-top:18px;
  display:flex; flex-wrap:wrap; gap:10px;
  align-items:center; justify-content:space-between;
  color: var(--muted);
  font-size:12px;
  padding: 10px 4px 0;
}
.footer a{color: var(--muted); text-decoration: underline; text-underline-offset: 2px}

/* ========== Modal (router.js uses these) ========== */
.modalBack{
  position:fixed; inset:0;
  background: rgba(0,0,0,.55);
  display:none;
  align-items:center; justify-content:center;
  padding: 18px;
  z-index: 999;
}
.modal{
  width:min(560px, 100%);
  border:1px solid var(--line);
  background: rgba(17,26,46,.95);
  border-radius: 18px;
  box-shadow: var(--shadow);
  overflow:hidden;
}
.modal .head{
  padding:14px 16px;
  border-bottom:1px solid var(--line);
  display:flex; align-items:center; justify-content:space-between;
  gap:10px;
}
.modal .head b{font-size:14px}
.x{
  width:34px; height:34px; border-radius:12px;
  border:1px solid var(--line);
  background: rgba(255,255,255,.04);
  display:flex; align-items:center; justify-content:center;
  cursor:pointer;
}
.modal .body{padding:16px}
.modal .body p{margin:0 0 12px; color:var(--muted); font-size:13px}
.modal .actions{display:flex; gap:10px; flex-wrap:wrap}
.divider{height:1px; background: var(--line); margin: 10px 0 12px}