:root {
    /* Colors */
    --color-white: #ffffff;
    --color-off-white: #faf9f7;
    --color-surface: #f6f5f3;
    --color-text: #242424;
    --color-text-soft: #626262;
    --color-text-muted: #8a8a8a;
    --color-charcoal: #292929;
    --color-silver: #b9b9b9;
    --color-silver-light: #e7e7e7;
    --color-gold: #b9904f;
    --color-gold-light: #d9bd85;
    --color-gold-soft: #efe4cf;
    --color-border: #e6e3df;
    --color-background: var(--color-white);
    --color-heading: var(--color-charcoal);
    --color-body: var(--color-text);
    --color-accent: var(--color-gold);
    --color-focus: var(--color-charcoal);
    --color-input-border: var(--color-text-muted);
    --color-error: #a23434;
    --color-success: #326348;

    /* Typography */
    --font-body: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    --font-heading: var(--font-body);
    --font-size-xs: 0.75rem;
    --font-size-sm: 0.875rem;
    --font-size-base: 1rem;
    --font-size-md: 1.125rem;
    --font-size-lg: clamp(1.25rem, 1.15rem + 0.5vw, 1.5rem);
    --font-size-xl: clamp(1.5rem, 1.3rem + 1vw, 2rem);
    --font-size-2xl: clamp(1.875rem, 1.575rem + 1.5vw, 2.625rem);
    --font-size-3xl: clamp(2.25rem, 1.75rem + 2.5vw, 3.5rem);
    --font-size-4xl: clamp(2.75rem, 1.95rem + 4vw, 4.75rem);
    --line-height-tight: 1.1;
    --line-height-heading: 1.2;
    --line-height-body: 1.65;
    --font-weight-regular: 400;
    --font-weight-medium: 500;
    --font-weight-semibold: 600;

    /* Spacing */
    --space-1: 0.25rem;
    --space-2: 0.5rem;
    --space-3: 0.75rem;
    --space-4: 1rem;
    --space-5: 1.5rem;
    --space-6: 2rem;
    --space-7: 3rem;
    --space-8: 4rem;
    --space-9: 6rem;
    --space-10: 8rem;

    /* Layout */
    --container-width: 75rem;
    --container-padding: clamp(1rem, 4vw, 2.5rem);
    --section-spacing: clamp(3rem, 8vw, 7rem);

    /* Radius */
    --radius-sm: 0.25rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-pill: 999px;

    /* Shadows */
    --shadow-sm: 0 2px 8px rgb(36 36 36 / 0.04);
    --shadow-md: 0 8px 24px rgb(36 36 36 / 0.06);

    /* Motion */
    --transition-fast: 150ms;
    --transition-base: 250ms;
    --transition-slow: 700ms;
    --ease-standard: cubic-bezier(0.2, 0, 0, 1);
    --ease-smooth: cubic-bezier(0.22, 1, 0.36, 1);
}

/* Reset and defaults */
*,
*::before,
*::after {
    box-sizing: border-box;
}

html,
body {
    /* Keep horizontal reveal offsets inside the viewport. */
    overflow-x: clip;
}

html {
    scroll-behavior: auto;
    -webkit-text-size-adjust: 100%;
    tab-size: 4;
}

body {
    margin: 0;
    min-height: 100vh;
    min-height: 100svh;
    background: var(--color-background);
    color: var(--color-body);
    font-family: var(--font-body);
    font-size: var(--font-size-base);
    font-weight: var(--font-weight-regular);
    line-height: var(--line-height-body);
}

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

button,
select {
    text-transform: none;
}

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

img,
video {
    display: block;
    height: auto;
}

[hidden] {
    display: none !important;
}

/* Typography */
:where(h1, h2, h3, h4, h5, h6) {
    margin: 0 0 var(--space-4);
    color: var(--color-heading);
    font-family: var(--font-heading);
    font-weight: var(--font-weight-semibold);
    line-height: var(--line-height-heading);
    overflow-wrap: break-word;
}

h1 { font-size: var(--font-size-4xl); line-height: var(--line-height-tight); }
h2 { font-size: var(--font-size-3xl); }
h3 { font-size: var(--font-size-2xl); }
h4 { font-size: var(--font-size-xl); }
h5 { font-size: var(--font-size-lg); }
h6 { font-size: var(--font-size-md); }

:where(p, ul, ol, dl, blockquote) {
    margin: 0 0 var(--space-4);
    overflow-wrap: break-word;
}

:where(ul, ol) {
    padding-inline-start: var(--space-5);
}

figure,
dd {
    margin: 0;
}

small { font-size: var(--font-size-sm); }
strong, b { font-weight: var(--font-weight-semibold); }

a {
    color: inherit;
    text-decoration-thickness: 1px;
    text-underline-offset: 0.2em;
    transition: color var(--transition-fast) var(--ease-standard);
}

@media (hover: hover) {
    a:hover {
        color: var(--color-text-soft);
    }
}

/* Layout */
.container {
    width: min(100% - (var(--container-padding) * 2), var(--container-width));
    margin-inline: auto;
}

.section {
    padding-block: var(--section-spacing);
}

/* Accessibility */
::selection {
    background: var(--color-gold-soft);
    color: var(--color-charcoal);
}

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

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
    border: 0;
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        animation: none !important;
        transition: none !important;
    }
}
