/* ============================================================
   SUKATA — Base: reset, tipografia, utilidades, acessibilidade
   ============================================================ */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg-0);
  color: var(--text-1);
  font-family: var(--font-ui);
  font-size: var(--fs-14);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

body::before {
  /* brilho de fundo da página (dark premium) */
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    var(--page-glow-1),
    var(--page-glow-2),
    linear-gradient(180deg, var(--bg-0) 0%, var(--bg-1) 100%);
}

img,
svg,
canvas {
  display: inline-block;
  vertical-align: middle;
  max-width: 100%;
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

a {
  color: var(--suk-orange-2);
  text-decoration: none;
  border-radius: var(--radius-sm);
}

a:hover {
  color: var(--suk-orange);
  text-decoration: underline;
  text-underline-offset: 3px;
}

h1, h2, h3, h4 {
  margin: 0 0 var(--sp-3);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.015em;
  color: var(--text-1);
}

h1 { font-size: var(--fs-34); }
h2 { font-size: var(--fs-20); }
h3 { font-size: var(--fs-16); }
p { margin: 0 0 var(--sp-3); }
code, pre, kbd { font-family: var(--font-mono); }

::selection {
  background: var(--suk-orange-soft);
  color: var(--text-1);
}

/* Scrollbar discreta */
* {
  scrollbar-width: thin;
  scrollbar-color: rgba(148, 163, 184, 0.25) transparent;
}
*::-webkit-scrollbar { width: 10px; height: 10px; }
*::-webkit-scrollbar-thumb {
  background: rgba(148, 163, 184, 0.22);
  border-radius: 8px;
  border: 3px solid transparent;
  background-clip: content-box;
}
*::-webkit-scrollbar-track { background: transparent; }

/* ---- Foco visível ---- */
:focus { outline: none; }
:focus-visible {
  outline: 2px solid var(--border-focus);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

/* ---- Acessibilidade ---- */
.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: fixed;
  top: -100px;
  left: var(--sp-4);
  z-index: 300;
  background: var(--surface-2);
  color: var(--text-1);
  padding: var(--sp-2) var(--sp-4);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-md);
  transition: top var(--dur) var(--ease);
}
.skip-link:focus { top: var(--sp-3); }

kbd {
  font-size: var(--fs-11);
  line-height: 1;
  padding: 4px 6px;
  border: 1px solid var(--border-strong);
  border-bottom-width: 2px;
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  color: var(--text-2);
  white-space: nowrap;
}

/* ---- Utilidades ---- */
.muted { color: var(--text-2); }
.muted-2 { color: var(--text-3); }
.strong { color: var(--text-1); font-weight: 600; }
.mono { font-family: var(--font-mono); font-size: 0.92em; }
.nowrap { white-space: nowrap; }
.truncate {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.row { display: flex; align-items: center; gap: var(--sp-2); }
.row-between { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-3); }
.col { display: flex; flex-direction: column; gap: var(--sp-2); }
.grow { flex: 1 1 auto; min-width: 0; }
.wrap { flex-wrap: wrap; }
.center { text-align: center; }
.hidden { display: none !important; }

/* ---- Layout de página interna ---- */
.page {
  width: 100%;
  max-width: var(--content-max);
  margin: 0 auto;
  padding: var(--sp-6) var(--sp-8) var(--sp-12);
}
.page-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--sp-4);
  margin-bottom: var(--sp-6);
  flex-wrap: wrap;
}
.page-title { margin-bottom: var(--sp-1); }
.page-sub { color: var(--text-2); max-width: 640px; margin: 0; }

@media (max-width: 768px) {
  .page { padding: var(--sp-5) var(--sp-4) var(--sp-10); }
}

/* ---- Prefers reduced motion ---- */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
