/* Base Styles and Reset */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

/* Focus styles for accessibility */
*:focus {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

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

/* Selection styles */
::selection {
  background-color: var(--primary);
  color: white;
}

/* Scrollbar styles */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

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

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

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

/* Links */
a {
  color: var(--primary);
  text-decoration: none;
  transition: color var(--transition-normal);
}

a:hover {
  color: var(--primary-hover);
}

/* Lists */
ul,
ol {
  list-style: none;
}

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

/* Tables */
table {
  border-collapse: collapse;
  width: 100%;
}

/* Form elements */
input,
button,
textarea,
select {
  font: inherit;
}

/* Remove default button styles */
button {
  background: none;
  border: none;
  cursor: pointer;
}

/* Prevent body scroll when modal is open */
body.modal-open {
  overflow: hidden;
}

body.mobile-sidebar-open {
  overflow: hidden;
}
