/*
 * The site's home page (deploy/home), in the same look as the sign-in
 * pages (deploy/keycloak/themes/berkshire-nordic/login/resources/css).
 */
@font-face {
    font-family: "Archivo Black";
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url("archivo-black-400.woff2") format("woff2");   /* OFL.txt */
}

:root {
    --bn-ink: #14263a;
    --bn-ink-soft: #3a4d61;
    --bn-accent: #1f4e79;
    --bn-accent-hover: #163a5b;
    --bn-sky-top: #d9e6f2;
    --bn-sky-bottom: #f6f9fc;
    --bn-font: "Trebuchet MS", Arial, Helvetica, sans-serif;
    --bn-title-font: "Archivo Black", "Arial Black", Arial, sans-serif;
}

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

/* Sky fading to snow, hills and pines along the bottom. */
body {
    margin: 0;
    min-height: 100vh;
    min-height: 100svh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    /* Room at the bottom for the hills, which scale with the width. */
    padding: 48px 20px clamp(120px, 20vw, 240px);
    background:
        url("hills.svg") no-repeat center bottom / 100% auto,
        linear-gradient(180deg, var(--bn-sky-top) 0%, var(--bn-sky-bottom) 70%);
    background-color: var(--bn-sky-bottom);
    color: var(--bn-ink);
    font-family: var(--bn-font);
    font-size: 1.0625rem;
    line-height: 1.6;
}

.home {
    width: 100%;
    max-width: 48rem;
    margin: 0 auto;
    text-align: center;
}

.home__logo {
    display: block;
    width: clamp(140px, 32vw, 220px);
    height: auto;
    margin: 0 auto 20px;
}

.home__title {
    margin: 0;
    font-family: var(--bn-title-font);
    font-weight: 400;
    font-size: clamp(2.1rem, 8vw, 4rem);
    line-height: 1.05;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--bn-ink);
}

.home__lead {
    margin: 14px 0 0;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--bn-accent);
}

/* The rule under the lead, as above the sign-in card. */
.home__lead::after {
    content: "";
    display: block;
    width: 56px;
    height: 4px;
    margin: 18px auto 0;
    border-radius: 2px;
    background: var(--bn-accent);
}

.home__text {
    max-width: 34rem;
    margin: 22px auto 0;
    color: var(--bn-ink-soft);
}

.home__actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 14px;
    margin-top: 30px;
}

.home__button {
    display: inline-block;
    padding: 12px 36px;
    border-radius: 6px;
    background: var(--bn-accent);
    color: #fff;
    font-weight: 700;
    font-size: 1.0625rem;
    text-decoration: none;
    box-shadow: 0 6px 16px rgba(20, 38, 58, 0.18);
}

.home__button:hover {
    background: var(--bn-accent-hover);
}

.home__button--secondary {
    background: transparent;
    color: var(--bn-accent);
    box-shadow: inset 0 0 0 2px var(--bn-accent);
}

.home__button--secondary:hover {
    background: rgba(31, 78, 121, 0.08);
}

.home__button:focus-visible {
    outline: 3px solid var(--bn-accent);
    outline-offset: 3px;
}

/* Privacy and terms links at the bottom of the home page and the legal pages. */
.site-footer {
    margin: 28px auto 0;
    text-align: center;
    font-size: 0.95rem;
    color: var(--bn-ink-soft);
}

.site-footer a {
    color: var(--bn-accent);
    margin: 0 6px;
}

/* On the home page the links sit in the snow under the hills, out of the
   centred column, so they don't push it into the trees. */
body:has(> .home) {
    position: relative;
}

.home ~ .site-footer {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 10px;
    margin: 0;
}

@media (max-width: 575px) {
    body {
        padding-top: 32px;
    }

    .home__lead {
        font-size: 1.125rem;
    }
}
