/* Base compartilhada: cores, tipografia, botoes e campos */
/* Fontes hospedadas junto com o site (sem depender de servidores externos) */
@font-face { font-family: 'Handlee'; font-weight: 400; font-style: normal; font-display: swap; src: url('../fonts/handlee-latin-400-normal.woff2') format('woff2'); }
@font-face { font-family: 'Jost'; font-weight: 400; font-style: normal; font-display: swap; src: url('../fonts/jost-latin-400-normal.woff2') format('woff2'); }
@font-face { font-family: 'Jost'; font-weight: 500; font-style: normal; font-display: swap; src: url('../fonts/jost-latin-500-normal.woff2') format('woff2'); }
@font-face { font-family: 'Jost'; font-weight: 600; font-style: normal; font-display: swap; src: url('../fonts/jost-latin-600-normal.woff2') format('woff2'); }
@font-face { font-family: 'Jost'; font-weight: 400; font-style: italic; font-display: swap; src: url('../fonts/jost-latin-400-italic.woff2') format('woff2'); }
@font-face { font-family: 'Jost'; font-weight: 500 700; font-style: italic; font-display: swap; src: url('../fonts/jost-latin-500-italic.woff2') format('woff2'); }

:root {
  /* Paleta tirada das artes do Instagram: linho, cacau, terracota, oliva */
  --noite: #4b3a2c;
  --noite-2: #5c4838;
  --nevoa: #e8e2d2;
  --linho: #dcd5c3;
  --papel: #f5f1e6;
  --ametista: #a9553e;        /* terracota (botões e destaques) */
  --ametista-esc: #8e4330;
  --ouro: #8f9a78;            /* oliva */
  --ouro-suave: #e4e3cf;
  --estrela: #e3b586;
  --texto: #5a4636;
  --suave: #7d6b5a;
  --linha: #cbbfa8;
  --erro: #a32b2b;
  --erro-fundo: #f6e3df;
  --ok: #4f7a58;
  --ok-fundo: #e2ecdf;
  --titulo: 'Handlee', 'Patrick Hand', 'Segoe Print', cursive;
  --corpo: 'Jost', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background-color: var(--linho);
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='240' height='240'><filter id='l'><feTurbulence type='fractalNoise' baseFrequency='0.012 0.8' numOctaves='2' seed='7'/><feColorMatrix values='0 0 0 0 .40  0 0 0 0 .32  0 0 0 0 .22  0 0 0 .16 0'/></filter><rect width='100%' height='100%' filter='url(%23l)'/></svg>");
  color: var(--texto);
  font-family: var(--corpo);
  font-size: 1.0625rem;
  line-height: 1.6;
}
h1, h2, h3 { font-family: var(--titulo); font-weight: 400; line-height: 1.2; margin: 0; color: var(--ametista); }
h1, h2 { text-transform: uppercase; letter-spacing: 0.1em; font-weight: 400; }
p { margin: 0 0 1em; }
a { color: var(--ametista-esc); }
img, svg { max-width: 100%; }
[hidden] { display: none !important; }

:focus-visible { outline: 3px solid var(--ametista); outline-offset: 2px; border-radius: 4px; }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

/* ---------- botoes ---------- */
.btn {
  appearance: none; border: 2px solid transparent; cursor: pointer;
  font: inherit; font-weight: 600; line-height: 1.2;
  padding: 0.8rem 1.4rem; border-radius: 999px; min-height: 48px;
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  text-decoration: none; transition: background-color 0.15s, border-color 0.15s, color 0.15s;
}
.btn-principal { background: var(--ametista); color: #fff; }
.btn-principal:hover { background: var(--ametista-esc); }
.btn-contorno { background: transparent; color: var(--ametista-esc); border-color: var(--ametista); }
.btn-contorno:hover { background: var(--nevoa); }
.btn-perigo { background: transparent; color: var(--erro); border-color: var(--erro); }
.btn-perigo:hover { background: var(--erro-fundo); }
.btn-pequeno { min-height: 38px; padding: 0.4rem 0.9rem; font-size: 0.9375rem; }
.btn-grande { width: 100%; font-size: 1.125rem; padding: 1rem 1.4rem; }
.btn[disabled] { opacity: 0.55; cursor: not-allowed; }
.link-botao {
  appearance: none; background: none; border: 0; padding: 0; font: inherit; cursor: pointer;
  color: var(--ametista-esc); text-decoration: underline;
}

/* ---------- campos ---------- */
.campo { display: block; margin-bottom: 1rem; }
.campo > span, .campo > legend { display: block; font-weight: 600; margin-bottom: 0.3rem; font-size: 0.9875rem; }
.campo small { display: block; color: var(--suave); font-size: 0.875rem; margin-top: 0.25rem; }
input[type='text'], input[type='email'], input[type='tel'], input[type='date'],
input[type='password'], input[type='time'], input[type='search'], select, textarea {
  width: 100%; font: inherit; font-size: 1rem; /* 16px evita zoom no iPhone */
  padding: 0.7rem 0.85rem; min-height: 48px;
  background: #fff; color: var(--texto);
  border: 1.5px solid var(--linha); border-radius: 10px;
}
textarea { min-height: 110px; resize: vertical; line-height: 1.5; }
input:focus, select:focus, textarea:focus { border-color: var(--ametista); outline: 3px solid rgba(91, 71, 168, 0.25); outline-offset: 0; }

.aviso { padding: 0.85rem 1rem; border-radius: 10px; margin: 0 0 1rem; font-size: 0.9875rem; }
.aviso-erro { background: var(--erro-fundo); color: var(--erro); }
.aviso-ok { background: var(--ok-fundo); color: var(--ok); }
.aviso-info { background: #fff; border: 1px solid var(--linha); color: var(--suave); }

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}
