/* ──────────────────────────────────────────────────────────────
   Curral Tech · folha de estilo compartilhada das páginas estáticas
   (sobre, termos, blog). Mesmo sistema de design da landing e da
   /privacy: navy #002848, verde #496800, lime #C0EF65, Fredoka+Inter.
   Servida da raiz do public/ pelo Netlify: <link href="/legal.css">.
   ────────────────────────────────────────────────────────────── */

:root {
  --primary: #002848;
  --primary-container: #003E6B;
  --primary-on: #FFFFFF;
  --secondary: #496800;
  --secondary-container: #C0EF65;
  --secondary-on-container: #1F2E00;
  --surface: #F7F9FC;
  --surface-low: #F2F4F7;
  --surface-high: #FFFFFF;
  --on-surface: #191C1E;
  --on-surface-muted: #4A5468;
  --border: #E2E8F0;
  --shadow-ambient: 0px 12px 32px rgba(0, 40, 72, 0.06);
  --shadow-ambient-strong: 0px 20px 48px rgba(0, 40, 72, 0.10);
  --radius-lg: 1.25rem;
  --radius-xl: 1.5rem;
}

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

html {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background: var(--surface);
  color: var(--on-surface);
  line-height: 1.7;
  font-size: 16px;
  font-feature-settings: 'ss01', 'cv11';
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Fredoka', system-ui, sans-serif;
  color: var(--primary);
  letter-spacing: -0.02em;
  text-wrap: balance;
}

/* ─── Header ─── */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(0, 40, 72, 0.06);
  padding: 1rem 0;
}
.header-inner {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}
.brand {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  font-family: 'Fredoka', sans-serif;
  font-weight: 700;
  font-size: 1.125rem;
  color: var(--primary);
  text-decoration: none;
}
.brand img { width: 34px; height: 34px; border-radius: 8px; object-fit: contain; }
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  color: var(--primary);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 500;
  opacity: 0.7;
  transition: opacity 200ms ease;
  padding: 0.5rem 1rem;
  border-radius: 9999px;
  background: var(--surface-low);
}
.back-link:hover { opacity: 1; }

/* ─── Hero ─── */
.hero {
  padding: 4rem 1.5rem 3.5rem;
  text-align: center;
  position: relative;
}
.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 600px;
  height: 600px;
  max-width: 100%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(192, 239, 101, 0.12) 0%, transparent 70%);
  pointer-events: none;
}
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.375rem 1rem;
  border-radius: 9999px;
  background: rgba(0, 40, 72, 0.06);
  color: var(--primary);
  font-family: 'Inter', sans-serif;
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  margin-bottom: 1.25rem;
}
.hero h1 {
  font-size: clamp(2rem, 4.4vw, 3.25rem);
  font-weight: 700;
  line-height: 1.08;
  color: var(--primary);
  margin-bottom: 0.75rem;
}
.hero-meta {
  font-size: 0.9375rem;
  color: var(--on-surface-muted);
  max-width: 560px;
  margin: 0 auto;
  line-height: 1.6;
}

/* ─── Main container ─── */
main {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 1.5rem 5rem;
}

/* ─── Document card ─── */
.doc {
  background: var(--surface-high);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-ambient);
  padding: 3rem 3rem;
}
.doc section { margin-top: 3rem; }
.doc section:first-of-type { margin-top: 0; }
.doc h2 {
  font-size: 1.375rem;
  font-weight: 700;
  margin-bottom: 1rem;
  padding-bottom: 0.625rem;
  border-bottom: 2px solid var(--surface-low);
  line-height: 1.2;
}
.doc h3 {
  font-size: 1.0625rem;
  font-weight: 600;
  margin-top: 1.75rem;
  margin-bottom: 0.5rem;
  color: var(--primary-container);
}
.doc p { margin-top: 0.75rem; max-width: 68ch; color: var(--on-surface); }
.doc p:first-child { margin-top: 0; }
.doc ul, .doc ol { margin: 0.75rem 0 0 1.25rem; max-width: 68ch; }
.doc li { margin-top: 0.4rem; color: var(--on-surface); }
.doc strong { color: var(--primary); font-weight: 600; }
.doc a {
  color: var(--primary-container);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
  transition: color 150ms ease;
}
.doc a:hover { color: var(--primary); text-decoration-thickness: 2px; }

/* ─── Tables ─── */
.doc table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 1rem;
  font-size: 0.9375rem;
  border-radius: 0.75rem;
  overflow: hidden;
  box-shadow: 0 0 0 1px var(--border);
}
.doc th, .doc td {
  padding: 0.75rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}
.doc th {
  background: var(--surface-low);
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  color: var(--primary);
  font-size: 0.8125rem;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}
.doc tr:last-child td { border-bottom: none; }

/* ─── Callout ─── */
.callout {
  background: linear-gradient(135deg, rgba(192, 239, 101, 0.1) 0%, rgba(192, 239, 101, 0.04) 100%);
  border-left: 3px solid var(--secondary);
  padding: 1rem 1.25rem;
  border-radius: 0 0.625rem 0.625rem 0;
  margin-top: 1rem;
  font-size: 0.9375rem;
}

/* ─── TOC ─── */
.toc {
  background: var(--surface-low);
  border-radius: var(--radius-lg);
  padding: 1.5rem 2rem;
  margin-bottom: 2.5rem;
}
.toc-title {
  border: none !important;
  padding: 0 !important;
  font-size: 0.75rem !important;
  margin-bottom: 0.875rem !important;
  color: var(--on-surface-muted) !important;
  font-weight: 700 !important;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.toc ol {
  list-style: decimal;
  columns: 2;
  column-gap: 2.5rem;
  margin: 0;
  padding-left: 1.25rem;
  font-size: 0.9375rem;
}
.toc li { margin-top: 0.3rem; break-inside: avoid; }
.toc a { color: var(--primary-container); text-decoration: none; transition: color 150ms ease; }
.toc a:hover { color: var(--primary); text-decoration: underline; }

/* ─── Cards grid (Sobre) ─── */
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
  margin-top: 1.25rem;
}
.info-card {
  background: var(--surface-low);
  border-radius: var(--radius-lg);
  padding: 1.5rem 1.75rem;
}
.info-card h3 {
  margin-top: 0;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--on-surface-muted);
  font-weight: 700;
}
.info-card p { margin-top: 0.5rem; font-size: 0.9375rem; }
.info-card a { color: var(--primary-container); }

/* ─── Pill button (CTA WhatsApp) ─── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.8125rem 1.5rem;
  border-radius: 9999px;
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  font-size: 0.9375rem;
  text-decoration: none;
  transition: transform 200ms cubic-bezier(0.25, 1, 0.5, 1), box-shadow 200ms ease;
  cursor: pointer;
  border: none;
}
.btn-primary {
  background: var(--primary);
  color: var(--primary-on);
  box-shadow: var(--shadow-ambient);
}
.btn-primary:hover { transform: translateY(-1px); box-shadow: var(--shadow-ambient-strong); }
.btn-ghost {
  background: var(--surface-low);
  color: var(--primary);
}
.btn-ghost:hover { transform: translateY(-1px); }

/* ─── Empty state (Blog em breve) ─── */
.empty {
  text-align: center;
  padding: 1rem 0 0;
}
.empty-icon {
  width: 64px;
  height: 64px;
  border-radius: 9999px;
  background: var(--secondary-container);
  color: var(--secondary-on-container);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
}
.empty h2 { border: none; padding: 0; margin-bottom: 0.75rem; font-size: 1.5rem; }
.empty p { margin: 0 auto; max-width: 46ch; color: var(--on-surface-muted); }
.empty .actions {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 2rem;
}

/* ─── Footer ─── */
footer {
  background: var(--primary);
  color: var(--primary-on);
  padding: 3rem 0;
}
.footer-inner {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  text-align: center;
}
.footer-brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: 'Fredoka', sans-serif;
  font-weight: 700;
  font-size: 1rem;
  margin-bottom: 0.5rem;
}
.footer-brand img { width: 28px; height: 28px; border-radius: 6px; object-fit: contain; }
.footer-inner p { margin: 0; font-size: 0.8125rem; opacity: 0.7; line-height: 1.6; }
.footer-inner a { color: var(--secondary-container); text-decoration: none; }
.footer-inner a:hover { text-decoration: underline; }
.footer-links { margin-top: 0.75rem; display: flex; gap: 1rem; flex-wrap: wrap; justify-content: center; }
.footer-divider { width: 48px; height: 1px; background: rgba(255, 255, 255, 0.15); margin: 0.75rem 0; }

/* ─── Responsive ─── */
@media (max-width: 640px) {
  body { font-size: 15px; }
  .doc { padding: 2rem 1.5rem; border-radius: var(--radius-lg); }
  .hero { padding: 3rem 1.5rem 3rem; }
  .hero h1 { font-size: 1.75rem; }
  .toc ol { columns: 1; }
  .doc table { font-size: 0.875rem; }
  .doc th, .doc td { padding: 0.5rem 0.75rem; }
  .toc { padding: 1.25rem 1.5rem; }
  .grid-2 { grid-template-columns: 1fr; }
}

/* ─── Print ─── */
@media print {
  .header, footer, .toc, .back-link { display: none; }
  .hero { padding: 1rem 0; }
  .hero::before { display: none; }
  .doc { box-shadow: none; padding: 0; border-radius: 0; }
  body { background: white; }
}

/* ─── Focus ─── */
:focus-visible { outline: 2px solid var(--primary); outline-offset: 3px; border-radius: 4px; }

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