/* 1. skeleton ****************************************************************/

* {
  box-sizing: border-box;
}
html {
  height: 100%;
}
body {
  height: 100%;
  width: 100%;
  margin: 0;
  box-sizing: border-box;
  font-family: "Raleway", sans-serif;
  font-size: 100%;
}
.wrapper {
  display: grid;
  grid-gap: 0px;
  grid-template-areas:  "intro"
                        "main";
}
/* end skeleton ***************************************************************/
/* intro **********************************************************************/
.intro {
  grid-area: intro;
}
/* logo: */
#homelink {
  display: block;
  position: absolute;
  left: .6rem;
  top: .4rem;
  margin: 0;
  height: 2rem;
  line-height: 2rem;
  color: white;
  opacity: .7;
  font-family: 'Permanent Marker', cursive;
  font-size: 2rem;
  text-shadow: 0 0 3px rgba(0,0,0,.5);
  text-decoration: none;
}
#homelink:hover {
  text-shadow: 0 0 3px rgba(0,0,0,1);
}
/* landing page: */
.splash {
  position: -webkit-sticky;
  position: sticky;
  top: 0px;
  z-index: 1;
  height: 100vh;
  width: 100%;
  background-image: linear-gradient(rgba(255, 255, 255, .5), rgba(255, 255, 255, .5)),
  linear-gradient(rgba(55, 0, 55, .6), rgba(55, 0, 55, .6)), url("../img/newspaper-collage-1.png");
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
  background-color: white;
}
.splash-grid {
  position: relative;
  top: 50%;
  transform: translate(0, -50%);
  margin: auto;
  height: 75%;
  width: 90%;
  display: grid;
  grid-gap: 2rem;
  grid-template-columns: 1fr 30px 1.5fr;
  grid-template-areas: "title braces para";
  align-items: center;
}
.splash-title, .splash-braces, .splash-para {
  color: white;
  text-shadow: 0 0 3px rgba(0,0,0,.5);
}
.splash-title {
  grid-area: title;
  color: black;
  font-size: 3.5rem;
  line-height: 3rem;
  font-weight: 300;
  text-align: right;
  text-shadow: 0 0 3px rgba(0,0,0,.2);
}
.border {
  background: linear-gradient(to right, rgba(0,0,0,.2), rgba(0,0,0,1) 30%, rgba(0,0,0,1) 90%, rgba(0,0,0,.2));
  height: 2px;
  width: 90%;
  float: right;
}
.text {
  margin: 2rem 0;
}
.splash-braces {
  grid-area: braces;
}
.splash-para {
  grid-area: para;
  font-family: 'Permanent Marker', cursive;
  font-size: 2rem;
  text-align: left;
}
.splash-btn { /* add shine animation */
  cursor: pointer;
  transform: rotate(90deg);
  float: right;
  position: relative;
  right: 10vw;
  top: 5vh;
  margin: 0;
  padding-bottom: 4px; /* centers char */
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 50%;
  font-size: 2rem;
  text-align: center;
  background-color: rgba(255,255,255,.7);
  box-shadow: 0 0 2px 2px rgba(0,0,0,.1);
  outline: none;
  border: none;
}
.splash-btn:hover {
  background-color: white;
  box-shadow: 0 0 3px 2px rgba(0,0,0,.3);
}

/* explainer: */
.explainer {
  transition: margin-top 2s ease; /* see 'explain-scroll' */
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-areas: "hook        hook  hook"
                       "reason1 reason2 reason3"
                       "circle1 circle2 circle3";
  grid-template-columns: 1fr 1fr 1fr;
  align-content: center;
  justify-items: center;
  margin: 0;
  margin-top: 0;
  padding: 0 1.5rem;
  height: 100vh;
  text-align: center;
  background-image: linear-gradient(rgba(138, 189, 95, .9), rgba(138, 189, 95, .9)), linear-gradient(rgba(255, 255, 255, .5), rgba(255, 255, 255, .5)), url("../img/graph-paper.png");
  box-shadow: 0 0 5px 1px rgba(0,0,0,.1);
}
.explain-scroll { /* if click btn */
  margin-top: -100vh;
}
.hook {
  grid-area: hook;
}
.reason1 {
  grid-area: reason1;
}
.reason2 {
  grid-area: reason2;
}
.reason3 {
  grid-area: reason3;
}
.downarrow {
  margin: 0 auto;
  transform: translate(0, 50%);
  width: 0;
  height: 0;
  border-color: white transparent transparent transparent;
  border-width: 16px;
  border-style: solid;
  box-sizing: content-box;
}
.circle1 {
  grid-area: circle1;
}
.circle2 {
  grid-area: circle2;
}
.circle3 {
  grid-area: circle3;
}
/* visuals */
.hook {
  padding: 0 1rem;
  margin-bottom: 2rem;
  font-size: 2rem;
  color: white;
  font-family: 'Roboto Slab', serif;
}
.mockdots {
  height: 12px;
  width: 12px;
  margin: auto;
  padding: 0;
  background-color: white;
  border-radius: 50%;
}
.reason1, .reason2, .reason3 {
  color: white;
  width: 16rem;
  margin-bottom: 2rem;
  font-size: 1.5rem;
  font-weight: bold;
}
.reason2 {
  border-left: 2px solid white;
  border-right: 2px solid white;
}
.circle1, .circle2, .circle3 {
  border-radius: 50%;
  height: 15rem;
  width: 15rem; /* 12rem for 768px cutoff */
  background-color: rgba(255, 255, 255, .3);
  font-family: 'Roboto Slab', serif;
  padding: 1rem;
}
.circle1 p, .circle2 p, .circle3 p {
  margin: 0;
  padding: 0;
  margin-top: 50%;
  transform: translate(0%, -50%);
  color: white;
  font-size: 1rem;
}
/* end intro ******************************************************************/
/* sidebar ********************************************************************/
.sidebar {
  z-index: 0;
  height: 100vh;
  width: 10rem;
  position: fixed;
  right: 0;
  top: 0;
  transition: width .5s;
  /* container: */
  display: grid;
  grid-template-columns: 1fr;
  grid-template-rows: 2rem 1fr 1.5rem;
  grid-template-areas: '.' /* options here */
                       "small-timeline"
                       '.';
  /* visual: */
  background-color: white;
}
/* interactivity: */
.hide-sidebar {
  width: 0rem;
}
.btn-zone {
  position: fixed;
  right: 0;
  height: 100%;
  width: 2.5rem;
  background-color: transparent;
}
.btn {
  cursor: pointer;
  position: fixed;
  top: 50%;
  transform: translate(50%, -50%);
  padding-right: 2rem;
  background-color: white;
  outline: none;
  border: none;
  font-size: 2rem;
  width: 4rem;
  height: 4rem;
  border-radius: 50%;
  overflow: hidden;
  -webkit-transition: color .4s, right .5s;
  transition: color .4s, right .5s;
}
.black-text {
  color: black;
}
.ten-rem {
  right: 10rem;
}
.eight-rem {
  right: 8rem;
  color: transparent;
}
.zero-rem {
  right: 0rem;
}
.neg2-rem {
  right: -2rem;
}
/* contents: */
.small-timeline {
  grid-area: small-timeline;
  display: grid;
  grid-template-rows: 5px repeat(199, auto) 5px;
  position: relative;
}
.line {
  z-index: -1;
  position: absolute;
  margin-left: 50%;
  transform: translate(-1px, 0);
  height: 100%;
  width: 1px;
  background-color: rgba(0,0,0,.5);
}
.admin, .student, .fed, .none { /* dots */
  height: 5px;
  width: 5px;
  border-radius: 50%;
  margin: .25px 1.5px;
  padding: 0px;
  font-size: .5rem;
  font-weight: bold;
  -webkit-transition: border .3s;
  transition: border .3s;
}
.none {
  height: 1px;
  margin: 0px;
}
.admin:hover, .student:hover, .fed:hover {
  background-color: yellow;
  border: 2px solid yellow;
  box-sizing: content-box;
}
.small-timeline div {
  display: flex;
  justify-content: center;
  align-items: center;
}
.admin {
  background-color: #bae397;
}
.student {
  background-color: purple;
}
.fed {
  background-color: #807615;
}
.none {
  background-color: transparent;
}
/* end sidebar ****************************************************************/
/* main ***********************************************************************/
.main-margin-right {
  margin-right: 0!important;
}
.main {
  margin-right: 10rem;
  padding-right: 0;
  grid-area: main;
}
/* end main *******************************************************************/
/* entries ********************************************************************/
/* layout: */
.container {
  margin: auto 0;
  display: grid;
  grid-gap: 10px;
  grid-auto-flow: row;
  grid-auto-rows: minmax(10px, auto);
  grid-template-columns: [col1-start] 12.5vw [col1-end col2-start] 1fr [col2-end];
  background-image: linear-gradient(to right, #6f256f -99.5%, rgba(255, 255, 255, 0) 10.5%, rgba(111, 37, 111, 1) 110%);
}
@media screen and (min-width: 900px) {
  .container {
    background-image: linear-gradient(to right, #6f256f -100%, rgba(255, 255, 255, 0), #6f256f 200%);
  }
}
.entry {
  grid-column: col2-start;
}
.tl-wrapper {
  grid-column: col1-start;
  justify-self: center;
}
.date {
  grid-column: col1-start;
}
@media all and (min-width: 900px) {
  .container {
    margin: auto 0;
    display: grid;
    grid-gap: 10px;
    grid-auto-flow: row dense;
    grid-auto-rows: minmax(10px, auto);
    grid-template-columns: [oe-start ed-start] 1fr [oe-end ed-end tl-start] 12.5vw [tl-end ee-start od-start] 1fr [ee-end od-end];
    /* key: 'oe'='odd entry'  'ed'='even date'  'tl'='timeline'  'ee'='even entry'  'od'='odd date' */
  }
  .entry.odd {
    grid-column: oe-start;
  }
  .entry.even {
    grid-column: ee-start;
  }
  .tl-wrapper {
    grid-column: 2;
    justify-self: center;
  }
  .date.odd {
    grid-column: od-start;
  }
  .date.even {
    grid-column: ed-start;
    text-align: right;
  }
}
/* entry: */
.entry {
  position: relative;
  padding: 1.5rem 2rem;
  margin: 0 2rem 0 1rem;
  background-color: rgba(255, 255, 255, 1);
  text-align: left;
  border-radius: 3px;
  box-shadow: 0 0 2px 1px rgba(0, 0, 0, .05);
}
.entry::before {
  content: '';
  position: absolute;
  top: 1.5rem;
  right: 100%;
  height: 0;
  width: 0;
  border: 7px solid transparent;
  border-right: 7px solid white;
}
@media only screen and (min-width: 900px) {
  .entry.even {
    margin: 0 3rem 0 0;
  }
  .entry.odd {
    margin: 0 0 0 3rem;
  }
  .entry.odd::before { /* odd arrow */
    top: 2rem;
    left: 100%;
    transform: translate(0, -50%);
    border-color: transparent;
    border-left-color: white;
  }
}
.entry h2, .entry h3 {
  margin: 0;
  font-weight: normal;
  color: #292956;
}
.entry h2 {
  font-size: 1.5rem;
}
.entry h3 {
  font-size: 1rem;
  font-family: 'Roboto Slab', serif;
}
.entry p {
  margin: 1rem 0;
  line-height: 1.6; /* 1 or 1.15 for lil screens */
}
/* icon: */
.icon {
  transform: translate(-50%, 0);
  margin-left: 2px;
  height: 3rem;
  width: 3rem;
  border-radius: 50%;
  background-color: white;
  border: 3px solid #6f256f;
  z-index: 10;
}
.icon img {
  height: 1.5rem;
  width: 1.5rem;
  position: relative;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}
@media screen and (min-width: 1024px) {
  .icon {
    height: 4rem;
    width: 4rem;
  }
  .icon img {
    height: 2rem;
    width: 2rem;
  }
}
/* thumbnail: */
.entry img {
  display: block;
  float: left;
  margin-right: .5rem;
  padding: 5px;
  border: 2px solid #aaa039
}
/* click -> modal: */
.entry button {
  position: relative;
  display: block;
  float: left;
  background-color: white;
  border: 2px solid #aaa039;
  color: #807615;
  font-family: 'Roboto Slab', serif;
  font-size: 1rem;
  padding: 5px;
  padding-right: 1.5rem;
  cursor: pointer;
}
.entry button:hover {
  background-color: #aaa039;
  color: white;
}
.entry button::after {
  position: absolute;
  bottom: 0px;
  right: -5px;
  transform: translate(0,-50%) rotate(45deg);
  content: '';
  border-width: .75rem;
  border-style: solid;
  border-top-color: transparent;
  border-left-color: transparent;
  border-right-color: transparent;
  border-bottom-color: #aaa039;
}
.entry button:hover::after {
  border-bottom-color: white;
}
.entry button:focus {
  outline: 0;
  border-color: #807615;
}
/* date: */
.date {
  visibility: hidden;
}
@media screen and (min-width: 900px) {
  .date {
    visibility: visible;
    font-size: 1rem;
    height: 3rem;
    line-height: 3rem; /* =icon height */
    width: auto;
  }
}
@media only screen and (min-width: 1024px) {
  .date {
    height: 4rem;
    line-height: 4rem;
  }
}
/* timeline: */
.timeline { /* NB: 1 line segment per entry; 120% hgt = smooth appearance */
  width: 4px;
  transform: translate(-2px, 0);
  height: 120%;
  background-color: #6f256f;
  margin-top: 0;
  margin-bottom: -10px;
  z-index: -10;
}
.container div:nth-last-of-type(3) { /* rounds tl bottom edge */
  border-bottom-right-radius: 2px;
  border-bottom-left-radius: 2px;
  height: 100%;
}
.container div:nth-last-of-type(2) {
  margin-bottom: 1rem;
}
.dots {
  grid-column: col1-start;
  justify-self: center;
  height: 4px;
  width: 4px;
  border-radius: 50%;
  transform: translate(-2px, 0);
  background-color: purple;
}
@media screen and (min-width: 900px) {
  .dots {
    grid-column: 1 / -1;
    justify-self: center;
    height: 4px;
    width: 4px;
    border-radius: 50%;
    transform: translate(-2px, 0);
    background-color: purple;
  }
}
/* dot 'gradient': */
p[class="dots"]:nth-of-type(1), p[class="dots"]:nth-last-of-type(1) {
  opacity: .5;
}
p[class="dots"]:nth-of-type(2), p[class="dots"]:nth-last-of-type(2) {
  opacity: .7;
}
p[class="dots"]:nth-of-type(3), p[class="dots"]:nth-last-of-type(3) {
  opacity: .9;
}

/* end entries **************************************************************/
/* modal **********************************************************************/
.modal {
  display: none;
  position: fixed;
  z-index: 3;
  padding-top: 4rem;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0,0,0,.4);
}
.modal::before {
  position: absolute;
  content: 'x';
  right: 11rem;
  top: 3.125rem;
  font-size: 2rem;
  font-weight: bold;
  opacity: .7;
}
.modal-content {
  position: relative;
  box-sizing: content-box;
  background-color: white;
  margin: auto;
  padding: 0;
  border: 1px solid #888;
  width: 60%;
  box-shadow: 0 4px 8px 0 rgba(0,0,0,.2), 0 6px 20px 0 rgba(0,0,0,.19);
  animation-name: animatemodal;
  animation-duration: .7s;
  animation-timing-function: ease-in-out;
  display: flex;
  align-content: center;
  justify-content: space-between;
}
@keyframes animatemodal {
  from {left: -300px; opacity: 0}
  to {left: 0; opacity: 1}
}
.pic {
  padding: 1rem;
  border: 2px solid #aaa039;
  height: auto;
  margin: 1rem;
  text-align: center;
  font-family: 'Roboto Slab', serif;
  color: #807615;
  font-style: italic;
  font-size: .825rem;
  background-color: white;
}
.num-msg { /* has purpose, see main.js */
  font-style: normal;
}
.text-wrapper {
  display: flex;
  flex-flow: column;
  justify-content: space-between;
  padding: 1rem;
  width: 50%;
  position: relative;
}
.preview-text, .title, .link {
  box-sizing: border-box;
  width: 100%;
  font-family: 'Roboto Slab', serif;
  border: 2px solid #aaa039;
  background-color: white;
  padding: 1rem;
  margin-top: .25rem;
}
.title {
  margin-top: 0;
  font-weight: bold;
}
.link {
  text-decoration: none;
  cursor: pointer;
  color: black;
  font-weight: bold;
}
.link span {
  border-bottom: 2px solid #aaa039;
}
/* end modal ******************************************************************/
