/* TDA Digital · landing estilo Apple light, base comum das variações A, B e C (08/10/2026).
   Tokens vêm da versão Apple light de app/site/src/index.css e do anúncio "implementar IA"
   (Criação de conteudo/07-videos/linguagem-edicao/tutorial-apple-light-tda.md).
   Regras de UI: skill ui-profissional (regras 1–12). Movimento: sai rápido, assenta longo, mola na chegada. */

:root {
  --fundo: #f5f5f7;
  --branco: #ffffff;
  --texto: #1d1d1f;
  --texto-2: #6e6e73;
  --texto-3: #86868b;
  --linha: rgba(0, 0, 0, 0.08);
  --cinza-claro: #e8e8ed;
  --cinza-campo: #f2f2f7;

  --azul: #007aff;
  --azul-hover: #0066d6;
  --azul-claro: #e8f2ff;
  --verde: #34c759;
  --laranja: #ff9500;
  --vermelho: #ff3b30;
  --roxo: #af52de;
  --rosa: #ff2d55;
  --indigo: #5856d6;
  --teal: #30b0c7;
  --amarelo: #ffcc00;
  --whats: #25d366;

  /* Degradê do Apple Intelligence: só onde a página fala de IA. */
  --ia: linear-gradient(90deg, #3d8bff 0%, #a35bf7 38%, #f062c0 68%, #ff9f3a 100%);
  --ia-conico: conic-gradient(from var(--giro, 200deg), #3d8bff, #a35bf7, #f062c0, #ff9f3a, #3d8bff);

  --display: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Inter Tight', 'Inter', system-ui, sans-serif;
  --corpo: -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'Inter', system-ui, sans-serif;
  --mono: 'SF Mono', ui-monospace, Menlo, Consolas, monospace;

  /* Uma escala de raio: cartão 28, item 16, pílula 999. */
  --raio: 28px;
  --raio-p: 16px;

  --sombra: 0 1px 2px rgba(0, 0, 0, 0.04), 0 12px 32px -22px rgba(0, 0, 0, 0.16);
  --sombra-hover: 0 1px 2px rgba(0, 0, 0, 0.04), 0 8px 24px -16px rgba(0, 0, 0, 0.25), 0 24px 48px -28px rgba(0, 0, 0, 0.18);
  --sombra-flutua: 0 2px 6px rgba(0, 0, 0, 0.05), 0 30px 60px -30px rgba(0, 0, 0, 0.28);

  /* Curvas: --curva sai rápido e assenta longo; --mola passa um pouco do ponto e volta. */
  --curva: cubic-bezier(0.2, 0.8, 0.2, 1);
  --mola: cubic-bezier(0.34, 1.36, 0.64, 1);
  --saida: cubic-bezier(0.55, 0, 0.75, 0.2);

  --gutter: 16px;
  --secao: 88px;
}

@media (min-width: 900px) {
  :root {
    --gutter: 40px;
    --secao: 136px;
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 88px;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--fundo);
  color: var(--texto);
  font-family: var(--corpo);
  font-size: 17px;
  line-height: 1.47;
  letter-spacing: -0.01em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: clip;
}

img,
svg {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
textarea,
select {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
}

h1,
h2,
h3,
h4,
p {
  margin: 0;
}

:focus-visible {
  outline: 3px solid rgba(0, 122, 255, 0.45);
  outline-offset: 2px;
  border-radius: 12px;
}

.container {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.secao {
  padding: var(--secao) 0;
}

/* ---------- tipografia (landing: 72/48/28/21/17/13) ---------- */
.t-hero {
  font-family: var(--display);
  font-size: clamp(44px, 8.4vw, 80px);
  line-height: 1.04;
  font-weight: 700;
  letter-spacing: -0.035em;
  text-wrap: balance;
}

.t-titulo {
  font-family: var(--display);
  font-size: clamp(34px, 5.6vw, 52px);
  line-height: 1.08;
  font-weight: 700;
  letter-spacing: -0.03em;
  text-wrap: balance;
}

.t-sub {
  font-family: var(--display);
  font-size: clamp(22px, 2.6vw, 28px);
  line-height: 1.18;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.t-lead {
  font-size: clamp(19px, 2vw, 21px);
  line-height: 1.42;
  color: var(--texto-2);
  letter-spacing: -0.012em;
  text-wrap: pretty;
}

.t-corpo {
  font-size: 17px;
  color: var(--texto-2);
}

.t-mini {
  font-size: 13px;
  line-height: 1.38;
  color: var(--texto-3);
  letter-spacing: -0.005em;
}

/* Texto preenchido pelo degradê da IA (só a palavra "IA" ou a frase sobre IA). */
.ia-texto {
  background: var(--ia);
  background-size: 200% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: ia-corre 6s linear infinite;
}

@keyframes ia-corre {
  to {
    background-position: -200% 0;
  }
}

@property --giro {
  syntax: '<angle>';
  inherits: true;
  initial-value: 200deg;
}

/* Borda viva da IA: aplique .ia-borda num elemento com position relativa. */
.ia-borda {
  position: relative;
  isolation: isolate;
}

.ia-borda::before {
  content: '';
  position: absolute;
  inset: -2px;
  border-radius: inherit;
  padding: 2px;
  background: var(--ia-conico);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  animation: ia-gira 4s linear infinite;
  z-index: -1;
}

.ia-borda::after {
  content: '';
  position: absolute;
  inset: -10px;
  border-radius: inherit;
  background: var(--ia-conico);
  filter: blur(18px);
  opacity: 0.32;
  animation: ia-gira 4s linear infinite;
  z-index: -2;
}

@keyframes ia-gira {
  to {
    --giro: 560deg;
  }
}

/* ---------- botões (padding horizontal = 2× vertical; primário + ghost) ---------- */
.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 12px 24px;
  border-radius: 999px;
  border: 0;
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.015em;
  white-space: nowrap;
  overflow: hidden;
  transition: transform 0.16s var(--curva), background-color 0.16s ease, box-shadow 0.16s ease, color 0.16s ease;
  -webkit-tap-highlight-color: transparent;
}

.btn svg {
  width: 18px;
  height: 18px;
  flex: none;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn:active {
  transform: scale(0.97);
  transition-duration: 0.08s;
}

.btn:disabled,
.btn[aria-disabled='true'] {
  opacity: 0.4;
  pointer-events: none;
}

.btn-primario {
  background: var(--azul);
  color: #fff;
  box-shadow: 0 8px 24px -14px rgba(0, 122, 255, 0.7);
}

.btn-primario:hover {
  background: var(--azul-hover);
  box-shadow: 0 14px 32px -16px rgba(0, 122, 255, 0.75);
}

.btn-escuro {
  background: var(--texto);
  color: #fff;
}

.btn-escuro:hover {
  background: #000;
}

.btn-ghost {
  background: transparent;
  color: var(--azul);
  box-shadow: inset 0 0 0 1.5px rgba(0, 122, 255, 0.45);
}

.btn-ghost:hover {
  background: var(--azul-claro);
}

.btn-whats {
  background: var(--whats);
  color: #fff;
  box-shadow: 0 8px 24px -14px rgba(37, 211, 102, 0.8);
}

.btn-whats:hover {
  background: #1fbd5a;
}

.btn-largo {
  width: 100%;
}

.btn.carregando {
  color: transparent;
  pointer-events: none;
}

.btn.carregando::after {
  content: '';
  position: absolute;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 2.5px solid rgba(255, 255, 255, 0.4);
  border-top-color: #fff;
  animation: gira 0.7s linear infinite;
}

@keyframes gira {
  to {
    transform: rotate(360deg);
  }
}

.link {
  color: var(--azul);
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: color 0.16s ease;
}

.link svg {
  width: 14px;
  height: 14px;
  transition: transform 0.2s var(--curva);
}

.link:hover {
  color: var(--azul-hover);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.link:hover svg {
  transform: translateX(3px);
}

/* Ripple leve (regra 11). O span é criado em base.js. */
.ripple-onda {
  position: absolute;
  border-radius: 50%;
  background: currentColor;
  opacity: 0.18;
  transform: scale(0);
  animation: ripple 0.55s var(--curva) forwards;
  pointer-events: none;
}

.btn-primario .ripple-onda,
.btn-escuro .ripple-onda,
.btn-whats .ripple-onda {
  background: #fff;
  opacity: 0.3;
}

@keyframes ripple {
  to {
    transform: scale(1);
    opacity: 0;
  }
}

/* ---------- cartão ---------- */
.cartao {
  background: var(--branco);
  border-radius: var(--raio);
  box-shadow: var(--sombra);
  transition: transform 0.16s ease, box-shadow 0.16s ease;
}

.cartao-vivo:hover {
  transform: translateY(-2px);
  box-shadow: var(--sombra-hover);
}

/* ---------- ícone de app (quadrado colorido + símbolo branco) ---------- */
.app-ic {
  --cor: var(--azul);
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: var(--cor);
  color: #fff;
  flex: none;
  box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.08);
}

.app-ic svg {
  width: 60%;
  height: 60%;
}

/* Toda tag de ícone vira uma caixa atômica do tamanho do SVG: sem itálico nem folga de linha de base. */
i[data-ic] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  font-style: normal;
  line-height: 0;
}

/* O <i data-ic> que embrulha o SVG ocupa o quadrado inteiro e centraliza o desenho.
   Sem isto, o SVG mede 60% da tag (e não do quadrado) e fica pequeno e puxado para a esquerda.
   78% do quadrado deixa o símbolo em ~55% da caixa, como nos ícones de app da Apple. */
.app-ic > i[data-ic] {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  font-style: normal;
}

.app-ic > i[data-ic] > svg {
  width: 78%;
  height: 78%;
}

.app-ic.g {
  width: 56px;
  height: 56px;
  border-radius: 14px;
}

.app-ic.p {
  width: 26px;
  height: 26px;
  border-radius: 7px;
}

.c-azul { --cor: var(--azul); }
.c-verde { --cor: var(--verde); }
.c-laranja { --cor: var(--laranja); }
.c-vermelho { --cor: var(--vermelho); }
.c-roxo { --cor: var(--roxo); }
.c-rosa { --cor: var(--rosa); }
.c-indigo { --cor: var(--indigo); }
.c-teal { --cor: var(--teal); }
.c-whats { --cor: var(--whats); }
.c-preto { --cor: var(--texto); }

/* ---------- pílula "Alto impacto" e chips ---------- */
.pilula-ia {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 9px 3px 7px;
  border-radius: 999px;
  background: var(--ia);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0;
  white-space: nowrap;
}

.pilula-ia svg {
  width: 11px;
  height: 11px;
}

/* ---------- iPhone (moldura titânio, tela arredondada, Dynamic Island) ---------- */
.iphone {
  --w: 300px;
  position: relative;
  width: var(--w);
  aspect-ratio: 9 / 19.5;
  border-radius: calc(var(--w) * 0.17);
  padding: calc(var(--w) * 0.034);
  background: linear-gradient(145deg, #e3e4e8, #b9bbc2 45%, #d8d9de 70%, #a9abb2);
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.12), inset 0 0 0 2px rgba(255, 255, 255, 0.5), var(--sombra-flutua);
}

.iphone-tela {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: calc(var(--w) * 0.14);
  background: #fff;
  overflow: hidden;
  box-shadow: 0 0 0 calc(var(--w) * 0.012) #111;
}

.iphone-ilha {
  position: absolute;
  top: calc(var(--w) * 0.035);
  left: 50%;
  translate: -50% 0;
  width: calc(var(--w) * 0.31);
  height: calc(var(--w) * 0.09);
  border-radius: 999px;
  background: #000;
  z-index: 20;
  transition: width 0.5s var(--mola), height 0.5s var(--mola), border-radius 0.5s var(--mola);
}

.iphone-status {
  position: absolute;
  top: calc(var(--w) * 0.045);
  left: 0;
  right: 0;
  display: flex;
  justify-content: space-between;
  padding: 0 calc(var(--w) * 0.09);
  font-size: calc(var(--w) * 0.045);
  font-weight: 600;
  z-index: 19;
}

/* ---------- entrada por scroll: sobe com fade e um pouco de desfoque ---------- */
[data-reveal] {
  opacity: 0;
  transform: translateY(24px);
  filter: blur(6px);
  transition: opacity 0.8s var(--curva), transform 0.9s var(--curva), filter 0.8s var(--curva);
  transition-delay: var(--atraso, 0s);
}

[data-reveal].visivel {
  opacity: 1;
  transform: none;
  filter: none;
}

/* Título que entra palavra por palavra (o span é criado em base.js). */
.palavra {
  display: inline-block;
  opacity: 0;
  transform: translateY(0.4em);
  filter: blur(8px);
  transition: opacity 0.7s var(--curva), transform 0.8s var(--curva), filter 0.7s var(--curva);
  transition-delay: calc(var(--i) * 55ms + var(--atraso, 0s));
}

.visivel .palavra,
.palavra.visivel {
  opacity: 1;
  transform: none;
  filter: none;
}

/* ---------- skeleton com brilho ---------- */
.skeleton {
  position: relative;
  overflow: hidden;
  background: var(--cinza-claro);
  border-radius: 8px;
}

.skeleton::after {
  content: '';
  position: absolute;
  inset: 0;
  transform: translateX(-100%);
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.7), transparent);
  animation: brilho 1.4s ease-in-out infinite;
}

@keyframes brilho {
  to {
    transform: translateX(100%);
  }
}

/* ---------- navegação em pílula ---------- */
.nav {
  position: fixed;
  top: 12px;
  left: 50%;
  translate: -50% 0;
  z-index: 50;
  width: min(1080px, calc(100% - 24px));
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 8px 8px 8px 20px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  box-shadow: 0 0 0 1px var(--linha), 0 10px 30px -20px rgba(0, 0, 0, 0.25);
  transition: translate 0.4s var(--curva), box-shadow 0.3s ease;
}

.nav-logo img {
  height: 22px;
  width: auto;
}

.nav-links {
  display: none;
  gap: 4px;
}

.nav-links a {
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 14px;
  color: var(--texto-2);
  transition: background-color 0.16s ease, color 0.16s ease;
}

.nav-links a:hover,
.nav-links a.ativo {
  background: rgba(0, 0, 0, 0.05);
  color: var(--texto);
}

.nav .btn {
  min-height: 40px;
  padding: 8px 16px;
  font-size: 15px;
}

@media (min-width: 900px) {
  .nav-links {
    display: flex;
  }
}

/* ---------- perguntas (accordion com altura animada) ---------- */
.faq {
  border-radius: var(--raio);
  background: var(--branco);
  box-shadow: var(--sombra);
  overflow: hidden;
}

.faq details {
  border-top: 1px solid var(--linha);
}

.faq details:first-child {
  border-top: 0;
}

.faq summary {
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 20px 24px;
  font-weight: 600;
  font-size: 17px;
  cursor: pointer;
  transition: background-color 0.16s ease;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary:hover {
  background: rgba(0, 0, 0, 0.02);
}

.faq summary svg {
  width: 14px;
  height: 14px;
  color: var(--texto-3);
  transition: transform 0.3s var(--curva);
  flex: none;
}

.faq details[open] summary svg {
  transform: rotate(180deg);
}

.faq .resposta {
  padding: 0 24px 22px;
  color: var(--texto-2);
}

/* ---------- rodapé ---------- */
.rodape {
  padding: 56px 0 40px;
  border-top: 1px solid var(--linha);
  font-size: 14px;
  color: var(--texto-2);
}

.rodape-grade {
  display: grid;
  gap: 32px;
}

.rodape h4 {
  font-size: 13px;
  font-weight: 600;
  color: var(--texto);
  margin-bottom: 12px;
}

.rodape ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
}

.rodape a:hover {
  color: var(--texto);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.rodape-logo img {
  height: 26px;
  width: auto;
  margin-bottom: 12px;
}

@media (min-width: 900px) {
  .rodape-grade {
    grid-template-columns: 2fr 1fr 1fr 1fr;
  }
}

/* Faixa de protótipo (some na versão de produção). */
.faixa-prototipo {
  position: fixed;
  bottom: 12px;
  left: 12px;
  z-index: 60;
  display: flex;
  gap: 6px;
  padding: 6px;
  border-radius: 999px;
  background: rgba(29, 29, 31, 0.86);
  backdrop-filter: blur(12px);
  font-size: 12px;
  color: #fff;
}

.faixa-prototipo a {
  padding: 6px 10px;
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.7);
}

.faixa-prototipo a.ativo,
.faixa-prototipo a:hover {
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
}

/* Campo oculto contra robôs (o worker descarta quem preenche). */
.campo-oculto {
  position: absolute !important;
  left: -9999px !important;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }

  [data-reveal],
  .palavra {
    opacity: 1;
    transform: none;
    filter: none;
  }
}
