:root{
  --bg: #0b0f17;
  --panel: rgba(255,255,255,.06);
  --panel2: rgba(255,255,255,.09);
  --text: rgba(255,255,255,.92);
  --muted: rgba(255,255,255,.66);
  --border: rgba(255,255,255,.12);
  --brand: #7c5cff;
  --brand2:#28d7ff;
  --good:#3ddc97;
  --warn:#ffcc66;
  --bad:#ff6b6b;
  --shadow: 0 10px 30px rgba(0,0,0,.35);
  --radius: 18px;
  --radius2: 24px;
  --mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  --sans: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial;
}

[data-theme="light"]{
  --bg: #f6f7fb;
  --panel: rgba(0,0,0,.04);
  --panel2: rgba(0,0,0,.06);
  --text: rgba(0,0,0,.88);
  --muted: rgba(0,0,0,.60);
  --border: rgba(0,0,0,.12);
  --shadow: 0 10px 25px rgba(0,0,0,.10);
}

*{box-sizing:border-box}
html,body{height:100%}
body{
  margin:0;
  background: radial-gradient(1200px 700px at 20% -10%, rgba(124,92,255,.35), transparent 55%),
              radial-gradient(900px 600px at 95% 10%, rgba(40,215,255,.25), transparent 55%),
              var(--bg);
  color:var(--text);
  font-family:var(--sans);
}

a{color:inherit; text-decoration:none}
button{font-family:inherit}

.topbar{
  position:sticky; top:0; z-index:50;
  display:flex; align-items:center; justify-content:space-between;
  padding:14px 18px;
  border-bottom: 1px solid var(--border);
  background: linear-gradient(to bottom, rgba(0,0,0,.28), rgba(0,0,0,.10));
  backdrop-filter: blur(14px);
}

.brand{display:flex; align-items:center; gap:12px; cursor:pointer}
.logo{
  width:40px; height:40px; border-radius:14px;
  display:grid; place-items:center;
  background: linear-gradient(135deg, var(--brand), var(--brand2));
  color:white; font-weight:900;
  box-shadow: var(--shadow);
}
.brandName{font-weight:900; letter-spacing:.4px}
.brandSub{font-size:12px; color:var(--muted)}

.nav{display:flex; gap:10px; align-items:center}
.navLink{
  padding:10px 12px;
  border-radius:12px;
  border:1px solid transparent;
  color:var(--muted);
}
.navLink:hover{border-color:var(--border); color:var(--text); background:var(--panel)}

.userBox{display:flex; gap:10px}
.btn{
  border:1px solid var(--border);
  background: var(--panel);
  color: var(--text);
  padding:10px 12px;
  border-radius:14px;
  cursor:pointer;
  transition: transform .08s ease, background .2s ease;
}
.btn:hover{background:var(--panel2)}
.btn:active{transform: translateY(1px)}
.btn.primary{
  border-color: rgba(124,92,255,.45);
  background: linear-gradient(135deg, rgba(124,92,255,.25), rgba(40,215,255,.12));
}
.btn.ghost{
  background: transparent;
}
.btn.small{padding:8px 10px; border-radius:12px; font-size:13px}
.btn.danger{border-color: rgba(255,107,107,.45);}

.shell{
  max-width: 1180px;
  margin: 0 auto;
  padding: 18px;
}

.footer{
  border-top:1px solid var(--border);
  padding:18px;
  color:var(--muted);
}
.footerInner{
  max-width:1180px;
  margin:0 auto;
  display:flex;
  gap:10px;
  flex-wrap:wrap;
  justify-content:space-between;
}

.app{min-height:70vh}

.hero{
  border:1px solid var(--border);
  background: linear-gradient(135deg, rgba(124,92,255,.20), rgba(40,215,255,.10));
  border-radius: var(--radius2);
  padding: 18px;
  box-shadow: var(--shadow);
  overflow:hidden;
}
.heroGrid{
  display:grid;
  grid-template-columns: 1.3fr .7fr;
  gap:16px;
  align-items:stretch;
}
@media (max-width: 920px){
  .heroGrid{grid-template-columns:1fr}
}
.hTitle{font-size:34px; font-weight:950; letter-spacing:-.6px; margin:0}
.hLead{color:var(--muted); margin-top:8px; line-height:1.45}
.heroBadges{display:flex; gap:10px; flex-wrap:wrap; margin-top:14px}
.badge{
  border:1px solid var(--border);
  background: rgba(255,255,255,.04);
  padding:7px 10px;
  border-radius:999px;
  color:var(--muted);
  font-size:13px;
}

.panel{
  border:1px solid var(--border);
  background: var(--panel);
  border-radius: var(--radius2);
  padding: 16px;
  box-shadow: var(--shadow);
}
.panelTitle{margin:0 0 10px 0; font-weight:900}
.muted{color:var(--muted)}
.hr{height:1px; background:var(--border); margin:14px 0}

.controls{
  margin-top:14px;
  display:grid;
  grid-template-columns: 1.2fr .5fr .5fr .35fr;
  gap:10px;
}
@media (max-width: 920px){
  .controls{grid-template-columns:1fr 1fr}
}
.input, .select, .textarea{
  width:100%;
  border:1px solid var(--border);
  background: rgba(255,255,255,.04);
  color:var(--text);
  padding:12px 12px;
  border-radius: 14px;
  outline:none;
}
.textarea{min-height: 110px; resize: vertical}
.input:focus, .select:focus, .textarea:focus{
  border-color: rgba(124,92,255,.55);
  box-shadow: 0 0 0 4px rgba(124,92,255,.12);
}

.grid{
  margin-top:14px;
  display:grid;
  grid-template-columns: repeat(3, 1fr);
  gap:12px;
}
@media (max-width: 1000px){
  .grid{grid-template-columns: repeat(2, 1fr)}
}
@media (max-width: 640px){
  .grid{grid-template-columns: 1fr}
}

.card{
  border:1px solid var(--border);
  background: rgba(255,255,255,.05);
  border-radius: var(--radius2);
  padding: 14px;
  display:flex;
  flex-direction:column;
  gap:10px;
  transition: transform .10s ease, background .2s ease, border-color .2s ease;
  cursor:pointer;
}
.card:hover{
  transform: translateY(-2px);
  background: rgba(255,255,255,.07);
  border-color: rgba(124,92,255,.28);
}
.cardTop{display:flex; align-items:flex-start; justify-content:space-between; gap:10px}
.cardName{font-weight:950; margin:0; letter-spacing:-.2px}
.cardDesc{margin:0; color:var(--muted); line-height:1.35; font-size:14px}
.pills{display:flex; flex-wrap:wrap; gap:8px}
.pill{
  font-size:12px;
  border:1px solid var(--border);
  padding:6px 10px;
  border-radius:999px;
  color:var(--muted);
  background: rgba(255,255,255,.03);
}
.kpiRow{display:flex; gap:12px; flex-wrap:wrap; margin-top:4px}
.kpi{font-size:12px; color:var(--muted)}
.kpi b{color:var(--text)}

.cardActions{display:flex; gap:10px; margin-top:auto; flex-wrap:wrap}
.starBtn{
  display:inline-flex; align-items:center; gap:6px;
  border:1px solid var(--border);
  background: transparent;
  padding:8px 10px;
  border-radius: 14px;
  cursor:pointer;
  color:var(--muted);
}
.starBtn.active{border-color: rgba(255,204,102,.55); color: var(--text)}
.star{font-family: var(--mono);}

.breadcrumbs{display:flex; gap:8px; flex-wrap:wrap; color:var(--muted); margin-bottom:12px}
.breadcrumbs a{color:var(--muted)}
.breadcrumbs a:hover{color:var(--text)}

.split{
  display:grid;
  grid-template-columns: 1.25fr .75fr;
  gap:12px;
}
@media (max-width: 920px){
  .split{grid-template-columns:1fr}
}

.endpoint{
  border:1px solid var(--border);
  background: rgba(255,255,255,.04);
  border-radius: 16px;
  padding: 12px;
  display:flex;
  flex-direction:column;
  gap:8px;
}
.epHead{display:flex; align-items:center; justify-content:space-between; gap:10px}
.method{
  font-family: var(--mono);
  font-size:12px;
  padding:6px 10px;
  border-radius:999px;
  border:1px solid var(--border);
  background: rgba(255,255,255,.03);
}
.path{font-family: var(--mono); font-size:13px; color: var(--text)}
.tryRow{display:flex; gap:10px; flex-wrap:wrap}
.code{
  font-family: var(--mono);
  font-size:12px;
  color: var(--muted);
  white-space: pre-wrap;
  word-break: break-word;
}
.resultBox{
  border:1px dashed var(--border);
  border-radius: 16px;
  padding: 12px;
  background: rgba(0,0,0,.10);
  min-height: 110px;
}

.priceGrid{
  display:grid;
  grid-template-columns: repeat(3, 1fr);
  gap:10px;
}
@media (max-width: 920px){
  .priceGrid{grid-template-columns:1fr}
}
.plan{
  border:1px solid var(--border);
  background: rgba(255,255,255,.04);
  border-radius: 18px;
  padding: 14px;
  display:flex;
  flex-direction:column;
  gap:8px;
}
.plan h4{margin:0; font-weight:950}
.planPrice{font-size:26px; font-weight:950}
.plan ul{margin:0; padding-left:18px; color:var(--muted)}
.planBest{border-color: rgba(124,92,255,.40); background: rgba(124,92,255,.10)}

.table{
  width:100%;
  border-collapse: collapse;
  overflow:hidden;
  border-radius: 16px;
  border:1px solid var(--border);
}
.table th, .table td{
  padding:10px 10px;
  border-bottom:1px solid var(--border);
  text-align:left;
  font-size:14px;
}
.table th{color:var(--muted); font-weight:800; background: rgba(255,255,255,.03)}
.table tr:last-child td{border-bottom:none}

.toastHost{
  position: fixed;
  top: 70px;
  right: 18px;
  display:flex;
  flex-direction:column;
  gap:10px;
  z-index: 100;
}
.toast{
  border:1px solid var(--border);
  background: rgba(0,0,0,.35);
  backdrop-filter: blur(10px);
  border-radius: 16px;
  padding: 10px 12px;
  min-width: 240px;
  box-shadow: var(--shadow);
}
.toast .tTitle{font-weight:900}
.toast .tBody{color:var(--muted); margin-top:4px; font-size:13px}