/* ==========================================================================
   BASE — reset, fundo ambiente, layout e componentes compartilhados.
   Carregado por TODAS as páginas do site. Não coloque aqui nada que seja
   específico de uma página só.
   ========================================================================== */

/* --- Reset ---------------------------------------------------------------- */

*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  scroll-behavior: smooth;
}

body {
  background: var(--bg);
  color: var(--paper);
  font-family: var(--font-body);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
}

/* Foco visível para navegação por teclado (acessibilidade). */
:focus-visible {
  outline: 2px solid var(--lime);
  outline-offset: 3px;
  border-radius: 4px;
}

/* --- Fundo: textura de grão animada -------------------------------------- */

@keyframes grain {
  0%, 100% { transform: translate(0, 0) }
  10%      { transform: translate(-2%, -3%) }
  20%      { transform: translate(3%, 1%) }
  30%      { transform: translate(-1%, 3%) }
  40%      { transform: translate(2%, -2%) }
  50%      { transform: translate(-3%, 1%) }
  60%      { transform: translate(1%, -1%) }
  70%      { transform: translate(-2%, 2%) }
  80%      { transform: translate(3%, -3%) }
  90%      { transform: translate(-1%, 2%) }
}

body::before {
  content: '';
  position: fixed;
  inset: -20%;
  width: 140%;
  height: 140%;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 512 512' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.03'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 0;
  animation: grain 6s steps(8) infinite;
}

/* --- Fundo: orbes de luz flutuantes -------------------------------------- */

@keyframes float1 {
  0%, 100% { transform: translate(0, 0) scale(1) }
  25%      { transform: translate(40px, -30px) scale(1.05) }
  50%      { transform: translate(-20px, 20px) scale(0.95) }
  75%      { transform: translate(30px, 40px) scale(1.02) }
}

@keyframes float2 {
  0%, 100% { transform: translate(0, 0) scale(1) }
  25%      { transform: translate(-50px, 20px) scale(0.97) }
  50%      { transform: translate(30px, -40px) scale(1.04) }
  75%      { transform: translate(-20px, -20px) scale(1.01) }
}

@keyframes float3 {
  0%, 100% { transform: translate(0, 0) scale(1) }
  33%      { transform: translate(25px, 35px) scale(1.03) }
  66%      { transform: translate(-35px, -15px) scale(0.98) }
}

.bg-orbs {
  position: fixed;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
}

.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(100px);
  /* Cada orbe define --orb-color; o gradiente é o mesmo para todos. */
  background: radial-gradient(circle, var(--orb-color) 0%, transparent 70%);
}

.orb-1 {
  --orb-color: rgba(207, 233, 106, 0.04);
  width: 500px;
  height: 500px;
  top: -10%;
  right: -10%;
  animation: float1 25s ease-in-out infinite;
}

.orb-2 {
  --orb-color: rgba(107, 127, 255, 0.03);
  width: 400px;
  height: 400px;
  bottom: 20%;
  left: -8%;
  animation: float2 30s ease-in-out infinite;
}

.orb-3 {
  --orb-color: rgba(212, 165, 116, 0.03);
  width: 350px;
  height: 350px;
  top: 50%;
  right: 20%;
  animation: float3 20s ease-in-out infinite;
}

/* --- Layout --------------------------------------------------------------- */

.page-wrap {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 960px;
  margin: 0 auto;
  padding: 0 24px;
}

/* --- Componente: rótulo de seção ----------------------------------------- */
/* Um traço curto seguido de um texto em maiúsculas. Ex: "— CONTEÚDO" */

.section-label {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 0 0 28px;
}

.section-label::before {
  content: '';
  width: 20px;
  height: 1px;
  background: var(--paper-dim);
  flex-shrink: 0;
}

.section-label span {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--paper-dim);
  white-space: nowrap;
}

/* --- Componente: botão principal ----------------------------------------- */

.btn-primary {
  display: block;
  width: 100%;
  padding: 18px 24px;
  background: var(--lime);
  color: var(--bg);
  text-align: center;
  text-decoration: none;
  border-radius: var(--radius-button);
  font-weight: 600;
  font-size: 15px;
  letter-spacing: 0.01em;
  transition: transform 0.2s, box-shadow 0.2s;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(207, 233, 106, 0.18);
}

/* Legenda pequena logo abaixo de um botão. */
.btn-caption {
  text-align: center;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--paper-dim);
  margin-top: 8px;
}

/* --- Componente: pílula (tag) -------------------------------------------- */

.pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.pill {
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 5px 14px;
  border-radius: 100px;
  border: 1px solid var(--border);
  color: var(--paper-dim);
}

/* --- Componente: ícones sociais circulares ------------------------------- */

.social-row {
  display: flex;
  gap: 6px;
  align-items: center;
}

.social-row a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid var(--border);
  color: var(--paper-dim);
  text-decoration: none;
  transition: border-color 0.3s, color 0.3s, background 0.3s;
}

.social-row a:hover {
  border-color: var(--lime);
  color: var(--lime);
  background: var(--lime-dim);
}

.social-row svg {
  width: 14px;
  height: 14px;
}

/* --- Componente: rodapé --------------------------------------------------- */

.footer {
  text-align: center;
  padding: 32px 0 48px;
  border-top: 1px solid var(--border);
}

.footer p {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--paper-dim);
}

/* --- Animação de entrada -------------------------------------------------- */
/* Adicione .animate a um elemento para ele surgir de baixo.
   Combine com .delay-1 ... .delay-6 para escalonar a entrada. */

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(18px); }
  to   { opacity: 1; transform: translateY(0); }
}

.animate {
  animation: fadeUp 0.6s ease-out both;
}

.delay-1 { animation-delay: 0.08s; }
.delay-2 { animation-delay: 0.16s; }
.delay-3 { animation-delay: 0.24s; }
.delay-4 { animation-delay: 0.32s; }
.delay-5 { animation-delay: 0.40s; }
.delay-6 { animation-delay: 0.48s; }

/* Respeita quem pediu menos movimento no sistema operacional. */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  body::before,
  .orb { animation: none; }
  .animate { animation: none; opacity: 1; transform: none; }
}

/* --- Responsivo ----------------------------------------------------------- */

@media (max-width: 640px) {
  .page-wrap { padding: 0 16px; }
}
