@charset "UTF-8";

/*
 * Cookie banner (FO-COOKIE-BANNER-01). The layout is the one of the site in production, measured
 * on it rather than guessed: a white strip pinned to the bottom of the viewport across its whole
 * width, the message centred, the cross flush against the right edge, and a two pixel shadow
 * above that detaches the strip from the page scrolling underneath it.
 *
 * Nothing compensates for the height of the strip on the page below, exactly as in production:
 * the banner covers the last line of a page until it is closed, which is what makes a visitor
 * close it.
 */

.fo-cookie-banner {
    position: fixed;
    right: 0;
    bottom: 0;
    left: 0;
    /* The highest layer of the whole Front-Office, the medias carousel included: the acceptance
       criteria ask for it in those words. In the carousel's NATIVE fullscreen the banner is out
       of the rendered subtree and disappears, which no z-index can change */
    z-index: var(--fo-z-cookie-banner);
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;
    background: var(--fo-color-background);
    color: var(--fo-color-text);
    box-shadow: 0 -1px 0 0 rgba(0, 0, 0, 0.3), 0 -2px 0 0 rgba(0, 0, 0, 0.2);
}

/*
 * The left margin answers the width of the cross on the other side, so that the text reads as
 * centred on the strip and not pushed aside by it. Percentages, as in production, so that the
 * balance holds at every width.
 */
.fo-cookie-banner__message {
    -webkit-box-flex: 1;
    -ms-flex: 1;
    flex: 1;
    margin: 1rem 0 1rem 5%;
    padding: 0 2.5%;
    text-align: center;
    font-family: var(--fo-font-sans);
    font-weight: 100;
    line-height: 175%;
}

/* ".fo a" clears the underline of every link of the Front-Office: this one needs it back, the
   phrase having to show where the privacy policy is to be found */
.fo-cookie-banner__link {
    text-decoration: underline !important;
    -webkit-transition: color 0.4s ease;
    -moz-transition: color 0.4s ease;
    -o-transition: color 0.4s ease;
    transition: color 0.4s ease;
}

.fo-cookie-banner__link:hover {
    color: var(--fo-color-primary);
    text-decoration: none !important;
}

.fo-cookie-banner__close {
    -webkit-box-flex: 0;
    -ms-flex: 0 0 4.5%;
    flex: 0 0 4.5%;
    padding: 0;
    border: 0;
    background: none;
    color: inherit;
    font-size: 1.2rem;
    line-height: 1;
    cursor: pointer;
    -webkit-transition: color 0.4s ease;
    -moz-transition: color 0.4s ease;
    -o-transition: color 0.4s ease;
    transition: color 0.4s ease;
}

.fo-cookie-banner__close:hover {
    color: var(--fo-color-primary);
}

/*
 * Same scale as ".fo-footer__legal", the two sitting one above the other at the bottom of the
 * page and reading as one block - but with a floor the footer does not need. At 1280 px the bare
 * 0.85vw gives 10.9 px, where the banner in production shows 16 px: too small for a notice a
 * visitor is expected to read before agreeing to it. The floor holds it at 14.4 px until the
 * viewport is wide enough for the ratio to take over again.
 */
@media only screen and (max-width: 991.98px) {
    .fo-cookie-banner__message {
        font-size: 3.2vw;
    }
}

@media only screen and (min-width: 992px) {
    .fo-cookie-banner__message {
        font-size: max(1.1vw, 0.9rem);
    }
}

@media only screen and (min-width: 1200px) {
    .fo-cookie-banner__message {
        font-size: max(0.85vw, 0.9rem);
    }
}
