/**
 * Vesper · base: the global element rules of the contract §2.4 allow-list, and nothing else.
 *
 * Reduced motion is handled at the token layer (tokens.css zeroes --ec-dur-*), so every template
 * transition and delay collapses to 0ms without touching the extensions' own animations.
 *
 * Every other element style lives under a template class (.ts-*, .vs-*) or under .ts-prose,
 * so the community apps that mount inside the page (Tailwind islands, shadcn themes) are never
 * reached. The body background is a hex token on purpose: Community Surveys tone-matches the
 * computed page colour.
 *
 * @copyright   Copyright (C) 2026 BulaSikku Technologies Private Limited. All rights reserved.
 * @license     GNU General Public License version 2 or later
 */

*,
::before,
::after {
    box-sizing: border-box;
}

html {
    font-size: 100%;
    overflow-x: clip;
    scroll-padding-top: calc(var(--ts-sticky-offset, 0px) + 1rem);
}

/* No smooth scrolling (Reboot's): an interrupted one left focus under the sticky header (2.4.11). */
html:root {
    scroll-behavior: auto;
}

body {
    margin: 0;
    background-color: var(--ec-bg);
    color: var(--ec-fg);
    font-family: var(--ec-font-body);
    line-height: 1.5;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* One ring for every focusable thing: 2px in --ts-focus (marigold in the dark, brass ink in
   the light), 2px away so the speech-bubble radius keeps its tail. Components on marigold
   switch the colour to ink; tightly packed mullion grids pull the ring inside. */
:focus-visible {
    outline: var(--ts-focus-width, 2px) solid var(--ts-focus);
    outline-offset: 2px;
}

::selection {
    background-color: var(--vs-lit);
    color: var(--ec-fg);
}

[hidden] {
    display: none !important;
}

img,
video {
    max-inline-size: 100%;
    block-size: auto;
}

mark {
    padding: 0 0.125em;
    border-radius: var(--vs-r-bar);
    background-color: var(--vs-lit);
    color: var(--ec-fg);
}
