:root {
  --bg: #0b0a17; --bg2: #121027; --panel: #17142f; --panel2: #1e1a3d; --line: #2a2550;
  --text: #ecebff; --muted: #9a97c0; --brand: #8b5cf6; --brand2: #22d3ee;
  --ok: #22c55e; --warn: #f59e0b; --bad: #ef4444; --discord: #5865f2;
  --radius: 14px; --shadow: 0 10px 30px rgba(0,0,0,.35);
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font: 15px/1.55 Inter, system-ui, -apple-system, Segoe UI, Roboto, sans-serif; }
a { color: inherit; text-decoration: none; }
a:hover { color: #fff; }
img { max-width: 100%; }
h1, h2, h3 { line-height: 1.2; margin: 0 0 .5em; }
code, .mono { font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: .85em; }
.wrap { max-width: 1240px; margin: 0 auto; padding: 0 16px; }
.narrow { max-width: 760px; }
.muted { color: var(--muted); }
.small { font-size: .85rem; }
.ok-text { color: var(--ok); } .bad-text { color: var(--bad); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.nowrap { white-space: nowrap; }

/* topo */
.topbar { position: sticky; top: 0; z-index: 20; background: rgba(11,10,23,.85); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.topbar-in { display: flex; align-items: center; justify-content: space-between; height: 62px; gap: 12px; }
.logo { display: flex; align-items: center; gap: 8px; font-weight: 800; font-size: 1.15rem; letter-spacing: -.02em; }
.logo b { background: linear-gradient(90deg, var(--brand), var(--brand2)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.nav { display: flex; align-items: center; gap: 18px; font-weight: 500; color: var(--muted); }
.nav a:hover { color: #fff; }

/* botões */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; border: 0; cursor: pointer; font: inherit; font-weight: 600;
  background: linear-gradient(135deg, var(--brand), #6d28d9); color: #fff; padding: 10px 16px; border-radius: 10px; transition: transform .1s, filter .15s; }
.btn:hover { filter: brightness(1.12); color: #fff; }
.btn:active { transform: translateY(1px); }
.btn-sm { padding: 6px 12px; font-size: .88rem; }
.btn-lg { padding: 13px 22px; font-size: 1rem; }
.btn-ghost { background: var(--panel2); border: 1px solid var(--line); }
.btn-discord { background: var(--discord); }
.inline { display: inline; }

/* hero */
.hero { padding: 48px 0 28px; background: radial-gradient(900px 300px at 15% -10%, rgba(139,92,246,.28), transparent), radial-gradient(700px 260px at 90% 0, rgba(34,211,238,.15), transparent); }
.hero h1 { font-size: clamp(1.8rem, 4.5vw, 3rem); font-weight: 800; letter-spacing: -.03em; max-width: 820px; }
.grad { background: linear-gradient(90deg, var(--brand), var(--brand2)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.lead { font-size: 1.1rem; color: var(--muted); max-width: 680px; }
.eyebrow { color: var(--muted); font-size: .9rem; margin: 0 0 8px; }
.eyebrow a:hover { text-decoration: underline; }
.kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin: 24px 0 10px; max-width: 820px; }
.kpi { background: rgba(23,20,47,.8); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; }
.kpi b { display: block; font-size: 1.6rem; font-weight: 800; letter-spacing: -.02em; }
.kpi span { color: var(--muted); font-size: .85rem; }
.live { display: flex; align-items: center; gap: 8px; }
.pulse { width: 8px; height: 8px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 0 rgba(34,197,94,.7); animation: pulse 2s infinite; }
@keyframes pulse { 70% { box-shadow: 0 0 0 8px rgba(34,197,94,0); } 100% { box-shadow: 0 0 0 0 rgba(34,197,94,0); } }

/* categorias e filtros */
.cats { display: flex; gap: 8px; overflow-x: auto; padding: 4px 0 14px; scrollbar-width: thin; }
.cat { flex: none; background: var(--panel); border: 1px solid var(--line); padding: 8px 14px; border-radius: 999px; font-weight: 500; white-space: nowrap; }
.cat small { color: var(--muted); margin-left: 4px; }
.cat.active, .cat:hover { border-color: var(--brand); background: rgba(139,92,246,.15); }
.filters { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 14px; }
.filters .search { flex: 1 1 260px; }
input, select { font: inherit; color: var(--text); background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; min-width: 0; }
input:focus, select:focus { outline: 2px solid var(--brand); outline-offset: 1px; }
.toggle { display: flex; align-items: center; gap: 6px; color: var(--muted); cursor: pointer; }
.toggle input { width: 16px; height: 16px; accent-color: var(--brand); }
.tabs { display: flex; gap: 4px; align-items: center; border-bottom: 1px solid var(--line); margin-bottom: 18px; overflow-x: auto; }
.tab { padding: 10px 14px; color: var(--muted); font-weight: 600; border-bottom: 2px solid transparent; white-space: nowrap; }
.tab.active { color: #fff; border-color: var(--brand); }
.tabs-count { margin-left: auto; white-space: nowrap; padding-left: 10px; }

/* cards */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; margin-bottom: 28px; }
.card { display: flex; flex-direction: column; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; transition: transform .15s, border-color .15s, box-shadow .15s; }
.card:hover { transform: translateY(-3px); border-color: rgba(139,92,246,.6); box-shadow: var(--shadow); }
.card-banner { position: relative; aspect-ratio: 1260 / 500; background: linear-gradient(135deg, hsl(var(--h) 70% 35%), hsl(calc(var(--h) + 60) 70% 22%)); overflow: hidden; }
.card-banner img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 1; }
.card-initial { position: absolute; inset: 0; display: grid; place-items: center; font-size: 3rem; font-weight: 800; color: rgba(255,255,255,.25); }
.rank { position: absolute; z-index: 2; left: 10px; top: 10px; background: rgba(0,0,0,.65); padding: 2px 9px; border-radius: 8px; font-weight: 800; font-size: .85rem; }
.rank-1 { background: linear-gradient(135deg, #facc15, #f59e0b); color: #1a1300; }
.rank-2 { background: linear-gradient(135deg, #e5e7eb, #9ca3af); color: #111; }
.rank-3 { background: linear-gradient(135deg, #fdba74, #c2410c); color: #1a0a00; }
.status { position: absolute; z-index: 2; right: 10px; top: 10px; display: flex; align-items: center; gap: 6px; background: rgba(0,0,0,.65); padding: 3px 10px; border-radius: 999px; font-size: .78rem; font-weight: 600; }
.status i, .status-big i { width: 8px; height: 8px; border-radius: 50%; background: var(--muted); }
.status-ok i { background: var(--ok); box-shadow: 0 0 8px var(--ok); }
.status-warn i { background: var(--warn); }
.status-bad i { background: var(--bad); }
.card-body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.card-title { display: flex; align-items: center; gap: 8px; }
.card-title h3 { font-size: 1.05rem; margin: 0; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.favicon { width: 22px; height: 22px; border-radius: 5px; flex: none; }
.flag { font-size: 1rem; }
.card-desc { margin: 0; color: var(--muted); font-size: .88rem; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 2.6em; }
.card-meta { display: flex; gap: 6px; flex-wrap: wrap; }
.chip { font-size: .75rem; background: var(--panel2); border: 1px solid var(--line); padding: 2px 8px; border-radius: 999px; color: var(--muted); }
.chip-beta { color: #fde68a; border-color: #78350f; }
.chip-dev { color: #a5f3fc; border-color: #155e75; }
.card-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin-top: auto; padding-top: 10px; border-top: 1px solid var(--line); }
.card-stats div { text-align: center; }
.card-stats b { display: block; font-size: 1.05rem; }
.card-stats small { color: var(--muted); font-size: .72rem; }

.rating { white-space: nowrap; }
.r-top { color: #facc15; } .r-good { color: #4ade80; } .r-ok { color: #93c5fd; } .r-low, .r-none { color: var(--muted); }
.rating-box { display: flex; gap: 14px; align-items: center; margin-bottom: 14px; }
.rating-box p { margin: 4px 0 0; }
.rating-big { font-size: 2rem; font-weight: 800; white-space: nowrap; }
.rating-big small { font-size: .9rem; color: var(--muted); font-weight: 600; }
.rating-parts { display: grid; gap: 8px; margin-bottom: 20px; }
.rp { display: grid; grid-template-columns: 1fr 90px 34px; gap: 10px; align-items: center; font-size: .85rem; }
.rp .bar { height: 8px; background: var(--panel2); border-radius: 99px; overflow: hidden; }
.rp .bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--brand), var(--brand2)); }
.rp b { text-align: right; }
@media (max-width: 640px) { .rp { grid-template-columns: 1fr 60px 30px; } }
.empty { text-align: center; padding: 60px 16px; background: var(--panel); border: 1px dashed var(--line); border-radius: var(--radius); }
.empty a { color: var(--brand2); }
.pager { display: flex; justify-content: center; align-items: center; gap: 16px; margin: 0 0 40px; }

/* detalhe */
.detail-hero { position: relative; overflow: hidden; padding: 40px 0 30px; background: linear-gradient(135deg, hsl(var(--h) 60% 20%), var(--bg)); border-bottom: 1px solid var(--line); }
.detail-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .22; filter: blur(2px); }
.detail-hero-in { position: relative; }
.detail-title { display: flex; gap: 16px; align-items: center; margin-bottom: 18px; }
.detail-title h1 { font-size: clamp(1.6rem, 4vw, 2.4rem); margin: 0; }
.detail-title p { margin: 4px 0 0; }
.favicon-lg { width: 64px; height: 64px; border-radius: 14px; background: var(--panel); flex: none; }
.detail-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.flash { margin: 14px 0 0; padding: 10px 14px; border-radius: 10px; background: var(--panel2); border: 1px solid var(--line); }
.flash.ok { border-color: var(--ok); }
.detail-grid { display: grid; grid-template-columns: 1fr 1.4fr; gap: 16px; padding-top: 24px; padding-bottom: 24px; }
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; min-width: 0; }
.panel h3 { font-size: .95rem; color: var(--muted); margin-top: 20px; }
.status-big { display: inline-flex; align-items: center; gap: 10px; font-size: 1.4rem; font-weight: 800; margin-bottom: 10px; }
.status-big i { width: 14px; height: 14px; }
.facts { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 10px 0 0; }
.facts div { background: var(--panel2); border-radius: 10px; padding: 10px 12px; }
.facts dt { color: var(--muted); font-size: .78rem; }
.facts dd { margin: 2px 0 0; font-weight: 700; }
.uptime-bars { display: grid; grid-template-columns: repeat(24, 1fr); gap: 3px; height: 34px; }
.uptime-bars span { border-radius: 3px; background: var(--line); }
.uptime-bars .ok { background: var(--ok); } .uptime-bars .warn { background: var(--warn); } .uptime-bars .bad { background: var(--bad); }
.uptime-legend { display: flex; justify-content: space-between; margin-top: 4px; }
.chart { width: 100%; height: 120px; display: block; background: var(--panel2); border-radius: 10px; }
.chart-line { fill: none; stroke: var(--brand2); stroke-width: 2; vector-effect: non-scaling-stroke; }
.chart-area { fill: rgba(34,211,238,.12); }
.address { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin: 4px 0 6px; }
.address code { background: var(--panel2); border: 1px solid var(--line); padding: 6px 10px; border-radius: 8px; font-size: .95rem; }
.loader-link { text-decoration: underline dotted; }
.loader-link:hover { color: var(--text); }
.motd { background: var(--panel2); border-radius: 10px; padding: 10px 12px; margin-top: 12px; font-size: .9rem; }
.chart-tabs { margin: 18px 0 4px; }
.embed code.inline-code { display: inline; padding: 2px 6px; }
.embed { margin-top: 20px; }
.embed summary, .report summary { cursor: pointer; }
.embed code { display: block; margin-top: 8px; padding: 10px; background: var(--panel2); border-radius: 8px; overflow-x: auto; white-space: nowrap; }
.report { margin-top: 14px; }
.report input { width: 100%; margin: 8px 0; }
.section-title { margin-top: 10px; }

/* páginas */
.page { padding-top: 40px; padding-bottom: 40px; }
.suggest { display: flex; gap: 10px; flex-wrap: wrap; margin: 20px 0; }
.suggest input[type=url] { flex: 1 1 280px; padding: 13px 14px; }
.checklist li { margin: 6px 0; }
.steps { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; margin: 20px 0; }
.step { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; }
.step p { margin: 6px 0 0; color: var(--muted); }
.table { width: 100%; border-collapse: collapse; margin-bottom: 24px; display: block; overflow-x: auto; }
.table td { padding: 8px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
.inline-form { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 10px; }

/* rodapé */
.footer { border-top: 1px solid var(--line); margin-top: 40px; padding: 30px 0 24px; background: var(--bg2); }
.footer-in { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 24px; margin-bottom: 16px; }
.footer-links { display: flex; flex-direction: column; gap: 6px; color: var(--muted); }
.footer-links strong { color: var(--text); }

@media (max-width: 860px) {
  .detail-grid { grid-template-columns: 1fr; }
  .footer-in { grid-template-columns: 1fr 1fr; }
  .footer-in > div:first-child { grid-column: 1 / -1; }
}
@media (max-width: 640px) {
  .nav a:not(.btn) { display: none; }
  .kpis { grid-template-columns: repeat(2, 1fr); }
  .kpi b { font-size: 1.3rem; }
  .hero { padding-top: 30px; }
  .steps { grid-template-columns: 1fr; }
  .facts { grid-template-columns: 1fr; }
  .grid { grid-template-columns: 1fr; }
}
