/* =====================================================================
   LEAD MARINE: the base rules of the public pages (BEM-ish, prefix .lm-)
   Before the move onto Vsi.Cms (October 2026) the public pages also loaded the admin stylesheet
   app.css; these are the rules of that sheet that reached a public page: the self-hosted fonts,
   the body, the focus ring, the hidden Blazor error bar and the cookie banner. The admin has its
   own style now (Vsi.Cms, vsi-admin.css) and never loads this sheet. Loaded before lead-marine.css.
   ===================================================================== */

/* Roboto and Montserrat, SELF-HOSTED (wwwroot/fonts) so no external font request happens before
   consent (privacy rule). Montserrat is the house font of LEAD Marine (the style guide of the design). */
@font-face {
    font-family: "Roboto";
    font-style: normal;
    font-weight: 400 700;
    font-display: swap;
    src: url("../fonts/roboto-latin.woff2") format("woff2");
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
    font-family: "Roboto";
    font-style: normal;
    font-weight: 400 700;
    font-display: swap;
    src: url("../fonts/roboto-latin-ext.woff2") format("woff2");
    unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
    font-family: "Montserrat";
    font-style: normal;
    font-weight: 300 700;
    font-display: swap;
    src: url("../fonts/montserrat-latin.woff2") format("woff2");
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
    font-family: "Montserrat";
    font-style: normal;
    font-weight: 300 700;
    font-display: swap;
    src: url("../fonts/montserrat-latin-ext.woff2") format("woff2");
    unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
    --lm-base-ink: #181b31;
    --lm-base-bg: #ffffff;
    --lm-base-accent: #e0563c;
    --lm-base-radius: 6px;
    --lm-base-font: "Roboto", "Montserrat", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
    /* Outline of tick boxes: Bootstrap draws it so lightly that on white it is hardly visible. */
    --lm-base-check-border: #222222;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: var(--lm-base-font);
    color: var(--lm-base-ink);
    background: var(--lm-base-bg);
    line-height: 1.7;
    /* Body copy is not editable: with caret browsing (F7) or a stray focus, browsers drew a blinking
       cursor in headings and paragraphs. Hidden everywhere except in real input fields. */
    caret-color: transparent;
}

input,
textarea,
select,
[contenteditable="true"] {
    caret-color: auto;
}

/* Only paint a focus ring on genuinely interactive elements (accessibility). */
:focus {
    outline: none;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible,
label:focus-visible,
/* tabindex="-1" = programmatically focusable only (script focus targets): never a focus ring. */
[tabindex]:not([tabindex="-1"]):focus-visible {
    outline: 3px solid var(--lm-base-accent);
    outline-offset: 2px;
}

.form-check-input {
    border-color: var(--lm-base-check-border);
}

/* Bootstrap's default gutter leaves only 12px next to the text on a phone. */
@media (max-width: 575.98px) {
    .container {
        --bs-gutter-x: 2.5rem;
    }
}

/* The error bar of the layout stays hidden until Blazor shows it. */
#blazor-error-ui {
    color-scheme: light only;
    background: lightyellow;
    bottom: 0;
    box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
    box-sizing: border-box;
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
}

#blazor-error-ui .dismiss {
    cursor: pointer;
    position: absolute;
    right: 0.75rem;
    top: 0.5rem;
}

/* ---------- Cookie banner (MainLayout, js/consent.js) ---------- */
.lm-consent {
    position: fixed;
    bottom: 1rem;
    left: 1rem;
    right: 1rem;
    max-width: 34rem;
    margin: 0 auto;
    background: #fff;
    border: 2px solid var(--lm-base-accent);
    border-radius: var(--lm-base-radius);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.18);
    padding: 1.1rem 1.3rem;
    z-index: 200;
}

.lm-consent__text {
    margin-bottom: 0.75rem;
}

.lm-consent__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
}
