/* =============================================================================
   Pagyou — base do design system
   Compartilhada pelo developer portal (internal/docs) e pelo painel do master
   (internal/master). É a FONTE ÚNICA dos tokens: cor, tipografia, espaço e forma.
   Cada página concatena este arquivo antes do seu CSS próprio (um request só).

   Três camadas de decisão:
   1) COR — um par de superfícies frias (quase-preto azulado) e um acento
      ciano→violeta usado com parcimônia: só no que é ação ou identidade.
      Nunca colorir texto corrido; contraste AA no mínimo em tudo.
   2) RITMO — escala de espaço em 4px e medida de leitura de ~68ch.
   3) MOVIMENTO — transições curtas (120–220ms) e só em cor/transform/opacity.
      Tudo respeita prefers-reduced-motion.
   ============================================================================= */

/* --- reset enxuto ---------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; }
body { min-height: 100dvh; }
img, svg { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }
[hidden] { display: none !important; }

/* --- tokens ---------------------------------------------------------------- */
:root {
  color-scheme: dark;

  /* superfícies: frias, com passos curtos — profundidade vem da luz, não do preto */
  --bg:        #06070c;
  --bg-2:      #090b12;
  --surface:   #0d1018;
  --surface-2: #11151f;
  --surface-3: #161b27;
  --line:      #1e2433;
  --line-2:    #2a3346;

  /* texto */
  --fg:        #e8ecf5;
  --fg-2:      #a9b3c7;
  --fg-3:      #6f7a91;

  /* acento */
  --a1: #22d3ee;   /* ciano */
  --a2: #a78bfa;   /* violeta */
  --a1-soft: rgba(34, 211, 238, .12);
  --a2-soft: rgba(167, 139, 250, .12);
  --accent-line: linear-gradient(90deg, var(--a1), var(--a2));

  /* semânticos */
  --ok:   #34d399;
  --warn: #fbbf24;
  --bad:  #fb7185;
  --info: #60a5fa;

  /* métodos HTTP */
  --get:   #34d399;
  --post:  #60a5fa;
  --put:   #fbbf24;
  --patch: #a78bfa;
  --del:   #fb7185;

  /* tipografia */
  --sans: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Inter, Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, "SF Mono", "JetBrains Mono", Menlo, Consolas, "Liberation Mono", monospace;

  /* espaço e forma */
  --r-sm: 8px;
  --r:    12px;
  --r-lg: 18px;
  --shadow: 0 1px 2px rgba(0,0,0,.4), 0 8px 32px rgba(0,0,0,.35);
  --shadow-lg: 0 24px 80px -12px rgba(0,0,0,.7);

  /* layout */
  --top-h: 60px;
  --side-w: 268px;
  --rail-w: 460px;
  --gutter: 40px;
}

:root[data-theme="light"] {
  color-scheme: light;
  --bg:        #fbfcfe;
  --bg-2:      #f4f6fb;
  --surface:   #ffffff;
  --surface-2: #f7f9fc;
  --surface-3: #eef2f8;
  --line:      #e3e8f0;
  --line-2:    #cfd7e4;
  --fg:        #0e1420;
  --fg-2:      #45536b;
  --fg-3:      #75839a;
  --a1: #0891b2;
  --a2: #7c3aed;
  --a1-soft: rgba(8, 145, 178, .10);
  --a2-soft: rgba(124, 58, 237, .10);
  --ok:   #059669;
  --warn: #b45309;
  --bad:  #e11d48;
  --info: #2563eb;
  --get:   #059669;
  --post:  #2563eb;
  --put:   #b45309;
  --patch: #7c3aed;
  --del:   #e11d48;
  --shadow: 0 1px 2px rgba(16,24,40,.06), 0 8px 24px rgba(16,24,40,.06);
  --shadow-lg: 0 24px 64px -16px rgba(16,24,40,.18);
}

/* --- base ------------------------------------------------------------------ */
body {
  font-family: var(--sans);
  font-size: 15.5px;
  line-height: 1.65;
  color: var(--fg);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-feature-settings: "cv05" 1, "ss01" 1;
}

a { color: inherit; text-decoration: none; }
p a, li a, dd a, td a {
  color: var(--a1);
  text-underline-offset: 3px;
  text-decoration: underline;
  text-decoration-color: color-mix(in oklab, var(--a1) 35%, transparent);
  transition: text-decoration-color .15s, color .15s;
}
p a:hover, li a:hover, dd a:hover, td a:hover { text-decoration-color: var(--a1); }

::selection { background: color-mix(in oklab, var(--a1) 28%, transparent); color: var(--fg); }

:focus-visible {
  outline: 2px solid var(--a1);
  outline-offset: 2px;
  border-radius: 4px;
}

.skip {
  position: fixed; top: 8px; left: 8px; z-index: 100;
  padding: 10px 16px; border-radius: var(--r-sm);
  background: var(--surface-3); color: var(--fg);
  border: 1px solid var(--line-2);
  transform: translateY(-200%);
  transition: transform .18s;
}
.skip:focus { transform: none; }

code {
  font-family: var(--mono);
  font-size: .875em;
  font-feature-settings: "liga" 0;
}
p code, li code, td code, dd code, .callout code {
  padding: .12em .38em;
  border-radius: 5px;
  background: var(--surface-2);
  border: 1px solid var(--line);
  color: color-mix(in oklab, var(--fg) 88%, var(--a1));
  white-space: nowrap;
}
kbd {
  font-family: var(--mono);
  font-size: 11px;
  padding: 2px 6px;
  border-radius: 5px;
  background: var(--surface-3);
  border: 1px solid var(--line-2);
  border-bottom-width: 2px;
  color: var(--fg-2);
  white-space: nowrap;
}


/* =============================================================================
   Dashboard do cliente — v3 (ADR-018/019).
   Régua: Stripe/Linear/Mercury. Luz colorida com propósito, número-herói em
   texto-gradiente, gráfico interativo, ícones duotone, composição em grid.
   ============================================================================= */

/* ─── fundamentos ─────────────────────────────────────────────────────────── */
.svg-defs { position: absolute; width: 0; height: 0; }
.mini { font-size: 12px; }
.inline-form.spaced { margin-top: 12px; }
.cell-scopes { white-space: normal; max-width: 280px; }
html, body { height: 100%; }
body { overflow-x: hidden; background: var(--bg); }
.mono { font-family: var(--mono); font-size: .86em; letter-spacing: -.01em; }
.num { font-variant-numeric: tabular-nums; }
.sub { color: var(--fg-3); font-size: 13px; line-height: 1.5; }
.link { color: var(--fg-2); font-size: 13px; transition: color .15s; }
.link:hover { color: var(--a1); }
.link .arr { display: inline-block; transition: transform .18s; }
.link:hover .arr { transform: translateX(3px); }

::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: rgba(255,255,255,.09); border-radius: 8px; border: 3px solid var(--bg); }
::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,.16); }
::-webkit-scrollbar-track { background: transparent; }

@keyframes rise { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
.section.anim { animation: rise .45s cubic-bezier(.22,1,.36,1) both; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* ─── GATE: split screen ──────────────────────────────────────────────────── */
.gate { display: flex; min-height: 100dvh; }
.gate-showcase {
  position: relative; flex: 1.25; overflow: hidden;
  display: flex; flex-direction: column; justify-content: center;
  padding: 60px 72px;
  background:
    radial-gradient(1000px 700px at 20% 0%, rgba(34,211,238,.10), transparent 55%),
    radial-gradient(900px 700px at 90% 100%, rgba(167,139,250,.12), transparent 55%),
    #05060b;
}
.aurora { position: absolute; inset: -25%; filter: blur(100px); opacity: .6; pointer-events: none; }
.aurora i { position: absolute; border-radius: 50%; mix-blend-mode: screen; animation: drift 24s ease-in-out infinite alternate; }
.aurora i:nth-child(1) { width: 46vw; height: 46vw; left: -4%; top: -10%; background: radial-gradient(circle, rgba(34,211,238,.34), transparent 65%); }
.aurora i:nth-child(2) { width: 40vw; height: 40vw; right: -6%; bottom: -8%; background: radial-gradient(circle, rgba(167,139,250,.30), transparent 65%); animation-delay: -8s; animation-duration: 28s; }
.aurora i:nth-child(3) { width: 26vw; height: 26vw; left: 42%; top: 46%; background: radial-gradient(circle, rgba(96,165,250,.22), transparent 65%); animation-delay: -16s; animation-duration: 32s; }
@keyframes drift { from { transform: translate(-3%, -4%) scale(1); } to { transform: translate(5%, 6%) scale(1.18); } }
.gridlines {
  position: absolute; inset: 0; pointer-events: none; opacity: .5;
  background-image:
    linear-gradient(rgba(255,255,255,.028) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.028) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(75% 75% at 40% 40%, #000 30%, transparent 100%);
}
.grain {
  position: absolute; inset: 0; pointer-events: none; opacity: .5;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 .035 0'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)'/%3E%3C/svg%3E");
}
.show-inner { position: relative; max-width: 560px; }
.brand { display: flex; align-items: center; gap: 11px; }
.brand.xl { margin-bottom: 44px; }
.brand-mark { width: 34px; height: 34px; filter: drop-shadow(0 0 14px rgba(34,211,238,.45)); }
.brand-mark.sm { width: 25px; height: 25px; filter: drop-shadow(0 0 10px rgba(34,211,238,.35)); }
.brand-name { font-size: 18px; font-weight: 680; letter-spacing: -.02em; }
.show-title {
  font-size: clamp(34px, 3.6vw, 50px); font-weight: 720; letter-spacing: -.04em; line-height: 1.06;
}
.show-title em {
  font-style: normal;
  background: linear-gradient(100deg, var(--a1), #7dd3fc 45%, var(--a2));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.show-lead { color: var(--fg-2); font-size: 16.5px; line-height: 1.6; margin: 20px 0 36px; max-width: 44ch; }
.show-points { list-style: none; padding: 0; display: grid; gap: 13px; }
.show-points li { display: flex; align-items: center; gap: 11px; color: var(--fg-2); font-size: 14px; }
.show-points svg {
  width: 20px; height: 20px; padding: 3px; border-radius: 7px; flex-shrink: 0;
  background: rgba(52,211,153,.10); border: 1px solid rgba(52,211,153,.25);
  fill: none; stroke: var(--ok); stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round;
}
.show-foot { position: absolute; bottom: 26px; left: 72px; font-size: 12px; color: var(--fg-3); opacity: .8; }

.gate-side {
  flex: 1; display: grid; place-items: center; padding: 48px 40px;
  background: linear-gradient(180deg, #0a0d15, #07090f);
  border-left: 1px solid rgba(255,255,255,.06);
}
.gate-card { width: min(400px, 100%); }
.gate-card .only-narrow { display: none; margin-bottom: 28px; }
.gate-card h2 { font-size: 27px; font-weight: 700; letter-spacing: -.03em; }
.gate-lead { color: var(--fg-3); font-size: 14px; margin: 6px 0 30px; }

.field { display: block; margin-bottom: 16px; }
.field span {
  display: block; margin-bottom: 7px;
  font-size: 11px; font-weight: 650; letter-spacing: .1em; text-transform: uppercase;
  color: var(--fg-3);
}
.field input {
  width: 100%; padding: 13px 15px;
  border-radius: 12px; font-size: 15px;
  background: rgba(255,255,255,.035);
  border: 1px solid rgba(255,255,255,.10);
  color: var(--fg);
  transition: border-color .16s, box-shadow .16s, background .16s;
}
.field input::placeholder { color: var(--fg-3); opacity: .65; }
.field input:focus-visible {
  outline: none; border-color: var(--a1);
  box-shadow: 0 0 0 3px var(--a1-soft);
  background: rgba(255,255,255,.05);
}
.btn-hero {
  display: flex; align-items: center; justify-content: center; gap: 9px;
  width: 100%; margin-top: 10px;
  padding: 14px; border: 0; border-radius: 13px; cursor: pointer;
  font-size: 15px; font-weight: 680; letter-spacing: -.01em; color: #041018;
  background: linear-gradient(120deg, var(--a1), #67e8f9 50%, var(--a2) 120%);
  background-size: 170% 170%; background-position: 0% 50%;
  box-shadow: 0 12px 34px -10px rgba(34,211,238,.55), inset 0 1px 0 rgba(255,255,255,.35);
  transition: background-position .4s, transform .16s, box-shadow .25s;
}
.btn-hero svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; transition: transform .18s; }
.btn-hero:hover { background-position: 95% 50%; transform: translateY(-1px); box-shadow: 0 18px 44px -12px rgba(34,211,238,.65), inset 0 1px 0 rgba(255,255,255,.35); }
.btn-hero:hover svg { transform: translateX(3px); }
.btn-hero:active { transform: none; }
.gate-error { color: var(--bad); font-size: 13px; margin-top: 12px; }
.gate-alt { display: flex; align-items: center; gap: 10px; margin-top: 26px; font-size: 12.5px; color: var(--fg-3); }
.gate-alt a { color: var(--fg-2); transition: color .15s; }
.gate-alt a:hover { color: var(--a1); }
.dot-sep { width: 3px; height: 3px; border-radius: 50%; background: var(--line-2); }

@media (max-width: 960px) {
  .gate-showcase { display: none; }
  .gate-side { border-left: 0; background:
    radial-gradient(800px 500px at 50% -10%, rgba(34,211,238,.08), transparent 60%),
    radial-gradient(700px 500px at 50% 110%, rgba(167,139,250,.08), transparent 60%), var(--bg); }
  .gate-card .only-narrow { display: flex; }
}

/* ─── casca do app ────────────────────────────────────────────────────────── */
.app { position: relative; display: flex; min-height: 100dvh; }
.app-glow {
  position: fixed; inset: 0; pointer-events: none; z-index: 0;
  background:
    radial-gradient(900px 420px at 68% -8%, rgba(34,211,238,.055), transparent 60%),
    radial-gradient(700px 420px at 100% 100%, rgba(167,139,250,.05), transparent 60%);
}
.sidebar {
  position: sticky; top: 0; align-self: flex-start; z-index: 2;
  display: flex; flex-direction: column;
  width: 240px; flex-shrink: 0; height: 100dvh;
  padding: 24px 14px 18px;
  background: rgba(255,255,255,.016);
  backdrop-filter: blur(10px);
  border-right: 1px solid rgba(255,255,255,.06);
}
.side-brand { display: flex; align-items: center; gap: 10px; padding: 0 10px 26px; }
.nav-label {
  padding: 0 12px 8px;
  font-size: 10.5px; font-weight: 650; letter-spacing: .14em; text-transform: uppercase;
  color: var(--fg-3);
}
#nav { display: flex; flex-direction: column; gap: 3px; }
#nav a {
  position: relative; display: flex; align-items: center; gap: 12px;
  padding: 10px 12px; border-radius: 11px;
  font-size: 13.5px; font-weight: 540; color: var(--fg-2);
  transition: color .15s, background .15s;
}
#nav a svg {
  width: 18px; height: 18px; flex-shrink: 0;
  fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round;
  opacity: .8; transition: opacity .15s, stroke .15s;
}
#nav a:hover { color: var(--fg); background: rgba(255,255,255,.04); }
#nav a:hover svg { opacity: 1; }
#nav a.active {
  color: var(--fg);
  background: linear-gradient(90deg, rgba(34,211,238,.12), rgba(167,139,250,.07));
  box-shadow: inset 0 0 0 1px rgba(34,211,238,.18);
}
#nav a.active svg { opacity: 1; stroke: var(--a1); filter: drop-shadow(0 0 6px rgba(34,211,238,.6)); }

.side-foot { margin-top: auto; padding: 16px 4px 0; border-top: 1px solid rgba(255,255,255,.06); }
.who { display: flex; align-items: center; gap: 10px; padding: 2px 6px 12px; min-width: 0; }
.avatar {
  width: 32px; height: 32px; flex-shrink: 0; border-radius: 10px;
  display: grid; place-items: center;
  font-size: 13px; font-weight: 750; color: #041018;
  background: linear-gradient(135deg, var(--a1), var(--a2));
  box-shadow: 0 4px 14px -4px rgba(34,211,238,.5);
}
.who-col { min-width: 0; display: flex; flex-direction: column; }
.who-name { font-size: 12.5px; font-weight: 600; }
.who-id { font-size: 11px; color: var(--fg-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ─── conteúdo ────────────────────────────────────────────────────────────── */
.content { position: relative; z-index: 1; flex: 1; min-width: 0; padding: 36px 48px 90px; max-width: 1280px; margin-inline: auto; }
.section-head {
  display: flex; align-items: flex-end; justify-content: space-between; gap: 18px;
  flex-wrap: wrap; margin-bottom: 26px;
}
.section-head h2 { font-size: 25px; font-weight: 700; letter-spacing: -.03em; }
.section-head .sub { margin-top: 3px; }
.clock { font-size: 12.5px; color: var(--fg-3); font-variant-numeric: tabular-nums; }

.panel {
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(255,255,255,.035), rgba(255,255,255,.014));
  border: 1px solid rgba(255,255,255,.075);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.05), 0 24px 60px -36px rgba(0,0,0,.7);
  margin-bottom: 22px; overflow: hidden;
}
.panel-head {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  padding: 17px 22px; border-bottom: 1px solid rgba(255,255,255,.06);
}
.panel-head h3 { font-size: 15px; font-weight: 650; letter-spacing: -.015em; }

/* ─── KPIs ────────────────────────────────────────────────────────────────── */
.kpi-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 16px; }
.kpi {
  display: flex; align-items: center; gap: 14px;
  padding: 16px 18px; border-radius: 16px;
  background: linear-gradient(180deg, rgba(255,255,255,.035), rgba(255,255,255,.014));
  border: 1px solid rgba(255,255,255,.075);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.05);
  animation: rise .5s cubic-bezier(.22,1,.36,1) both;
}
.kpi:nth-child(2) { animation-delay: .06s; } .kpi:nth-child(3) { animation-delay: .12s; } .kpi:nth-child(4) { animation-delay: .18s; }
.kpi-ic {
  width: 40px; height: 40px; flex-shrink: 0; border-radius: 12px;
  display: grid; place-items: center;
  background: linear-gradient(135deg, rgba(34,211,238,.14), rgba(167,139,250,.10));
  border: 1px solid rgba(34,211,238,.22);
}
.kpi-ic svg { width: 19px; height: 19px; fill: none; stroke: var(--a1); stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.kpi-col { min-width: 0; }
.kpi-k { font-size: 11px; font-weight: 650; letter-spacing: .1em; text-transform: uppercase; color: var(--fg-3); }
.kpi-v { font-size: 19px; font-weight: 700; letter-spacing: -.03em; font-variant-numeric: tabular-nums; margin-top: 2px; white-space: nowrap; }
.kpi-v .up { font-size: 11.5px; font-weight: 600; color: var(--ok); margin-left: 7px; }

/* ─── grade da visão geral ────────────────────────────────────────────────── */
.ov-grid { display: grid; grid-template-columns: 5fr 7fr; gap: 16px; }
.ov-grid .panel { margin-bottom: 22px; }

/* cartão-herói do saldo */
@property --hue { syntax: "<angle>"; initial-value: 0deg; inherits: false; }
.hero-card { position: relative; padding: 24px 26px 20px; display: flex; flex-direction: column; }
.hero-card::before {
  content: ""; position: absolute; inset: -1px; border-radius: 19px; padding: 1px;
  background: conic-gradient(from var(--hue), rgba(34,211,238,.65), rgba(167,139,250,.2), transparent 40%, transparent 60%, rgba(167,139,250,.55), rgba(34,211,238,.65));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  animation: spin-hue 7s linear infinite; pointer-events: none;
}
@keyframes spin-hue { to { --hue: 360deg; } }
.hero-card::after {
  content: ""; position: absolute; right: -50px; top: -60px; width: 230px; height: 230px;
  background: radial-gradient(circle, rgba(34,211,238,.13), transparent 65%); pointer-events: none;
}
.hero-k {
  display: flex; align-items: center; gap: 8px;
  font-size: 11px; font-weight: 650; letter-spacing: .12em; text-transform: uppercase; color: var(--fg-3);
}
.hero-k .live {
  width: 7px; height: 7px; border-radius: 50%; background: var(--ok);
  box-shadow: 0 0 10px var(--ok); animation: blink 2.2s ease-in-out infinite;
}
@keyframes blink { 50% { opacity: .35; } }
.hero-v {
  margin-top: 10px;
  font-size: clamp(34px, 3vw, 44px); font-weight: 750; letter-spacing: -.045em; line-height: 1.05;
  font-variant-numeric: tabular-nums;
  background: linear-gradient(105deg, #fff 30%, #a5f3fc 75%, #c4b5fd);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 4px 24px rgba(34,211,238,.18));
}
.hero-v .cur { font-size: .42em; font-weight: 650; vertical-align: .35em; margin-right: .3em; letter-spacing: -.01em; }
.hero-hint { margin-top: 6px; font-size: 12.5px; color: var(--fg-3); }
.hero-buckets { margin-top: auto; padding-top: 20px; display: grid; gap: 1px; }
.hb {
  display: flex; align-items: center; gap: 11px;
  padding: 10px 2px; border-top: 1px solid rgba(255,255,255,.055);
  font-size: 13px;
}
.hb svg { width: 16px; height: 16px; fill: none; stroke: var(--fg-3); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.hb .k { color: var(--fg-2); }
.hb .v { margin-left: auto; font-weight: 620; font-variant-numeric: tabular-nums; }
.hb .v.zero { color: var(--fg-3); font-weight: 500; }
.hb .v.bad { color: var(--bad); }

/* ─── gráfico ─────────────────────────────────────────────────────────────── */
.chart-panel { display: flex; flex-direction: column; }
.chart-panel .panel-head { border-bottom: 0; padding-bottom: 2px; }
.chart-total { font-size: 17px; font-weight: 700; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.chart-total .up { color: var(--ok); font-size: 11.5px; font-weight: 600; margin-left: 8px; }
.chart { position: relative; flex: 1; padding: 4px 12px 12px; min-height: 200px; }
.chart svg { width: 100%; height: 100%; min-height: 190px; display: block; }
.chart .axis { font-size: 10px; fill: var(--fg-3); font-family: var(--sans); }
.chart .gridline { stroke: rgba(255,255,255,.05); }
.chart .flow-line { fill: none; stroke: url(#g-chart); stroke-width: 2.2; stroke-linecap: round; }
.chart .flow-fill { fill: url(#g-fill); }
.chart .dot-last { fill: var(--a1); }
.chart .dot-pulse { fill: none; stroke: var(--a1); animation: pulse 2.4s ease-out infinite; }
@keyframes pulse { 0% { opacity: .8; r: 4; } 70% { opacity: 0; r: 13; } 100% { opacity: 0; r: 13; } }
.chart .xhair { stroke: rgba(255,255,255,.18); stroke-dasharray: 3 3; }
.chart .xdot { fill: #fff; stroke: var(--a1); stroke-width: 2; }
.chart-tip {
  position: absolute; pointer-events: none; z-index: 3;
  padding: 8px 12px; border-radius: 10px; white-space: nowrap;
  background: rgba(14,18,28,.95); backdrop-filter: blur(8px);
  border: 1px solid rgba(34,211,238,.25);
  box-shadow: 0 12px 34px -12px rgba(0,0,0,.8);
  font-size: 12px; transform: translate(-50%, -115%);
}
.chart-tip .d { color: var(--fg-3); }
.chart-tip .v { font-weight: 700; font-variant-numeric: tabular-nums; font-size: 13px; }
.chart-empty { padding: 44px 20px; text-align: center; color: var(--fg-3); font-size: 13px; }

/* ─── feed ────────────────────────────────────────────────────────────────── */
.feed { padding: 8px 10px; }
.feed-row {
  display: grid; grid-template-columns: 38px 1fr auto auto; align-items: center; gap: 14px;
  padding: 12px 14px; border-radius: 12px;
  transition: background .14s, transform .14s;
}
.feed-row:hover { background: rgba(255,255,255,.032); }
.feed-row + .feed-row { border-top: 1px solid rgba(255,255,255,.04); }
.feed-ic {
  width: 36px; height: 36px; border-radius: 11px;
  display: grid; place-items: center;
  border: 1px solid rgba(255,255,255,.07);
}
.feed-ic svg { width: 16px; height: 16px; fill: none; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.feed-ic.in   { background: rgba(52,211,153,.10); border-color: rgba(52,211,153,.22); }
.feed-ic.in  svg { stroke: var(--ok); }
.feed-ic.out  { background: rgba(96,165,250,.10); border-color: rgba(96,165,250,.22); }
.feed-ic.out svg { stroke: var(--info); }
.feed-ic.back { background: rgba(251,191,36,.09); border-color: rgba(251,191,36,.2); }
.feed-ic.back svg { stroke: var(--warn); }
.feed-ic.hold { background: rgba(167,139,250,.10); border-color: rgba(167,139,250,.22); }
.feed-ic.hold svg { stroke: var(--a2); }
.feed-main { min-width: 0; }
.feed-t { font-size: 13.5px; font-weight: 570; }
.feed-s { font-size: 12px; color: var(--fg-3); margin-top: 1px; }
.feed-v { font-size: 14px; font-weight: 680; font-variant-numeric: tabular-nums; }
.feed-v.plus { color: var(--ok); }

/* ─── tabelas ─────────────────────────────────────────────────────────────── */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
thead th {
  position: sticky; top: 0; z-index: 1; text-align: left;
  padding: 13px 18px; white-space: nowrap;
  font-size: 10.5px; font-weight: 680; letter-spacing: .12em; text-transform: uppercase;
  color: var(--fg-3);
  background: rgba(11, 13, 20, .92); backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(255,255,255,.08);
}
tbody td { padding: 13px 18px; border-bottom: 1px solid rgba(255,255,255,.045); white-space: nowrap; }
tbody tr:last-child td { border-bottom: 0; }
tbody tr { transition: background .13s; }
tbody tr:hover { background: rgba(255,255,255,.03); }
tr.clickable { cursor: pointer; }
td.right, th.right { text-align: right; }
td.dim { color: var(--fg-3); }
td.strong { font-weight: 650; }
.wrap { max-width: 260px; overflow: hidden; text-overflow: ellipsis; }
.ok { color: var(--ok); } .bad { color: var(--bad); } .warn { color: var(--warn); }

.pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 3.5px 11px 3.5px 9px; border-radius: 999px;
  font-size: 11.5px; font-weight: 640; letter-spacing: .01em;
  background: rgba(255,255,255,.05); color: var(--fg-2);
  border: 1px solid rgba(255,255,255,.08);
}
.pill::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; box-shadow: 0 0 9px currentColor; }
.pill.paid, .pill.completed, .pill.delivered, .pill.active
  { color: #4ade80; background: rgba(52,211,153,.10); border-color: rgba(52,211,153,.26); }
.pill.pending, .pill.processing, .pill.requested
  { color: #7db8fb; background: rgba(96,165,250,.10); border-color: rgba(96,165,250,.26); }
.pill.refunded, .pill.returned
  { color: #c4b5fd; background: rgba(167,139,250,.10); border-color: rgba(167,139,250,.26); }
.pill.failed, .pill.exhausted, .pill.rejected
  { color: #fda4af; background: rgba(251,113,133,.10); border-color: rgba(251,113,133,.26); }
.pill.expired, .pill.cancelled, .pill.disabled { color: var(--fg-3); }

/* ─── filtros ─────────────────────────────────────────────────────────────── */
.filters { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.seg {
  display: inline-flex; padding: 3px; gap: 2px; border-radius: 12px;
  background: rgba(255,255,255,.045); border: 1px solid rgba(255,255,255,.08);
}
.seg button {
  padding: 6.5px 13px; border: 0; border-radius: 9px; cursor: pointer;
  background: transparent; color: var(--fg-3);
  font-size: 12.5px; font-weight: 570;
  transition: color .14s, background .14s;
}
.seg button:hover { color: var(--fg-2); }
.seg button.on { color: var(--fg); background: rgba(255,255,255,.09); box-shadow: inset 0 1px 0 rgba(255,255,255,.07); }
.search {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 0 13px; border-radius: 12px; height: 38px;
  background: rgba(255,255,255,.045); border: 1px solid rgba(255,255,255,.08);
  transition: border-color .15s, box-shadow .15s;
}
.search:focus-within { border-color: var(--a1); box-shadow: 0 0 0 3px var(--a1-soft); }
.search svg { width: 14px; height: 14px; fill: none; stroke: var(--fg-3); stroke-width: 1.9; stroke-linecap: round; }
.search input { border: 0; background: transparent; color: var(--fg); font-size: 13px; width: 190px; }
.search input:focus-visible { outline: none; }
.date {
  padding: 8px 11px; border-radius: 11px; font-size: 13px;
  background: rgba(255,255,255,.045); border: 1px solid rgba(255,255,255,.08); color: var(--fg-2);
  color-scheme: dark;
}
.ip-chip {
  font-size: 12px; color: var(--fg-2); padding: 7px 13px; border-radius: 999px;
  background: rgba(255,255,255,.045); border: 1px solid rgba(255,255,255,.08);
}

/* ─── botões ──────────────────────────────────────────────────────────────── */
.btn-primary {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 9px 17px; border: 0; border-radius: 11px; cursor: pointer;
  font-size: 13px; font-weight: 680; color: #041018;
  background: linear-gradient(130deg, var(--a1), #67e8f9);
  box-shadow: 0 8px 22px -8px rgba(34,211,238,.6), inset 0 1px 0 rgba(255,255,255,.35);
  transition: transform .14s, box-shadow .2s, filter .15s;
}
.btn-primary:hover { transform: translateY(-1px); filter: brightness(1.07); }
.btn-primary:active { transform: none; }
.btn-primary:disabled { opacity: .55; cursor: default; transform: none; }
.btn-primary.danger {
  color: #fff; background: linear-gradient(130deg, #fb7185, #f43f5e);
  box-shadow: 0 8px 24px -8px rgba(244,63,94,.6), inset 0 1px 0 rgba(255,255,255,.25);
}
.btn-ghost {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 8px 15px; border-radius: 11px; cursor: pointer;
  background: rgba(255,255,255,.045); border: 1px solid rgba(255,255,255,.09);
  color: var(--fg-2); font-size: 12.5px; font-weight: 570;
  transition: color .14s, background .14s, border-color .14s;
}
.btn-ghost:hover { color: var(--fg); background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.16); }
.btn-ghost svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.btn-ghost.slim { width: 100%; justify-content: center; }
.icon-btn {
  display: grid; place-items: center; width: 32px; height: 32px;
  border: 1px solid rgba(255,255,255,.09); border-radius: 10px; cursor: pointer;
  background: rgba(255,255,255,.045); color: var(--fg-2);
  transition: color .14s, background .14s;
}
.icon-btn:hover { color: var(--fg); background: rgba(255,255,255,.08); }
.icon-btn svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; }
.copy-chip {
  display: inline-flex; align-items: center; gap: 6px; max-width: 100%;
  padding: 4px 9px; border-radius: 8px; cursor: pointer;
  background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.08);
  color: var(--fg-2); font-family: var(--mono); font-size: 11.5px;
  transition: color .13s, border-color .13s;
}
.copy-chip:hover { color: var(--a1); border-color: rgba(34,211,238,.4); }
.copy-chip svg { width: 11px; height: 11px; flex-shrink: 0; fill: none; stroke: currentColor; stroke-width: 1.9; }
.copy-chip .t { overflow: hidden; text-overflow: ellipsis; }

.inline-form { display: flex; gap: 8px; }
.inline-form input {
  min-width: 250px; padding: 9px 13px; border-radius: 11px; font-size: 13px;
  background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.09); color: var(--fg);
  transition: border-color .15s, box-shadow .15s;
}
.inline-form input:focus-visible { outline: none; border-color: var(--a1); box-shadow: 0 0 0 3px var(--a1-soft); }

.pager { display: flex; justify-content: center; margin-top: -4px; }

/* ─── vazios e skeleton ───────────────────────────────────────────────────── */
.empty { padding: 54px 24px; text-align: center; }
.empty svg { width: 40px; height: 40px; margin: 0 auto 14px; fill: none; stroke: var(--fg-3); stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; opacity: .7; }
.empty .t { font-size: 14.5px; font-weight: 620; color: var(--fg-2); margin-bottom: 4px; }
.empty .h { font-size: 13px; color: var(--fg-3); }
.skeleton { padding: 14px 16px; }
.skeleton .row {
  height: 40px; border-radius: 10px; margin-bottom: 8px;
  background: linear-gradient(90deg, rgba(255,255,255,.035) 25%, rgba(255,255,255,.075) 45%, rgba(255,255,255,.035) 65%);
  background-size: 240% 100%;
  animation: shimmer 1.3s ease-in-out infinite;
}
@keyframes shimmer { from { background-position: 130% 0; } to { background-position: -110% 0; } }

/* ─── drawer ──────────────────────────────────────────────────────────────── */
.drawer { position: fixed; inset: 0; z-index: 50; }
.drawer-backdrop { position: absolute; inset: 0; background: rgba(3,5,10,.66); backdrop-filter: blur(5px); animation: fadein .2s both; }
@keyframes fadein { from { opacity: 0; } }
.drawer-card {
  position: absolute; top: 10px; right: 10px; bottom: 10px;
  width: min(480px, 94vw); display: flex; flex-direction: column;
  border-radius: 18px;
  background: linear-gradient(180deg, #0d1019, #090b12);
  border: 1px solid rgba(255,255,255,.09);
  box-shadow: -30px 0 90px -30px rgba(0,0,0,.85), inset 0 1px 0 rgba(255,255,255,.05);
  animation: slidein .34s cubic-bezier(.22,1,.36,1) both;
  overflow-y: auto;
}
@keyframes slidein { from { transform: translateX(46px); opacity: 0; } }
.drawer-head {
  position: sticky; top: 0; z-index: 2;
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  padding: 20px 24px 16px;
  background: rgba(13,16,25,.92); backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(255,255,255,.06);
}
.drawer-head h3 { font-size: 16.5px; font-weight: 680; letter-spacing: -.02em; }
#drawer-body { padding: 22px 24px 34px; }
.kv { display: grid; grid-template-columns: 132px 1fr; row-gap: 13px; column-gap: 14px; font-size: 13.5px; }
.kv .k { color: var(--fg-3); font-size: 12.5px; padding-top: 1px; }
.kv .v { min-width: 0; overflow-wrap: anywhere; }
.drawer-sec {
  margin-top: 22px; padding: 18px; border-radius: 15px;
  background: rgba(255,255,255,.03); border: 1px solid rgba(255,255,255,.08);
}
.drawer-sec.risk { border-color: rgba(251,113,133,.28); background: rgba(251,113,133,.055); }
.drawer-sec h4 { font-size: 12px; font-weight: 680; letter-spacing: .1em; text-transform: uppercase; color: var(--fg-2); margin-bottom: 10px; }
.hint { font-size: 12.5px; color: var(--fg-3); line-height: 1.55; }

/* ─── toast ───────────────────────────────────────────────────────────────── */
.toast {
  position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%);
  z-index: 90; display: flex; align-items: center; gap: 9px;
  padding: 12px 19px; border-radius: 13px;
  background: rgba(17,21,32,.94); backdrop-filter: blur(12px);
  border: 1px solid rgba(52,211,153,.32);
  color: var(--fg); font-size: 13.5px; font-weight: 570;
  box-shadow: 0 20px 50px -18px rgba(0,0,0,.85);
  animation: rise .3s cubic-bezier(.22,1,.36,1) both;
}
.toast::before { content: "✓"; color: var(--ok); font-weight: 800; }
.toast.bad { border-color: rgba(251,113,133,.4); }
.toast.bad::before { content: "✕"; color: var(--bad); }

/* ─── responsivo ──────────────────────────────────────────────────────────── */
@media (max-width: 1100px) {
  .kpi-row { grid-template-columns: repeat(2, 1fr); }
  .ov-grid { grid-template-columns: 1fr; }
}
@media (max-width: 860px) {
  .app { flex-direction: column; }
  .sidebar {
    position: static; width: 100%; height: auto; flex-direction: row; align-items: center;
    padding: 10px 14px; border-right: 0; border-bottom: 1px solid rgba(255,255,255,.06);
  }
  .side-brand { padding: 0 12px 0 0; }
  .nav-label { display: none; }
  #nav { flex-direction: row; overflow-x: auto; }
  #nav a span { display: none; }
  .side-foot { margin: 0 0 0 auto; padding: 0; border: 0; display: flex; align-items: center; gap: 8px; }
  .who-col { display: none; }
  .btn-ghost.slim { width: auto; }
  .content { padding: 22px 18px 60px; }
  .kpi-row { grid-template-columns: 1fr 1fr; gap: 10px; }
  .kv { grid-template-columns: 1fr; row-gap: 4px; }
  .kv .k { margin-top: 8px; }
}

/* ─── conta: perfil, taxas, senha ─────────────────────────────────────────── */
.acc-grid { display: grid; grid-template-columns: 5fr 7fr; gap: 16px; }
.acc-grid .panel { margin-bottom: 22px; }
.profile-card { padding: 24px; }
.prof-top { display: flex; align-items: center; gap: 16px; margin-bottom: 20px; }
.avatar.xl { width: 54px; height: 54px; border-radius: 16px; font-size: 22px; }
.prof-name { font-size: 17px; font-weight: 680; letter-spacing: -.02em; }
.prof-mail { font-size: 13px; color: var(--fg-3); margin-top: 2px; }
.prof-kv { padding-top: 16px; border-top: 1px solid rgba(255,255,255,.06); }
.hint.pad { padding-top: 6px; }
.fee-list { padding: 6px 0; }
.fee-row { padding: 14px 22px; }
.fee-row + .fee-row { border-top: 1px solid rgba(255,255,255,.05); }
.fee-op { font-size: 13.5px; font-weight: 600; }
.fee-v { font-size: 16px; font-weight: 700; letter-spacing: -.02em; margin-top: 3px; }
.fee-note { font-size: 12.5px; color: var(--fg-3); margin-top: 3px; line-height: 1.5; }
.pw-form { display: grid; grid-template-columns: repeat(3, 1fr) auto; gap: 14px; align-items: end; padding: 18px 22px 20px; }
.pw-form .field { margin-bottom: 0; }
.pw-form .btn-primary { height: 44px; }
@media (max-width: 1100px) { .acc-grid { grid-template-columns: 1fr; } .pw-form { grid-template-columns: 1fr; } }

/* ─── affordance de clique e saque ────────────────────────────────────────── */
.chev { width: 15px; height: 15px; fill: none; stroke: var(--fg-3); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; opacity: 0; transition: opacity .14s, transform .14s; }
tr:hover .chev, .feed-row:hover .chev { opacity: 1; transform: translateX(2px); }
.td-chev { width: 30px; }
.feed-row.clickable { cursor: pointer; }
.field.spaced { margin-top: 12px; }
.field span em { font-style: normal; text-transform: none; letter-spacing: 0; font-weight: 500; }
.btn-primary.wide { width: 100%; justify-content: center; margin-top: 4px; }

/* ─── select e captcha ────────────────────────────────────────────────────── */
.sel {
  width: 100%; padding: 12px 14px; border-radius: 11px; font-size: 14px;
  background: rgba(255,255,255,.045); border: 1px solid rgba(255,255,255,.10);
  color: var(--fg); appearance: none; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1.5 6 6.5 11 1.5' fill='none' stroke='%236f7a91' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center;
}
.sel:focus-visible { outline: none; border-color: var(--a1); box-shadow: 0 0 0 3px var(--a1-soft); }
.sel option { background: #0d1019; color: var(--fg); }
.captcha-slot { margin: 2px 0 6px; min-height: 0; display: flex; justify-content: center; }
.captcha-slot:has(iframe) { min-height: 68px; margin-bottom: 10px; }
input:disabled { opacity: .5; cursor: not-allowed; }
