/** 基础重置与通用样式。 */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html,
body {
    min-height: 100%;
    overflow-x: clip;
}

html {
    -webkit-tap-highlight-color: transparent;
}

body {
    min-height: 100svh;
    font-family: var(--font-body);
    font-variant-ligatures: none;
    font-feature-settings: 'liga' 0, 'clig' 0, 'dlig' 0, 'hlig' 0, 'calt' 0;
    font-synthesis: none;
    color: var(--color-ink);
    background: var(--color-paper);
    position: relative;
    isolation: isolate;
}

a {
    color: inherit;
}

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

::selection {
    color: var(--color-ink);
    background: var(--color-selection);
}

/** 仅在视觉层隐藏标题，保留页面语义与辅助技术可读性。 */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
    border: 0;
}

.page-shell {
    min-height: 100svh;
    display: grid;
    grid-template-rows: auto minmax(0, 1fr) auto;
    position: relative;
    z-index: var(--layer-content);
    pointer-events: none;
}
