/* Visual inspirado na Liga Pokémon: fundo claro, vermelho #C21515, azul #0085FF,
   preços em verde (menor), laranja (médio) e vermelho (maior). */
:root {
  --red: #c21515;
  --red-soft: #fdecec;
  --blue: #0085ff;
  --blue-soft: #e6f3ff;
  --bg: #f2f3f5;
  --card: #ffffff;
  --line: #e2e5e9;
  --text: #1f2328;
  --muted: #6b7280;
  --p-min: #1f9d49;
  --p-avg: #f08a00;
  --p-max: #d93025;
  --gold: #b7791f;
  --radius: 12px;
  --shadow: 0 1px 2px rgba(16,24,40,.06), 0 1px 3px rgba(16,24,40,.08);
  color-scheme: light;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; min-height: 100%; }
body {
  font: 15px/1.45 "Segoe UI", Roboto, system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  overscroll-behavior-y: contain;
}
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: var(--blue); }
img { max-width: 100%; }
[hidden] { display: none !important; }

/* ===== Topo ===== */
.topbar {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: calc(env(safe-area-inset-top, 0px) + 8px) 16px 8px;
  background: #fff;
  border-bottom: 1px solid var(--line);
}
.logo { height: 38px; width: auto; display: block; }
.trainer {
  display: flex; align-items: center; gap: 8px; min-width: 0;
  background: none; border: 1px solid var(--line); border-radius: 99px; padding: 5px 12px 5px 8px;
  color: var(--red); text-align: left;
}
.trainer span { display: flex; flex-direction: column; line-height: 1.1; min-width: 0; }
.trainer small { font-size: 10.5px; color: var(--muted); text-transform: uppercase; letter-spacing: .5px; }
.trainer b { color: var(--text); font-size: 14px; max-width: 130px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.subbar {
  position: sticky; top: calc(env(safe-area-inset-top, 0px) + 55px); z-index: 19;
  background: var(--red); color: #fff; padding: 8px 16px;
}
.subbar h1 { margin: 0 auto; font-size: 16px; font-weight: 700; max-width: 900px; }
.busy {
  position: absolute; left: 0; right: 0; bottom: 0; height: 3px;
  background: linear-gradient(90deg, transparent, #fff, transparent);
  background-size: 50% 100%; background-repeat: no-repeat;
  animation: busy 1.1s linear infinite;
}
@keyframes busy { from { background-position: -50% 0; } to { background-position: 150% 0; } }

/* ===== Conteúdo ===== */
main {
  padding: 14px 16px calc(env(safe-area-inset-bottom, 0px) + 86px);
  max-width: 900px; margin: 0 auto;
}
h2 { font-size: 18px; margin: 18px 0 10px; }
h3 {
  font-size: 13px; margin: 20px 0 8px; color: var(--red); text-transform: uppercase; letter-spacing: .6px;
  border-left: 3px solid var(--red); padding-left: 8px;
}
.muted { color: var(--muted); }
.small { font-size: 12.5px; }
.center { text-align: center; }

/* ===== Abas inferiores ===== */
.tabs {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 20;
  display: grid; grid-template-columns: repeat(4, 1fr);
  background: #fff; border-top: 1px solid var(--line);
  padding-bottom: env(safe-area-inset-bottom, 0px);
  box-shadow: 0 -2px 10px rgba(0,0,0,.05);
}
.tabs button {
  background: none; border: 0; padding: 7px 0 8px; position: relative;
  color: var(--muted); font-size: 11.5px; font-weight: 600;
  display: flex; flex-direction: column; align-items: center; gap: 2px;
}
.tabs svg { width: 24px; height: 24px; }
.tabs button.on { color: var(--red); }
.tabs button.on::before {
  content: ""; position: absolute; top: -1px; left: 25%; right: 25%; height: 3px; background: var(--red); border-radius: 0 0 3px 3px;
}

/* ===== Blocos ===== */
.strip { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 12px; }
.stat {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 10px 12px; box-shadow: var(--shadow);
}
.stat b { display: block; font-size: 20px; font-variant-numeric: tabular-nums; }
.stat span { font-size: 12px; color: var(--muted); }
.stat.hero { grid-column: 1 / -1; border-top: 3px solid var(--red); }
.stat.hero b { font-size: 28px; color: var(--red); }
.up { color: var(--p-min); } .down { color: var(--p-max); }

.toolbar { display: flex; gap: 8px; margin-bottom: 12px; flex-wrap: wrap; }
.toolbar input { flex: 1 1 180px; }
input[type=search], input[type=text], input[type=password], select, .input {
  background: #fff; border: 1px solid #cfd4da; border-radius: 8px;
  padding: 10px 12px; min-width: 0; outline: none;
}
input:focus, select:focus, input[type=password]:focus { border-color: var(--blue); box-shadow: 0 0 0 3px var(--blue-soft); }

.btn {
  border: 0; border-radius: 8px; padding: 12px 16px; font-weight: 700;
  background: #fff; color: var(--text); border: 1px solid #cfd4da; text-decoration: none;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
}
.btn.primary { background: var(--red); border-color: var(--red); color: #fff; }
.btn.blue { background: var(--blue); border-color: var(--blue); color: #fff; }
.btn.green { background: var(--p-min); border-color: var(--p-min); color: #fff; }
.btn.danger { background: #fff; border-color: var(--p-max); color: var(--p-max); }
.btn.block { width: 100%; }
.btn:disabled { opacity: .55; }
.btn svg { width: 20px; height: 20px; }
.btn-sm {
  border: 1px solid var(--blue); background: #fff; border-radius: 7px; color: var(--blue);
  padding: 6px 10px; font-size: 13px; font-weight: 600; text-decoration: none; white-space: nowrap;
}
.linkbtn { background: none; border: 0; color: var(--blue); font-weight: 600; padding: 8px; text-decoration: underline; }

.seg { display: flex; background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 3px; margin-bottom: 12px; }
.seg button { flex: 1; border: 0; background: none; padding: 9px; border-radius: 8px; color: var(--muted); font-weight: 700; }
.seg button.on { background: var(--red); color: #fff; }

.photo-cta {
  background: #fff; border: 2px dashed #f0b4b4; border-radius: var(--radius); padding: 14px; margin-bottom: 14px; text-align: center;
}
.photo-cta p { margin: 8px 0 0; font-size: 12.5px; color: var(--muted); }
.or { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 12px; margin: 4px 0 12px; }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--line); }

/* ===== Grade de cartas (Pokédex) ===== */
.grid { display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); }
.tile {
  position: relative; text-align: left;
  background: var(--card); border: 1px solid var(--line); border-radius: 10px; box-shadow: var(--shadow);
  padding: 6px 6px 8px; display: flex; flex-direction: column; gap: 3px;
}
.tile:active { transform: scale(.97); }
.tile .img, .dimg, .thumb {
  aspect-ratio: 63 / 88; width: 100%; border-radius: 6px; overflow: hidden;
  background: repeating-linear-gradient(45deg, #eef0f3 0 8px, #e6e9ed 8px 16px);
  display: grid; place-items: center; color: var(--muted); font-size: 11px;
}
.tile .img img, .dimg img, .thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.dexno {
  position: absolute; top: 10px; left: 10px; z-index: 1;
  background: var(--red); color: #fff; font-weight: 700;
  font-size: 11px; padding: 1px 6px; border-radius: 5px; font-variant-numeric: tabular-nums;
}
.qty {
  position: absolute; top: 10px; right: 10px; z-index: 1;
  background: var(--blue); color: #fff; font-weight: 700; font-size: 11px; padding: 1px 6px; border-radius: 5px;
}
.tname { font-size: 12.5px; font-weight: 700; line-height: 1.2; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; margin-top: 2px; }
.tsub { font-size: 11px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tprice { font-size: 13.5px; font-weight: 800; color: var(--p-min); font-variant-numeric: tabular-nums; }
.tprice small { font-weight: 600; color: var(--muted); font-size: 10px; }

.empty {
  text-align: center; color: var(--muted); padding: 34px 16px; background: #fff;
  border: 1px dashed #cfd4da; border-radius: var(--radius);
}
.empty .big { display: block; margin: 0 auto 8px; width: 48px; height: 48px; color: #d7dbe0; }

/* ===== Listas ===== */
.list { display: flex; flex-direction: column; gap: 8px; }
.row {
  display: grid; grid-template-columns: 48px 1fr auto; gap: 10px; align-items: center;
  background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 8px; box-shadow: var(--shadow);
}
.row .thumb { width: 48px; }
.row .info { min-width: 0; }
.row .info b { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 14px; }
.row .right { text-align: right; display: flex; flex-direction: column; gap: 6px; align-items: flex-end; }
.row .val { font-weight: 800; color: var(--p-min); font-variant-numeric: tabular-nums; }
.mine-btn { border: 1px solid var(--p-min); color: #fff; background: var(--p-min); border-radius: 7px; padding: 5px 8px; font-size: 12px; font-weight: 700; white-space: nowrap; }
.plain-row { display: flex; justify-content: space-between; gap: 10px; padding: 9px 2px; border-bottom: 1px solid var(--line); font-size: 14px; }
.plain-row:last-child { border-bottom: 0; }
.plain-row .v { font-variant-numeric: tabular-nums; white-space: nowrap; font-weight: 600; }
.box { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 6px 12px; box-shadow: var(--shadow); }
.total-bar {
  display: flex; justify-content: space-between; align-items: center;
  background: #fff; border: 1px solid var(--line); border-left: 4px solid var(--p-min); border-radius: 10px; padding: 12px 14px; margin-bottom: 10px;
}
.total-bar b { color: var(--p-min); font-size: 18px; }

.progress { height: 8px; background: #e6e9ed; border-radius: 99px; overflow: hidden; margin: 8px 0; }
.progress i { display: block; height: 100%; background: var(--red); transition: width .2s; }

/* ===== Preços estilo Liga (menor / médio / maior) ===== */
.pbox { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 12px; margin-bottom: 10px; box-shadow: var(--shadow); }
.pbox.used { border: 2px solid var(--p-min); }
.pbox-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.pbox-head b { font-size: 15px; }
.pbox-head small { display: block; color: var(--muted); font-size: 11.5px; font-weight: 400; }
.tag-used { background: var(--p-min); color: #fff; font-size: 10.5px; font-weight: 700; padding: 1px 6px; border-radius: 4px; margin-left: 4px; vertical-align: 2px; }
.ptriple { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.pchip { border-radius: 7px; overflow: hidden; text-align: center; border: 1px solid; background: #fff; }
.pchip > span { display: block; color: #fff; font-size: 11px; font-weight: 700; text-transform: uppercase; padding: 3px 0; letter-spacing: .4px; }
.pchip > b, .pchip > input { display: block; width: 100%; padding: 7px 4px; font-size: 14px; font-weight: 800; text-align: center; font-variant-numeric: tabular-nums; }
.pchip > input { border: 0; outline: none; background: #fff; }
.pchip > input:focus { background: #fffbe6; }
.pchip.min { border-color: var(--p-min); } .pchip.min > span { background: var(--p-min); } .pchip.min > b { color: var(--p-min); }
.pchip.avg { border-color: var(--p-avg); } .pchip.avg > span { background: var(--p-avg); } .pchip.avg > b { color: var(--p-avg); }
.pchip.max { border-color: var(--p-max); } .pchip.max > span { background: var(--p-max); } .pchip.max > b { color: var(--p-max); }
.pchip.pick { box-shadow: 0 0 0 2px var(--text); }
.pnote { font-size: 11.5px; color: var(--muted); margin: 6px 0 0; }

/* ===== Folha de detalhes ===== */
.sheet { position: fixed; inset: 0; z-index: 50; }
.sheet-backdrop { position: absolute; inset: 0; background: rgba(15,20,30,.55); animation: fade .2s; }
/* No celular a carta abre em tela cheia, com o cabeçalho "Voltar" sempre visível */
.sheet-panel {
  position: absolute; inset: 0; display: flex; flex-direction: column;
  background: var(--bg); animation: up .2s ease-out;
  height: 100%; height: 100dvh;
}
.sheet-head {
  flex: none; display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: calc(env(safe-area-inset-top, 0px) + 8px) 12px 8px;
  background: #fff; border-bottom: 3px solid var(--red); box-shadow: 0 2px 8px rgba(0,0,0,.08);
}
.sheet-back {
  border: 0; background: var(--red); color: #fff; font-weight: 700; font-size: 15px;
  padding: 10px 16px; border-radius: 8px;
}
.sheet-close {
  width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--line); background: #fff; font-size: 18px; flex: none;
}
.sheet-scroll {
  flex: 1; overflow-y: auto; -webkit-overflow-scrolling: touch; overscroll-behavior: contain;
  padding: 14px 16px calc(env(safe-area-inset-bottom, 0px) + 24px);
}
@media (min-width: 700px) {
  .sheet-panel {
    inset: auto 0 0 0; height: auto; max-height: 94vh; max-height: 94dvh;
    max-width: 640px; margin: 0 auto; border-radius: 18px 18px 0 0; overflow: hidden;
  }
}
@keyframes up { from { transform: translateY(30px); opacity: 0; } }
@keyframes fade { from { opacity: 0; } }
.dimg { max-width: 240px; margin: 0 auto 12px; border-radius: 12px; box-shadow: 0 8px 24px rgba(0,0,0,.25); }
.detail h2 { text-align: center; margin: 6px 0 2px; font-size: 21px; }
.detail .meta { text-align: center; color: var(--muted); margin: 0 0 12px; font-size: 13px; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; justify-content: center; margin-bottom: 12px; }
.chip { border: 1px solid #cfd4da; background: #fff; border-radius: 99px; padding: 6px 12px; font-size: 13px; font-weight: 600; }
.chip.on { background: var(--blue); color: #fff; border-color: var(--blue); }
.value-hero {
  text-align: center; background: #fff; border: 1px solid var(--line); border-top: 4px solid var(--p-min);
  border-radius: var(--radius); padding: 12px; margin-bottom: 12px; box-shadow: var(--shadow);
}
.value-hero span { display: block; font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .6px; font-weight: 700; }
.value-hero b { display: block; font-size: 30px; color: var(--p-min); font-variant-numeric: tabular-nums; }
.value-hero small { color: var(--muted); }
.actions { display: flex; flex-direction: column; gap: 8px; margin-top: 14px; }
.actions .two { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.stepper { display: flex; align-items: center; justify-content: center; gap: 16px; margin: 6px 0 4px; }
.stepper button { width: 42px; height: 42px; border-radius: 50%; border: 1px solid #cfd4da; background: #fff; font-size: 22px; font-weight: 700; color: var(--red); }
.stepper b { font-size: 22px; min-width: 40px; text-align: center; }
.confirm-box { background: var(--red-soft); border: 1px solid var(--p-max); border-radius: 10px; padding: 12px; }
.confirm-box p { margin: 0 0 10px; }
.loading { text-align: center; padding: 50px 0; color: var(--muted); }
.loading::before {
  content: ""; display: block; width: 46px; height: 46px; margin: 0 auto 12px; border-radius: 50%;
  background: linear-gradient(var(--red) 0 46%, #222 46% 54%, #fff 54%);
  box-shadow: 0 0 0 2px #222 inset;
  animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.photo-preview { max-height: 220px; display: block; margin: 0 auto 12px; border-radius: 10px; box-shadow: var(--shadow); }
.ocr-found { background: #fff; border: 1px solid var(--line); border-left: 4px solid var(--blue); border-radius: 10px; padding: 10px 12px; margin-bottom: 12px; }

.toast {
  position: fixed; left: 50%; transform: translateX(-50%); z-index: 60;
  bottom: calc(env(safe-area-inset-bottom, 0px) + 82px);
  background: #1f2328; color: #fff; padding: 10px 16px; border-radius: 99px; font-weight: 600;
  box-shadow: 0 6px 20px rgba(0,0,0,.25); max-width: calc(100% - 32px); text-align: center; pointer-events: none;
}

.radio { display: flex; gap: 10px; align-items: flex-start; padding: 10px 2px; border-bottom: 1px solid var(--line); }
.radio:last-child { border-bottom: 0; }
.radio input { margin-top: 4px; accent-color: var(--red); }
.links a { display: block; padding: 8px 0; font-weight: 600; }
.hint { color: var(--muted); font-size: 12.5px; margin: 6px 0 12px; }
.welcome { text-align: center; padding: 10px 4px; }
.welcome img { height: 60px; margin-bottom: 10px; }
.welcome input { width: 100%; font-size: 17px; text-align: center; margin: 12px 0; }

@media (min-width: 600px) {
  .grid { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
  .strip { grid-template-columns: repeat(4, 1fr); }
  .stat.hero { grid-column: span 2; }
}
.tile.best { border: 2px solid var(--p-min); box-shadow: 0 0 0 3px #d9f2e1; }
.tile.best::after {
  content: "Mais parecida"; position: absolute; top: -9px; left: 50%; transform: translateX(-50%);
  background: var(--p-min); color: #fff; font-size: 10px; font-weight: 700; padding: 1px 7px; border-radius: 99px; white-space: nowrap;
}

.pnote.est { color: var(--p-avg); }
/* Botões principais da carta ficam presos no rodapé, sempre à mão */
.detail .actions {
  position: sticky; bottom: calc(-24px - env(safe-area-inset-bottom, 0px)); z-index: 2;
  background: var(--bg); margin: 14px -16px 0; padding: 10px 16px calc(env(safe-area-inset-bottom, 0px) + 12px);
  border-top: 1px solid var(--line);
}

/* status da nuvem ao lado do nome */
.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-left: 3px; vertical-align: 1px; background: #c3c8cf; }
.dot.ok { background: var(--p-min); } .dot.sync { background: var(--p-avg); animation: pulse 1s infinite; } .dot.warn { background: var(--p-max); }
@keyframes pulse { 50% { opacity: .35; } }
.cloud-banner {
  display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap;
  background: var(--blue-soft); border: 1px solid #b8dcff; border-radius: 10px; padding: 10px 12px; margin-bottom: 12px; font-size: 13.5px;
}
.welcome input + input { margin-top: 0; }
.welcome .seg { margin: 14px 0 4px; }

.liga-cap { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.liga-cap .btn-sm { flex: 1 1 140px; text-align: center; padding: 9px 10px; }
#ligaPasteBox { margin-top: 8px; display: flex; flex-direction: column; gap: 6px; }
#ligaPasteBox textarea { width: 100%; border: 1px solid #cfd4da; border-radius: 8px; padding: 8px; font: inherit; }
.liga-pick { margin-top: 10px; display: flex; flex-direction: column; gap: 6px; }
.liga-pick p { margin: 0; }
.rowbtn { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; text-align: left;
  background: #fff; border: 1px solid #cfd4da; border-radius: 8px; padding: 10px 12px; font-size: 13.5px; }
.rowbtn.sug { border: 2px solid var(--blue); background: var(--blue-soft); }
.rowbtn small { color: var(--blue); font-weight: 700; }
.rowbtn i { font-style: normal; font-weight: 700; font-variant-numeric: tabular-nums; }
.c-min { color: var(--p-min); } .c-avg { color: var(--p-avg); } .c-max { color: var(--p-max); }

.own-photo { display: flex; flex-direction: column; align-items: center; gap: 2px; margin: -4px 0 10px; }

/* ===== Câmera com moldura ===== */
.sheet.camera-mode .sheet-panel { background: #000; }
.sheet.camera-mode .sheet-scroll { padding: 0; overflow: hidden; }
.cam { position: relative; height: 100%; min-height: calc(100dvh - 70px); background: #000; overflow: hidden; }
.cam video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.cam-mask { position: absolute; inset: 0; display: grid; place-items: center; padding-bottom: 90px; pointer-events: none; }
.cam-frame {
  position: relative; width: min(78vw, 58dvh * 63 / 88); aspect-ratio: 63 / 88; border-radius: 4.5%;
  box-shadow: 0 0 0 100vmax rgba(0,0,0,.55); outline: 2px solid rgba(255,255,255,.85);
}
.cam-frame i { position: absolute; width: 26px; height: 26px; border: 4px solid var(--yellow, #ffcb05); }
.cam-frame i:nth-child(1) { top: -4px; left: -4px; border-right: 0; border-bottom: 0; border-radius: 8px 0 0 0; }
.cam-frame i:nth-child(2) { top: -4px; right: -4px; border-left: 0; border-bottom: 0; border-radius: 0 8px 0 0; }
.cam-frame i:nth-child(3) { bottom: -4px; left: -4px; border-right: 0; border-top: 0; border-radius: 0 0 0 8px; }
.cam-frame i:nth-child(4) { bottom: -4px; right: -4px; border-left: 0; border-top: 0; border-radius: 0 0 8px 0; }
.cam-hint { position: absolute; left: 0; right: 0; top: 12px; margin: 0; text-align: center; color: #fff; font-weight: 600; font-size: 14px; text-shadow: 0 1px 3px #000; }
.cam-bar {
  position: absolute; left: 0; right: 0; bottom: 0; display: flex; align-items: center; justify-content: space-around;
  padding: 14px 16px calc(env(safe-area-inset-bottom, 0px) + 18px); background: linear-gradient(transparent, rgba(0,0,0,.7));
}
.cam-shot { width: 74px; height: 74px; border-radius: 50%; border: 5px solid #fff; background: var(--red); box-shadow: 0 0 0 3px rgba(0,0,0,.3); }
.cam-shot:active { transform: scale(.94); }
.cam-side { width: 64px; background: none; border: 0; color: #fff; font-size: 24px; display: flex; flex-direction: column; align-items: center; }
.cam-side small { font-size: 11px; font-weight: 600; }
.cam-side[hidden] { visibility: hidden; display: flex !important; }

.chip-title { text-align: center; margin: 4px 0 6px; font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .5px; }
.chip.lang.on { background: var(--red); border-color: var(--red); }
.lang-tag { display: inline-block; background: var(--blue); color: #fff; border-radius: 3px; padding: 0 3px; font-size: 9.5px; margin-right: 2px; vertical-align: 1px; }

.pin-row { display: flex; gap: 6px; align-items: center; }
.pin-row input { flex: 1; }
.welcome .pin-row input { margin: 6px 0; }
.eye { border: 1px solid #cfd4da; background: #fff; border-radius: 8px; width: 46px; height: 44px; font-size: 18px; flex: none; }
.pin-form { display: flex; flex-direction: column; gap: 6px; }
.pin-form input { width: 100%; }
.welcome input[hidden] { display: none !important; }

/* ===== Portão: entrada e assinatura ===== */
.portao { position: fixed; inset: 0; z-index: 40; background: #fff; overflow-y: auto; -webkit-overflow-scrolling: touch; }
.portao[hidden] { display: none; }
.portao-in { max-width: 460px; margin: 0 auto; padding: calc(env(safe-area-inset-top, 0px) + 28px) 20px 40px; text-align: center; }
.portao-in h1 { font-size: 26px; line-height: 1.15; margin: 10px 0 8px; }
.portao-in h2 { font-size: 20px; margin: 14px 0 8px; }
.portao-logo { width: min(300px, 82%); height: auto; display: block; margin: 0 auto; }
.portao-lista { list-style: none; padding: 0; margin: 18px 0 22px; text-align: left; display: grid; gap: 8px; }
.portao-lista li { background: #f6f7f9; border-radius: 10px; padding: 10px 12px; font-size: 15px; }
.portao-in .btn.block { margin-top: 10px; }
.portao-in input[type=email] { width: 100%; margin-top: 14px; }
.planos { display: grid; gap: 10px; text-align: left; }
.plano { display: grid; gap: 2px; border: 2px solid #e2e5ea; border-radius: 12px; padding: 12px 14px; cursor: pointer; position: relative; }
.plano.on { border-color: var(--red); background: var(--red-soft); }
.plano input { position: absolute; opacity: 0; pointer-events: none; }
.plano-topo { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.plano .preco { font-size: 24px; font-weight: 800; }
.plano .preco small { font-size: 14px; font-weight: 600; color: #667; margin-left: 2px; }
.plano .selo { background: var(--red); color: #fff; font-size: 12px; font-weight: 700; padding: 2px 8px; border-radius: 99px; }
.ts-box { display: flex; justify-content: center; margin: 6px 0; min-height: 0; }
