:root{
  --bg:#0E141B;
  --panel:#131B24;
  --card:#1A2430;
  --card2:#202C3A;
  --text:#E6EDF3;
  --muted:#9FB0C0;
  --accent:#4FA3D1;
  --good:#5FB3A2;
  --warn:#E0B15A;
  --bad:#D96C6C;
  --border:rgba(230,237,243,0.10);
  --shadow: 0 10px 30px rgba(0,0,0,0.35);
  --radius:14px;
  --radius2:18px;
  --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(1200px 700px at 20% 0%, rgba(79,163,209,0.14), transparent 60%),
              radial-gradient(1000px 600px at 95% 10%, rgba(95,179,162,0.10), transparent 55%),
              var(--bg);
}

a{color:var(--accent); text-decoration:none;}
a:hover{text-decoration:underline;}
button, input, select, textarea{
  font: inherit;
}

.container{
  max-width: 1100px;
  margin: 0 auto;
  padding: 18px 14px 88px;
}

.topbar{
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(12px);
  background: linear-gradient(to bottom, rgba(14,20,27,0.92), rgba(14,20,27,0.66));
  border-bottom: 1px solid var(--border);
}

.topbar-inner{
  max-width: 1100px;
  margin: 0 auto;
  display:flex;
  gap:12px;
  align-items:center;
  padding: 12px 14px;
}

.brand{
  display:flex;
  align-items:center;
  gap:10px;
  font-weight: 700;
  letter-spacing: 0.2px;
}
.brand .logo{
  width:34px;height:34px;
  border-radius: 12px;
  display:grid;
  place-items:center;
  background: rgba(19,27,36,0.9);
  border: 1px solid var(--border);
}
.brand .logo svg{width:24px;height:24px;}

.pills{
  margin-left:auto;
  display:flex;
  gap:8px;
  flex-wrap:wrap;
}
.pill{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding: 8px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(19,27,36,0.65);
  color: var(--muted);
  cursor:pointer;
  user-select:none;
}
.pill.active{
  background: rgba(79,163,209,0.14);
  border-color: rgba(79,163,209,0.35);
  color: var(--text);
}
.pill .dot{
  width:8px;height:8px;border-radius:99px;background: var(--accent);
  opacity:0.85;
}
.pill .dot.good{background: var(--good);}
.pill .dot.warn{background: var(--warn);}
.pill .dot.bad{background: var(--bad);}

.grid{
  display:grid;
  grid-template-columns: 1fr;
  gap: 14px;
}
@media(min-width:920px){
  .grid.cols-2{
    grid-template-columns: 1.2fr 0.8fr;
  }
  .grid.cols-3{
    grid-template-columns: 1fr 1fr 1fr;
  }
}

.card{
  background: linear-gradient(180deg, rgba(26,36,48,0.95), rgba(19,27,36,0.92));
  border: 1px solid var(--border);
  border-radius: var(--radius2);
  box-shadow: var(--shadow);
  overflow:hidden;
}
.card .hd{
  padding: 14px 14px 10px;
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:12px;
  border-bottom: 1px solid var(--border);
  background: rgba(19,27,36,0.55);
}
.card .hd h2{
  margin:0;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.2px;
}
.card .hd small{
  color: var(--muted);
  font-size: 12px;
}
.card .bd{
  padding: 14px;
}

.kpis{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
}
.kpi{
  flex:1;
  min-width: 150px;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: rgba(32,44,58,0.45);
}
.kpi .label{color:var(--muted); font-size:12px;}
.kpi .value{font-size:18px; font-weight:800; margin-top:6px;}
.kpi .value.good{color:var(--good);}
.kpi .value.bad{color:var(--bad);}

.toolbar{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
  align-items:center;
}
.btn{
  border: 1px solid var(--border);
  background: rgba(32,44,58,0.55);
  color: var(--text);
  padding: 10px 12px;
  border-radius: 12px;
  cursor:pointer;
}
.btn.primary{
  background: rgba(79,163,209,0.20);
  border-color: rgba(79,163,209,0.45);
}
.btn.ghost{
  background: transparent;
}
.btn:active{transform: translateY(1px);}
.btn small{color: var(--muted);}

.field{
  display:flex;
  flex-direction:column;
  gap:6px;
  margin-bottom: 10px;
}
.field label{
  color: var(--muted);
  font-size: 12px;
}
.field input, .field select, .field textarea{
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: rgba(14,20,27,0.65);
  color: var(--text);
  outline:none;
}
.field textarea{min-height: 92px; resize: vertical;}

.table{
  width:100%;
  border-collapse: collapse;
}
.table th, .table td{
  text-align:left;
  padding: 10px 10px;
  border-bottom: 1px solid rgba(230,237,243,0.08);
  font-size: 13px;
}
.table th{color: var(--muted); font-weight: 600;}
.badge{
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(32,44,58,0.45);
  font-size: 12px;
  color: var(--muted);
}
.badge.buy{color: var(--good); border-color: rgba(95,179,162,0.35); background: rgba(95,179,162,0.08);}
.badge.sell{color: var(--bad); border-color: rgba(217,108,108,0.35); background: rgba(217,108,108,0.08);}

.footer-nav{
  position: fixed;
  left: 0; right: 0; bottom: 0;
  background: rgba(14,20,27,0.86);
  border-top: 1px solid var(--border);
  backdrop-filter: blur(12px);
  padding: 10px 8px;
  z-index: 40;
}
.footer-nav .inner{
  max-width: 1100px;
  margin: 0 auto;
  display:flex;
  justify-content:space-between;
  gap: 8px;
}
.navbtn{
  flex:1;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:6px;
  padding: 10px 8px;
  border-radius: 14px;
  border: 1px solid transparent;
  color: var(--muted);
  user-select:none;
  cursor:pointer;
}
.navbtn.active{
  color: var(--text);
  border-color: rgba(79,163,209,0.35);
  background: rgba(79,163,209,0.10);
}
.navbtn span{font-size: 12px;}
.navbtn svg{width:20px;height:20px; opacity:0.95;}

.split{
  display:grid;
  grid-template-columns: 1fr;
  gap:14px;
}
@media(min-width:920px){
  .split{grid-template-columns: 1.25fr 0.75fr;}
}

.note{
  border:1px solid var(--border);
  background: rgba(32,44,58,0.42);
  border-radius: 14px;
  padding: 10px 12px;
  margin-bottom: 10px;
}
.note .meta{
  display:flex; justify-content:space-between; gap:10px; align-items:center;
  margin-bottom: 8px;
}
.note .meta .title{font-weight: 700; font-size: 13px;}
.note .meta .tags{color: var(--muted); font-size: 12px;}
.note .content{white-space: pre-wrap; color: var(--text); font-size: 13px;}
.note .actions{display:flex; gap:8px; margin-top:10px; flex-wrap:wrap;}
.mono{font-family: var(--mono);}

.toast{
  position: fixed;
  left: 50%;
  bottom: 90px;
  transform: translateX(-50%);
  background: rgba(19,27,36,0.92);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 10px 12px;
  border-radius: 14px;
  box-shadow: var(--shadow);
  z-index: 999;
  display:none;
}


.good{color: var(--good);} 
.bad{color: var(--bad);} 
.table tr:hover{background: rgba(79,163,209,0.06);} 
