/* ============================================
   Global Base Styles (non-scoped)
   Reset, root element defaults, global utilities,
   reusable keyframes. References Tier 2 tokens only.
   ============================================ */

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

html {
  font-family: var(--font-mono);
  font-size: 16px;
  line-height: var(--leading-normal);
  -webkit-text-size-adjust: 100%;
  tab-size: 4;
}

body {
  background-color: var(--bg-primary);
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: var(--font-size-md);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow: hidden;
}

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

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

a {
  color: inherit;
  text-decoration: none;
}

code {
  font-family: var(--font-code);
}

ul, ol {
  list-style: none;
}

::selection {
  background-color: var(--selection-bg);
  color: var(--text-primary);
}

@keyframes blink {
  0%, 50% { opacity: 1; }
  51%, 100% { opacity: 0; }
}

.scrollbar-thin {
  scrollbar-width: thin;
  scrollbar-color: var(--text-muted) transparent;
}

.scrollbar-thin::-webkit-scrollbar {
  width: var(--space-1_5);
}

.scrollbar-thin::-webkit-scrollbar-track {
  background: transparent;
}

.scrollbar-thin::-webkit-scrollbar-thumb {
  background-color: var(--text-muted);
  border-radius: var(--radius-sm);
}

.scrollbar-thin::-webkit-scrollbar-thumb:hover {
  background-color: var(--text-dim);
}

.glow {
  text-shadow: 0 0 1.5px currentColor;
}

.flex {
  display: flex;
}

.flex-center {
  display: flex;
  align-items: center;
  justify-content: center;
}

.flex-col {
  display: flex;
  flex-direction: column;
}
