/* =============================================================
   mygamesandi — Base / Reset
   Elite Gamer Arena dark theme base.
   ============================================================= */

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  color-scheme: dark;
}

body {
  background: var(--color-bg-base);
  color: var(--color-text-primary);
  font-family: var(--font-body);
  line-height: var(--leading-normal);
  min-height: 100dvh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ─── Interactive elements — prevent double-tap zoom on mobile */
button,
a,
input,
select,
textarea,
[role="button"],
[tabindex] {
  touch-action: manipulation;
}

/* ─── Headings ───────────────────────────────────────────────*/
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  line-height: var(--leading-tight);
  font-weight: var(--fw-bold);
  color: var(--color-text-primary);
}

/* ─── Focus ring — cyan for dark theme ──────────────────────*/
:focus-visible {
  outline: 2px solid var(--color-accent-cyan);
  outline-offset: 3px;
  border-radius: 4px;
}

:focus:not(:focus-visible) {
  outline: none;
}

/* ─── Links ──────────────────────────────────────────────────*/
a {
  color: var(--color-accent-cyan);
  text-decoration: none;
}

a:hover {
  color: var(--color-accent-yellow);
  text-decoration: underline;
}

/* ─── Images ─────────────────────────────────────────────────*/
img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* ─── Text selection — cyan highlight ────────────────────────*/
::selection {
  background: rgba(0, 212, 255, 0.25);
  color: var(--color-text-primary);
}

/* ─── Custom scrollbar — dark theme ─────────────────────────*/
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: var(--color-bg-panel);
}

::-webkit-scrollbar-thumb {
  background: var(--color-border-subtle);
  border-radius: var(--radius-full);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--color-text-muted);
}

/* Firefox scrollbar */
* {
  scrollbar-width: thin;
  scrollbar-color: var(--color-border-subtle) var(--color-bg-panel);
}

/* ─── 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;
  }

  /* Strip glow effects in reduced motion */
  .glow-cyan,
  .glow-yellow,
  .glow-purple {
    box-shadow: none !important;
  }

  .text-glow-cyan,
  .text-glow-yellow {
    text-shadow: none !important;
  }
}
