/* Page-level basics on top of Bootstrap: layout skeleton, links, focus, selection and rich-text content. */

html { -webkit-text-size-adjust: 100%; }

body {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background-color: var(--fv-bg);
    color: var(--fv-ink);
    font-family: var(--fv-font-ui);
    font-feature-settings: "cv11", "ss01";
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}
main { flex: 1 0 auto; }
footer { flex-shrink: 0; }

a { text-underline-offset: .2em; }
a:hover { text-decoration: underline; }
.btn:hover, .nav-link:hover, .dropdown-item:hover, .list-group-item:hover, .page-link:hover, .navbar-brand:hover,
.badge:hover, .card a.stretched-link:hover { text-decoration: none; }

::selection { background: color-mix(in srgb, var(--fv-gold) 40%, transparent); color: var(--fv-ink); }

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

/* Skip link, visible only on keyboard focus */
.fv-skip {
    position: absolute;
    left: 1rem;
    top: -100px;
    z-index: 2000;
    padding: .6rem 1rem;
    border-radius: var(--fv-radius-control);
    background: var(--fv-surface);
    color: var(--fv-ink);
    font-weight: 600;
    box-shadow: var(--fv-shadow-lg);
}
/* Light chip on the navy top bar, so it stands out where it appears */
.fv-skip:focus { top: .6rem; color: var(--fv-ink); text-decoration: none; outline: 3px solid var(--fv-or-400); outline-offset: 2px; }

/* Shared text styles */
.fv-eyebrow {
    font-family: var(--fv-font-caps);
    font-size: .75rem;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: .18em;
    text-transform: uppercase;
    color: var(--fv-muted);
}
.fv-motto,
.monsieur-la-doulaise-regular {
    font-family: var(--fv-font-script);
    font-weight: 400;
    font-style: normal;
}
.fv-motto { font-size: 2rem; line-height: 1.1; color: var(--fv-link); }
.fv-num { font-variant-numeric: tabular-nums; }

/* Icons (Phosphor). Bootstrap Icons sat slightly below the baseline; keep the same feel. */
.ph, .ph-fill, .ph-duotone { vertical-align: -.125em; line-height: 1; }
.ph-fw { width: 1.25em; text-align: center; }
.ph-lg { font-size: 1.33em; }
.ph-2x { font-size: 2em; }
.ph-3x { font-size: 3em; }

/*
 * Rich text written in Quill (events, news, recipes, static pages). .event-description and .rich-text-content are
 * the class names the templates use today; new templates use .fv-prose.
 */
.fv-prose,
.event-description,
.rich-text-content {
    overflow-wrap: break-word;
    line-height: 1.65;
}
:is(.fv-prose, .event-description, .rich-text-content) p { margin: 0 0 .75em; }
:is(.fv-prose, .event-description, .rich-text-content) > :last-child { margin-bottom: 0; }
:is(.fv-prose, .event-description, .rich-text-content) img { max-width: 100%; height: auto; border-radius: var(--fv-radius-control); }
:is(.fv-prose, .event-description, .rich-text-content) :is(ul, ol) { padding-left: 1.5rem; margin-bottom: .75em; }
:is(.fv-prose, .event-description, .rich-text-content) h1 { font-size: 1.75rem; margin: 1em 0 .4em; }
:is(.fv-prose, .event-description, .rich-text-content) h2 { font-size: 1.4rem; margin: 1em 0 .4em; }
:is(.fv-prose, .event-description, .rich-text-content) h3 { font-size: 1.2rem; margin: 1em 0 .4em; }
:is(.fv-prose, .event-description, .rich-text-content) blockquote {
    margin: 0 0 .75em;
    padding-left: 1rem;
    border-left: 3px double var(--fv-gold-ui);
    color: var(--fv-muted);
}
:is(.fv-prose, .event-description, .rich-text-content) :is(pre, code) {
    background: var(--fv-raised);
    border: 1px solid var(--fv-line);
    border-radius: 4px;
    font-size: .875em;
}
:is(.fv-prose, .event-description, .rich-text-content) code { padding: .1em .35em; }
:is(.fv-prose, .event-description, .rich-text-content) pre { padding: .6rem .8rem; }
:is(.fv-prose, .event-description, .rich-text-content) a { text-decoration: underline; }
/* Truncated previews in cards and feeds are a single tight block */
:is(.card-text, .list-group-item) :is(.fv-prose, .rich-text-content, .event-description) p { margin-bottom: 0; }

/* Quill alignment classes appear in saved content everywhere it is shown */
.ql-align-center { text-align: center; }
.ql-align-right { text-align: right; }
.ql-align-justify { text-align: justify; }
.ql-direction-rtl { direction: rtl; }

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .01ms !important;
        scroll-behavior: auto !important;
    }
}
