/* player-celular.css — player dos vídeos curtos da página da IA NO CELULAR
   (até 640px). Padrão desde 27/11/2026: é a "proposta 6" da amostra
   /amostras/player-propostas/ (abas Vídeo | Notas AIX + feed de deslizar).
   No notebook continua a janela .nh-player (public/ferramenta.css).
   Tudo fica dentro de .pc-player para não vazar no resto da página.
   JS em public/player-celular.js. */

html:has(.pc-player[open]) { overflow: hidden; }

.pc-player {
  --solido: #131318;
  --tinta: #f4f4f6;
  --tinta-2: #a3a6b0;
  --tinta-3: #7f828c;
  --linha: rgba(255, 255, 255, 0.09);
  --grad-aix: linear-gradient(135deg, #20b997, #8b5cf6);
  container-type: size;
  width: 100vw;
  max-width: none;
  height: 100dvh;
  max-height: none;
  margin: 0;
  padding: 0;
  overflow: hidden;
  border: 0;
  background: #000000;
  color: var(--tinta);
  color-scheme: dark;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
  overscroll-behavior: contain;
}
.pc-player[open] { display: grid; grid-template-rows: auto minmax(0, 1fr); }
.pc-player::backdrop { background: #000000; }
.pc-player *, .pc-player *::before, .pc-player *::after { box-sizing: border-box; }
.pc-player [hidden] { display: none !important; }
.pc-player button { color: inherit; font: inherit; }
.pc-defs { position: absolute; width: 0; height: 0; overflow: hidden; }

/* ícones de traço (os que têm preenchimento próprio ficam de fora) */
.pc-player svg {
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ── Topo: × · abas Vídeo | Notas AIX · Enviar ────────────────────────────── */
.pc-topo { display: grid; grid-template-columns: 40px minmax(0, 1fr) 40px; align-items: center; gap: 10px; padding: max(8px, env(safe-area-inset-top)) 10px 8px; }
.pc-redondo {
  position: relative;
  display: grid;
  flex: none;
  place-items: center;
  width: 38px;
  height: 38px;
  padding: 0;
  border: 1px solid var(--linha);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.pc-redondo:active { background: rgba(255, 255, 255, 0.12); }
.pc-redondo svg { width: 18px; height: 18px; }
.pc-enviar { justify-self: end; }
.pc-abas { position: relative; display: grid; grid-template-columns: 1fr 1fr; padding: 3px; border-radius: 999px; background: rgba(255, 255, 255, 0.08); }
.pc-abas button { position: relative; z-index: 1; height: 34px; padding: 0; border: 0; background: none; color: var(--tinta-2); font-size: 14px; font-weight: 600; cursor: pointer; transition: color 0.2s; }
.pc-abas button[aria-selected="true"] { color: #0a0a0f; }
.pc-indicador { position: absolute; top: 3px; bottom: 3px; left: 3px; width: calc(50% - 3px); border-radius: 999px; background: #ececf1; }

/* aviso "Copiado!" do Enviar: abre para baixo */
.pc-balao:empty { display: none; }
.pc-balao {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 2;
  padding: 5px 10px;
  border-radius: 8px;
  background: #ffffff;
  color: #111111;
  font-size: 12.5px;
  font-weight: 600;
  white-space: nowrap;
  pointer-events: none;
}

/* ── Duas páginas lado a lado (deslizar ou tocar nas abas) ────────────────── */
.pc-paginas { display: flex; overflow-x: auto; overflow-y: hidden; overscroll-behavior-x: contain; scroll-snap-type: x mandatory; scrollbar-width: none; }
.pc-paginas::-webkit-scrollbar { display: none; }
.pc-pag { position: relative; flex: 0 0 100%; height: 100%; scroll-snap-align: start; scroll-snap-stop: always; }
.pc-pag-video { container-type: size; }
.pc-pag-notas { overflow-y: auto; overscroll-behavior-y: contain; border-radius: 18px 18px 0 0; background: var(--solido); }

/* ── Feed: um vídeo por "página", deslizar para cima = próximo ────────────── */
/* só a rolagem vertical fica presa: o deslize de lado chega às abas */
.pc-feed { position: absolute; inset: 0; overflow-y: auto; overscroll-behavior: auto contain; scroll-snap-type: y mandatory; scrollbar-width: none; }
.pc-feed::-webkit-scrollbar { display: none; }
.pc-slide { position: relative; height: 100cqh; scroll-snap-align: start; scroll-snap-stop: always; }
/* 9:16 na altura toda embaixo das abas (8px de respiro até o próximo) */
.pc-video { --alt: min(calc(100cqh - 8px), calc((100cqw - 24px) * 16 / 9)); position: absolute; top: 0; left: calc(50% - var(--alt) * 9 / 32); width: calc(var(--alt) * 9 / 16); height: var(--alt); }
.pc-quadro { position: relative; width: 100%; height: 100%; overflow: hidden; border-radius: 14px; background: #0c0c10; }
.pc-quadro iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
/* Instagram não tem player puro: recorta o cartão do post (o mesmo recorte do notebook) */
.pc-quadro[data-plataforma="instagram"] iframe {
  inset: auto;
  top: -54px;
  left: 50%;
  width: calc(var(--alt) * 0.8);
  height: calc(var(--alt) + 400px);
  transform: translateX(-50%);
}
.pc-capa { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.pc-play { position: absolute; top: 50%; left: 50%; display: grid; place-items: center; width: 64px; height: 64px; margin: -32px 0 0 -32px; border-radius: 50%; background: rgba(0, 0, 0, 0.45); color: #ffffff; }
.pc-player .pc-play svg { width: 28px; height: 28px; margin-left: 3px; fill: currentColor; stroke: none; }
.pc-slide.is-ativo .pc-play { display: none; }

/* crédito do criador (Instagram) */
.pc-autor {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  max-width: calc(100% - 64px);
  padding: 6px 12px 6px 9px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  background: rgba(10, 10, 14, 0.55);
  color: #ffffff;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}
.pc-autor svg { width: 16px; height: 16px; }
.pc-autor span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* lateral no meio da altura: embaixo, à direita, o TikTok e o YouTube Shorts
   mostram os botões deles (curtir, comentar, compartilhar) */
.pc-trilho { position: absolute; top: 50%; right: 8px; z-index: 4; transform: translateY(-50%); }
.pc-acoes { display: grid; justify-items: center; gap: 14px; }
.pc-acao {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 4px;
  padding: 0;
  border: 0;
  background: none;
  color: #ffffff;
  text-decoration: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.pc-acao small { max-width: 64px; overflow: hidden; font-size: 11.5px; font-weight: 600; text-overflow: ellipsis; text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6); white-space: nowrap; }
.pc-acao-ic {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 50%;
  background: rgba(16, 16, 20, 0.52);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}
.pc-acao:active .pc-acao-ic { background: rgba(48, 48, 56, 0.75); }
.pc-acao-ic svg { width: 21px; height: 21px; }
/* logo da IA na cor dela (a mesma receita do quadrado do topo da página) */
.pc-logo {
  --px-a: var(--px-marca-a, #0f8369);
  background: linear-gradient(140deg, var(--px-a), var(--px-marca-b, color-mix(in srgb, var(--px-a) 58%, #0a0a0f)));
  font-size: 13px;
  font-weight: 700;
}
.pc-logo img { width: 56%; height: 56%; object-fit: contain; }
.pc-logo-cheio { background: none; }
.pc-logo-cheio img { width: 100%; height: 100%; }
/* "Notas": o redondo com o degradê da AIX */
.pc-ic-notas { border-color: transparent; background: var(--grad-aix); }
.pc-acao:active .pc-ic-notas { background: var(--grad-aix); opacity: 0.85; }

/* dica "Deslize para cima" na abertura */
.pc-dica {
  position: absolute;
  top: 27%;
  left: 50%;
  z-index: 8;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  border-radius: 999px;
  background: rgba(16, 16, 20, 0.74);
  color: #ffffff;
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  opacity: 0;
  transform: translateX(-50%);
  pointer-events: none;
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}
.pc-dica svg { width: 20px; height: 20px; animation: pc-sobe 1s ease-in-out infinite; }
.pc-player.com-dica .pc-dica { animation: pc-dica 3.6s ease forwards; }
@keyframes pc-dica {
  0% { opacity: 0; transform: translate(-50%, 10px); }
  12%, 80% { opacity: 1; transform: translate(-50%, 0); }
  100% { opacity: 0; transform: translate(-50%, -6px); }
}
@keyframes pc-sobe {
  0%, 100% { transform: translateY(2px); }
  50% { transform: translateY(-3px); }
}

/* ── Painel "Notas AIX" (o mesmo do notebook) ─────────────────────────────── */
.pc-painel { display: grid; gap: 16px; padding: 18px 18px 6px; }
.pc-marca { display: inline-flex; align-items: center; gap: 9px; color: var(--tinta-2); font-size: 12px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; }
.pc-marca-ic { display: grid; flex: none; place-items: center; width: 30px; height: 30px; border-radius: 9px; background: var(--grad-aix); color: #ffffff; }
.pc-marca-ic svg { width: 18px; height: 18px; stroke-width: 1.8; }
.pc-titulo { margin: 0; color: var(--tinta); font-family: inherit; font-size: 18px; font-weight: 600; letter-spacing: -0.01em; line-height: 1.3; }

.pc-pontos { padding: 14px 16px 15px; border-radius: 4px 14px 14px 14px; background: rgba(255, 255, 255, 0.05); }
.pc-pontos h3 { display: flex; align-items: center; gap: 7px; margin: 0 0 10px; color: var(--tinta); font-family: inherit; font-size: 13px; font-weight: 600; }
.pc-player .pc-brilho { width: 17px; height: 17px; stroke: none; }
.pc-pontos ul { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; }
.pc-pontos li { position: relative; padding-left: 25px; color: var(--tinta-2); font-size: 14.5px; line-height: 1.45; }
/* selo azul com ✓ (o mesmo do notebook) */
.pc-pontos li::before {
  content: "";
  position: absolute;
  top: 2px;
  left: 0;
  width: 17px;
  height: 17px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%2338bdf8' d='M22.25 12c0-1.43-.88-2.67-2.19-3.34.46-1.39.2-2.9-.81-3.91s-2.52-1.27-3.91-.81c-.66-1.31-1.91-2.19-3.34-2.19s-2.67.88-3.33 2.19c-1.4-.46-2.91-.2-3.92.81s-1.26 2.52-.8 3.91c-1.31.67-2.2 1.91-2.2 3.34s.89 2.67 2.2 3.34c-.46 1.39-.21 2.9.8 3.91s2.52 1.26 3.91.81c.67 1.31 1.91 2.19 3.34 2.19s2.68-.88 3.34-2.19c1.39.45 2.9.2 3.91-.81s1.27-2.52.81-3.91c1.31-.67 2.19-1.91 2.19-3.34z'/%3E%3Cpath fill='none' stroke='%23fff' stroke-width='2.3' stroke-linecap='round' stroke-linejoin='round' d='M8.2 12.2l2.6 2.6 5-5.2'/%3E%3C/svg%3E") center / contain no-repeat;
}

.pc-acessar {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 13px;
  padding-top: 11px;
  border-top: 1px solid var(--linha);
  color: var(--tinta-2);
  font-size: 13.5px;
  font-weight: 600;
  text-decoration: none;
}
.pc-acessar img { flex: none; width: 20px; height: 20px; border-radius: 5px; }
.pc-acessar-txt { flex: 1; min-width: 0; }
.pc-acessar b { color: var(--tinta); font-weight: 600; }
.pc-acessar-cta { display: inline-flex; flex: none; align-items: center; gap: 4px; color: var(--tinta); }
.pc-acessar-cta svg { width: 14px; height: 14px; stroke-width: 2.2; }

.pc-fim { display: grid; gap: 14px; padding-top: 14px; border-top: 1px solid var(--linha); }
.pc-captura { margin: 0; }
.pc-captura-titulo { margin: 0; color: var(--tinta); font-size: 14px; font-weight: 600; line-height: 1.35; }
.pc-captura-texto { margin: 3px 0 0; color: var(--tinta-2); font-size: 13px; line-height: 1.4; }
.pc-captura-linha { display: flex; gap: 6px; margin-top: 10px; }
/* 16px no campo evita o zoom automático do iPhone */
.pc-captura input {
  flex: 1;
  width: 0;
  min-width: 0;
  height: 40px;
  padding: 0 14px;
  border: 1px solid var(--linha);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--tinta);
  font: inherit;
  font-size: 16px;
}
.pc-captura input::placeholder { color: var(--tinta-3); }
.pc-captura input[aria-invalid="true"] { border-color: #f87171; }
.pc-captura button { flex: none; height: 40px; padding: 0 15px; border: 0; border-radius: 999px; background: #ececf1; color: #0a0a0f; font-size: 13px; font-weight: 700; cursor: pointer; }
.pc-captura-ok { display: flex; gap: 7px; margin: 10px 0 0; color: var(--tinta); font-size: 13px; line-height: 1.4; }
.pc-captura-ok::before { content: "✓"; color: #6fd9a2; font-weight: 700; }
.pc-mais p { margin: 0 0 3px; color: var(--tinta-2); font-size: 13px; font-weight: 600; }
.pc-mais-link { display: inline-flex; align-items: center; gap: 5px; color: var(--tinta); font-size: 14px; font-weight: 600; text-decoration: underline 1.5px rgba(255, 255, 255, 0.38); text-underline-offset: 4px; }
.pc-mais-link svg { width: 15px; height: 15px; }

/* ── Próximo vídeo ────────────────────────────────────────────────────────── */
.pc-proximo { padding: 18px 18px max(24px, env(safe-area-inset-bottom)); }
.pc-proximo h3 { display: flex; align-items: center; gap: 9px; margin: 0 0 10px; color: var(--tinta-2); font-family: inherit; font-size: 12px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; }
.pc-proximo h3 svg { width: 18px; height: 18px; stroke-width: 1.8; }
.pc-proximo-card {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr) 32px;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 8px 10px 8px 8px;
  border: 1px solid var(--linha);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.04);
  text-align: left;
  cursor: pointer;
}
.pc-proximo-capa { display: block; aspect-ratio: 9 / 16; overflow: hidden; border-radius: 8px; background: #1a1a22; }
.pc-proximo-capa img { display: block; width: 100%; height: 100%; object-fit: cover; }
.pc-proximo-titulo { display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 2; font-size: 14.5px; font-weight: 600; line-height: 1.3; }
.pc-proximo-fonte { display: block; margin-top: 4px; overflow: hidden; color: var(--tinta-3); font-size: 12.5px; text-overflow: ellipsis; white-space: nowrap; }
.pc-proximo-seta { display: grid; place-items: center; width: 32px; height: 32px; border: 1px solid var(--linha); border-radius: 50%; }
.pc-proximo-seta svg { width: 16px; height: 16px; }

@media (prefers-reduced-motion: reduce) {
  .pc-dica svg { animation: none; }
}
