/* Element resets and global defaults. Touch only document-wide rules here. */

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

html,
body {
    margin: 0;
    padding: 0;
}

html {
    -webkit-text-size-adjust: 100%;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    background: var(--color-bg);
    color: var(--color-fg);
    font-family: var(--font-sans);
    font-size: var(--fs-base);
    line-height: var(--lh-base);
    font-weight: var(--fw-regular);
    min-height: 100vh;
}

h1, h2, h3, h4, h5, h6, p, figure, blockquote, dl, dd {
    margin: 0;
}

h1 { font-size: var(--fs-4xl); line-height: var(--lh-4xl); font-weight: var(--fw-semibold); }
h2 { font-size: var(--fs-3xl); line-height: var(--lh-3xl); font-weight: var(--fw-semibold); }
h3 { font-size: var(--fs-2xl); line-height: var(--lh-2xl); font-weight: var(--fw-semibold); }
h4 { font-size: var(--fs-xl);  line-height: var(--lh-xl);  font-weight: var(--fw-semibold); }
h5 { font-size: var(--fs-lg);  line-height: var(--lh-lg);  font-weight: var(--fw-medium); }
h6 { font-size: var(--fs-base); line-height: var(--lh-base); font-weight: var(--fw-medium); }

a {
    color: var(--color-primary);
    text-decoration: none;
    transition: color var(--motion-fast) var(--easing);
}

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

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

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

button {
    cursor: pointer;
}

ul, ol {
    margin: 0;
    padding: 0;
}

:focus-visible {
    outline: 2px solid var(--color-primary);
    outline-offset: 2px;
    border-radius: var(--radius-sm);
}
