/* =============================================================
   RESET.CSS — Modern CSS Reset & Base Styles
   Al Buraimi Ministry eServices Web Portal
   ============================================================= */

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  font-size: var(--text-base);
  color: var(--color-text-primary);
  background-color: var(--color-bg-light);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

[dir="rtl"] body {
  font-family: var(--font-arabic);
}

img, picture, video, canvas, svg {
  display: block;
  max-width: 100%;
}

input, button, textarea, select {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
  border: none;
  background: none;
}

a {
  color: inherit;
  text-decoration: none;
}

a:hover {
  text-decoration: none;
}

ul, ol {
  list-style: none;
}

h1, h2, h3, h4, h5, h6 {
  line-height: 1.2;
  font-weight: 600;
}

p {
  line-height: 1.7;
}

fieldset {
  border: none;
}

/* Skip to main content (accessibility) */
.skip-link {
  position: absolute;
  top: -100px;
  inset-inline-start: var(--space-4);
  background: var(--color-primary);
  color: var(--color-white);
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius-sm);
  z-index: 9999;
  font-size: var(--text-sm);
  font-weight: 600;
  transition: top var(--transition-base);
}

.skip-link:focus {
  top: var(--space-4);
}

/* Focus styles (WCAG 2.1 AA) */
:focus-visible {
  outline: 2px solid var(--color-accent-orange);
  outline-offset: 2px;
}

/* Selection color */
::selection {
  background: rgba(16, 28, 78, 0.15);
  color: var(--color-primary);
}

/* Scrollbar */
::-webkit-scrollbar {
  width: 6px;
}
::-webkit-scrollbar-track {
  background: var(--color-bg-light);
}
::-webkit-scrollbar-thumb {
  background: var(--color-primary-light);
  border-radius: var(--radius-full);
}
::-webkit-scrollbar-thumb:hover {
  background: var(--color-primary);
}
