/*
    Delivery's own few rules. A delivered site's appearance is SiteKit's and the site's tokens
    (`--cms-*`, CMS-053); none of the Cafiana app's styles reach a public site (PD-0007). What is
    here styles this host's own notices until then, through the same tokens with fallbacks for
    a page that has not linked SiteKit's stylesheet, and stays small: the reader may be on a phone
    on a slow connection.

    Light only. Site tokens get a value per colour scheme later (legacy T-0128); until then the
    page says what has been checked.
*/
:root {
    color-scheme: light;
}

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

body {
    margin: 0;
    font-family: var(--cms-font-body, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif);
    font-size: var(--cms-font-size-md, 1rem);
    line-height: var(--cms-line-height-normal, 1.5);
    color: var(--cms-color-on-surface, #1f2328);
    background: var(--cms-color-surface, #ffffff);
}

/*
    THIS HOST'S OWN PAGES ONLY: a notice (not found, an error) and the search results. A site's page
    is drawn in its layout's widths, as CMS Admin's preview draws it (CMS-112): these rules were
    written before Delivery drew pages, and on `.site` they put every page in a 40rem column with 4rem
    above it, so a band could not reach the header, links on a band took the link colour back, and
    the delivered page did not look like its preview.
*/
.site:has(> .site__missing, > .site__search) {
    max-inline-size: 40rem;
    margin-inline: auto;
    padding-block: var(--cms-space-12, 4rem);
    padding-inline: var(--cms-space-4, 1rem);
}

:is(.site__missing, .site__search) h1 {
    margin-block: 0 var(--cms-space-4, 1rem);
    font-size: var(--cms-font-size-2xl, 2rem);
    line-height: 1.2;
}

:is(.site__missing, .site__search) a {
    color: var(--cms-color-link, #0b57d0);
}

:is(.site__missing, .site__search) a:focus-visible {
    outline: 3px solid var(--cms-color-link, #0b57d0);
    outline-offset: 2px;
}

:is(.site__missing, .site__search) code {
    font-family: var(--cms-font-body, ui-monospace, Consolas, monospace);
    overflow-wrap: anywhere;
}
