/* ─── Reset moderno ─────────────────────────────────────────────── */
*,
*::before,
*::after {
  box-sizing: border-box;
}

* {
  margin: 0;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

html:focus-within {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-family: var(--font-body);
  color: var(--color-ink);
  background: var(--color-bg);
  font-size: 16px;
  overflow-x: hidden;
}

img,
picture,
svg,
video {
  display: block;
  max-width: 100%;
  height: auto;
}

input,
button,
textarea,
select {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
  background: none;
  border: 0;
  padding: 0;
}

ul,
ol {
  padding: 0;
  list-style: none;
}

a {
  color: var(--color-brand);
  text-decoration: none;
  transition: color var(--duration) var(--ease);
}

a:hover {
  color: var(--color-brand-dark);
}

/* ─── Tipografia ────────────────────────────────────────────────── */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.2;
  color: var(--color-ink);
  letter-spacing: -0.01em;
}

h1 {
  font-size: clamp(2rem, 4vw + 1rem, 3.5rem);
  font-weight: 800;
  letter-spacing: -0.02em;
}

h2 {
  font-size: clamp(1.625rem, 2.5vw + 0.75rem, 2.5rem);
  letter-spacing: -0.015em;
}

h3 {
  font-size: clamp(1.25rem, 1.5vw + 0.5rem, 1.625rem);
}

h4 {
  font-size: clamp(1.125rem, 0.5vw + 0.875rem, 1.25rem);
}

p {
  color: var(--color-ink-muted);
}

strong {
  font-weight: 600;
  color: var(--color-ink);
}

small {
  font-size: 0.875em;
}

/* ─── Foco acessível ───────────────────────────────────────────── */
:focus {
  outline: none;
}

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

/* ─── Skip link ────────────────────────────────────────────────── */
.skip-link {
  position: fixed;
  top: -100px;
  left: var(--space-4);
  background: var(--color-brand);
  color: #fff;
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-sm);
  z-index: 999;
  font-weight: 600;
  transition: top var(--duration) var(--ease);
}

.skip-link:focus {
  top: var(--space-4);
  color: #fff;
}

/* ─── Seleção ──────────────────────────────────────────────────── */
::selection {
  background: var(--color-brand-soft);
  color: var(--color-brand-dark);
}

/* ─── Scrollbar (Webkit) ───────────────────────────────────────── */
::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}
::-webkit-scrollbar-track {
  background: var(--color-surface);
}
::-webkit-scrollbar-thumb {
  background: var(--color-border-strong);
  border-radius: 5px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--color-muted);
}
