/* ALL A */
html {
    height: 100%;
    font-size: 100%;
    font-family: Verdana, Geneva, sans-serif;
    background:
        url(/public/img/background-left.png) no-repeat left bottom,
        url(/public/img/background-right.png) no-repeat right top,
        #F6C945;
    background-size:
        20% auto,
        10% auto;
    background-attachment: fixed;
}

html:before {
    content: '';
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background: none;
    pointer-events: none;
    z-index: 1;
    transition: background 1s 0.1s;
}

html.playing:before {
    pointer-events: auto;
    background: rgba(0, 0, 0, 0.9);
}

body {
    position: relative; /* for footer */
    min-height: 100%;
    max-width: 1000px;
    margin: 0 auto;
    padding: 20px 20px 80px 20px;
}

a {
    display: inline-block;
    text-decoration: none;
    cursor: pointer;
    color: #0055CC;
}

[hidden] {
    display: none;
}

.spin{
    animation: spin 2s linear infinite;
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}
/* ALL Z */

/* FORM FIELDS A */
input,
select,
textarea {
    display: inline-block;
    padding: 8px 10px;
    border: 1px solid #CCCCCC;
    box-shadow: none;
    font-size: 0.9rem;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

select {
    padding-right: 35px;
    background: url(/public/img/select.png) no-repeat calc(100% - 10px) center white;
    background-size: auto 25%;
    cursor: pointer;
}

input:focus,
select:focus,
textarea:focus {
    border: 1px solid black;
}
/* FORM FIELDS Z */

/* BUTTONS A */
.btn,
button,
input[type='button'],
input[type='reset'],
input[type='submit'] {
    display: inline-block;
    padding: 8px 10px;
    background: #5B87A5;
    border: 1px solid #5B87A5;
    border-radius: 0;
    text-align: center;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: normal;
    color: white;
    cursor: pointer;
    vertical-align: middle;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

a.btn {
    color: white;
}

.btn:hover,
button:hover,
input[type='button']:hover,
input[type='reset']:hover,
input[type='submit']:hover {
    text-decoration: none;
    background: #4C748F;
    color: white;
}
/* BUTTONS Z */

/* HEADER A */
header {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
}

#logo {
    margin-bottom: 20px;
}

#logo img {
    max-height: 80px;
}

#toggles > * {
    margin: 0 10px 20px 10px;
    vertical-align: middle;
}

#toggles > *:first-child {
    margin-left: 0;
}

#toggles > *:last-child {
    margin-right: 0;
}
/* HEADER Z */

/* MAIN A */
#donut {
    position: relative;
    left: 50%;
    margin: 10vh auto;
    transform: translateX(-50%);
    text-align: center;
}

.ready #donut {
    display: none;
}

#donut:before {
    content: '';
    display: inline-block;
    width: 25%;
    padding-top: 25%;
    background: url(/public/img/donut.png) no-repeat center;
    background-size: contain;
    animation: spin 2s linear infinite;
}

#donut .msg {
    margin-top: 20px;
    font-size: 0.9rem;
    color: #D43084;
}

#donut .msg:empty {
    display: none;
}

#error {
    background: #0565CB;
}

#error .txt {
    padding: 20px 25px;
    font-size: 1.5rem;
    font-weight: bold;
    color: white;
}

video {
    width: 100%;
    object-fit: cover;
}

.playing video {
    position: relative; /* for z-index */
    z-index: 2;
}
/* MAIN Z */

/* FOOTER A */
footer {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 15px 0;
    text-align: center;
    font-size: 0.9rem;
}

footer .links li {
    margin: 0 10px 15px 10px;
}

footer .links a img {
    max-height: 1rem;
}
/* FOOTER Z */


@media(max-width: 1200px) {
    body {
        max-width: calc(100vw - 200px);
    }
}

@media(max-width: 992px) {
    header {
        display: block;
        text-align: center;
    }
}

@media(max-width: 768px) {
    html {
        background: #F6C945;
    }
    body {
        max-width: 100%;
        padding-bottom: 100px;
    }
    #donut:before {
        width: 100px;
        padding-top: 100px;
    }
}