/* Rede Blue — design system base. Paleta GQuest filha. */
:root {
  --azul: #1E3A5F;
  --azul-claro: #2E5489;
  --azul-escuro: #142840;
  --offwhite: #F7F8FA;
  --texto: #0F172A;
  --cinza-1: #F1F5F9;
  --cinza-2: #E2E8F0;
  --cinza-3: #CBD5E1;
  --cinza-4: #94A3B8;
  --cinza-5: #64748B;
  --cinza-6: #475569;
  --vermelho: #DC2626;
  --verde: #15803D;
  --amarelo: #CA8A04;
  --sombra-1: 0 1px 2px rgba(15,23,42,.04);
  --sombra-2: 0 1px 3px rgba(15,23,42,.08), 0 1px 2px rgba(15,23,42,.04);
  --sombra-3: 0 4px 12px rgba(15,23,42,.08), 0 2px 4px rgba(15,23,42,.04);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html, body {
  font-family: 'Inter', 'Helvetica Neue', Helvetica, Arial, sans-serif;
  color: var(--texto);
  /* Ativa features tipográficas do Inter: 'l' com cauda, '1' distintivo,
     ligaduras refinadas e numerais tabulares. Eleva o "polimento" visual. */
  font-feature-settings: 'cv11', 'ss01', 'ss03', 'cv02';
}
body {
  background: var(--offwhite); min-height: 100vh;
  font-size: 15px; font-weight: 400; line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

/* Reset universal de elementos de formulário — browsers NÃO herdam
   font/color por default em <input>, <select>, <textarea>, <button>. */
input, select, textarea, button, label, optgroup, option, fieldset, legend {
  font-family: inherit; font-size: inherit; line-height: inherit; color: inherit;
}

a { color: var(--azul); text-decoration: none; }
a:hover { text-decoration: underline; }

/* Headings — hierarquia por peso e tamanho, NÃO por cor.
   Cor primária do texto pra todos; cinza só pra texto auxiliar. */
h1, h2, h3, h4, h5, h6 {
  font-family: inherit; color: var(--texto);
  line-height: 1.2; font-weight: 700;
  letter-spacing: -0.01em;
}
h1 { font-size: 28px; letter-spacing: -0.02em; font-weight: 700; }
h2 { font-size: 20px; }
h3 { font-size: 17px; font-weight: 600; }

p { line-height: 1.6; }
strong, b { font-weight: 600; }

code, pre, kbd, samp {
  font-family: 'JetBrains Mono', 'Courier New', monospace;
  font-size: 0.92em;
}
code {
  padding: 1px 6px; border-radius: 4px;
  background: var(--cinza-1); color: var(--cinza-7, var(--texto));
  font-weight: 500;
}

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 12px 24px; border-radius: 8px;
  font-family: 'Inter', 'Helvetica Neue', Helvetica, Arial, sans-serif;
  font-weight: 600; font-size: 15px; line-height: 1;
  background: var(--azul); color: #fff; border: 0; cursor: pointer;
  transition: background .15s, transform .05s;
  appearance: none; -webkit-appearance: none;
}
.btn:hover { background: var(--azul-claro); text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn-secundario { background: #fff; color: var(--azul); border: 1px solid var(--cinza-2); }
.btn-secundario:hover { background: var(--cinza-1); }
.btn-perigo { background: var(--vermelho); }
.btn-perigo:hover { background: #B91C1C; }

.campo { margin-bottom: 18px; }
.campo label {
  display: block; font-size: 13px; font-weight: 500;
  color: var(--texto); margin-bottom: 6px;
  letter-spacing: -0.005em;
}
.campo label .opcional {
  font-weight: 400; color: var(--cinza-4);
  margin-left: 4px;
}
.campo small, .campo .ajuda-campo {
  display: block; margin-top: 6px;
  color: var(--cinza-5); font-size: 13px; line-height: 1.5;
  font-weight: 400;
}
.campo small code, .campo .ajuda-campo code {
  background: var(--cinza-1); color: var(--cinza-6);
  font-weight: 500;
}
.campo input, .campo select, .campo textarea {
  width: 100%; padding: 11px 14px;
  border: 1px solid var(--cinza-2); border-radius: 8px;
  font-family: inherit; font-size: 15px; font-weight: 400;
  background: #fff; color: var(--texto);
  transition: border-color .12s, box-shadow .12s;
  appearance: none; -webkit-appearance: none; -moz-appearance: none;
}
.campo input:hover, .campo select:hover, .campo textarea:hover {
  border-color: var(--cinza-3);
}
.campo input:focus, .campo select:focus, .campo textarea:focus {
  outline: none; border-color: var(--azul);
  box-shadow: 0 0 0 3px rgba(30,58,95,.10);
}
.campo input::placeholder, .campo textarea::placeholder {
  color: var(--cinza-4); font-weight: 400;
}
.campo input:disabled, .campo select:disabled, .campo textarea:disabled {
  background: var(--cinza-1); color: var(--cinza-5); cursor: not-allowed;
}

/* Layout 2 colunas pra agrupar campos curtos lado a lado */
.campo-duo {
  display: grid; grid-template-columns: 1fr 1fr; gap: 16px;
}

/* Section header — pequeno, sutil, cinza-4 com letter-spacing. */
.titulo-secao {
  font-size: 11px; font-weight: 600;
  color: var(--cinza-4);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin: 32px 0 16px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--cinza-2);
}
.titulo-secao:first-child { margin-top: 0; }

/* Descrição auxiliar de página/seção — cinza-5, leve, sem bold inline */
.descricao-pagina {
  color: var(--cinza-5); font-size: 15px;
  line-height: 1.65; max-width: 640px;
  font-weight: 400;
  margin-bottom: 32px;
}

/* Prefix/suffix dentro de input (ex: <subdomain>.rede.blue) */
.campo-com-sufixo {
  display: flex; align-items: stretch;
  border: 1px solid var(--cinza-2); border-radius: 8px;
  background: #fff; overflow: hidden;
  transition: border-color .12s, box-shadow .12s;
}
.campo-com-sufixo:focus-within {
  border-color: var(--azul);
  box-shadow: 0 0 0 3px rgba(30,58,95,.10);
}
.campo-com-sufixo input {
  flex: 1; border: 0 !important; border-radius: 0 !important;
  background: transparent;
}
.campo-com-sufixo input:focus { box-shadow: none !important; }
.campo-com-sufixo .sufixo {
  display: flex; align-items: center;
  padding: 0 14px; background: var(--cinza-1);
  border-left: 1px solid var(--cinza-2);
  font-family: 'JetBrains Mono', 'Courier New', monospace;
  font-size: 14px; color: var(--cinza-5); font-weight: 500;
  white-space: nowrap;
}

/* Select: setinha SVG própria pra fugir do estilo nativo do SO */
.campo select {
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8' fill='none'><path d='M1 1.5L6 6.5L11 1.5' stroke='%2364748B' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/></svg>");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 38px;
  cursor: pointer;
}
.campo select::-ms-expand { display: none; }
.campo select option { color: var(--texto); background: #fff; }

.alerta {
  padding: 12px 16px; border-radius: 8px; font-size: 14px; margin-bottom: 16px;
  border: 1px solid; line-height: 1.5;
}
.alerta-erro { background: #FEE2E2; border-color: #FECACA; color: #991B1B; }
.alerta-sucesso { background: #DCFCE7; border-color: #BBF7D0; color: #166534; }
.alerta-aviso { background: #FEF3C7; border-color: #FDE68A; color: #854D0E; }
.alerta-info { background: #DBEAFE; border-color: #BFDBFE; color: #1E3A8A; }

.card-auth {
  max-width: 440px; margin: 64px auto; background: #fff;
  padding: 40px; border-radius: 12px; box-shadow: var(--sombra-2);
}
.card-auth .lockup { margin-bottom: 8px; }

/* === LOCKUP: mark + wordmark "Blue" ============================
   REGRA PÉTREA DE PROPORÇÃO — NÃO ALTERAR
   ---------------------------------------------------------------
   Pra cada font-size F do "Blue":
     mark height   = F × 1.4
     gap           = F × 0.25
     letter-spacing= F × -0.038
   Sempre Inter weight 800, cor #1E3A5F (light) ou #e8f4f8 (dark).
   Tabela canônica:
     sm  font 16  → mark 22  gap 4   ls -0.5  (Inter 700)
     md  font 26  → mark 36  gap 6   ls -1.0
     gd  font 40  → mark 56  gap 10  ls -1.5
     xl  font 56  → mark 78  gap 14  ls -2.0
   =============================================================== */
.lockup {
  display: inline-flex; align-items: center;
  text-decoration: none; color: inherit;
}
.lockup img { display: block; }
.lockup .lockup-text {
  font-family: 'Inter', sans-serif; font-weight: 800;
  color: var(--azul); line-height: 1;
}
.lockup.sm { gap: 4px; }
.lockup.sm img { width: 22px; height: 22px; }
.lockup.sm .lockup-text { font-size: 16px; font-weight: 700; letter-spacing: -.5px; }

.lockup.md { gap: 6px; }
.lockup.md img { width: 36px; height: 36px; }
.lockup.md .lockup-text { font-size: 26px; letter-spacing: -1px; }

.lockup.gd { gap: 10px; }
.lockup.gd img { width: 56px; height: 56px; }
.lockup.gd .lockup-text { font-size: 40px; letter-spacing: -1.5px; }

.lockup.xl { gap: 14px; }
.lockup.xl img { width: 78px; height: 78px; }
.lockup.xl .lockup-text { font-size: 56px; letter-spacing: -2px; }

/* === LOADING SPINNER === */
.spinner { display: inline-block; }
.spinner img { width: 32px; height: 32px; }
.spinner.gd img { width: 56px; height: 56px; }
.card-auth .subtitulo { font-size: 14px; color: var(--cinza-5); margin-bottom: 32px; }
.card-auth h1 { font-size: 20px; font-weight: 700; margin-bottom: 8px; color: var(--texto); }
.card-auth .ajuda { font-size: 14px; color: var(--cinza-5); margin-bottom: 24px; line-height: 1.5; }
.card-auth .acoes-extras { margin-top: 24px; font-size: 14px; color: var(--cinza-5); text-align: center; }

.topbar {
  background: #fff; border-bottom: 1px solid var(--cinza-2);
  padding: 14px 32px; display: flex; align-items: center; gap: 12px;
}
.topbar .marca {
  font-size: 12px; color: var(--cinza-4); font-weight: 500;
  letter-spacing: 0.04em; text-transform: uppercase;
}
.topbar .spacer { flex: 1; }
.topbar .usuario {
  font-size: 14px; color: var(--cinza-6); font-weight: 500;
}

.painel { max-width: 1200px; margin: 32px auto; padding: 0 32px 64px; }
.painel-estreito { max-width: 720px; }
.painel h1 { margin-bottom: 8px; }
.painel .descricao { color: var(--cinza-5); font-size: 15px; line-height: 1.6; margin-bottom: 32px; max-width: 640px; }

/* Card branco que envolve um form completo */
.card-form {
  background: #fff; border-radius: 12px;
  padding: 32px; box-shadow: var(--sombra-1);
}

/* Descrição auxiliar dentro de uma seção (menor que descricao-pagina) */
.descricao-secao {
  font-size: 14px; color: var(--cinza-5); line-height: 1.6;
  margin: -8px 0 16px;
  font-weight: 400;
}

/* Footer de form com botões alinhados à direita */
.acoes-form {
  display: flex; gap: 10px; justify-content: flex-end;
  margin-top: 32px; padding-top: 24px;
  border-top: 1px solid var(--cinza-2);
}

/* Botão pequeno — pra usos secundários (voltar, etc.) */
.btn-sm { padding: 7px 14px; font-size: 13px; }

/* Resumo em grid — celas com rótulo pequeno e valor destacado */
.resumo-grid {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 12px; margin-top: 16px;
}
@media (max-width: 700px) {
  .resumo-grid { grid-template-columns: repeat(2, 1fr); }
}
.resumo-cel {
  padding: 14px 16px; background: var(--cinza-1);
  border-radius: 8px;
}
.resumo-destaque {
  background: rgba(30, 58, 95, 0.06);
  border: 1px solid rgba(30, 58, 95, 0.12);
}
.resumo-rotulo {
  color: var(--cinza-4); text-transform: uppercase;
  font-size: 11px; letter-spacing: 0.08em;
  font-weight: 600; margin-bottom: 6px;
}
.resumo-valor {
  font-size: 17px; font-weight: 600;
  color: var(--texto); line-height: 1.2;
}
.resumo-detalhe {
  font-size: 11px; color: var(--cinza-5);
  margin-top: 4px;
}

.tabela { width: 100%; border-collapse: collapse; background: #fff; border-radius: 12px; overflow: hidden; box-shadow: var(--sombra-1); }
.tabela th { text-align: left; padding: 14px 16px; font-size: 12px; font-weight: 600;
              text-transform: uppercase; letter-spacing: .5px; color: var(--cinza-5);
              background: var(--cinza-1); border-bottom: 1px solid var(--cinza-2); }
.tabela td { padding: 16px; font-size: 14px; border-bottom: 1px solid var(--cinza-1); }
.tabela tr:last-child td { border-bottom: 0; }
.tabela tr:hover td { background: var(--cinza-1); }

.vazio { text-align: center; padding: 48px; color: var(--cinza-5); background: #fff; border-radius: 12px; box-shadow: var(--sombra-1); }
.vazio .emoji { font-size: 48px; margin-bottom: 8px; }

.tag {
  display: inline-block; padding: 4px 10px; border-radius: 999px;
  font-size: 12px; font-weight: 600; letter-spacing: .3px;
}
.tag-azul { background: #DBEAFE; color: #1E40AF; }
.tag-verde { background: #DCFCE7; color: #166534; }
.tag-vermelho { background: #FEE2E2; color: #991B1B; }
.tag-amarelo { background: #FEF3C7; color: #854D0E; }
.tag-cinza { background: var(--cinza-1); color: var(--cinza-6); }

.codigo-recovery { font-family: 'Courier New', monospace; font-size: 14px;
                    background: var(--cinza-1); padding: 4px 8px; border-radius: 4px; }

/* ============================================================
   Filtros de listagem — linha com busca + selects + botão
   ============================================================ */
.filtros-linha {
  display: flex; align-items: center; gap: 12px;
  margin-top: 24px; flex-wrap: wrap;
}
.filtros-linha .filtro-busca {
  flex: 1; min-width: 240px;
  padding: 10px 14px; border: 1px solid var(--cinza-2);
  border-radius: 8px; background: #fff;
  font-family: inherit; font-size: 14px;
}
.filtros-linha .filtro-busca:focus {
  outline: none; border-color: var(--azul);
  box-shadow: 0 0 0 3px rgba(30,58,95,.10);
}
.filtros-linha select {
  padding: 10px 36px 10px 14px;
  border: 1px solid var(--cinza-2); border-radius: 8px;
  background: #fff;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8' fill='none'><path d='M1 1.5L6 6.5L11 1.5' stroke='%2364748B' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/></svg>");
  background-repeat: no-repeat;
  background-position: right 14px center;
  font-family: inherit; font-size: 14px;
  appearance: none; -webkit-appearance: none; cursor: pointer;
}
.filtros-linha .link-limpar {
  font-size: 13px; color: var(--cinza-5);
}

/* Paginação no rodapé de tabelas */
.paginacao {
  display: flex; align-items: center; justify-content: space-between;
  margin-top: 16px; padding: 12px 4px;
  font-size: 13px; color: var(--cinza-5);
}
.paginacao-botoes { display: flex; gap: 6px; }

/* ============================================================
   Dashboard cards — ícone, título, descrição, contador
   ============================================================ */
.dashboard-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px; margin-top: 8px;
}
.card-feature {
  display: block; padding: 24px;
  background: #fff; border-radius: 12px;
  box-shadow: var(--sombra-1);
  border: 1px solid var(--cinza-2);
  transition: transform .15s, box-shadow .15s, border-color .15s;
  text-decoration: none; color: inherit;
}
.card-feature:hover {
  transform: translateY(-2px);
  box-shadow: var(--sombra-2);
  border-color: var(--cinza-3);
  text-decoration: none;
}
.card-feature.card-feature-disabled {
  opacity: .55; cursor: default;
}
.card-feature.card-feature-disabled:hover { transform: none; box-shadow: var(--sombra-1); }
.card-feature-emoji { font-size: 28px; margin-bottom: 8px; }
.card-feature h3 { font-size: 16px; font-weight: 700; margin-bottom: 4px; color: var(--texto); }
.card-feature p { font-size: 13px; color: var(--cinza-5); line-height: 1.5; margin-bottom: 12px; }
.card-feature-count {
  font-size: 12px; font-weight: 600; color: var(--azul);
  text-transform: uppercase; letter-spacing: 0.04em;
}

.painel-info {
  margin-top: 32px; padding: 20px;
  background: var(--cinza-1); border-radius: 10px;
  font-size: 13px; color: var(--cinza-6); line-height: 1.6;
}

/* ============================================================
   Parceiro — detalhe (header + grid 2 colunas)
   ============================================================ */
.parceiro-header {
  display: flex; align-items: center; gap: 20px;
  padding: 24px; background: #fff; border-radius: 12px;
  box-shadow: var(--sombra-1); margin-bottom: 24px;
  flex-wrap: wrap;
}
.parceiro-logo {
  width: 80px; height: 80px; border-radius: 12px;
  object-fit: cover; background: var(--cinza-1);
}
.parceiro-logo-vazio {
  width: 80px; height: 80px; border-radius: 12px;
  background: linear-gradient(135deg, var(--azul) 0%, var(--azul-claro) 100%);
  color: #fff; display: grid; place-items: center;
  font-size: 32px; font-weight: 700;
}
.parceiro-header h1 { margin-bottom: 4px; }
.parceiro-sub {
  color: var(--cinza-5); font-size: 14px;
  display: flex; align-items: center; gap: 6px; flex-wrap: wrap;
}
.parceiro-sub .tag { margin-left: 0; }
.parceiro-acoes {
  display: flex; gap: 8px; flex-wrap: wrap;
}

.parceiro-grid {
  display: grid; grid-template-columns: 1.6fr 1fr; gap: 24px;
}
@media (max-width: 980px) {
  .parceiro-grid { grid-template-columns: 1fr; }
}
.parceiro-coluna-esquerda, .parceiro-coluna-direita {
  display: flex; flex-direction: column; gap: 16px;
}
.card-secao {
  background: #fff; border-radius: 12px; padding: 24px;
  box-shadow: var(--sombra-1);
}

.dados-lista { display: grid; grid-template-columns: 130px 1fr; gap: 10px 16px; font-size: 14px; }
.dados-lista dt { color: var(--cinza-5); font-weight: 500; }
.dados-lista dd { color: var(--texto); word-break: break-word; }

.tabela-compacta { width: 100%; border-collapse: collapse; }
.tabela-compacta td { padding: 12px 0; border-bottom: 1px solid var(--cinza-1); font-size: 14px; }
.tabela-compacta tr:last-child td { border-bottom: 0; }

.lista-scanners { list-style: none; padding: 0; margin: 0; }
.lista-scanners li {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--cinza-1);
}
.lista-scanners li:last-child { border-bottom: 0; }
.lista-scanners li > div:first-child { flex: 1; font-size: 14px; line-height: 1.5; }

/* ============================================================
   Oferta — radio cards (tipo de desconto)
   ============================================================ */
.opcoes-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 10px;
}
.opcao-card {
  display: flex; align-items: flex-start; gap: 10px;
  padding: 14px; border: 1px solid var(--cinza-2);
  border-radius: 8px; cursor: pointer;
  transition: border-color .12s, background .12s, box-shadow .12s;
  background: #fff;
}
.opcao-card:hover { border-color: var(--cinza-3); }
.opcao-card input[type="radio"] {
  margin: 4px 0 0 0; accent-color: var(--azul);
}
.opcao-card:has(input:checked) {
  border-color: var(--azul); background: rgba(30,58,95,.04);
  box-shadow: 0 0 0 3px rgba(30,58,95,.08);
}
.opcao-card-body { flex: 1; }
.opcao-titulo { font-size: 14px; font-weight: 600; }
.opcao-sub { font-size: 12px; color: var(--cinza-5); margin-top: 2px; line-height: 1.4; }

/* ============================================================
   Card de fluxo de importação (hub de elegíveis)
   ============================================================ */
.card-import {
  display: flex; align-items: center; gap: 20px;
  padding: 20px 24px; background: #fff; border-radius: 12px;
  box-shadow: var(--sombra-1); border: 1px solid var(--cinza-2);
  text-decoration: none; color: inherit;
  transition: border-color .15s, transform .15s, box-shadow .15s;
}
.card-import:hover {
  border-color: var(--azul);
  transform: translateY(-1px);
  box-shadow: var(--sombra-2);
  text-decoration: none;
}
.card-import.card-import-soon:hover { border-color: var(--cinza-3); transform: none; }
.card-import-icon {
  font-size: 32px; flex: 0 0 56px; text-align: center;
}
.card-import h3 { font-size: 16px; font-weight: 700; margin-bottom: 4px; }
.card-import p { font-size: 13px; color: var(--cinza-5); line-height: 1.5; margin-bottom: 0; }
.card-import-cta {
  font-size: 14px; font-weight: 600; color: var(--azul);
  white-space: nowrap;
}

textarea {
  width: 100%; padding: 11px 14px;
  border: 1px solid var(--cinza-2); border-radius: 8px;
  font-family: inherit; font-size: 14px; line-height: 1.5;
  background: #fff; color: var(--texto);
  transition: border-color .12s, box-shadow .12s;
  resize: vertical;
}
textarea:focus {
  outline: none; border-color: var(--azul);
  box-shadow: 0 0 0 3px rgba(30,58,95,.10);
}

/* ============================================================
   PWA cliente final — mobile-first layout
   ============================================================ */
body.pwa-shell {
  background: var(--offwhite); padding: 0;
}
body.pwa-shell .pwa-header {
  position: sticky; top: 0; z-index: 20;
  background: #fff; border-bottom: 1px solid var(--cinza-2);
  padding: 12px 16px;
  display: flex; align-items: center; gap: 12px;
}
.pwa-header-tenant {
  flex: 1; text-align: right;
  font-size: 12px; color: var(--cinza-5); font-weight: 500;
  letter-spacing: 0.02em; text-transform: uppercase;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.pwa-main {
  max-width: 560px; margin: 0 auto;
  padding: 20px 16px 96px;
}
.pwa-bottom-nav {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 30;
  background: #fff; border-top: 1px solid var(--cinza-2);
  display: flex; justify-content: space-around;
  padding: 8px 4px 12px;
  padding-bottom: calc(8px + env(safe-area-inset-bottom));
  max-width: 100%;
}
.pwa-nav-item {
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  text-decoration: none; color: var(--cinza-5); font-size: 11px; font-weight: 500;
  padding: 6px 12px; border-radius: 8px; flex: 1; text-align: center;
}
.pwa-nav-item.ativo { color: var(--azul); }
.pwa-nav-item:hover { text-decoration: none; }
.pwa-nav-icon { font-size: 22px; line-height: 1; }
.pwa-nav-label { font-size: 11px; }

.pwa-h1 {
  font-size: 26px; font-weight: 700; margin-bottom: 4px;
  letter-spacing: -0.02em;
}
.pwa-sub {
  color: var(--cinza-5); font-size: 14px; margin-bottom: 24px;
}
.pwa-secao {
  font-size: 12px; font-weight: 600;
  color: var(--cinza-5); text-transform: uppercase;
  letter-spacing: 0.08em; margin: 28px 0 12px;
}
.pwa-tag {
  display: inline-block; padding: 4px 12px; border-radius: 999px;
  background: var(--cinza-1); color: var(--cinza-6);
  font-size: 12px; font-weight: 500;
}
.pwa-voltar {
  display: inline-block; margin-bottom: 16px;
  font-size: 13px; color: var(--cinza-5);
}

.pwa-filtros { display: flex; gap: 8px; margin-bottom: 16px; }
.pwa-busca {
  flex: 1; padding: 10px 14px; border: 1px solid var(--cinza-2);
  border-radius: 8px; font-family: inherit; font-size: 14px; background: #fff;
}
.pwa-busca:focus { outline: none; border-color: var(--azul);
                    box-shadow: 0 0 0 3px rgba(30,58,95,.10); }
.pwa-select {
  padding: 10px 32px 10px 12px; border: 1px solid var(--cinza-2);
  border-radius: 8px; font-family: inherit; font-size: 13px; background: #fff;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8' fill='none'><path d='M1 1.5L6 6.5L11 1.5' stroke='%2364748B' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/></svg>");
  background-repeat: no-repeat; background-position: right 10px center;
  appearance: none; -webkit-appearance: none;
}

.pwa-vouchers-lista { display: flex; flex-direction: column; gap: 12px; }
.voucher-card {
  display: block; padding: 16px; background: #fff;
  border-radius: 14px; border: 1px solid var(--cinza-2);
  text-decoration: none; color: inherit;
  transition: border-color .15s, transform .12s;
}
.voucher-card:hover {
  border-color: var(--cinza-3); text-decoration: none;
  transform: translateY(-1px);
}
.voucher-card-header { display: flex; align-items: center; gap: 12px; }
.voucher-card-logo {
  width: 48px; height: 48px; border-radius: 10px;
  object-fit: cover; background: var(--cinza-1); flex-shrink: 0;
}
.voucher-card-logo-vazio {
  background: linear-gradient(135deg, var(--azul) 0%, var(--azul-claro) 100%);
  color: #fff; display: grid; place-items: center;
  font-size: 20px; font-weight: 700;
}
.voucher-card-partner { font-size: 12px; color: var(--cinza-5); text-transform: uppercase; letter-spacing: 0.04em; font-weight: 600; }
.voucher-card-titulo { font-size: 16px; font-weight: 600; margin-top: 2px; }
.voucher-card-desconto {
  font-size: 20px; font-weight: 800; color: var(--azul);
  background: rgba(30,58,95,.08); padding: 8px 12px;
  border-radius: 8px; min-width: 56px; text-align: center; line-height: 1.1;
  white-space: nowrap;
}
.voucher-card-desconto-claro { background: var(--cinza-1); color: var(--cinza-6); }
.voucher-card-footer { margin-top: 12px; font-size: 12px; color: var(--cinza-5); }
.voucher-card-footer-action { margin-top: 12px; }
.voucher-card-sugestao { border-style: dashed; }

.parceiros-grid { display: grid; grid-template-columns: 1fr; gap: 12px; }
.parceiro-mini-card {
  display: flex; align-items: center; gap: 12px;
  background: #fff; border: 1px solid var(--cinza-2); border-radius: 12px;
  padding: 14px; text-decoration: none; color: inherit;
  transition: border-color .15s;
}
.parceiro-mini-card:hover { border-color: var(--azul); text-decoration: none; }
.parceiro-mini-logo {
  width: 56px; height: 56px; border-radius: 12px;
  object-fit: cover; background: var(--cinza-1); flex-shrink: 0;
}
.parceiro-mini-logo-vazio {
  background: linear-gradient(135deg, var(--azul) 0%, var(--azul-claro) 100%);
  color: #fff; display: grid; place-items: center;
  font-size: 22px; font-weight: 700;
}
.parceiro-mini-info { flex: 1; min-width: 0; }
.parceiro-mini-nome { font-size: 15px; font-weight: 600; }
.parceiro-mini-meta { font-size: 12px; color: var(--cinza-5); margin-top: 2px; }
.parceiro-mini-ofertas { font-size: 12px; color: var(--azul); margin-top: 4px; font-weight: 500; }

.parceiro-pwa-header {
  text-align: center; padding: 16px 0 24px;
  border-bottom: 1px solid var(--cinza-2);
}
.parceiro-pwa-logo {
  width: 88px; height: 88px; border-radius: 16px;
  object-fit: cover; margin: 0 auto; background: var(--cinza-1);
}
.parceiro-pwa-logo-vazio {
  background: linear-gradient(135deg, var(--azul) 0%, var(--azul-claro) 100%);
  color: #fff; display: grid; place-items: center;
  font-size: 36px; font-weight: 700;
}
.parceiro-pwa-contato {
  display: flex; flex-direction: column; gap: 6px;
  background: var(--cinza-1); border-radius: 10px; padding: 14px;
  margin: 16px 0; font-size: 13px; color: var(--cinza-6);
}
.oferta-card {
  background: #fff; border: 1px solid var(--cinza-2);
  border-radius: 12px; padding: 16px;
}
.oferta-card-titulo { font-size: 16px; font-weight: 600; }
.oferta-card-desconto {
  font-size: 13px; color: var(--azul); font-weight: 500; margin-top: 4px;
}
.oferta-card-desc { font-size: 13px; color: var(--cinza-5); margin-top: 8px; line-height: 1.5; }

.voucher-tela-cheia {
  min-height: 100vh; background: #fff;
  display: flex; flex-direction: column;
  padding: 16px 20px 32px; position: relative;
}
.voucher-fechar {
  position: absolute; top: 16px; right: 16px;
  width: 40px; height: 40px; border-radius: 50%;
  background: var(--cinza-1); color: var(--cinza-6);
  display: grid; place-items: center; font-size: 24px;
  text-decoration: none; font-weight: 400;
}
.voucher-fechar:hover { background: var(--cinza-2); text-decoration: none; }
.voucher-info-topo { text-align: center; margin-top: 32px; }
.voucher-parceiro-nome {
  font-size: 12px; color: var(--cinza-5); text-transform: uppercase;
  font-weight: 600; letter-spacing: 0.08em;
}
.voucher-oferta-titulo { font-size: 20px; font-weight: 700; margin-top: 4px; }
.voucher-oferta-desconto { font-size: 14px; color: var(--azul); font-weight: 500; margin-top: 4px; }
.voucher-qr-wrap {
  flex: 1; display: flex; flex-direction: column; align-items: center;
  justify-content: center; gap: 16px; padding: 24px 0;
}
.voucher-qr {
  width: 280px; height: 280px; max-width: 75vw; max-height: 75vw;
  background: #fff; padding: 8px;
  border-radius: 12px; box-shadow: var(--sombra-3);
}
.voucher-qr-info { text-align: center; }
#qr-rotacao-status { font-size: 12px; color: var(--cinza-5); }
.voucher-codigo {
  font-family: 'JetBrains Mono','Courier New',monospace;
  font-size: 16px; font-weight: 600; letter-spacing: 2px;
  margin-top: 8px; color: var(--cinza-6);
}
.voucher-info-rodape {
  text-align: center; font-size: 14px; color: var(--cinza-6);
  padding-top: 16px; border-top: 1px solid var(--cinza-2);
}

.historico-lista { display: flex; flex-direction: column; gap: 12px; }
.historico-item {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 14px; background: #fff; border-radius: 12px;
  border: 1px solid var(--cinza-2);
}
.historico-logo {
  width: 40px; height: 40px; border-radius: 8px;
  object-fit: cover; background: var(--cinza-1); flex-shrink: 0;
}
.historico-logo-vazio {
  background: linear-gradient(135deg, var(--azul) 0%, var(--azul-claro) 100%);
  color: #fff; display: grid; place-items: center;
  font-size: 16px; font-weight: 700;
}
.historico-info { flex: 1; min-width: 0; }
.historico-partner { font-size: 11px; color: var(--cinza-5); font-weight: 600; text-transform: uppercase; }
.historico-oferta { font-size: 14px; font-weight: 500; margin-top: 2px; }
.historico-meta { font-size: 12px; color: var(--cinza-5); margin-top: 4px; }
.historico-status { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; }

.perfil-card { text-align: center; padding: 24px; background: #fff; border-radius: 16px; margin-bottom: 16px; }
.perfil-avatar {
  width: 80px; height: 80px; border-radius: 50%; margin: 0 auto;
  background: linear-gradient(135deg, var(--azul) 0%, var(--azul-claro) 100%);
  color: #fff; display: grid; place-items: center;
  font-size: 32px; font-weight: 700;
}
.perfil-info { background: #fff; border-radius: 12px; padding: 4px 16px; }
.perfil-info-item {
  display: flex; justify-content: space-between; align-items: center;
  padding: 14px 0; border-bottom: 1px solid var(--cinza-1);
  font-size: 14px;
}
.perfil-info-item:last-child { border-bottom: 0; }
.perfil-info-item span { color: var(--cinza-5); }

/* Scanner do parceiro */
#scanner-box { position: relative; }
.scanner-status {
  position: absolute; bottom: 12px; left: 50%; transform: translateX(-50%);
  background: rgba(0,0,0,.75); color: #fff; padding: 8px 16px;
  border-radius: 999px; font-size: 13px; font-weight: 500;
}
.scanner-status-ok { background: var(--verde); }
.scanner-status-erro { background: var(--vermelho); }

/* ============================================================
   Landing pública do tenant + público sem auth
   ============================================================ */
.landing-tenant {
  max-width: 1100px; margin: 0 auto; padding: 32px 24px 64px;
}
.landing-tenant-hero {
  text-align: center; padding: 48px 24px 64px;
}
.landing-tenant-tenant {
  font-size: 12px; color: var(--cinza-5); font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.12em;
  margin-top: 16px;
}
.landing-tenant-hero h1 {
  font-size: 44px; font-weight: 800;
  letter-spacing: -0.03em; margin-top: 8px;
  background: linear-gradient(135deg, var(--azul) 0%, var(--azul-claro) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.landing-tenant-sub {
  font-size: 17px; color: var(--cinza-6); line-height: 1.55;
  max-width: 560px; margin: 16px auto 32px;
}
.landing-tenant-cta {
  display: flex; gap: 12px; justify-content: center; flex-wrap: wrap;
}
.landing-tenant-secao { margin-top: 64px; }
.landing-tenant-secao h2 {
  font-size: 24px; font-weight: 700; letter-spacing: -0.01em;
}
.landing-tenant-secao-sub {
  color: var(--cinza-5); font-size: 14px; margin-top: 4px; margin-bottom: 24px;
}
.landing-tenant-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
}
.landing-tenant-footer {
  text-align: center; padding: 48px 0 16px;
  border-top: 1px solid var(--cinza-2); margin-top: 48px;
}

.public-header {
  background: #fff; border-bottom: 1px solid var(--cinza-2);
  padding: 14px 24px; display: flex; align-items: center; gap: 12px;
  position: sticky; top: 0; z-index: 20;
}
.public-header-tenant {
  font-size: 12px; color: var(--cinza-5); font-weight: 500;
  letter-spacing: 0.04em; text-transform: uppercase;
}
.public-header .spacer { flex: 1; }
