/* Explain: Base CSS reset, typography, and global element styles. */
* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    background: var(--background-color);
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    overflow-x: hidden;
    font-family: var(--font-body);
    font-size: 1.0625rem;
    line-height: 1.75;
    color: var(--text-color);
    background: var(--background-color);
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
    margin: 0;
    font-family: var(--font-heading);
    font-weight: 500;
    line-height: 1.14;
    letter-spacing: 0.005em;
}

h1 { font-size: clamp(2.5rem, 7vw, 5rem); }
h2 { font-size: clamp(2rem, 4.5vw, 3.25rem); }
h3 { font-size: clamp(1.4rem, 2.5vw, 2rem); }

p { margin: 0; }

a {
    color: inherit;
    text-decoration: none;
}

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

button {
    font-family: inherit;
}

main[id],
section[id] {
    scroll-margin-top: 5.5rem;
}

::selection {
    background: var(--accent-color);
    color: #fff;
}

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