p, h1, h2, h3, h4, h5, h6, a {
    animation: fadein 2s;
    -moz-animation: fadein 2s; /* Firefox */
    -webkit-animation: fadein 2s; /* Safari and Chrome */
    -o-animation: fadein 2s; /* Opera */
}
@keyframes fadein {
    from {
        opacity:0;
    }
    to {
        opacity:1;
    }
}
@-moz-keyframes fadein { /* Firefox */
    from {
        opacity:0;
    }
    to {
        opacity:1;
    }
}
@-webkit-keyframes fadein { /* Safari and Chrome */
    from {
        opacity:0;
    }
    to {
        opacity:1;
    }
}
@-o-keyframes fadein { /* Opera */
    from {
        opacity:0;
    }
    to {
        opacity: 1;
    }
}
.topbackground {
    box-shadow: 0 0 100px 50px #999999;
    width: 100%;
    z-index: -1;
}

body {
    margin: 0;
}

.content {
    background-color: white;
    position: relative;
}

nav {
    position: absolute;
    left: 0;
    right: 0;
    margin: 30px auto 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-family: Imprima, sans-serif;
    font-size: 18px;
    font-weight: bold;
}

#myTopnav {
    width: 100%;
}

.topnav {
    overflow: hidden;
}

.topnav a {
    float: left;
    display: block;
    color: #f2f2f2;
    text-align: center;
    padding: 14px 16px;
    text-decoration: none;
    font-size: 17px;
}

.topnav .icon {
    display: none;
}

#logo {
    height: 30px;
    padding: 8px 16px;
}

.chapter {
    display: block;
    width: 100%;
    font-family: 'Ubuntu Condensed', sans-serif;
}

.chaptername {
    padding-top: 30px;
    overflow: hidden;
    text-align: center;
    font-family: 'Imprima', sans-serif;
}
/*Styling for linjer ved siden av kapittelnavn */
    .chaptername:before,
    .chaptername:after {
        background-color: #000;
        content: "";
        display: inline-block;
        height: 2px;
        position: relative;
        vertical-align: middle;
        width: 10%;
    }
    .chaptername:before {
        right: 0.5em;
        margin-left: -50%;
    }
    .chaptername:after {
        left: 0.5em;
        margin-right: -50%;
    }


/* Season info */
#seasoninfo {
    width: 85%;
    margin: auto;
    overflow: hidden;
}
#infotextdiv h4:nth-child(1) {
    margin-top: 0;
}
    #infopicdiv {
        float: left;
        width: 40%;
    }
    #infopicdiv img {
        width: 90%;
        border-radius: 5px;
    }
#raintext {
    text-align: center;
}
.rain {
    padding: 14px 28px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 16px;
    margin: 4px 2px;
    -webkit-transition-duration: 0.4s; /* Safari */
    transition-duration: 0.4s;
    cursor: pointer;
    background-color: white; 
    color: var(--seasoncolor); 
    border: 2px solid var(--seasoncolor);
    border-radius: 5px;
}
.rain:hover {
    background-color: var(--seasoncolor);
    color: white;
}
/* Activity content */
#activitycontent {
    width: 100%;
    margin: auto;
    text-align: center;
    display: block;
}
.choice {
    padding: 14px 28px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 16px;
    margin: 4px 2px;
    -webkit-transition-duration: 0.4s; /* Safari */
    transition-duration: 0.4s;
    cursor: pointer;
    background-color: white; 
    color: black; 
    border: 2px solid var(--seasoncolor);
    border-radius: 5px;
}
.flex-container {
  padding: 0;
  list-style: none;
  display: -webkit-box;
  display: -moz-box;
  display: -ms-flexbox;
  display: -webkit-flex;
  display: flex;
  -webkit-flex-flow: row wrap;
  justify-content: space-around;
}
.flex-item {
    width: 400px;
    text-align: left;
}
.flex-item img {
    width: 100%;
    border-radius: 5px;
    padding: 0;
}
.iconinfo {
    color: grey;
}
#musicchapter {
    text-align: center;
}

footer {
    margin-top: 40px;
    background: rgba(15, 15, 15, .5);
    background-color: var(--seasoncolor);
    font-family: "Fira Sans", sans-serif;
    font-weight: bold;
    display:flex;
    align-items: center;
    -webkit-flex-flow: row wrap;
    justify-content: space-around;
}
    footer a {
        padding: 8px 0 8px 0;
        color: white;
    }



@media only screen and (max-width: 600px) {
    nav {
        margin-top: 0;
        z-index: 10;
    }

    .container {
        width: 100%;
    }
    .content {
        margin: -50px auto 0 auto;  
    }
    #youtubeVideo {
        width:95%;
    }

    .topnav {
        background-color: #333;
    }

    .topnav a:not(:first-child) {display: none;}
    .topnav a.icon {
        float: right;
        display: block;
    }

    .topnav.responsive {position: relative;}
    .topnav.responsive .icon {
        position: absolute;
        right: 0;
        top: 0;
    }
    .topnav.responsive a {
        float: none;
        display: block;
        text-align: left;
    }

    .topnav a:hover {
        background-color: var(--seasoncolor);
    }
    .flex-item {
        padding: 0 10px 0 10px;
    }
    
    #currentPage {
        background-color: var(--seasoncolor);
    }
}

@media only screen and (min-width: 601px) and (max-width: 768px) {
    .container {
        width: 90%;
    }
    .content {
        margin: -70px auto 0 auto;
        border: 1px solid var(--seasoncolor);
    }
    #youtubeVideo {
        width:85%;
    }
}
@media only screen and (min-width: 768px) {
    .container {
        width: 80%;
    }
    .content {
        margin: -120px auto 0 auto;
        border: 1px solid var(--seasoncolor);
    }
    #youtubeVideo {
        width:70%;
    }
}

@media only screen and (min-width: 601px) {
    #myTopnav {
        display: flex;
        justify-content: space-between;
    }

    .topnav a {
        padding-bottom: 0;
    }

    .topnav a:hover {
        border-bottom: 3px solid var(--seasoncolor);
    }

    .topnav a:nth-child(1) {
        border: none;
    }
    
    #currentPage {
        border-bottom: 3px solid var(--seasoncolor);
    }
}