/*! HTML5 Boilerplate v6.0.1 | MIT License | https://html5boilerplate.com/ */

/*
 * What follows is the result of much research on cross-browser styling.
 * Credit left inline and big thanks to Nicolas Gallagher, Jonathan Neal,
 * Kroc Camen, and the H5BP dev community and team.
 */

/* ==========================================================================
   Base styles: opinionated defaults
   ========================================================================== */

html {
    color: #222;
    font-size: 1em;
    line-height: 1.4;
}

/*
 * Remove text-shadow in selection highlight:
 * https://twitter.com/miketaylr/status/12228805301
 *
 * Vendor-prefixed and regular ::selection selectors cannot be combined:
 * https://stackoverflow.com/a/16982510/7133471
 *
 * Customize the background color to match your design.
 */

::-moz-selection {
    background: #b3d4fc;
    text-shadow: none;
}

::selection {
    background: #b3d4fc;
    text-shadow: none;
}

/*
 * A better looking default horizontal rule
 */

hr {
    display: block;
    height: 1px;
    border: 0;
    border-top: 1px solid #ccc;
    margin: 1em 0;
    padding: 0;
}

/*
 * Remove the gap between audio, canvas, iframes,
 * images, videos and the bottom of their containers:
 * https://github.com/h5bp/html5-boilerplate/issues/440
 */

audio,
canvas,
iframe,
img,
svg,
video {
    vertical-align: middle;
}

/*
 * Remove default fieldset styles.
 */

fieldset {
    border: 0;
    margin: 0;
    padding: 0;
}

/*
 * Allow only vertical resizing of textareas.
 */

textarea {
    resize: vertical;
}

/* ==========================================================================
   Browser Upgrade Prompt
   ========================================================================== */

.browserupgrade {
    margin: 0.2em 0;
    background: #ccc;
    color: #000;
    padding: 0.2em 0;
}

/* ==========================================================================
   Author's custom styles
   ========================================================================== */


body {
  margin: 0;
  padding: 0;
/*  Background fallback in case of IE8 & down, or in case video doens't load, such as with slower connections  */
  background: url('/img/ESA_Halle.jpg') no-repeat center center;
  background-color: #000;
  background-attachment: fixed;
  background-size: cover;
  font-family: 'Libre Franklin', sans-serif;
  color:  #fff;
  text-align: right;
  overflow: hidden;
}

body.no-bg {
    background-image: none;
    background: #fff;
    overflow: initial;
}

a {
    color:  #fff;
    text-decoration: underline;
}

a:hover, a:active {
    color: #ddd;
}

.video-container {
    position: fixed;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    overflow: hidden;
    z-index: -1;
    background: #000;
}

.video {
    position: absolute;
    top: 0;
    bottom: 0;
    right: 0;
    left: 0;
    margin: auto;
    min-height: 50%;
    min-width: 50%;
    width: auto;
    height: auto;
    z-index: -1;
    background: transparent;
}

.video img {
    text-align: center;
    max-width: 100vw;
    margin: auto;
}

.top-right {
    position: absolute;
    top:  2rem;
    right:  2rem;
    z-index:  1;
    text-align: right;
}

.button {
    color:  #fff;
    text-transform: uppercase;
    text-decoration: none;
    font-weight: bold;
    font-size: 1.5rem;
    border:  2px solid #fff;
    padding: .3rem .6rem .15rem .6rem;
    margin:  .5rem 0;
    line-height: 1;
    display: inline-block;
    float: right;
    /* for the video */
    background-color: rgba(0, 0, 0, 0.1);
}

.bottom-right {
    position: absolute;
    bottom:  2rem;
    right:  2rem;
    z-index:  1;
}

.input-email {
    color:  #fff;
    background:  transparent;
    text-decoration: none;
    font-weight: bold;
    font-size: 1.5rem;
    z-index:  1;
    border:  2px solid #fff;
    padding: .3rem .6rem .15rem .6rem;
    line-height: 1;
    z-index:  1;

}

.text-justify {
    text-align: justify;
}

.text-large {
    font-size: 1.5rem;
    line-height: 1;
}

button.button,
input.button {
    float:  right;
    background: transparent;
    background:  rgba(255, 255, 255, 0.3);
}

::-webkit-input-placeholder { /* Chrome/Opera/Safari */
  color: #fff;
  text-transform: uppercase;
}
::-moz-placeholder { /* Firefox 19+ */
  color: #fff;
  text-transform: uppercase;
}
:-ms-input-placeholder { /* IE 10+ */
  color: #fff;
  text-transform: uppercase;
}
:-moz-placeholder { /* Firefox 18- */
  color: #fff;
  text-transform: uppercase;
}

@media only screen and (max-width: 560px) {
    .video {
        /* display on mobile for now
        display:  none; */
    }
    /* .video-container {
        background: url('/img/ESA_Halle.jpg') no-repeat center center;
        background-color: #000;
        background-attachment: fixed;
        background-size: cover;
        overflow: hidden;
        position: fixed;
    } */
}

@media screen and (prefers-reduced-motion) {
    .video {
        display:  none;
    }
    .video-container {
        background: url('/img/ESA_Halle.jpg') no-repeat center center;
        background-color: #000;
        background-attachment: fixed;
        background-size: cover;
        overflow: hidden;
        position: fixed;
    }
}

img, iframe, video {
    max-width: 100%;
}

.voting {
    max-width: 600px;
    margin: 0 auto;
    text-align: left;
    color: #000;
}

.voting a {
    color: #000;
}

.voting h2,
.voting h1 {
    margin: 2em auto .5em;
    padding: 0 1em;
    max-width: 400px;
    text-align: center;
}

.voting ul,
.voting p {
    padding: .5em 1.5em 1em 1.5em;
    margin: 0 auto;
    list-style: none;
    text-align: justify;
}

.voting iframe {
    margin: 0 auto;
    display: block;
}

.voting ul {
    max-width: 300px;
}

.voting li {
    line-height: 2em;
    height: 2em;
    vertical-align: center;
}

.voting label {
    margin: 0 .5em;
    display: inline-block;
}

.mce-field-group--email {
    max-width: 400px;
    margin-left: auto;
    margin-right: auto;
}

.mce-field-group--email label {
    display: block;
    margin: 0;
}

.mce-field-group--email input {
    width: 100%;
}

.voting-header {
    margin: 0 auto 1rem;
    text-align: center;
    max-width: 600px;
}

.voting .button {
    text-align: center;
    display: block;
    margin: 0 auto 1em;
    padding: .5em 1em;
    float: none;
    border-color: #000;
    color: #000;
    cursor: pointer;
}

.vote-button {
    position: absolute;
    top: 0;
    right: 0;
    left: 0;
    bottom: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    margin: auto;
}

.vote-now {
    flex: 0 0 auto;
    max-width: 60%;
}

.results {
    max-width: 600px;
    margin: 0 auto;
    text-align: justify;
    color: #000;
}

.results h1 {
    text-align: center;
}

.results p {
    max-width: 450px;
    text-align: justify;
    margin: 1em auto;
}

.results h2 {
    text-align: center;
    margin-top: 2rem;
}

.results ul {
    margin: 0;
    padding: 0;
    list-style: circle;
    text-align: justify;
}

.results li {
    margin: 0 .5em 0;
    padding: 0;
    display: inline;
    text-align: justify;
}

.results div {
    text-align: justify;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
}

.results div span {
    padding-right: .5em;
    white-space: nowrap;
}

.results div span:not(:first-child):before {
    content: '-';
    display: inline;
    padding-right: .5em;
}


/* ==========================================================================
   Helper classes
   ========================================================================== */

/*
 * Hide visually and from screen readers
 */

.hidden {
    display: none !important;
}

/*
 * Hide only visually, but have it available for screen readers:
 * https://snook.ca/archives/html_and_css/hiding-content-for-accessibility
 *
 * 1. For long content, line feeds are not interpreted as spaces and small width
 *    causes content to wrap 1 word per line:
 *    https://medium.com/@jessebeach/beware-smushed-off-screen-accessible-text-5952a4c2cbfe
 */

.visuallyhidden {
    border: 0;
    clip: rect(0 0 0 0);
    -webkit-clip-path: inset(50%);
    clip-path: inset(50%);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    width: 1px;
    white-space: nowrap; /* 1 */
}

/*
 * Extends the .visuallyhidden class to allow the element
 * to be focusable when navigated to via the keyboard:
 * https://www.drupal.org/node/897638
 */

.visuallyhidden.focusable:active,
.visuallyhidden.focusable:focus {
    clip: auto;
    -webkit-clip-path: none;
    clip-path: none;
    height: auto;
    margin: 0;
    overflow: visible;
    position: static;
    width: auto;
    white-space: inherit;
}

/*
 * Hide visually and from screen readers, but maintain layout
 */

.invisible {
    visibility: hidden;
}

/*
 * Clearfix: contain floats
 *
 * For modern browsers
 * 1. The space content is one way to avoid an Opera bug when the
 *    `contenteditable` attribute is included anywhere else in the document.
 *    Otherwise it causes space to appear at the top and bottom of elements
 *    that receive the `clearfix` class.
 * 2. The use of `table` rather than `block` is only necessary if using
 *    `:before` to contain the top-margins of child elements.
 */

.clearfix:before,
.clearfix:after {
    content: " "; /* 1 */
    display: table; /* 2 */
}

.clearfix:after {
    clear: both;
}


/* ==========================================================================
   Print styles.
   Inlined to avoid the additional HTTP request:
   http://www.phpied.com/delay-loading-your-print-css/
   ========================================================================== */

@media print {
    *,
    *:before,
    *:after {
        background: transparent !important;
        color: #000 !important; /* Black prints faster:
                                   http://www.sanbeiji.com/archives/953 */
        box-shadow: none !important;
        text-shadow: none !important;
    }

    a,
    a:visited {
        text-decoration: underline;
    }

    a[href]:after {
        content: " (" attr(href) ")";
    }

    abbr[title]:after {
        content: " (" attr(title) ")";
    }

    /*
     * Don't show links that are fragment identifiers,
     * or use the `javascript:` pseudo protocol
     */

    a[href^="#"]:after,
    a[href^="javascript:"]:after {
        content: "";
    }

    pre {
        white-space: pre-wrap !important;
    }
    pre,
    blockquote {
        border: 1px solid #999;
        page-break-inside: avoid;
    }

    /*
     * Printing Tables:
     * http://css-discuss.incutio.com/wiki/Printing_Tables
     */

    thead {
        display: table-header-group;
    }

    tr,
    img {
        page-break-inside: avoid;
    }

    p,
    h2,
    h3 {
        orphans: 3;
        widows: 3;
    }

    h2,
    h3 {
        page-break-after: avoid;
    }
}
