/* ConfTech · base: reset, tipografia, foco, utilitários mínimos, impressão */

*, *::before, *::after { box-sizing: border-box; }
html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scrollbar-gutter: stable;
  scrollbar-width: thin;
  scrollbar-color: rgb(var(--border-strong)) transparent;
}
body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  background: rgb(var(--bg));
  color: rgb(var(--text));
  font: 400 var(--text-base)/1.5 var(--font-sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
img, svg { max-width: 100%; display: block; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
[hidden] { display: none !important; }

h1, h2, h3, h4 { margin: 0; font-weight: 600; line-height: 1.25; color: rgb(var(--text)); text-wrap: balance; }
p { margin: 0 0 var(--sp-3); }
p:last-child { margin-bottom: 0; }
a { color: rgb(var(--link)); text-decoration: none; text-underline-offset: 3px; }
a:hover { text-decoration: underline; }
hr { border: 0; border-top: 1px solid rgb(var(--border)); margin: var(--sp-6) 0; }
small { font-size: var(--text-sm); }
code, kbd, samp, .mono { font-family: var(--font-mono); font-size: .92em; }
ul, ol { margin: 0; padding-left: 1.25rem; }

/* Foco: anel de 2 px, nunca removido */
:focus { outline: none; }
:focus-visible {
  outline: 2px solid rgb(var(--focus));
  outline-offset: 2px;
  border-radius: var(--r-sm);
}
::selection { background: rgb(var(--primary) / .28); }

/* Ícones (sprite SVG) */
.icon {
  width: 1.125rem; height: 1.125rem; flex: none;
  fill: none; stroke: currentColor; stroke-width: 1.75;
  stroke-linecap: round; stroke-linejoin: round;
}
.icon-sm { width: 1rem; height: 1rem; }
.icon-lg { width: 1.375rem; height: 1.375rem; }

/* Utilitários mínimos (o resto é componente) */
.sr-only {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.num { font-variant-numeric: tabular-nums; text-align: right; }
.mono { font-variant-numeric: tabular-nums; }
.muted { color: rgb(var(--text-3)); }
.nowrap { white-space: nowrap; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.break { overflow-wrap: anywhere; }
.stack { display: grid; gap: var(--sp-4); }
.stack-sm { display: grid; gap: var(--sp-2); }
.stack-lg { display: grid; gap: var(--sp-6); }
.cluster { display: flex; flex-wrap: wrap; align-items: center; gap: var(--sp-2); }
.cluster-between { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--sp-3); }
.push { margin-left: auto; }
.mt-4 { margin-top: var(--sp-4); }
.mt-6 { margin-top: var(--sp-6); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
    scroll-behavior: auto !important;
  }
}

/* Impressão: sempre no claro, sem menu */
@media print {
  :root, :root[data-theme="dark"] {
    --bg: 255 255 255; --surface: 255 255 255; --surface-2: 245 245 245;
    --border: 190 190 190; --border-strong: 120 120 120;
    --text: 0 0 0; --text-2: 40 40 40; --text-3: 70 70 70; --link: 0 0 0;
    color-scheme: light;
  }
  body { background: #fff; font-size: 11pt; }
  .no-print, .sidebar, .topbar, .toasts, .skip-link, .page-actions, .filters, .pagination { display: none !important; }
  .app { display: block !important; }
  .main { padding: 0 !important; max-width: none !important; }
  a { text-decoration: underline; }
  .card, .table-wrap { box-shadow: none; break-inside: avoid; }
  tr { break-inside: avoid; }
}
