/* =========================================================================
   Mattos & Campos Advogados — Design System
   Estética premium jurídica: navy profundo + dourado da marca + marfim quente.
   ========================================================================= */

/* ---- Fontes auto-hospedadas (variáveis, woff2 subset latino) ---- */
@font-face {
  font-family: 'Fraunces';
  src: url('/fonts/fraunces-var.woff2') format('woff2');
  font-weight: 300 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Inter';
  src: url('/fonts/inter-var.woff2') format('woff2');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

/* ---- Design tokens ---- */
:root {
  /* Cores */
  --ink: #0e1a2b;          /* navy profundo (texto/headers) */
  --ink-soft: #1f3047;     /* navy mais claro */
  --gold: #ca9a69;         /* dourado da marca */
  --gold-deep: #a87c4f;    /* dourado para hover/contraste em fundo claro */
  --paper: #f7f5f1;        /* marfim quente (fundo) */
  --paper-2: #efeae2;      /* marfim mais fechado */
  --white: #ffffff;
  --text: #26303c;         /* corpo de texto */
  --text-soft: #5b6675;    /* texto secundário */
  --line: #e4ddd2;         /* linhas/bordas sutis */
  --line-dark: rgba(255, 255, 255, 0.12);

  /* Tipografia */
  --font-serif: 'Fraunces', Georgia, 'Times New Roman', serif;
  --font-sans: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;

  /* Escala fluida (clamp) */
  --step--1: clamp(0.83rem, 0.8rem + 0.15vw, 0.9rem);
  --step-0: clamp(1rem, 0.96rem + 0.2vw, 1.1rem);
  --step-1: clamp(1.2rem, 1.12rem + 0.4vw, 1.45rem);
  --step-2: clamp(1.5rem, 1.36rem + 0.7vw, 1.95rem);
  --step-3: clamp(1.85rem, 1.6rem + 1.25vw, 2.6rem);
  --step-4: clamp(2.3rem, 1.9rem + 2vw, 3.5rem);
  --step-5: clamp(2.8rem, 2.1rem + 3.5vw, 4.75rem);

  /* Layout */
  --container: 1180px;
  --container-narrow: 760px;
  --radius: 14px;
  --radius-sm: 8px;
  --shadow-sm: 0 1px 2px rgba(14, 26, 43, 0.06), 0 4px 16px rgba(14, 26, 43, 0.05);
  --shadow-md: 0 8px 30px rgba(14, 26, 43, 0.1);
  --shadow-lg: 0 30px 60px -20px rgba(14, 26, 43, 0.28);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* ---- Reset enxuto ---- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

body {
  font-family: var(--font-sans);
  font-size: var(--step-0);
  line-height: 1.7;
  color: var(--text);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, svg, video { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
ul, ol { padding: 0; list-style: none; }
button { font: inherit; cursor: pointer; }

/* ---- Tipografia ---- */
h1, h2, h3, h4 {
  font-family: var(--font-serif);
  font-weight: 500;
  line-height: 1.12;
  color: var(--ink);
  letter-spacing: -0.01em;
  text-wrap: balance;
}
h1 { font-size: var(--step-4); }
h2 { font-size: var(--step-3); }
h3 { font-size: var(--step-2); }
h4 { font-size: var(--step-1); }
p { text-wrap: pretty; }

/* ---- Utilidades de layout ---- */
.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: 1.5rem; }
.narrow { max-width: var(--container-narrow); margin-inline: auto; }
.section { padding-block: clamp(3.5rem, 2.5rem + 4vw, 7rem); }
.center { text-align: center; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 0.55rem;
  font-family: var(--font-sans);
  font-size: var(--step--1);
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold-deep);
}
.eyebrow::before { content: ''; width: 1.6rem; height: 1px; background: var(--gold); }
.eyebrow.center { justify-content: center; }

.lead { font-size: var(--step-1); color: var(--text-soft); line-height: 1.6; }

/* ---- Botões ---- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.6rem;
  padding: 0.95rem 1.7rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: var(--step-0);
  letter-spacing: 0.01em;
  border: 1px solid transparent;
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), background 0.25s, color 0.25s;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-2px); }
.btn-gold { background: var(--gold); color: var(--ink); box-shadow: var(--shadow-sm); }
.btn-gold:hover { background: #d9ad81; box-shadow: var(--shadow-md); }
.btn-ink { background: var(--ink); color: var(--white); }
.btn-ink:hover { background: var(--ink-soft); }
.btn-ghost { background: transparent; border-color: var(--line); color: var(--ink); }
.btn-ghost:hover { border-color: var(--gold); color: var(--gold-deep); }
.btn-outline-light { background: transparent; border-color: var(--line-dark); color: var(--white); }
.btn-outline-light:hover { border-color: var(--gold); color: var(--gold); }

/* ---- Cartões ---- */
.card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 2rem;
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease), border-color 0.3s;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: var(--gold); }

/* ---- Conteúdo de artigo (HTML vindo do WP) ---- */
.prose { font-size: var(--step-0); line-height: 1.8; color: var(--text); }
.prose > * + * { margin-top: 1.25rem; }
.prose h2 { font-size: var(--step-2); margin-top: 2.6rem; }
.prose h3 { font-size: var(--step-1); margin-top: 2rem; }
.prose h2 + p, .prose h3 + p { margin-top: 0.75rem; }
.prose p, .prose li { color: var(--text); }
.prose a { color: var(--gold-deep); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.prose a:hover { color: var(--ink); }
.prose ul, .prose ol { padding-left: 1.3rem; display: grid; gap: 0.6rem; }
.prose ul li { list-style: none; position: relative; }
.prose ul li::before { content: ''; position: absolute; left: -1.3rem; top: 0.65em; width: 7px; height: 7px; background: var(--gold); border-radius: 2px; transform: rotate(45deg); }
.prose ol { list-style: decimal; }
.prose img { border-radius: var(--radius); margin-block: 1.75rem; box-shadow: var(--shadow-sm); }
.prose blockquote {
  border-left: 3px solid var(--gold);
  padding: 0.4rem 0 0.4rem 1.5rem;
  font-family: var(--font-serif);
  font-size: var(--step-1);
  font-style: italic;
  color: var(--ink);
}
.prose strong { color: var(--ink); font-weight: 600; }
.prose figure { margin: 0; }
.prose table { width: 100%; border-collapse: collapse; font-size: var(--step--1); }
.prose th, .prose td { border: 1px solid var(--line); padding: 0.7rem 0.9rem; text-align: left; }
.prose th { background: var(--paper-2); font-weight: 600; }

/* ---- Acessibilidade ---- */
:focus-visible { outline: 2px solid var(--gold); 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;
}
.skip-link {
  position: absolute; left: 1rem; top: -3rem; z-index: 200;
  background: var(--ink); color: var(--white); padding: 0.6rem 1rem; border-radius: var(--radius-sm);
  transition: top 0.2s;
}
.skip-link:focus { top: 1rem; }

/* ---- Animação de entrada (reveal) ---- */
[data-reveal] { opacity: 0; transform: translateY(18px); transition: opacity 0.7s var(--ease), transform 0.7s var(--ease); }
[data-reveal].is-visible { opacity: 1; transform: none; }
