/* AegisFlow — landing autossuficiente (sem CDNs). */
:root {
  --bg: #0f172a;
  --panel: #1e293b;
  --panel-solid: #131c31;
  --border: #334155;
  --border-soft: rgba(255, 255, 255, 0.08);
  --text: #f8fafc;
  --muted: #94a3b8;
  --muted-2: #64748b;
  --brand: #14b8a6;
  --brand-400: #2dd4bf;
  --brand-300: #5eead4;
  --blue: #3b82f6;
  --purple: #a855f7;
  --green: #34d399;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background-color: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 0.9em; color: var(--brand-300); }

.container { max-width: 1152px; margin: 0 auto; padding: 0 1.5rem; }

/* Decoration blobs */
.bg-blobs { position: fixed; inset: 0; z-index: -1; overflow: hidden; pointer-events: none; }
.blob { position: absolute; width: 24rem; height: 24rem; border-radius: 9999px; filter: blur(128px); opacity: 0.18; }
.blob.b1 { top: -8%; left: -8%; background: var(--brand); }
.blob.b2 { top: 18%; right: -8%; background: var(--blue); }
.blob.b3 { bottom: -12%; left: 18%; background: var(--purple); }

/* Glass */
.glass {
  background: rgba(30, 41, 59, 0.7);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--border-soft);
}

/* Text helpers */
.grad-text {
  background-image: linear-gradient(to right, var(--brand-400), var(--blue));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.brand { color: var(--brand-400); }
.muted { color: var(--muted); }
.center { text-align: center; }

/* Nav */
.nav {
  position: fixed; top: 0; left: 0; width: 100%; z-index: 50;
  border-bottom: 1px solid var(--border);
}
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 5rem; }
.logo { display: flex; align-items: center; gap: 0.5rem; font-weight: 700; font-size: 1.25rem; }
.logo .mark { color: var(--brand-400); font-size: 1.6rem; line-height: 1; }
.nav-links { display: flex; gap: 2rem; font-size: 0.9rem; color: var(--muted); }
.nav-links a:hover { color: var(--brand-400); }
.nav-cta { display: flex; align-items: center; gap: 1rem; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  padding: 0.7rem 1.25rem; border-radius: 0.6rem; font-weight: 600; font-size: 0.9rem;
  cursor: pointer; transition: all 0.2s; border: 1px solid transparent;
}
.btn-lg { padding: 1rem 2rem; font-size: 1.05rem; border-radius: 0.75rem; }
.btn-primary { background: var(--brand); color: #fff; box-shadow: 0 10px 25px -5px rgba(20, 184, 166, 0.3); }
.btn-primary:hover { background: var(--brand-600, #0d9488); }
.btn-ghost { border: 1px solid var(--border); color: #fff; }
.btn-ghost:hover { background: var(--panel); }
.btn-outline { width: 100%; border: 1px solid #475569; color: #fff; background: transparent; }
.btn-outline:hover { background: var(--panel); }
.link-quiet { font-size: 0.9rem; color: var(--muted); }
.link-quiet:hover { color: #fff; }

/* Sections */
section { position: relative; }
.section { padding: 5rem 0; border-top: 1px solid var(--border); }
.section-alt { background: rgba(30, 41, 59, 0.35); }
.section-head { text-align: center; max-width: 42rem; margin: 0 auto 3.5rem; }
.section-head h2 { font-size: clamp(1.8rem, 3vw, 2.25rem); font-weight: 700; margin-bottom: 0.75rem; }
.section-head p { color: var(--muted); }

/* Hero */
.hero { padding: 9rem 0 5rem; text-align: center; }
.badge {
  display: inline-flex; align-items: center; gap: 0.5rem; padding: 0.3rem 0.85rem;
  border-radius: 9999px; font-size: 0.72rem; font-weight: 600; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--brand-400); margin-bottom: 2rem;
}
.dot { width: 0.5rem; height: 0.5rem; border-radius: 9999px; background: var(--brand); box-shadow: 0 0 0 4px rgba(20,184,166,0.25); }
.hero h1 { font-size: clamp(2.6rem, 6vw, 4.5rem); font-weight: 700; line-height: 1.05; letter-spacing: -0.02em; margin-bottom: 1.5rem; }
.hero .sub { font-size: clamp(1.05rem, 2vw, 1.25rem); color: var(--muted); max-width: 48rem; margin: 0 auto 1rem; }
.hero .sub strong { color: var(--text); }
.hero .tags { font-size: 0.85rem; color: var(--muted-2); margin-bottom: 2.5rem; }
.hero-actions { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }

/* Mockup */
.mockup { margin: 5rem auto 0; max-width: 64rem; border-radius: 1rem; border: 1px solid var(--border); padding: 2rem; box-shadow: 0 25px 50px -12px rgba(0,0,0,0.5); }
.mockup-bar { display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--border); padding-bottom: 1rem; margin-bottom: 1.5rem; }
.traffic { display: flex; gap: 0.5rem; }
.traffic span { width: 0.75rem; height: 0.75rem; border-radius: 9999px; }
.traffic .r { background: #ef4444; } .traffic .y { background: #eab308; } .traffic .g { background: #22c55e; }
.mockup-status { display: flex; gap: 1rem; font-size: 0.8rem; color: var(--muted); font-family: ui-monospace, monospace; }
.text-green { color: var(--green); }
.text-mono-mut { color: var(--muted-2); font-size: 0.72rem; }

/* ---------- Documentação ---------- */
.doc-shell { display: grid; grid-template-columns: 240px 1fr; gap: 2.5rem; align-items: start; padding-top: 7rem; }
.doc-nav { position: sticky; top: 6rem; align-self: start; border: 1px solid var(--border); border-radius: 0.9rem; padding: 1rem; font-size: 0.9rem; }
.doc-nav a { display: block; color: var(--muted); padding: 0.35rem 0.5rem; border-radius: 0.4rem; }
.doc-nav a:hover { color: #fff; background: var(--panel); }
.doc-nav .grp { color: var(--muted-2); font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.05em; margin: 0.9rem 0 0.3rem; }
.doc-content { min-width: 0; max-width: 760px; }
.doc-content h1 { font-size: 2rem; font-weight: 700; margin-bottom: 0.5rem; }
.doc-content h3 { font-size: 1rem; font-weight: 600; margin: 1.25rem 0 0.5rem; color: #e2e8f0; }
.doc-content p, .doc-content li { color: var(--muted); line-height: 1.7; }
.doc-content ul { margin: 0.5rem 0 0.5rem 1.2rem; }
.doc-content strong { color: #e2e8f0; }
.doc-lead { font-size: 1.05rem; color: var(--muted); margin-bottom: 1.5rem; }

/* cada serviço em um card */
.doc-card { border: 1px solid var(--border); border-radius: 1rem; padding: 1.6rem 1.75rem; margin-bottom: 1.25rem; scroll-margin-top: 6rem; }
.doc-card > h2 { display: flex; align-items: center; gap: 0.6rem; font-size: 1.3rem; font-weight: 700; margin: 0 0 0.5rem; }
.doc-card > h2 .num { display: inline-flex; align-items: center; justify-content: center; width: 1.6rem; height: 1.6rem; border-radius: 0.5rem; background: rgba(20,184,166,0.15); color: var(--brand-400); font-size: 0.8rem; font-weight: 700; flex: 0 0 auto; }
.doc-card > h2 .doc-tag { margin-left: auto; }
.doc-card p:first-of-type { margin-top: 0.25rem; }

.doc-pre { background: #0b1220; border: 1px solid var(--border); border-radius: 0.6rem; padding: 1rem 1.1rem; overflow-x: auto; margin: 0.9rem 0 0.3rem; }
.doc-pre code { color: #cbd5e1; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 0.82rem; line-height: 1.6; white-space: pre; }
.doc-endpoint { display: flex; width: fit-content; max-width: 100%; align-items: center; gap: 0.5rem; font-family: ui-monospace, monospace; font-size: 0.85rem; background: #0b1220; border: 1px solid var(--border); border-radius: 0.5rem; padding: 0.4rem 0.75rem; margin: 0.5rem 0; color: #cbd5e1; }
.doc-method { font-weight: 700; font-size: 0.72rem; padding: 0.1rem 0.45rem; border-radius: 0.3rem; }
.doc-method.get { background: rgba(20,184,166,0.15); color: var(--brand-300); }
.doc-method.post { background: rgba(59,130,246,0.15); color: #93c5fd; }
.doc-method.patch, .doc-method.delete { background: rgba(234,179,8,0.15); color: #fde047; }
.doc-note { border-left: 3px solid var(--brand); background: rgba(20,184,166,0.08); border-radius: 0 0.5rem 0.5rem 0; padding: 0.8rem 1rem; margin: 1rem 0; font-size: 0.9rem; color: #cbd5e1; }
.doc-tag { display: inline-block; font-size: 0.7rem; padding: 0.15rem 0.5rem; border-radius: 9999px; background: var(--panel); border: 1px solid var(--border); color: var(--muted); margin-left: 0.5rem; }
@media (max-width: 860px) { .doc-shell { grid-template-columns: 1fr; } .doc-nav { display: none; } }

/* Hub de roteamento (hero) — layout horizontal */
.hub-flow { display: flex; align-items: stretch; gap: 0.85rem; font-family: ui-monospace, monospace; font-size: 0.8rem; }
.hub-req { flex: 1 1 0; min-width: 0; background: #0b1220; border: 1px solid var(--border); border-radius: 0.6rem; padding: 1rem 1.1rem; display: flex; flex-direction: column; justify-content: center; }
.hub-req .lbl { color: var(--muted-2); margin-bottom: 0.4rem; }
.hub-req .meta { display: flex; justify-content: space-between; gap: 0.5rem; margin-top: 0.7rem; font-size: 0.72rem; }
.hub-arrow { align-self: center; color: var(--brand-400); font-size: 1.6rem; line-height: 1; flex: 0 0 auto; }
.hub-core { flex: 0 0 auto; align-self: center; display: flex; align-items: center; gap: 0.6rem; max-width: 220px; background: linear-gradient(135deg, rgba(19,78,74,0.5), rgba(30,58,138,0.4)); border: 1px solid rgba(45,212,191,0.4); border-radius: 0.75rem; padding: 0.85rem 1rem; box-shadow: 0 0 24px rgba(20,184,166,0.15); }
.hub-core .spin { color: var(--brand-400); font-size: 1.3rem; }
.hub-core .t { font-weight: 700; }
.hub-core .s { color: var(--muted-2); font-size: 0.68rem; margin-top: 0.15rem; }
.hub-fan { flex: 0 0 auto; display: flex; flex-direction: column; justify-content: space-around; color: var(--brand-400); font-size: 1.3rem; padding: 0.2rem 0; }
.hub-targets { flex: 0 0 auto; width: 250px; display: flex; flex-direction: column; gap: 0.6rem; }
.target { background: #0b1220; border: 1px solid var(--border); border-radius: 0.6rem; padding: 0.7rem 0.85rem; opacity: 0.72; }
.target .name { font-weight: 700; display: flex; align-items: center; gap: 0.4rem; }
.target .model { color: var(--muted-2); font-size: 0.7rem; margin-top: 0.2rem; }
.target .tagline { font-size: 0.7rem; margin-top: 0.35rem; color: var(--muted); }
.target.chosen { opacity: 1; border-color: var(--brand); box-shadow: 0 0 0 1px var(--brand) inset, 0 10px 30px -10px rgba(20,184,166,0.4); }
.target.chosen .tagline { color: var(--brand-300); font-weight: 600; }

@media (max-width: 860px) {
  .hub-flow { flex-direction: column; }
  .hub-arrow, .hub-fan { transform: rotate(90deg); align-self: center; }
  .hub-fan { flex-direction: row; gap: 2.5rem; }
  .hub-core { max-width: none; align-self: stretch; justify-content: center; }
  .hub-targets { width: auto; }
}

/* Feature grid */
.grid { display: grid; gap: 2rem; }
.grid-features { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.card { padding: 2rem; border-radius: 1rem; border: 1px solid var(--border); transition: transform 0.3s, border-color 0.3s; }
.card:hover { transform: translateY(-0.5rem); border-color: rgba(20,184,166,0.5); }
.card .icon { width: 3.5rem; height: 3.5rem; border-radius: 0.75rem; background: var(--panel); display: flex; align-items: center; justify-content: center; font-size: 1.6rem; margin-bottom: 1.5rem; }
.card h3 { font-size: 1.25rem; font-weight: 700; margin-bottom: 0.75rem; }
.card p { color: var(--muted); font-size: 0.9rem; }
.card p strong { color: #e2e8f0; }

/* Brazil grid */
.grid-brasil { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.mini { padding: 1.5rem; border-radius: 1rem; border: 1px solid var(--border); text-align: center; }
.mini .icon { font-size: 1.9rem; margin-bottom: 0.75rem; }
.mini h4 { font-weight: 700; margin-bottom: 0.25rem; }
.mini p { font-size: 0.85rem; color: var(--muted); }

/* How it works */
.how { display: flex; gap: 4rem; align-items: center; flex-wrap: wrap; }
.how > div { flex: 1 1 360px; min-width: 300px; }
.how h2 { font-size: clamp(1.8rem, 3vw, 2.25rem); font-weight: 700; margin-bottom: 1.5rem; }
.how .lead { color: var(--muted); margin-bottom: 2rem; }
.steps { display: flex; flex-direction: column; gap: 1.5rem; }
.step { display: flex; gap: 1rem; }
.step .num { width: 2.5rem; height: 2.5rem; border-radius: 9999px; background: var(--panel); border: 1px solid var(--border); display: flex; align-items: center; justify-content: center; font-weight: 700; color: var(--brand-400); flex-shrink: 0; }
.step h4 { margin-bottom: 0.2rem; }
.step p { font-size: 0.9rem; color: var(--muted-2); }
.code { border-radius: 0.75rem; padding: 1.5rem; border: 1px solid var(--border); box-shadow: 0 25px 50px -12px rgba(0,0,0,0.5); }
.code-bar { display: flex; justify-content: space-between; margin-bottom: 1rem; font-size: 0.75rem; color: var(--muted); font-family: ui-monospace, monospace; }
.code pre { overflow-x: auto; font-family: ui-monospace, monospace; font-size: 0.85rem; color: #cbd5e1; }
.tok-kw { color: var(--purple); } .tok-str { color: #fde047; } .tok-key { color: var(--green); } .tok-com { color: var(--muted-2); }

/* Simulator */
.sim-wrap { max-width: 56rem; margin: 0 auto; }
.sim-card { border: 1px solid var(--border); border-radius: 1.5rem; padding: 3rem; box-shadow: 0 25px 50px -12px rgba(0,0,0,0.5); }
.sim-top { margin-bottom: 2.5rem; }
.sim-label-row { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 1rem; }
.sim-label-row label { font-size: 0.9rem; color: #cbd5e1; }
.sim-value { font-size: 1.5rem; font-weight: 700; }
.sim-scale { display: flex; justify-content: space-between; margin-top: 0.5rem; font-size: 0.72rem; color: var(--muted-2); font-family: ui-monospace, monospace; }
.sim-results { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 2rem; border-top: 1px solid var(--border); padding-top: 2rem; }
.res { border-radius: 1rem; padding: 1.5rem; border: 1px solid var(--border); background: rgba(15,23,42,0.5); }
.res h4 { font-size: 0.85rem; color: var(--muted); font-weight: 500; margin-bottom: 0.35rem; }
.res .big { font-size: 1.9rem; font-weight: 700; }
.res ul { list-style: none; margin-top: 1rem; display: flex; flex-direction: column; gap: 0.5rem; font-size: 0.85rem; color: var(--muted); }
.res ul li::before { content: "✓ "; color: var(--brand-400); font-weight: 700; }
.res.highlight { background: linear-gradient(135deg, rgba(19,78,74,0.4), rgba(30,58,138,0.4)); border-color: rgba(20,184,166,0.3); position: relative; overflow: hidden; }
.res.highlight h4 { color: var(--brand-300); }
.res.highlight .big { font-size: 2.75rem; }
.res.highlight .note { margin-top: 1rem; font-size: 0.72rem; color: #cbd5e1; }

input[type=range] { -webkit-appearance: none; appearance: none; width: 100%; background: transparent; }
input[type=range]::-webkit-slider-runnable-track { height: 8px; background: var(--border); border-radius: 4px; }
input[type=range]::-moz-range-track { height: 8px; background: var(--border); border-radius: 4px; }
input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; height: 24px; width: 24px; margin-top: -8px; border-radius: 50%; background: var(--brand-400); cursor: pointer; box-shadow: 0 0 15px rgba(45,212,191,0.5); }
input[type=range]::-moz-range-thumb { height: 24px; width: 24px; border: none; border-radius: 50%; background: var(--brand-400); cursor: pointer; box-shadow: 0 0 15px rgba(45,212,191,0.5); }

/* Pricing */
.grid-pricing { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); max-width: 64rem; margin: 0 auto; align-items: stretch; }
.plan { padding: 2rem; border-radius: 1rem; border: 1px solid var(--border); display: flex; flex-direction: column; }
.plan.featured { border: 2px solid var(--brand); box-shadow: 0 25px 50px -12px rgba(19,78,74,0.5); position: relative; }
.plan .tag { position: absolute; top: 0; left: 50%; transform: translate(-50%, -50%); background: var(--brand); color: #fff; padding: 0.25rem 0.75rem; border-radius: 9999px; font-size: 0.7rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; }
.plan h3 { font-size: 1.25rem; font-weight: 700; margin-bottom: 0.5rem; }
.plan .desc { font-size: 0.85rem; color: var(--muted); margin-bottom: 1.5rem; }
.plan .price { margin-bottom: 1.5rem; }
.plan .price .amt { font-size: 2.25rem; font-weight: 700; }
.plan .price .per { color: var(--muted); font-size: 0.85rem; }
.plan ul { list-style: none; display: flex; flex-direction: column; gap: 1rem; font-size: 0.9rem; color: #cbd5e1; margin-bottom: 2rem; flex-grow: 1; }
.plan ul li::before { content: "✓ "; color: var(--brand-400); font-weight: 700; }

/* CTA final */
.cta { text-align: center; }
.cta h2 { font-size: clamp(1.8rem, 3vw, 2.25rem); font-weight: 700; margin-bottom: 0.75rem; }
.cta p { color: var(--muted); max-width: 40rem; margin: 0 auto 2rem; }

/* Footer */
.footer { border-top: 1px solid var(--border); background: var(--bg); padding: 3rem 0; }
.footer-top { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 1rem; }
.footer-links { display: flex; gap: 1.5rem; font-size: 0.9rem; color: var(--muted-2); }
.footer-links a:hover { color: var(--brand-400); }
.footer .copy { margin-top: 2rem; text-align: center; font-size: 0.75rem; color: #475569; }

@media (max-width: 820px) {
  .nav-links { display: none; }
  .hero { padding: 7rem 0 3rem; }
}

/* ---------- Auth (login) ---------- */
.auth-wrap { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 2rem 1.5rem; }
.auth-card { width: 100%; max-width: 26rem; border: 1px solid var(--border); border-radius: 1.25rem; padding: 2.5rem; box-shadow: 0 25px 50px -12px rgba(0,0,0,0.5); }
.auth-logo { display: flex; align-items: center; justify-content: center; gap: 0.5rem; font-weight: 700; font-size: 1.4rem; margin-bottom: 0.5rem; }
.auth-logo .mark { color: var(--brand-400); font-size: 1.7rem; }
.auth-sub { text-align: center; color: var(--muted); font-size: 0.9rem; margin-bottom: 2rem; }
.field { margin-bottom: 1rem; }
.field label { display: block; font-size: 0.8rem; color: var(--muted); margin-bottom: 0.4rem; }
.input {
  width: 100%; padding: 0.75rem 0.9rem; border-radius: 0.6rem; background: #0b1220;
  border: 1px solid var(--border); color: var(--text); font-size: 0.95rem; outline: none;
}
.input:focus { border-color: var(--brand); box-shadow: 0 0 0 3px rgba(20,184,166,0.15); }
.btn-block { width: 100%; }
.auth-alt { text-align: center; margin-top: 1.25rem; font-size: 0.85rem; color: var(--muted); }
.auth-alt a, .link-btn { color: var(--brand-400); cursor: pointer; background: none; border: none; font-size: inherit; }
.auth-alt a:hover, .link-btn:hover { text-decoration: underline; }
.divider { display: flex; align-items: center; gap: 0.75rem; margin: 1.25rem 0; color: var(--muted-2); font-size: 0.75rem; }
.divider::before, .divider::after { content: ""; flex: 1; height: 1px; background: var(--border); }
.msg { padding: 0.75rem 0.9rem; border-radius: 0.6rem; font-size: 0.85rem; margin-bottom: 1rem; display: none; }
.msg.show { display: block; }
.msg.error { background: rgba(239,68,68,0.12); border: 1px solid rgba(239,68,68,0.4); color: #fca5a5; }
.msg.ok { background: rgba(20,184,166,0.12); border: 1px solid rgba(20,184,166,0.4); color: var(--brand-300); }
.msg.warn { background: rgba(234,179,8,0.12); border: 1px solid rgba(234,179,8,0.4); color: #fde047; }
.back-home { position: fixed; top: 1.25rem; left: 1.5rem; font-size: 0.85rem; color: var(--muted); }
.back-home:hover { color: #fff; }

/* ---------- Dashboard ---------- */
.dash-nav { position: sticky; top: 0; z-index: 40; border-bottom: 1px solid var(--border); }
.dash-main { padding: 2.5rem 0 4rem; }
.dash-head { display: flex; justify-content: space-between; align-items: flex-start; flex-wrap: wrap; gap: 1rem; margin-bottom: 2rem; }
.dash-head h1 { font-size: 1.75rem; font-weight: 700; }
.dash-head p { color: var(--muted); font-size: 0.9rem; }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 1rem; margin-bottom: 2.5rem; }
.stat { border: 1px solid var(--border); border-radius: 0.9rem; padding: 1.25rem; }
.stat .k { font-size: 0.8rem; color: var(--muted); margin-bottom: 0.35rem; }
.stat .v { font-size: 1.4rem; font-weight: 700; }
.panel { border: 1px solid var(--border); border-radius: 1rem; padding: 1.75rem; margin-bottom: 2rem; }
.panel-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.25rem; flex-wrap: wrap; gap: 0.75rem; }
.panel-head h2 { font-size: 1.15rem; font-weight: 700; }
.table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.table th { text-align: left; color: var(--muted); font-weight: 500; font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.04em; padding: 0.6rem 0.75rem; border-bottom: 1px solid var(--border); }
.table td { padding: 0.75rem; border-bottom: 1px solid rgba(51,65,85,0.5); }
.table td.mono { font-family: ui-monospace, monospace; color: var(--brand-300); }
.badge-status { font-size: 0.72rem; padding: 0.15rem 0.55rem; border-radius: 9999px; }
.badge-status.active { background: rgba(20,184,166,0.15); color: var(--brand-300); }
.badge-status.revoked { background: rgba(148,163,184,0.15); color: var(--muted); }
.btn-sm { padding: 0.4rem 0.75rem; font-size: 0.8rem; border-radius: 0.5rem; }
.btn-danger { background: transparent; border: 1px solid rgba(239,68,68,0.5); color: #fca5a5; }
.btn-danger:hover { background: rgba(239,68,68,0.12); }
.empty { text-align: center; color: var(--muted-2); padding: 2rem; font-size: 0.9rem; }
.key-reveal { font-family: ui-monospace, monospace; background: #0b1220; border: 1px solid var(--brand); border-radius: 0.6rem; padding: 0.9rem; word-break: break-all; color: var(--brand-300); margin: 0.75rem 0; }
.row-inline { display: flex; gap: 0.75rem; flex-wrap: wrap; }
.row-inline .input { flex: 1 1 200px; }

/* Tabs */
.tabs { display: flex; gap: 0.5rem; border-bottom: 1px solid var(--border); margin-bottom: 2rem; }
.tab-btn { background: none; border: none; color: var(--muted); font-size: 0.95rem; font-weight: 500; padding: 0.75rem 1rem; cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.tab-btn:hover { color: #fff; }
.tab-btn.active { color: var(--brand-400); border-bottom-color: var(--brand-400); }

/* Comparação de economia */
.compare { border: 1px solid rgba(20,184,166,0.3); border-radius: 1rem; padding: 1.5rem; background: linear-gradient(135deg, rgba(19,78,74,0.35), rgba(30,58,138,0.35)); margin-bottom: 2rem; }
.compare .row-inline { align-items: center; }
.compare label { font-size: 0.85rem; color: var(--muted); }
.compare-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 1rem; margin-top: 1.25rem; }
.compare-grid .cell { background: rgba(15,23,42,0.45); border: 1px solid var(--border); border-radius: 0.75rem; padding: 1rem; }
.compare-grid .cell .k { font-size: 0.78rem; color: var(--muted); margin-bottom: 0.3rem; }
.compare-grid .cell .v { font-size: 1.4rem; font-weight: 700; }
.compare-grid .cell.win .v { color: var(--brand-300); }
.pct { font-size: 0.85rem; color: var(--brand-300); }
select.input { appearance: none; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }

/* ===== Artigos / Blog ===== */
.blog-hero { padding: 3rem 0 1rem; text-align: center; }
.blog-hero h1 { font-size: clamp(1.9rem, 4vw, 2.8rem); margin: 0 0 .6rem; }
.blog-hero p { color: var(--muted); max-width: 640px; margin: 0 auto; }
.blog-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1.25rem; margin: 2rem 0 4rem; }
.article-card { display: flex; flex-direction: column; padding: 1.5rem; border-radius: 16px; text-decoration: none; color: inherit; transition: transform .15s ease, border-color .15s ease; }
.article-card:hover { transform: translateY(-3px); border-color: var(--brand); }
.article-card .tag { font-size: .72rem; letter-spacing: .04em; text-transform: uppercase; color: var(--brand-300); font-weight: 700; }
.article-card h2 { font-size: 1.2rem; margin: .5rem 0 .6rem; line-height: 1.3; }
.article-card p { color: var(--muted); font-size: .95rem; margin: 0 0 1rem; flex: 1; }
.article-card .read { color: var(--brand-300); font-weight: 600; font-size: .9rem; }

.article-shell { max-width: 760px; margin: 0 auto; padding: 2.5rem 1.25rem 4rem; }
.breadcrumb { font-size: .85rem; color: var(--muted-2); margin-bottom: 1.2rem; }
.breadcrumb a { color: var(--muted); text-decoration: none; }
.breadcrumb a:hover { color: var(--brand-300); }
.article-body h1 { font-size: clamp(1.7rem, 3.5vw, 2.4rem); line-height: 1.2; margin: 0 0 .5rem; }
.article-meta { color: var(--muted-2); font-size: .85rem; margin-bottom: 2rem; }
.article-body h2 { font-size: 1.4rem; margin: 2.2rem 0 .8rem; }
.article-body h3 { font-size: 1.1rem; margin: 1.6rem 0 .5rem; color: var(--brand-300); }
.article-body p, .article-body li { color: #cbd5e1; line-height: 1.75; }
.article-body ul { padding-left: 1.2rem; }
.article-body li { margin: .5rem 0; }
.article-body strong { color: var(--text); }
.article-body a { color: var(--brand-300); }
.article-body .lead { font-size: 1.1rem; color: var(--muted); }
.formula { text-align: center; font-family: ui-monospace, "Cascadia Code", Consolas, monospace; font-size: 1.05rem; background: var(--panel-solid); border: 1px solid var(--border); border-radius: 12px; padding: 1.1rem; margin: 1.2rem 0; color: var(--brand-300); }
.diagram { background: var(--panel-solid); border: 1px solid var(--border); border-radius: 12px; padding: 1.1rem; overflow-x: auto; font-family: ui-monospace, Consolas, monospace; font-size: .8rem; line-height: 1.35; color: #cbd5e1; }
.article-cta { margin-top: 2.5rem; padding: 1.75rem; border-radius: 16px; text-align: center; }
.article-cta h2 { margin: 0 0 .6rem; }
.article-cta p { color: var(--muted); margin: 0 0 1.2rem; }
.related { margin-top: 3rem; border-top: 1px solid var(--border-soft); padding-top: 1.5rem; }
.related h3 { color: var(--muted); font-size: .9rem; text-transform: uppercase; letter-spacing: .04em; }
.related a { display: block; color: var(--brand-300); text-decoration: none; margin: .4rem 0; }
.related a:hover { text-decoration: underline; }
