@charset "UTF-8";

@font-face {
  font-family: "ProtestPaint";
  src: url('../fonts/ProtestPaint_BB_Regular.otf')  format('opentype');
  font-weight: normal;
  font-style: normal;
}

:root {
  --drop-shadow: drop-shadow(0 1px 1px rgb(240, 240, 240));
  --timeline-point: black;
}

/* general styles */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  margin: 0;
  background-color: #f5f5f5;
  font-family: Helvetica, Arial, sans-serif;
}

main {
  background-color: #ffffff;
  margin: 0 auto;
  padding-bottom: 2.5em;
  filter: var(--drop-shadow);
}

main > p,
section > p {
  margin-inline: 1.25em;
}

h1, h2, h3 {
  font-family: "ProtestPaint";
}

h2 {
  font-size: 3.5rem;
  margin: 0.5em 0.5em;
  line-height: 1;
}

h3 {
  font-size: 2rem;
  line-height: 1.2;
  margin: 0.5em 0em;
}

h3:not(.date) {
  margin-top: 0;
}


a {
  text-decoration: solid underline 3px;
  color: #0000cc;
}

a:hover {
  -webkit-filter: brightness(120%);
          filter: brightness(120%);
  /* color: #e80036; */
        }
/* update scroll margin */

  .card-wrapper .date {
    scroll-margin-top: 1em;
  }

img {
  max-width: 100%;
}

p, ul {
  margin: 1em;
  font-size: 1.125rem;
  line-height: 1.6;
}

ul {
  list-style: none;
}

ul li p {
  margin-block: 0.5em;
  line-height: 1.5;
}

blockquote {
  background: #ededed;
  font-size: 1.125rem;
  line-height: 1.6;
  padding: 1.25em 1.5em;
  margin: 1.5em 1.25em;
  font-style: italic;
}

blockquote p {
  margin: 0;
}

blockquote p:not(:last-child) {
  margin-bottom: 1em;
}

li + blockquote {
  margin-top: 0;
}

.resources li:last-child {
  padding-bottom: 0.5;
}

/* header */

header > a {
  padding-top: 4rem;
}

nav {
  position: fixed;
  top: 0;
  background: hsla(0, 0%, 100%, 0.9);
  width: fit-content;
  padding: 1em;
  width: 100%;
}

nav ul {
  margin: auto;
}

nav ul li a,
.toggle {
  color: #000;
  text-decoration: none;
  font-size: 1.25rem;
}

nav ul li {
  padding-bottom: 0.25em;
}

.toggles {
  margin: auto;
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  width: 100%;
}

.toggles > * {
  display: grid;
  place-items: center;
}

.menu-item {
  display: none;
}

.menu-active {
  display: block;
}

.hero-img {
  display: block;
  margin: auto;
  text-align: center; /* fix later */
}

/* resources details */

details {
  padding: 0.5em 0.5em 0;
  font-size: 1.125rem;
  cursor: pointer;
}

summary {
  background-color: #e8e8e8;
  padding: 0.5em;
  line-height: 1.6;
  font-weight: bold;
  font-size: 1.25rem;
}

details[open] summary {
  border-bottom: 1px solid #aaaaaa;
  margin-bottom: 0.5em;
}

.resources {
  padding: 0;
  margin: 1.5em 0.5em 0 0.5em;
}

.timeline-card details p,
.timeline-card details ul {
  margin-inline: 0;
}

.resources li {
  padding: 0em 1em 1em 1em;
}

.sources li:not(:last-child) {
  padding-block: 0.5em;
}

.sources li::before, 
.resources li::before {
  content: url("/img/arrow-right-2.svg");
  display: inline-block;
  vertical-align: text-top;
  /* padding-right: 0.25em; */
}

blockquote img,
.timeline-card img,
details img {
  display: inline-block;
  vertical-align: text-top;
  /* padding-right: 0.1em; */
}

.resources li {
  font-size: 1.125rem;
}

.resources li p a,
.sources li p a {
  word-wrap: break-word;
  word-break: break-all;
  overflow-wrap: break-word;
}

.resources li p a:not(.internal)::after,
.sources li p a:not(.internal)::after {
  content: url("/img/external-link.svg");
  display: inline-block;
  height: 1.125rem;
  width: 1.125rem;
  vertical-align: text-bottom;
  padding-left: 0.125em;
}



.item {
  color: #fff;
  font-weight: bold;
  padding: 0.125em 0.5em;
  border-radius: 0.25em;
  background-color: #000;
}

.item-red { background-color: #fc422f }
.item-yellow { background-color: #f5c714 }
.item-green {  background-color: #65dc30 }

.important {
  font-style: normal;
  font-weight: bold;
  color: #e01818;
}

/* updates */

.updates {
  background: #f5f5f5;
  padding: 1em;
  width: 85%;
  height: 180px; /* can be changed when more content is added */
  overflow: hidden;
  overflow-y: scroll;
  margin: 1em auto;
  border-radius: 4px;
}

.updates li {
  display: flex;
  gap: 1rem;
  border-bottom: 1px dotted #aaaaaa;
  padding-bottom: 0.125em;
}

.updates li b {
  display: inline-block;
  white-space: nowrap;
  width: fit-content;
}

.updates::-webkit-scrollbar {
  width: 5px;
}

.updates::-webkit-scrollbar-track {
  background: #f5f5f5;
}

.updates::-webkit-scrollbar-thumb {
  background: #ffffff;
  border-radius: 2px;
}

footer {
  text-align: center;
}

.details-wrapper details summary {
  margin-inline: 0.25em;
}

.timeline-wrapper {
  height: auto;
  margin: 0 1em;
  position: relative;
}

.timeline {
  list-style: none;
  padding-left: 1em;
  margin: 2em 0.5em;
  border-left: 4px black solid
}

/* item */

.timeline-card {
  background-color: white;
  color: black;
  border-radius: 10px;
  padding: 1.25em;
  filter: var(--drop-shadow);
  margin-bottom: 3em;
  /* margin-block: 3em; */
}

    .timeline-filler {
      width: 0%
    }

  .date {
    line-height: 0.5;
    margin-block: 2em 1em;
    margin-left: 0.125em;
  }

  .date:first-of-type {
    margin-top: 0;
  }

  .card-wrapper {
    position: relative;
  }

  .card-wrapper .date::before {
    content: "";
    position: absolute;
    display: block;
    height: 18px;
    width: 18px;
    border-radius: 50%;
    background: var(--timeline-point);
    left: -29px;
  }

  .card-wrapper:hover .date::before {
    background: #0000cc;
  }

@media all and (width > 700px) {

  main > p {
    margin-inline: 1.5em;
  }

  .toggles {
    display: none;
  }

  .menu-item {
    display: block;
  }

  nav ul {
    display: flex;
    justify-content: space-evenly;
  }

  .updates {
    width: 90%;
  }

  .timeline-card > p,
  .timeline-card details > p {
    margin: 1em 0.5em;
  }

  .timeline-card details ul {
    margin-inline: 1.5em;
  }

  .sources li {
    padding-left: 1em;
    text-wrap: wrap;
    word-wrap: break-word;
  }

}

@media all and (width > 800px) {

  main {
    border-radius: 0px 0px 8px 8px;
  }

  main, nav {
    width: 800px;
  }

  .details-wrapper details summary {
    margin-inline: 1em;
  }

  .timeline-wrapper,
  .timeline {
    width: 780px;
    margin: 3em auto;
  }
}

@media all and (width > 1000px) {

  .timeline {
    position: relative;
    margin: 3em auto; 
    width: 100%;                     
    /* left: 20% */}

    .timeline-card details p {
      margin-inline: 0em;
    }
 
    .timeline-card details ul {
      margin: 1.5em 0;
    }

  .timeline-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    margin: auto;
    padding-inline: 2em;
    width: 100%;
  }

  .timeline-card details {
    padding-inline: 0;
  }

  .card-wrapper {
    position: relative;
    margin-bottom: 5em;
    width: auto;
  }

  .card-wrapper:nth-child(even) {
    position: relative;
    right: calc(100% + 2.25em);
  }

  .card-wrapper:nth-child(even) .date {
    text-align: right;
    margin-right: 0.125em;
  }

  .card-wrapper:nth-child(even) .date::before {
    left: calc(100% + 11px);
    /* background: red; */
  }
}
