/* Base layer: html/body defaults, links, focus rings, text selection. */
@layer base {
  html {
    background: var(--color-bg);
    scroll-behavior: smooth;
  }

  body {
    min-block-size: 100vh;
    min-block-size: 100dvh;
    display: flex;
    flex-direction: column;
    background: var(--color-bg);
    color: var(--color-fg);
    font-family: var(--font-sans);
    font-size: var(--fs-body);
    line-height: var(--leading-snug);
    transition:
      background-color 200ms ease,
      color 200ms ease;
  }

  address {
    font-style: normal;
  }

  a {
    color: var(--color-link);
    text-decoration-thickness: 0.08em;
    text-underline-offset: 0.18em;
    transition: color 150ms ease;
  }

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

  a:active {
    opacity: 0.85;
    transition: opacity 80ms ease;
  }

  :focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 3px;
  }

  main:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: -2px;
  }

  ::selection {
    background: var(--color-selection-bg);
    color: var(--color-fg);
  }
}
