/* ─── Reset básico ─────────────────────────────────────────────── */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  -webkit-text-size-adjust: 100%;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background: linear-gradient(180deg, #ffffff 0%, #f0f7fc 100%);
  color: #1f2937;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 24px 20px 16px;
  text-align: center;
}

/* ─── Container principal ──────────────────────────────────────── */
.container {
  width: 100%;
  max-width: 420px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  flex: 1;
  justify-content: center;
  padding: 24px 0;
}

/* ─── Badge (indicador "canal oficial") ────────────────────────── */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: rgba(0, 136, 204, 0.08);
  color: #0088cc;
  font-size: 13px;
  font-weight: 600;
  border-radius: 999px;
  letter-spacing: 0.01em;
}

.badge-dot {
  width: 8px;
  height: 8px;
  background: #0088cc;
  border-radius: 50%;
  box-shadow: 0 0 0 4px rgba(0, 136, 204, 0.15);
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.6; }
}

/* ─── Avatar do Caumo ─────────────────────────────────────────── */
.avatar {
  margin-top: 8px;
}

.avatar img {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid #fff;
  box-shadow: 0 8px 24px rgba(0, 136, 204, 0.15), 0 2px 4px rgba(0, 0, 0, 0.04);
}

/* ─── Tipografia ───────────────────────────────────────────────── */
.title {
  font-size: 32px;
  font-weight: 700;
  color: #0a1929;
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin-top: 4px;
}

.subtitle {
  font-size: 16px;
  color: #4b5563;
  line-height: 1.45;
  max-width: 320px;
  font-weight: 400;
}

/* ─── Spinner ──────────────────────────────────────────────────── */
.spinner {
  width: 28px;
  height: 28px;
  border: 3px solid rgba(0, 136, 204, 0.15);
  border-top-color: #0088cc;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin-top: 4px;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* ─── Botão de fallback ────────────────────────────────────────── */
.cta-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 16px 32px;
  background: #0088cc;
  color: #fff;
  font-size: 17px;
  font-weight: 600;
  text-decoration: none;
  border-radius: 14px;
  letter-spacing: 0.01em;
  box-shadow: 0 4px 14px rgba(0, 136, 204, 0.3);
  transition: transform 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
  -webkit-tap-highlight-color: transparent;
  width: 100%;
  max-width: 320px;
  margin-top: 8px;
}

.cta-button:hover {
  background: #0077b8;
  box-shadow: 0 6px 18px rgba(0, 136, 204, 0.35);
}

.cta-button:active {
  transform: scale(0.98);
  box-shadow: 0 2px 8px rgba(0, 136, 204, 0.25);
}

/* ─── Noscript fallback ────────────────────────────────────────── */
.noscript-msg {
  font-size: 15px;
  color: #4b5563;
  line-height: 1.5;
  margin-top: 16px;
  padding: 16px;
  background: #fef3c7;
  border-radius: 12px;
  border: 1px solid #fde68a;
}

.noscript-msg a {
  color: #0088cc;
  font-weight: 600;
  text-decoration: underline;
}

/* ─── Footer disclaimer ────────────────────────────────────────── */
.footer {
  width: 100%;
  max-width: 420px;
  margin-top: auto;
  padding-top: 32px;
}

.footer p {
  font-size: 11px;
  color: #9ca3af;
  line-height: 1.55;
  font-weight: 400;
}

/* ─── Responsivo ───────────────────────────────────────────────── */
@media (max-width: 380px) {
  .title { font-size: 28px; }
  .subtitle { font-size: 15px; }
  .avatar img { width: 100px; height: 100px; }
}

/* ─── Estado: redirecionando concluído ─────────────────────────── */
.container.state-ready .spinner {
  display: none;
}

.container.state-ready #status-text {
  font-weight: 500;
  color: #0088cc;
}

/* ─── Estado: erro de tracking (mostra botão) ─────────────────── */
.container.state-fallback .spinner {
  display: none;
}

.container.state-fallback #fallback-btn {
  display: inline-flex !important;
}
