/* =========================================================
   TUCANO VERDE — Base (reset, tipografia, botões, badges,
   animações, toasts)
   ========================================================= */

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

/* 18/ago/2026 — bug real encontrado ao vivo: o painel /admin não escondia
   mais a tela de login depois de entrar (ficava sobreposta em cima da
   lista de pedidos). Causa: `.admin-login { display: flex }` (regra de
   autor) vence o `[hidden] { display: none }` do navegador na cascata —
   MESMO bug que o comentário no topo de 03-layout.css já alertava pro
   age-gate, só que aqui ninguém tinha aplicado o `:not([hidden])`. Achado
   também no `.btn` base (o botão "Sair" aparecia antes mesmo de logar).
   Em vez de caçar `:not([hidden])` classe por classe pra sempre lembrar de
   novo, resolve de vez aqui: `hidden` sempre ganha de qualquer `display`
   de qualquer classe, ponto final — é o mesmo reset que sanitize.css/
   normalize.css usam exatamente por essa razão. */
[hidden] { display: none !important; }

body {
  margin: 0;
  background: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: none; cursor: pointer; padding: 0; }
input, textarea, select { font: inherit; color: inherit; }
ul, ol { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, h4, h5 { margin: 0; font-family: var(--font-display); font-weight: 700; letter-spacing: -0.01em; color: var(--color-primary-dark); }
p { margin: 0; }

h1 { font-size: clamp(2rem, 1.6rem + 1.8vw, 3.2rem); line-height: 1.08; font-weight: 800; }
h2 { font-size: clamp(1.5rem, 1.3rem + 0.9vw, 2.25rem); line-height: 1.15; }
h3 { font-size: 1.25rem; line-height: 1.3; }

.lead { font-size: 1.125rem; color: var(--color-text-muted); }

.container {
  width: 100%;
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--space-4);
}
@media (min-width: 768px) { .container { padding-inline: var(--space-6); } }

.section { padding-block: var(--space-8); }
.section--tight { padding-block: var(--space-6); }
.section--cream { background: var(--color-surface-alt); }
.section--forest { background: var(--color-forest-800); color: var(--color-text-on-dark); }
.section--forest h2, .section--forest .section__title { color: var(--color-text-on-dark); }
.section--forest .section__subtitle { color: var(--color-text-on-dark-muted); }

.section__eyebrow {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-primary-light);
  margin-bottom: var(--space-2);
}
.section--forest .section__eyebrow { color: var(--color-accent); }
.section__title { margin-bottom: var(--space-2); }
.section__subtitle { color: var(--color-text-muted); max-width: 56ch; }
.section__header {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: var(--space-6);
}

/* ---- Botões ---- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: 13px 22px;
  border-radius: var(--radius-full);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.95rem;
  white-space: nowrap;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease, color 0.15s ease;
}
.btn:active { transform: scale(0.97); }
.btn svg { width: 18px; height: 18px; }

.btn--primary { background: var(--color-primary); color: #fff; }
.btn--primary:hover { background: var(--color-primary-dark); }

.btn--outline { background: transparent; color: #fff; box-shadow: inset 0 0 0 1.5px rgba(255,255,255,0.6); }
.btn--outline:hover { box-shadow: inset 0 0 0 1.5px #fff; }

.btn--outline-dark { background: transparent; color: var(--color-primary-dark); box-shadow: inset 0 0 0 1.5px var(--color-border); }
.btn--outline-dark:hover { box-shadow: inset 0 0 0 1.5px var(--color-primary); }

.btn--dark { background: var(--color-ink); color: var(--color-neon); }
.btn--dark:hover { background: var(--color-ink-soft); }

.btn--whatsapp { background: #25d366; color: #0b3b1f; }
.btn--whatsapp:hover { filter: brightness(1.05); }

.btn--full { width: 100%; }
.btn--sm { padding: 11px 18px; font-size: 0.9rem; } /* 18/ago/2026: era 9px/0.85rem — bump geral de legibilidade/toque pedido pelo usuário */

.btn--icon {
  width: 40px; height: 40px; border-radius: var(--radius-full);
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--color-surface-alt);
}
.btn--icon:hover { background: var(--color-border); }
.btn--icon svg { width: 18px; height: 18px; }

/* ---- Badges ---- */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 3px 8px;
  border-radius: var(--radius-full);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.6rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}
.badge--bestseller { background: var(--color-forest-100); color: var(--color-forest-700); }
.badge--new { background: var(--color-ink); color: var(--color-neon); }
.badge--featured { background: var(--color-primary-dark); color: #fff; }
.badge--sale { background: var(--color-danger); color: #fff; }

.icon { display: inline-flex; }
.icon svg { width: 18px; height: 18px; }

.dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--color-primary-light);
  display: inline-block;
}

/* ---- Animações de entrada ---- */
.reveal {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.is-visible { opacity: 1; transform: none; }

.reveal-stagger > * {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.reveal-stagger.is-visible > * { opacity: 1; transform: none; }
.reveal-stagger.is-visible > *:nth-child(1) { transition-delay: 0.02s; }
.reveal-stagger.is-visible > *:nth-child(2) { transition-delay: 0.08s; }
.reveal-stagger.is-visible > *:nth-child(3) { transition-delay: 0.14s; }
.reveal-stagger.is-visible > *:nth-child(4) { transition-delay: 0.2s; }
.reveal-stagger.is-visible > *:nth-child(5) { transition-delay: 0.26s; }
.reveal-stagger.is-visible > *:nth-child(6) { transition-delay: 0.32s; }
.reveal-stagger.is-visible > *:nth-child(n+7) { transition-delay: 0.36s; }

@media (prefers-reduced-motion: reduce) {
  .reveal, .reveal-stagger > * { opacity: 1; transform: none; transition: none; }
}

/* ---- Toasts ---- */
.toast-stack {
  position: fixed;
  bottom: var(--space-5);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  z-index: var(--z-toast);
  width: min(360px, calc(100vw - 32px));
}
.toast {
  background: var(--color-ink);
  color: #fff;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 600;
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: var(--space-1);
  animation: toast-in 0.25s ease;
}
.toast svg { width: 18px; height: 18px; flex-shrink: 0; } /* sem isso, o ícone
  não tinha limite de tamanho nenhum e renderizava a ~208px — a causa real do
  toast parecendo gigante, não o padding/fonte */
.toast--success { background: var(--color-forest-700); }
.toast--error { background: var(--color-danger); }
@keyframes toast-in {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: none; }
}

.config-note {
  display: flex;
  gap: var(--space-2);
  align-items: flex-start;
  background: var(--color-forest-100);
  border: 1px dashed var(--color-forest-500);
  color: var(--color-forest-700);
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-md);
  font-size: 0.85rem;
  margin-top: var(--space-4);
}
.config-note .icon { flex-shrink: 0; margin-top: 1px; }
