/* Afiliado — visual de app: tokens, layout, componentes e movimento. */

:root {
  --fundo: #f2f2f7;
  --superficie: #ffffff;
  --superficie-2: #f5f5f8;
  --preenche: rgba(118, 118, 128, .12);
  --preenche-2: rgba(118, 118, 128, .2);
  --linha: rgba(60, 60, 67, .13);
  --texto: #1d1d1f;
  --texto-2: #6b6b70;
  --texto-3: #aeaeb2;
  --azul: #0071e3;
  --verde: #1d8a3a;
  --pend: #c2410c;
  --verde-q: #34c759;
  --azul-q: #0a84ff;
  --laranja-q: #ff9500;
  --roxo-q: #af52de;
  --ambar-q: #ffb300;
  --cinza-q: #8e8e93;
  --barra-ok: #34c759;
  --barra-pend: #ffb59b;
  --sombra: 0 1px 2px rgba(0, 0, 0, .04), 0 8px 24px rgba(0, 0, 0, .04);
  --vidro: rgba(249, 249, 251, .78);
  --inverso: #1d1d1f;
  --inverso-txt: #ffffff;
  --raio: 20px;
  --raio-g: 16px;
  --mola: cubic-bezier(.32, .72, 0, 1);
  --suave: cubic-bezier(.2, .8, .2, 1);
  --topo: env(safe-area-inset-top, 0px);
  --baixo: env(safe-area-inset-bottom, 0px);
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-tema="claro"]) {
    --fundo: #000000;
    --superficie: #1c1c1e;
    --superficie-2: #2c2c2e;
    --preenche: rgba(118, 118, 128, .24);
    --preenche-2: rgba(118, 118, 128, .32);
    --linha: rgba(84, 84, 88, .55);
    --texto: #f5f5f7;
    --texto-2: #a1a1a6;
    --texto-3: #636366;
    --azul: #2997ff;
    --verde: #30d158;
    --pend: #ff9f6e;
    --barra-ok: #30d158;
    --barra-pend: #b4532a;
    --sombra: none;
    --vidro: rgba(22, 22, 24, .74);
    --inverso: #f5f5f7;
    --inverso-txt: #000000;
    color-scheme: dark;
  }
}

:root[data-tema="escuro"] {
  --fundo: #000000;
  --superficie: #1c1c1e;
  --superficie-2: #2c2c2e;
  --preenche: rgba(118, 118, 128, .24);
  --preenche-2: rgba(118, 118, 128, .32);
  --linha: rgba(84, 84, 88, .55);
  --texto: #f5f5f7;
  --texto-2: #a1a1a6;
  --texto-3: #636366;
  --azul: #2997ff;
  --verde: #30d158;
  --pend: #ff9f6e;
  --barra-ok: #30d158;
  --barra-pend: #b4532a;
  --sombra: none;
  --vidro: rgba(22, 22, 24, .74);
  --inverso: #f5f5f7;
  --inverso-txt: #000000;
  color-scheme: dark;
}

/* ---- base ------------------------------------------------------------------- */

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--fundo);
  color: var(--texto);
  font: 17px/1.35 -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI Variable Text", "Segoe UI", system-ui, sans-serif;
  letter-spacing: -.01em;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  overscroll-behavior-y: none;
  transition: background-color .3s;
}
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; text-align: inherit; }
input { font: inherit; color: inherit; }
b, strong { font-weight: 600; }
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.i { width: 22px; height: 22px; flex-shrink: 0; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
:focus-visible { outline: 3px solid color-mix(in srgb, var(--azul) 55%, transparent); outline-offset: 2px; border-radius: 10px; }
.ok { color: var(--verde); }
.pend { color: var(--pend); }
.mono { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: 14px; letter-spacing: 0; }
.quebra { word-break: break-all; }
[data-contar], [data-contar-n], .valor, .valor-heroi, .valor-medio, .linha-fim strong, .rank strong { font-variant-numeric: tabular-nums; }

/* ---- estrutura -------------------------------------------------------------- */

.shell { min-height: 100dvh; }
.palco { min-width: 0; }
.app-main {
  max-width: 760px;
  margin: 0 auto;
  padding: calc(var(--topo) + 6px) 16px calc(104px + var(--baixo));
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: opacity .18s var(--suave), transform .18s var(--suave);
}
.app-main.saindo { opacity: 0; transform: translateY(6px); }
.app-main.sub.saindo { transform: translateX(14px); }

.cab { padding: 6px 4px 4px; }
.cab-linha { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 44px; }
.sobre { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; font-weight: 600; letter-spacing: .02em; text-transform: uppercase; color: var(--texto-2); }
.titulo { margin: 0; font-size: 34px; line-height: 1.12; font-weight: 700; letter-spacing: -.025em; }
.cab-sub .titulo { margin-top: 2px; }
.voltar { display: inline-flex; align-items: center; gap: 2px; margin-left: -8px; padding: 8px 8px 8px 2px; color: var(--azul); font-size: 17px; border-radius: 12px; transition: opacity .15s; }
.voltar .i { width: 26px; height: 26px; stroke-width: 2.2; }
.voltar:active { opacity: .45; }

.topo-fixo {
  position: fixed; inset: 0 0 auto 0; z-index: 20;
  height: calc(var(--topo) + 44px); padding-top: var(--topo);
  display: flex; align-items: center; justify-content: center;
  background: var(--vidro); backdrop-filter: saturate(180%) blur(20px); -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: .5px solid var(--linha);
  opacity: 0; pointer-events: none; transition: opacity .2s;
}
.topo-titulo { font-size: 17px; font-weight: 600; transform: translateY(4px); transition: transform .25s var(--suave); }
body.rolou .topo-fixo { opacity: 1; }
body.rolou .topo-titulo { transform: none; }

/* barra de abas (celular) */
.abas {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  display: flex; justify-content: space-around;
  padding: 6px 4px calc(var(--baixo) + 4px);
  background: var(--vidro); backdrop-filter: saturate(180%) blur(20px); -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-top: .5px solid var(--linha);
}
.abas a { flex: 1; max-width: 96px; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 4px 0; min-height: 48px; font-size: 10.5px; font-weight: 500; color: var(--texto-3); transition: color .2s; }
.abas a .i { width: 26px; height: 26px; transition: transform .35s var(--mola); }
.abas a.on { color: var(--azul); }
.abas a.on .i { stroke-width: 2.1; }
.abas a:active .i { transform: scale(.86); }

/* lateral (computador) */
.lateral { display: none; }

@media (min-width: 1024px) {
  .shell { display: grid; grid-template-columns: 252px minmax(0, 1fr); }
  .abas, .topo-fixo { display: none; }
  .lateral {
    display: flex; flex-direction: column; gap: 4px;
    position: sticky; top: 0; height: 100dvh; padding: 22px 14px;
    background: var(--superficie-2); border-right: .5px solid var(--linha);
  }
  :root[data-tema="escuro"] .lateral { background: #121214; }
  .marca { display: flex; align-items: center; gap: 10px; padding: 4px 10px 22px; font-weight: 700; font-size: 17px; }
  .marca-ico { width: 34px; height: 34px; border-radius: 9px; background: var(--inverso); color: var(--inverso-txt); display: grid; place-items: center; }
  .marca-ico .i { width: 20px; height: 20px; }
  .lateral-nav { display: flex; flex-direction: column; gap: 2px; }
  .lateral-nav a { display: flex; align-items: center; gap: 12px; padding: 9px 12px; border-radius: 10px; font-size: 15px; font-weight: 500; color: var(--texto-2); transition: background .15s, color .15s; }
  .lateral-nav a:hover { background: var(--preenche); color: var(--texto); }
  .lateral-nav a.on { background: color-mix(in srgb, var(--azul) 13%, transparent); color: var(--azul); font-weight: 600; }
  .lateral-pe { margin-top: auto; padding: 10px 12px; }
  .app-main { padding: 34px 40px 60px; max-width: 880px; }
  .titulo { font-size: 38px; }
}

.ao-vivo { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; color: var(--verde); }
.ao-vivo i { width: 8px; height: 8px; border-radius: 50%; background: var(--verde-q); animation: pulsar 2s infinite; }

/* ---- cartões e grupos ------------------------------------------------------- */

.cartao { background: var(--superficie); border-radius: var(--raio); padding: 18px; box-shadow: var(--sombra); }
.cartao-cab { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-bottom: 14px; }
.cartao-tit { font-size: 17px; font-weight: 600; }
.heroi { display: flex; flex-direction: column; gap: 14px; padding: 20px; }
.heroi.centro { align-items: center; text-align: center; gap: 8px; padding: 26px 18px; }
.rotulo { display: block; font-size: 13px; font-weight: 500; color: var(--texto-2); }
.valor-heroi { display: block; font-size: 44px; line-height: 1.05; font-weight: 700; letter-spacing: -.035em; }
.valor { display: block; font-size: 22px; font-weight: 650; letter-spacing: -.02em; margin: 2px 0 1px; }
.valor-medio { display: block; font-size: 28px; font-weight: 700; letter-spacing: -.025em; }
.nota { font-size: 13px; color: var(--texto-2); }
.duplo { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.cartao.duplo { padding: 18px; }

.grupo { background: var(--superficie); border-radius: var(--raio-g); overflow: hidden; box-shadow: var(--sombra); }
.secao { margin: 14px 16px -4px; font-size: 13px; font-weight: 600; letter-spacing: .02em; text-transform: uppercase; color: var(--texto-2); }
.secao.dia { margin-top: 18px; margin-bottom: 8px; }
.lista > .secao.dia:first-child { margin-top: 4px; }

.linha {
  position: relative; display: flex; align-items: center; gap: 12px; width: 100%;
  min-height: 52px; padding: 11px 16px; background: transparent;
  transition: background-color .2s;
}
.grupo > .linha + .linha::before, .grupo > * + .linha::before {
  content: ""; position: absolute; top: 0; right: 0; left: 16px; height: .5px; background: var(--linha);
}
.grupo > .linha:has(.ico-quad) + .linha::before,
.grupo > .linha:has(.avatar) + .linha::before { left: 60px; }
a.linha:active, button.linha:active, .linha-link:active .linha { background: var(--preenche); transition: none; }
@media (hover: hover) { a.linha:hover, button.linha:hover { background: color-mix(in srgb, var(--preenche) 50%, transparent); } }
.linha-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.linha-txt .nota, .linha-tit { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.linha-tit { font-size: 16px; }
.linha-fim { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; flex-shrink: 0; }
.linha-fim strong { font-size: 16px; }
.chevron { width: 18px; height: 18px; color: var(--texto-3); stroke-width: 2.4; margin-right: -4px; }
.dir { margin-left: auto; }
.linha-link { display: block; }

.ico-quad { width: 32px; height: 32px; flex-shrink: 0; border-radius: 9px; display: grid; place-items: center; color: #fff; background: var(--cinza-q); }
.ico-quad .i { width: 19px; height: 19px; stroke-width: 2; }
.ico-quad.verde { background: var(--verde-q); }
.ico-quad.azul { background: var(--azul-q); }
.ico-quad.laranja { background: var(--laranja-q); }
.ico-quad.roxo { background: var(--roxo-q); }
.ico-quad.ambar { background: var(--ambar-q); }
.ico-quad.cinza { background: var(--cinza-q); }

.avatar { width: 38px; height: 38px; flex-shrink: 0; border-radius: 50%; display: grid; place-items: center; font-weight: 600; font-size: 16px; }
.avatar.verde { background: color-mix(in srgb, var(--verde-q) 18%, transparent); color: var(--verde); }
.avatar.laranja { background: color-mix(in srgb, var(--laranja-q) 20%, transparent); color: var(--pend); }

.etiqueta { display: inline-flex; align-items: center; height: 22px; padding: 0 9px; border-radius: 999px; font-size: 12px; font-weight: 600; white-space: nowrap; }
.e-ok { background: color-mix(in srgb, var(--verde-q) 16%, transparent); color: var(--verde); }
.e-pend { background: color-mix(in srgb, var(--laranja-q) 18%, transparent); color: var(--pend); }
.e-azul { background: color-mix(in srgb, var(--azul-q) 15%, transparent); color: var(--azul); }
.e-cinza { background: var(--preenche); color: var(--texto-2); }

.selo { flex-shrink: 0; white-space: nowrap; display: inline-flex; align-items: center; gap: 7px; height: 28px; padding: 0 11px; border-radius: 999px; font-size: 13px; font-weight: 600; }
.selo-ok { background: color-mix(in srgb, var(--verde-q) 15%, transparent); color: var(--verde); }
.selo-neutro { background: var(--preenche); color: var(--texto-2); }
.selo .pulso { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.selo-ok .pulso { animation: pulsar 2s infinite; }

.par { justify-content: space-between; }
.par-k { color: var(--texto-2); font-size: 15px; flex-shrink: 0; }
.par-v { text-align: right; font-size: 15px; min-width: 0; overflow-wrap: anywhere; }

/* ---- barras e gráficos -------------------------------------------------------- */

.barra { position: relative; height: 6px; border-radius: 99px; background: var(--preenche); overflow: hidden; }
.barra.grossa { height: 10px; }
.barra i { position: absolute; inset: 0 auto 0 0; width: 0; border-radius: inherit; background: var(--barra-ok); transition: width 1.1s var(--mola) .15s; }
.barra i.azul { background: var(--azul-q); }

.grafico { display: grid; grid-template-columns: repeat(var(--n), minmax(0, 1fr)); gap: 3px; align-items: end; }
.col { display: flex; flex-direction: column; align-items: stretch; gap: 6px; min-width: 0; padding: 0; }
.col-barra { height: 132px; display: flex; flex-direction: column-reverse; gap: 2px; border-radius: 5px; }
.grafico.mini .col-barra { height: 84px; }
.col-barra i { display: block; min-height: 3px; border-radius: 4px; transform-origin: bottom; transform: scaleY(0); transition: transform .7s var(--mola) calc(var(--i) * 14ms + .1s), opacity .2s; }
.col-barra i[style*="height:0%"] { display: none; }
.ok-b { background: var(--barra-ok); }
.pend-b { background: var(--barra-pend); }
.azul-b { background: var(--azul-q); }
.entrou .col-barra i { transform: scaleY(1); }
.col:hover .col-barra i, .col.ativo .col-barra i { opacity: .72; }
.col-rot { height: 14px; font-size: 11px; color: var(--texto-2); text-align: center; font-variant-numeric: tabular-nums; }
.legenda { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-top: 14px; font-size: 13px; color: var(--texto-2); }
.legenda i { display: inline-block; width: 9px; height: 9px; border-radius: 3px; margin-right: 6px; vertical-align: 0; }

.dica {
  position: fixed; z-index: 60; pointer-events: none; white-space: pre-line;
  padding: 8px 11px; border-radius: 12px; font-size: 13px; line-height: 1.4; font-weight: 500;
  background: var(--inverso); color: var(--inverso-txt); box-shadow: 0 8px 30px rgba(0, 0, 0, .18);
  opacity: 0; transform: translate(-50%, calc(-100% - 4px)) scale(.94); transition: opacity .15s, transform .2s var(--mola);
}
.dica.on { opacity: 1; transform: translate(-50%, calc(-100% - 10px)) scale(1); }

.frente { flex-direction: column; align-items: stretch; gap: 8px; padding-top: 14px; padding-bottom: 14px; }
.frente-topo { display: flex; align-items: baseline; gap: 8px; }
.frente-topo .linha-tit { font-weight: 600; }

.rank { overflow: hidden; }
.rank-fundo { position: absolute; inset: 0 auto 0 0; width: 0; background: color-mix(in srgb, var(--azul-q) 9%, transparent); transition: width .9s var(--mola) calc(var(--i) * 40ms + .1s); }
.entrou .rank-fundo { width: var(--w); }
.rank .linha-tit, .rank .nota, .rank strong { position: relative; }
.rank .linha-tit { flex: 1; min-width: 0; }
.rank strong { min-width: 44px; text-align: right; font-size: 15px; }

.ladrilhos { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
@media (min-width: 720px) { .ladrilhos { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.ladrilho { display: flex; flex-direction: column; gap: 8px; padding: 16px; }
.funil { display: flex; flex-direction: column; gap: 16px; }
.funil-topo { display: flex; justify-content: space-between; font-size: 15px; margin-bottom: 7px; }

/* ---- controles ------------------------------------------------------------------ */

.pilulas { display: flex; gap: 8px; overflow-x: auto; margin: 0 -16px; padding: 2px 16px; scrollbar-width: none; scroll-snap-type: x proximity; scroll-padding-inline: 16px; }
.pilulas::-webkit-scrollbar { display: none; }
.pilula {
  flex-shrink: 0; scroll-snap-align: start; display: inline-flex; align-items: center; gap: 6px;
  height: 36px; padding: 0 15px; border-radius: 999px; font-size: 15px; font-weight: 500; white-space: nowrap;
  background: var(--superficie); color: var(--texto); box-shadow: var(--sombra);
  transition: background-color .25s var(--suave), color .25s, transform .2s var(--mola);
}
.pilula .i-p { width: 17px; height: 17px; }
.pilula.on { background: var(--inverso); color: var(--inverso-txt); }
.pilula:active { transform: scale(.95); }

.segmento { display: flex; padding: 2px; gap: 2px; border-radius: 10px; background: var(--preenche); }
.segmento > a, .segmento > button {
  flex: 1; display: flex; align-items: center; justify-content: center; gap: 5px; min-height: 34px; padding: 0 8px;
  border-radius: 8px; font-size: 14px; font-weight: 500; text-align: center; transition: background-color .25s var(--suave), box-shadow .25s;
}
.segmento > a span { color: var(--texto-2); font-weight: 500; font-variant-numeric: tabular-nums; }
.segmento > .on { background: var(--superficie); box-shadow: 0 1px 3px rgba(0, 0, 0, .12), 0 0 0 .5px rgba(0, 0, 0, .04); font-weight: 600; }
:root[data-tema="escuro"] .segmento > .on { background: #636366; }
@media (prefers-color-scheme: dark) { :root:not([data-tema="claro"]) .segmento > .on { background: #636366; } }
.segmento.mini { flex: 0 0 auto; }
.segmento.mini > button { min-height: 30px; font-size: 13px; padding: 0 10px; }

.busca { display: flex; align-items: center; gap: 6px; height: 40px; padding: 0 10px; border-radius: 12px; background: var(--preenche); color: var(--texto-2); }
.busca input { flex: 1; min-width: 0; height: 100%; border: 0; outline: 0; background: none; font-size: 17px; color: var(--texto); }
.busca input::placeholder { color: var(--texto-2); }
.busca input::-webkit-search-cancel-button { filter: grayscale(1); }

.filtro-chip { align-self: flex-start; display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 8px 0 13px; border-radius: 999px; background: color-mix(in srgb, var(--azul-q) 14%, transparent); color: var(--azul); font-size: 14px; font-weight: 600; }
.filtro-chip .i { width: 16px; height: 16px; stroke-width: 2.4; }

.botao-redondo { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: var(--superficie); color: var(--azul); box-shadow: var(--sombra); transition: transform .25s var(--mola); }
.botao-redondo .i { width: 20px; height: 20px; stroke-width: 2.1; }
.botao-redondo:active { transform: scale(.88); }
.botao-redondo.girando .i { animation: girar .8s linear infinite; }
.botao-ico { width: 36px; height: 36px; margin: -6px -8px -6px 0; border-radius: 10px; display: grid; place-items: center; color: var(--azul); flex-shrink: 0; }
.botao-ico .i { width: 19px; height: 19px; }
.botao-ico:active { background: var(--preenche); }

.botao {
  display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; min-height: 52px;
  border-radius: 14px; background: var(--azul); color: #fff; font-size: 17px; font-weight: 600;
  transition: transform .2s var(--mola), filter .2s, opacity .2s;
}
.botao:active { transform: scale(.975); filter: brightness(.92); }
.botao.perigo { background: color-mix(in srgb, #ff3b30 14%, var(--superficie)); color: #e5342a; }
.botao.claro { background: var(--superficie); color: var(--azul); }
.botao[disabled] { opacity: .55; }
.txt { color: var(--azul); font-size: 17px; min-height: 44px; padding: 0 2px; }
.txt.forte { font-weight: 600; }

.campo { display: flex; flex-direction: column; gap: 6px; font-size: 13px; color: var(--texto-2); }
.campo input {
  width: 100%; height: 50px; padding: 0 14px; border: 0; border-radius: 12px; outline: 0;
  background: var(--superficie); font-size: 17px; color: var(--texto); box-shadow: inset 0 0 0 1px transparent; transition: box-shadow .2s;
}
.campo input:focus { box-shadow: inset 0 0 0 2px var(--azul); }

.interruptor { appearance: none; -webkit-appearance: none; position: relative; width: 51px; height: 31px; margin: 0; flex-shrink: 0; border-radius: 99px; background: var(--preenche-2); cursor: pointer; transition: background-color .25s; }
.interruptor::after { content: ""; position: absolute; top: 2px; left: 2px; width: 27px; height: 27px; border-radius: 50%; background: #fff; box-shadow: 0 3px 8px rgba(0, 0, 0, .15), 0 1px 1px rgba(0, 0, 0, .16); transition: transform .3s var(--mola); }
.interruptor:checked { background: var(--verde-q); }
.interruptor:checked::after { transform: translateX(20px); }

.url-linha { align-items: flex-start; }
.url-linha .mono { font-size: 13px; line-height: 1.4; margin-top: 2px; }
.sair { justify-content: center; color: #e5342a; font-weight: 500; gap: 8px; }

/* ---- listas, vazio, carregamento ------------------------------------------------- */

.lista { display: flex; flex-direction: column; }
.venda-linha .linha-fim { gap: 5px; }
.vazio { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 44px 16px; color: var(--texto-2); font-size: 15px; }
.vazio .i { width: 40px; height: 40px; stroke-width: 1.4; color: var(--texto-3); }
.vazio.grande { padding: 90px 16px; }
.vazio-mini { margin: 0; padding: 18px 16px; color: var(--texto-2); font-size: 15px; }
.mais-carga { display: flex; justify-content: center; padding: 18px; }
.giro, .carregando i { display: block; }
.giro { width: 22px; height: 22px; border-radius: 50%; border: 2.5px solid var(--preenche-2); border-top-color: var(--texto-2); animation: girar .7s linear infinite; }

.carregando { position: fixed; inset: 0 0 auto 0; z-index: 80; height: 2.5px; pointer-events: none; padding-top: var(--topo); }
.carregando i { height: 100%; width: 0; background: var(--azul); border-radius: 0 3px 3px 0; opacity: 0; transition: width .5s var(--suave), opacity .3s; }
.carregando.on i { width: 72%; opacity: 1; transition: width 8s cubic-bezier(.1, .7, .1, 1), opacity .1s; }
.carregando.fim i { width: 100%; opacity: 0; transition: width .2s, opacity .35s .2s; }

.esqueleto { background: linear-gradient(90deg, var(--preenche) 0, var(--preenche-2) 40%, var(--preenche) 80%); background-size: 300% 100%; animation: brilho 1.2s infinite linear; border-radius: 12px; }

/* ---- folha (bottom sheet) e avisos -------------------------------------------------- */

.folha-fundo { position: fixed; inset: 0; z-index: 70; background: rgba(0, 0, 0, .32); opacity: 0; transition: opacity .35s var(--suave); }
.folha-fundo.on { opacity: 1; }
.folha {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 71;
  max-height: 88dvh; overflow: auto; padding: 8px 16px calc(var(--baixo) + 20px);
  background: var(--fundo); border-radius: 16px 16px 0 0; box-shadow: 0 -10px 40px rgba(0, 0, 0, .18);
  transform: translateY(105%); transition: transform .5s var(--mola);
  touch-action: pan-y;
}
.folha.on { transform: translateY(0); }
.folha::before { content: ""; display: block; width: 36px; height: 5px; margin: 0 auto 8px; border-radius: 9px; background: var(--preenche-2); }
@media (min-width: 720px) {
  .folha { left: 50%; right: auto; bottom: auto; top: 50%; width: 420px; border-radius: 18px; padding-bottom: 22px; transform: translate(-50%, -46%) scale(.96); opacity: 0; transition: transform .45s var(--mola), opacity .25s; }
  .folha.on { transform: translate(-50%, -50%); opacity: 1; }
  .folha::before { display: none; }
}
.folha-form { display: flex; flex-direction: column; gap: 14px; }
.folha-cab { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; margin-bottom: 2px; }
.folha-cab > :first-child { justify-self: start; }
.folha-cab > :last-child { justify-self: end; }
.folha-cab strong { font-size: 17px; }
.folha-resumo { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 14px 0 6px; }
.folha-resumo strong { font-size: 30px; letter-spacing: -.02em; }
.passos { margin: 4px 0 8px; padding-left: 22px; display: flex; flex-direction: column; gap: 10px; font-size: 16px; }

.avisos { position: fixed; top: calc(var(--topo) + 10px); left: 50%; z-index: 90; display: flex; flex-direction: column; align-items: center; gap: 8px; transform: translateX(-50%); pointer-events: none; width: max-content; max-width: calc(100vw - 32px); }
.aviso {
  display: flex; align-items: center; gap: 10px; padding: 10px 16px 10px 12px; border-radius: 999px;
  background: var(--vidro); backdrop-filter: saturate(180%) blur(24px); -webkit-backdrop-filter: saturate(180%) blur(24px);
  box-shadow: 0 10px 40px rgba(0, 0, 0, .16), 0 0 0 .5px var(--linha); font-size: 15px; font-weight: 500;
  animation: aviso-entra .55s var(--mola) both; pointer-events: auto;
}
.aviso.sai { animation: aviso-sai .3s var(--suave) both; }
.aviso .ico-quad { width: 28px; height: 28px; border-radius: 50%; }
.aviso .ico-quad .i { width: 16px; height: 16px; }
.aviso b { font-variant-numeric: tabular-nums; }
.aviso.venda { padding: 12px 18px 12px 12px; }

/* ---- entrar ------------------------------------------------------------------------ */

.botao.digital { background: var(--inverso); color: var(--inverso-txt); }
.botao.digital .i { width: 24px; height: 24px; }
.ou { display: flex; align-items: center; gap: 12px; color: var(--texto-2); font-size: 13px; }
.ou::before, .ou::after { content: ""; flex: 1; height: .5px; background: var(--linha); }
.digital-anel { width: 76px; height: 76px; margin: 6px auto 2px; border-radius: 50%; display: grid; place-items: center; color: var(--azul); background: color-mix(in srgb, var(--azul-q) 13%, transparent); }
.digital-anel .i { width: 40px; height: 40px; stroke-width: 1.5; }
.folha-titulo { margin: 0; text-align: center; font-size: 20px; font-weight: 700; }
.instalar-faixa { display: flex; align-items: center; gap: 12px; }
.instalar-faixa .linha-txt { flex: 1; }
.botao.mini { width: auto; min-height: 34px; padding: 0 14px; border-radius: 999px; font-size: 14px; }

.tela-entrar { min-height: 100dvh; display: grid; place-items: center; }
.entrar { width: 100%; max-width: 380px; padding: calc(var(--topo) + 24px) 20px calc(var(--baixo) + 24px); display: flex; flex-direction: column; gap: 36px; }
.entrar-marca { display: flex; flex-direction: column; align-items: center; gap: 16px; animation: surgir .8s var(--mola) both; }
.entrar-marca h1 { margin: 0; font-size: 30px; font-weight: 700; letter-spacing: -.025em; }
.app-icone { width: 92px; height: 92px; border-radius: 22px; display: grid; place-items: center; background: var(--inverso); color: var(--inverso-txt); box-shadow: 0 16px 40px rgba(0, 0, 0, .18); }
.app-icone .i { width: 50px; height: 50px; stroke-width: 1.6; }
.entrar-form { display: flex; flex-direction: column; gap: 14px; animation: aparecer .7s var(--mola) .12s both; }
.entrar-form.treme { animation: tremer .45s var(--suave); }
.campos .campo-linha { padding: 0 16px; min-height: 54px; }
.campos .campo-linha + .campo-linha::before { content: ""; position: absolute; top: 0; right: 0; left: 16px; height: .5px; background: var(--linha); }
.campo-linha input { width: 100%; height: 54px; border: 0; outline: 0; background: none; font-size: 17px; }
.campo-linha input::placeholder { color: var(--texto-3); }
.interruptor-linha { justify-content: space-between; cursor: pointer; }
.erro { margin: 0; text-align: center; color: #e5342a; font-size: 15px; }

/* ---- movimento ------------------------------------------------------------------------ */

.entra { animation: aparecer .6s var(--mola) both; animation-delay: calc(var(--i, 0) * 45ms); }
@keyframes aparecer { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes surgir { from { opacity: 0; transform: scale(.82); } to { opacity: 1; transform: none; } }
@keyframes pulsar { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, currentColor 45%, transparent); } 70% { box-shadow: 0 0 0 7px transparent; } 100% { box-shadow: 0 0 0 0 transparent; } }
@keyframes girar { to { transform: rotate(360deg); } }
@keyframes brilho { from { background-position: 100% 0; } to { background-position: -100% 0; } }
@keyframes aviso-entra { from { opacity: 0; transform: translateY(-24px) scale(.9); } to { opacity: 1; transform: none; } }
@keyframes aviso-sai { to { opacity: 0; transform: translateY(-14px) scale(.96); } }
@keyframes tremer { 0%, 100% { transform: none; } 20%, 60% { transform: translateX(-9px); } 40%, 80% { transform: translateX(9px); } }
@keyframes destaque { from { background: color-mix(in srgb, var(--verde-q) 22%, transparent); } to { background: transparent; } }
.novo { animation: destaque 2.4s var(--suave); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; transition-delay: 0s !important; }
}
