/* Global reset, typography, layout helpers and accessibility utilities. */

*,
*::before,
*::after {
    box-sizing: border-box;
}
html {
    /* overflow-x: hidden; */
    scroll-behavior: smooth;
    scroll-padding-top: 90px;
}
body {
    /* overflow-x: hidden; */
    margin: 0;
    color: var(--color-ink);
    background: var(--color-paper);
    font-family: var(--font-sans);
    font-size: 17px;
    line-height: 1.6;
    text-rendering: optimizeLegibility;
    overflow-x: hidden;
}
body.nav-open {
    overflow: hidden;
    overscroll-behavior: none;
}
img,
svg {
    display: block;
    max-width: 100%;
}
img {
    height: auto;
}
a {
    color: inherit;
    text-decoration-thickness: 1px;
    text-underline-offset: 0.18em;
}
button,
input,
select,
textarea {
    font: inherit;
}
button,
a {
    -webkit-tap-highlight-color: transparent;
}
h1,
h2,
h3,
h4,
p,
ul,
figure {
    margin-top: 0;
}
h1,
h2,
h3,
h4 {
    color: var(--color-ink);
    font-family: var(--font-serif);
    line-height: 1.26;
}
h1 {
    margin-bottom: 2.1rem;
    font-size: clamp(3.1rem, 5.2vw, 5.45rem);
    font-weight: 600;
    letter-spacing: -0.035em;
}
h1 span {
    color: #8c7864;
}
h2 {
    margin-bottom: 1rem;
    font-size: clamp(2rem, 3.4vw, 3.15rem);
    font-weight: 700;
    letter-spacing: -0.025em;
}
h3 {
    margin-bottom: 0.85rem;
    font-size: clamp(1.32rem, 2vw, 1.85rem);
    font-weight: 700;
}
h4 {
    margin-bottom: 0.5rem;
    font-size: 1.07rem;
}
p:last-child,
ul:last-child {
    margin-bottom: 0;
}
strong {
    font-weight: 700;
}
.container {
    width: min(100% - (2 * var(--gutter)), var(--container));
    margin: 0 auto;
}

section {
    position: relative;
    padding-block: var(--space-8);
    overflow-x: hidden;
}

.section--sand {
    background: var(--color-sand);
}
.section--dark {
    color: var(--color-white);
    background: var(--color-dark);
}
.section--dark h2,
.section--dark h3,
.section--dark h4 {
    color: var(--color-white);
}
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}
.skip-link {
    position: fixed;
    z-index: 1000;
    top: 0.5rem;
    left: 0.5rem;
    padding: 0.75rem 1rem;
    color: #fff;
    background: var(--color-primary);
    transform: translateY(-140%);
    transition: transform var(--transition);
}
.skip-link:focus {
    transform: translateY(0);
}
:focus-visible {
    outline: 3px solid rgba(125, 30, 46, 0.35);
    outline-offset: 3px;
}
