/* =========================================================================
   RESET
   Minimal, opinionated. Based on modern-css-reset conventions.
   ========================================================================= */

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

* {
  margin: 0;
}

html {
  -webkit-text-size-adjust: 100%;
  -moz-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

html:focus-within {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html:focus-within {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

body {
  min-height: 100vh;
  min-height: 100svh;
  line-height: var(--theme-line-height-body);
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

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

button {
  background: none;
  border: none;
  cursor: pointer;
}

a {
  color: var(--theme-color-text-link);
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.18em;
  transition: color var(--theme-duration-fast) var(--theme-easing-default);
}

a:hover,
a:focus-visible {
  color: var(--theme-color-text-link-hover);
}

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

:focus-visible {
  outline: 3px solid var(--theme-color-border-focus);
  outline-offset: 3px;
  border-radius: var(--theme-radius-card);
}

/* Skip link — visible only when focused */
.skip-link,
.skip-link:hover,
.skip-link:focus,
.skip-link:focus-visible {
  position: absolute;
  left: var(--theme-space-inline-md);
  top: var(--theme-space-stack-sm);
  padding: var(--theme-space-stack-xs) var(--theme-space-inline-md);
  background: var(--theme-color-background-inverse);
  color: var(--theme-color-text-inverse);
  border-radius: var(--theme-radius-card);
  font-weight: var(--theme-font-weight-emphasis);
  text-decoration-color: var(--theme-color-text-inverse);
  z-index: 100;
}

.skip-link {
  transform: translateY(-200%);
  transition: transform var(--theme-duration-default) var(--theme-easing-default);
}

.skip-link:focus {
  transform: translateY(0);
}
