/**
 * CSS Reset
 * Normalizes browser default styles for consistent baseline
 */

/* ============================================
   Box Sizing & Basic Resets
   ============================================ */

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

html {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

body {
  margin: 0;
  padding: 0;
  min-height: 100vh;
  line-height: 1.5;
}


/* ============================================
   Typography Resets
   ============================================ */

h1, h2, h3, h4, h5, h6 {
  margin: 0;
  font-weight: inherit;
  font-size: inherit;
}

p {
  margin: 0;
}

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

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

strong, b {
  font-weight: bolder;
}

em, i {
  font-style: italic;
}


/* ============================================
   Form Elements
   ============================================ */

button,
input,
textarea,
select {
  font-family: inherit;
  font-size: inherit;
  line-height: inherit;
  color: inherit;
  background: none;
  border: none;
  outline: none;
}

button {
  cursor: pointer;
  user-select: none;
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.5;
}

input:focus,
textarea:focus,
select:focus,
button:focus {
  outline: none;
}

/* Remove default input styles */
input[type="text"],
input[type="password"],
input[type="email"],
input[type="number"],
textarea {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
}

/* Remove spinner arrows from number inputs */
input[type="number"]::-webkit-inner-spin-button,
input[type="number"]::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

input[type="number"] {
  -moz-appearance: textfield;
}


/* ============================================
   Media Elements
   ============================================ */

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

img {
  border-style: none;
}


/* ============================================
   Tables
   ============================================ */

table {
  border-collapse: collapse;
  border-spacing: 0;
}


/* ============================================
   Accessibility
   ============================================ */

/* Remove default focus for mouse users, keep for keyboard users */
:focus:not(:focus-visible) {
  outline: none;
}

:focus-visible {
  outline: var(--focus-outline, 2px solid currentColor);
  outline-offset: var(--focus-outline-offset, 2px);
}

/* Reduce motion for users who prefer it */
@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;
  }
}


/* ============================================
   Selection
   ============================================ */

::selection {
  background-color: var(--color-accent-primary, #d4a574);
  color: var(--color-text-on-accent, #1a1a1a);
}

::-moz-selection {
  background-color: var(--color-accent-primary, #d4a574);
  color: var(--color-text-on-accent, #1a1a1a);
}


/* ============================================
   Scrollbar (Webkit browsers)
   ============================================ */

::-webkit-scrollbar {
  width: 12px;
  height: 12px;
}

::-webkit-scrollbar-track {
  background: var(--color-bg-primary, #1a1a1a);
}

::-webkit-scrollbar-thumb {
  background: var(--color-bg-elevated, #3a3a3a);
  border-radius: var(--radius-md, 8px);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--color-accent-primary, #d4a574);
}
