/* ============================================================
   RESET + BASE
   ============================================================ */

:where(*, *::before, *::after) {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

[hidden] {
    display: none !important;
}

html {
    height: 100%;
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
    hanging-punctuation: first last;
}

body {
    min-height: 100svh;
    overflow: hidden;
    font: var(--text-base)/1.5 var(--font-body);
    color: var(--color-text);
    background: var(--color-bg);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
    caret-color: var(--color-primary);
    accent-color: var(--color-primary);
    font-synthesis: none;
    display: flex;
    flex-direction: column;
    scrollbar-width: thin;
    scrollbar-color: var(--color-text-faint) transparent;
}

:where(button, input, textarea, select) {
    font: inherit;
    color: inherit;
}
textarea {
    resize: none;
    overflow: auto;
}

img,
canvas,
svg {
    display: block;
    max-width: 100%;
}

p,
h1,
h3 {
    overflow-wrap: break-word;
}

h1,
h3 {
    text-wrap: balance;
}

p {
    text-wrap: pretty;
}

/* Accessible screen-reader-only text */
.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;
}

:focus-visible {
    outline: none;
    box-shadow: var(--focus-ring);
    border-radius: var(--radius-sm);
}

