/* variables - color scheme https://coolors.co/772334-1291a9-231f20-f4f4f4-bfd53e */
:root {
  --text: #231f20;
  --text-10: rgba(35, 31, 32, .1);
  --background: #f4f4f4;
  --background-shade: #e8e8e8;
  --background-shade-lighter: #efefef;
  --blue: #117A92;
  --font: 'Domaine Text', serif;
  --accent-font: 'Domaine Display', Georgia, serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --text: #f4f4f4;
    --text-10:  rgba(244, 244, 244, .1);
    --background: #231f20;
    --background-shade: #1f1b1c;
    --background-shade-lighter: #1b191a;
    --blue: #1595B2;
    --claret: #1595B2;
  }
}

/* basics */
body {
  background-color: var(--background);
  color: var(--text);
  font-family: var(--font);
  line-height: 1.5;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
  padding: 5%;
}

a {
  color: var(--blue);
  text-decoration: none;
  border-bottom: thin dotted var(--blue);
}

sup {
  vertical-align: top;
  
  a {
    border: none;
  }
}

.highlight {
  max-width: 900px;
  font-size: 1rem;
}

.highlight pre {
  white-space: pre-wrap;
  word-break: break-word;
  padding: 0.5% 1.5%;
}

table {
  border: 1px solid var(--blue);
  width: 100%;
  border-collapse: collapse;
  table-layout: auto;

  th {
    border: 1px solid var(--blue);
  }

  tr {
    
  }

  td {
    border: 1px solid var(--blue);
    padding: 5px 10px;
  }
}

/* header */
header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;

  h1 {
    font-family: var(--accent-font);
    font-style: italic;
    font-weight: normal;
    min-width: 150px;

    a {
      color: var(--text);
      border: none;
    }

    svg {
      color: var(--blue);
      width: 10px;
    }
  }

  nav {
    width: 80%;
    text-align: right;
  }
}

nav ul {
  list-style-type: none;
  padding: 0;
  margin: 0;

  li {
    display: inline-flex;
    box-sizing: border-box;
  }

  li:not(:last-child) {
    margin-right: 2%;
  }

  a {
    font-family: var(--accent-font);
    font-weight: normal;
    text-transform: lowercase;
    border: none;
  }
}

@media only screen and (max-width: 600px) {
  header {
    display: block;
    text-align: center;

    nav {
      width: 100%;
      text-align: center;
    }
  }
}

/* home.html & page.html */
.home, .page {

  time {
    font-family: var(--accent-font);
    font-weight: normal;
    font-style: italic;
    font-size: 1.75rem;
    display: block;
    text-align: center;
    @media only screen and (max-width: 600px) {
      font-size: 1.25rem;
    }
  }

  time::after {
    content: ' ';
    background: var(--text);
    width: 150px;
    height: 1px;
    display: block;
    margin: 2% auto 0 auto;
    opacity: .4;
  }

  .barcode {
    font-family: 'Libre Barcode', sans-serif;
    font-size: 2rem;
    text-align: center;
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    -khtml-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
    @media only screen and (max-width: 600px) {
      font-size: 1rem;
    }
  }

  article h2.title, article h1 {
    font-family: var(--accent-font);
    font-weight: 900;
    text-transform: uppercase;
    font-size: 3rem;
    text-align: center;
    margin: 2% 0;
    line-height: 1.2;
    word-spacing: .3rem;
    @media only screen and (max-width: 600px) {
      font-size: 2rem;
    }
  }

  article h2.title a {
    color: var(--text);
    border-bottom: none;
  }

  .tags ul {
    list-style-type: none;
    padding: 0;
    font-family: var(--accent-font);
    text-transform: uppercase;
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 5%;

    li {
      display: flex;
      background-color: var(--background-shade-lighter);
      border: 1px solid var(--background-shade);
      padding: 1% 2%;
      border-radius: 15px;

      svg {
        margin-right: 5px;
        margin-top: 4px;
      }

      a {
        color: var(--text);
        text-decoration: none;
        border-bottom: none;
        transition: all 0.5s ease;
      }
    }

    li:hover {
      a, svg {
        color: var(--blue);
        transition: all 0.5s ease;
      }
    }
  }

  @media only screen and (max-width: 600px) {
    .tags ul li {
      justify-content: center;
    }
  }

  article {
    padding: 7.5% 0;

    h2, h3 {
      color: var(--blue);
      font-family: var(--accent-font);
      text-transform: uppercase;
      text-align: center;
    }

    .anchor a {
      border: none;
      position: relative;
      transition: all 0.5s ease;
      margin-right: -30px;
    }

    .tooltip {
      opacity: 0;
      transition: all 0.25s ease;
      color: var(--text);
    }

    h2 a:hover .tooltip, h3 a:hover .tooltip, h4 a:hover .tooltip, h5 a:hover .tooltip, h6 a:hover .tooltip {
      opacity: .5;
      transition: all 0.25s ease;
    }

    .summary {

      p {
        display: inline;
      }

      .jump {
        display: inline;
        border-bottom: none;

        svg {
          height: 18px;
          position: relative;
          top: 3px;
        }
      }
    }
  }

  .cover {
    width: 100%;
    height: 500px;
    margin-top: 10px;
    border-radius: 15px;
    overflow: hidden;
    position: relative;

    img {
      transition: all 0.5s ease;
      object-fit: cover;
      width: 100%;
      height: 100%;
    }

    .overlay {
      position: absolute;
      top: 0;
      bottom: 0;
      left: 0;
      right: 0;
      height: 100%;
      width: 100%;
      opacity: 0;
      transition: .5s ease;
      background-color: var(--blue);
    }
  }

  .cover:hover {
    .overlay {
      opacity: .25;
    }

    img {
      scale: 1.2;
    }
  }
}

/* home.html that isn't shared with page.html */
.home article {
  border-bottom: 2px solid var(--text-10);

  .cover {
    margin-bottom: 2%;
  }

  h2.anchor {
    display: none;
  }
}

/* page.html that isn't shared with home.html */
.page {
  article {
    padding-top: 7.5%;

    p, ul, li {
      font-size: 1.25rem;
    }

    li {
      margin-bottom: 10px;
    }

    li::marker {
      color: var(--blue);
    }

    blockquote {
      margin: 0;
      padding: 2.5% 5%;
      background-color: var(--background-shade);
      border-radius: 15px;
    }

    code {
      background-color: var(--background-shade);
      padding: 4px 10px;
      border-radius: 15px;
    }

    pre {
      background-color: var(--background-shade);
      border-radius: 15px;
      padding: 2.5% 5%;
      color: var(--text);
      white-space: pre-wrap;

      code {
        background-color: transparent;
        color: var(--text);
      }
    }

    h2 {
      font-size: 2rem;
    }

    h3 {
      font-size: 1.5rem;
    }

    hr {
      border-top: 2px solid var(--text-10);
      color: var(--background);
      margin-top: 5%;
      margin-bottom: 5%;
    }

    img {
      max-width: 100%;
      display: block;
      margin: auto;
      border-radius: 15px;
    }

    img[src$='#album'] {
      float: left;
      width: 300px;
      margin-right: 25px;

      @media only screen and (max-width: 700px) {
        margin-right: 0;
        margin-bottom: 25px;
        width: 100%;
        float: none;
      }
    }

    .footnotes {
      margin: 5% 0;

      p {
        font-size: 1.1rem;
      }

      a.footnote-backref {
        border-bottom: none;
      }

      hr {
        background-color: var(--background-shade);
        opacity: .5;
      }
    }
  }
}

/* about/page.html */
.about h1 {
  color: var(--blue);
}

/* books/section.html & books/page.html */
.page.books, .page.games {
  .author {
    font-family: var(--accent-font);
    font-weight: normal;
    font-style: italic;
    font-size: 1.75rem;
    display: block;
    text-align: center;
    @media only screen and (max-width: 600px) {
      font-size: 1.25rem;
    }
  }

  .author::after {
    content: ' ';
    background: var(--text);
    width: 150px;
    height: 1px;
    display: block;
    margin: 2% auto 0 auto;
    opacity: .4;
  }

  h2.rating {
    color: var(--text);

    .stars {
      color: var(--blue);
    }
  }

  .info {
    margin-top: 4%;
    display: grid;
    grid-template-columns: 275px auto;
    @media only screen and (max-width: 600px) {
      display: inline;
    }
    grid-template-rows: auto 1fr;

    .bookcover {
      grid-row: span 2 / span 2;
      max-height: 400px;
      width: 250px;
      @media only screen and (max-width: 600px) {
        width: 100%;
        height: 300px;
        margin-top: 10px;
        margin-bottom: 10px;
      }
      overflow: hidden;
      border-radius: 15px;
      position: relative;

      img {
        object-fit: cover;
        transition: all 0.5s ease;
        height: 100%;
      }

      .overlay {
        position: absolute;
        top: 0;
        bottom: 0;
        left: 0;
        right: 0;
        height: 100%;
        width: 100%;
        opacity: 0;
        transition: .5s ease;
        background-color: var(--blue);
      }
    }

    .bookcover:hover {
      .overlay {
        opacity: .25;
      }

      img {
        scale: 1.2;
      }
    }

    .meta {
      padding: 0;
      margin: 0;
      list-style-type: none;
      display: flex;
      flex-wrap: wrap;
      gap: 1%;
      justify-content: center;
      align-items: stretch;

      li {
        display: flex;
        background-color: var(--background-shade-lighter);
        border: 1px solid var(--background-shade);
        padding: 2%;
        border-radius: 15px;
        font-size: .9rem;
        align-items: center;

        svg {
          color: var(--blue);
          position: relative;
          top: 2px;
        }

        svg.bi-playstation {
          height: 24px;
          width: 24px;
        }

        .label {
          font-weight: bold;
          text-transform: lowercase;
          margin-right: 5px;
          color: var(--blue);
        }
      }
    }

    .content {
      grid-column-start: 2;
      grid-row-start: 2;

      .summary {
        font-style: italic;
        margin-top: 2%;
        font-size: 1.4rem;
        font-family: var(--accent-font);
        font-weight: normal;
        text-align: center;
      }

      blockquote p {
        margin-bottom: 0;
      }

      p:first-of-type {
        margin-top: 0;
      }
    }
  }
}

.page.games .info.game {
  display: inline;

  .bookcover {
    width: 100%;
    height: 500px;
    margin-top: 10px;
    margin-bottom: 10px;

    img {
      width: 100%;
    }
  }
}

.section.books, .section.games {
  #read {
    margin-top: 2%;
    display: flex;
    gap: 2%;
    flex-wrap: wrap;
    justify-content: center;

    a {
      background-color: var(--background-shade-lighter);
      border: 1px solid var(--background-shade);
      width: 30%;
      box-sizing: border-box;      
      border-radius: 15px;
      padding: 2%;
      color: var(--text);
      transition: all 0.5s ease;
      margin-bottom: 2%;
    }

    a:hover {
      box-shadow: rgba(17, 17, 26, 0.05) 0px 1px 0px, rgba(17, 17, 26, 0.1) 0px 0px 8px;
      scale: 1.05;
      transition: all 0.25s ease;
    }
  }

  article {
    display: inline;
    border-bottom: none;

    .gamecover {
      height: 250px;
      display: flex;
      overflow: hidden;
      text-align: center;
      margin-bottom: 2%;
      border-radius: 15px;

      img {
        object-fit: cover;
        height: 100%;
        width: 100%;
      }
    }

    .bookcover {
      height: 250px;
      overflow: hidden;
      text-align: center;
      margin-bottom: 2%;

      img {
        object-fit: cover;
        height: 100%;
        border-radius: 15px;
      }
    }

    .title {
      color: var(--blue);
      font-family: var(--accent-font);
      font-weight: 900;
      font-style: italic;
      font-size: 1.5rem;
      text-align: center;
      width: 100%;
      line-height: 1.2;
    }

    .author {
      text-align: center;
      font-style: italic;
      margin-bottom: 2%;
      display: block;
    }

    .meta {
      padding: 0;
      margin: 2% 0 0 0;
      list-style-type: none;
      

      li, .time {
        display: inline;
        font-size: .8rem;
        font-style: normal;
        text-transform: capitalize;
        color: var(--blue);
      }
    }

    .barcode {
      font-family: 'Libre Barcode', sans-serif;
      font-size: 1.5rem;
      text-align: center;
      -webkit-touch-callout: none;
      -webkit-user-select: none;
      -khtml-user-select: none;
        -moz-user-select: none;
          -ms-user-select: none;
              user-select: none;
    }
  }

  p {
    font-size: .8rem;
    margin-top: 4%;
  }
}

@media only screen and (min-width: 500px) and (max-width: 900px) {
  .section.books #read a, .section.games #read a {
    width: 40%;
  }
}

@media only screen and (max-width: 499px) {
  .section.books #read a, .section.games #read a {
    width: 100%;
    margin-bottom: 2%;
  }
}

/* Shortcodes */
.page .audio {

  audio {
    display: block;
    margin: auto;
    border-radius: 15px;
    width: 60%;
  }

  figcaption {
    text-align: center;
    font-family: monospace;
    font-size: .9rem;
    font-style: italic;
  }
}

.boxes {
  display: flex;
  justify-content: center;
  align-items: baseline;
  gap: 10px;
  flex-wrap: wrap;
}

.box {
  background-color: var(--background-shade-lighter);
  border: 1px solid var(--background-shade);
  border-radius: 15px;
  padding: 2% 1%;
  text-transform: lowercase;

  .label {
    font-family: var(--accent-font);
    font-weight: bold;
    text-transform: lowercase;
    margin-right: 5px;
  }
}

figcaption {
  text-align: center;
  font-size: .9rem;
  font-style: italic;
}

/* pagination */
.pagination {
  list-style-type: none;
  padding: 7.5% 0 0 0;
  display: flex;
  justify-content: center;
  gap: 40px;
  font-family: var(--accent-font);
  text-align: center;
  text-transform: uppercase;
  font-size: 1.25rem;
}

@media only screen and (max-width: 600px) {
  .pagination {
    gap: 20px;
  }
}

.pagination__item a {
  border: none;
}

.pagination__item--current a {
  font-weight: 900;
  color: var(--text);
}

.pagination__item svg {
  width: 18px;
}

/* taxonomy.html, section.html, archive/page.html */
.term, .section, .archive {
  h1 {
    font-family: var(--accent-font);
    font-weight: 900;
    text-align: center;
    text-transform: uppercase;
    color: var(--blue);
    margin: 0;
    padding-top: 7.5%;
  }

  h2.year {
    color: var(--blue);
    font-weight: 900;
    font-family: var(--accent-font);
    font-size: 2rem;
  }

  article {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    border-bottom: 1px solid var(--text-10);
    padding: 2% 0;

    h2 {
      margin: 0;
      font-size: 1.3rem;
      text-align: left;
      width: 80%;
      text-transform: none;
      font-weight: normal;
      font-family: var(--accent-font);
  
      a {
        color: var(--text);
        border: none;
      }
    }

    time {
      font-style: italic;
      width: 20%;
      min-width: 200px;
      font-size: 1rem;
      text-align: left;
      text-transform: uppercase;
      opacity: .65;
      font-weight: 100;
      font-family: var(--accent-font);
    }

    time::after {
      display: none;
    }
  }  
}

#filter {
  h2 {
    text-align: center;
    margin: 0;
    font-weight: normal;
  }

  ul {
    list-style-type: none;
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    gap: 2%;
  }

  li {
    font-size: 1.25rem;
  }
}

/* footer */
footer {
  margin-top: 10%;

  nav {
    ul {
      justify-content: center;
      display: flex;
    }

    a {
      font-weight: 100;
    }
  }

  .social {
    list-style-type: none;
    padding: 0;
    display: flex;
    gap: 35px;
    justify-content: center;
    align-items: center;

    a {
      border-bottom: none;
    }

    svg {
      transform: scale(1.75);
    }
  }

  .forget {
    font-family: var(--accent-font);
    font-weight: normal;
    text-transform: uppercase;
    font-size: 1.5rem;
    text-align: center;
    margin: 10px 0;
    @media only screen and (max-width: 600px) {
      font-size: 1.25rem;
    }
  }

  .copyright {
    font-family: var(--accent-font);
    font-weight: normal;
    font-style: italic;
    text-transform: uppercase;
    text-align: center;
    margin: 10px 0;
  }
}