:root {
  --dot-bg: black;
  --dot-color: white;
  --dot-size: 1px;
  --dot-space: 6px;
}

.dots {
  background: linear-gradient(
        90deg,
        var(--dot-bg) calc(var(--dot-space) - var(--dot-size)),
        transparent 1%
      )
      center / var(--dot-space) var(--dot-space),
    linear-gradient(
        var(--dot-bg) calc(var(--dot-space) - var(--dot-size)),
        transparent 1%
      )
      center / var(--dot-space) var(--dot-space),
    var(--dot-color);
}

.stripes {
  background-color: #323232;
  opacity: 0.8;
  background-size: 5px 5px;
  background-image: repeating-linear-gradient(
    45deg,
    #d6d6d6 0,
    #d6d6d6 0.5px,
    #323232 0,
    #323232 50%
  );
}

* {
  box-sizing: border-box;
}

html,
button {
  font-size: 100%;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen,
    Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;
}

#home svg {
}

body {
  font-size: 18px;
  margin: 0;
  background-color: #000;
  color: white;
}

main {
  margin: 0.25rem;
}

figure {
  margin: 0;
}

.hidden {
  display: none;
}

/* VIEW TRANSITIONS */

@view-transition {
  navigation: auto;
}

::view-transition-old(root),
::view-transition-new(root) {
  animation: fade 0.3s ease both;
}

@keyframes fade {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

/* COLOR PREFERENCE */

@media (prefers-color-scheme: dark) {
  :root {
    --navlink-color: white;
  }

  body {
  }

  a {
    color: white;
  }

  a:visited {
    color: white;
  }

  a:hover,
  a:focus {
  }
}

@media (prefers-color-scheme: light) {
  :root {
    --navlink-color: #0066cc;
  }

  body {
  }

  a {
  }

  a:visited {
  }

  a:hover,
  a:focus {
  }
}

/* TYPOGRAPHY */

@media (min-width: 38rem) {
  h1,
  h2,
  h3,
  h4,
  h5 {
  }

  h1 {
  }

  h2 {
  }

  h3 {
  }

  h4 {
  }

  h5 {
  }
}

@media (min-width: 60rem) {
  body {
  }
}

/* GLOBAL */

p {
}

img {
  max-width: 100%;
}

pre {
}

table {
}

th,
td {
}

aside,
blockquote {
}

article h1 {
  padding-left: .5rem;
    background-color: #323232;
    opacity: 0.8;
    background-size: 5px 5px;
    background-image: repeating-linear-gradient(
      45deg,
      #d6d6d6 0,
      #d6d6d6 0.5px,
      #323232 0,
      #323232 50%
    );
  }
}

article blockquote {
}

/* LAYOUT */

@media (min-width: 55rem) {
  main,
  .masthead {
    margin-left: auto;
    margin-right: auto;
  }
}

@media (min-width: 55rem) {
  article,
  #item__nav {
    display: grid;
    grid-template-columns: 1fr 1fr 75ch 1fr 1fr;
  }
  aside {
    margin-left: auto;
    margin-right: auto;
  }

  #item__aside {
    grid-row: 2 / 100;
    grid-column: 2;
    /* rotate the text so its vertical */
    writing-mode: vertical-lr;
    width: fit-content;
    &:after {
      content: "";
      position: absolute;
      display: block;
      clear: both;
      background: linear-gradient(
            90deg,
            var(--dot-bg) calc(var(--dot-space) - var(--dot-size)),
            transparent 1%
          )
          center / var(--dot-space) var(--dot-space),
        linear-gradient(
            var(--dot-bg) calc(var(--dot-space) - var(--dot-size)),
            transparent 1%
          )
          center / var(--dot-space) var(--dot-space),
        var(--dot-color);
      height: 100vh;
      width: 30px;
    }
  }
}

/* MASTHEAD / NAV */

.masthead {
  display: grid;
  grid-template-rows: 100px 1fr 1fr;
  grid-template-columns: 1fr 1fr;
}

#masthead__name {
  grid-row: 1;
  grid-column: 1 / span 2;
  text-align: center;
}

#masthead__nav {
  grid-row: 4;
  grid-column: 1 / 3;
  display: flex;
  flex-direction: row;
  justify-content: center;
  margin: 1rem auto;
  gap: 1rem;

  a {
    color: var(--navlink-color);
    text-decoration: none;
    font-weight: bold;
  }
  a:hover {
    text-decoration: underline;
  }
}

#masthead__hero {
  grid-row: 1 / span 3;
  grid-column: 1 / span 3;
  z-index: -1;
  img {
    width: 100%;
    height: auto;
  }
}

@media (min-width: 38em) {
  #masthead__nav {
    grid-row: 2;
    grid-column: 2;
    justify-self: end;
    flex-direction: column;
    margin-right: 1rem;
  }

  #masthead__name {
    grid-row: 1;
    grid-column: 1;
    margin: 1rem;
    text-align: left;
  }
}

.nav {
  width: 100%;
}

.nav ul {
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 0;
}

.nav li {
  list-style: none;
  padding-bottom: 0.5rem;
}

@media (min-width: 50rem) {
  .nav ul {
    flex-direction: row;
  }
  .nav li {
    padding-bottom: unset;
    padding-right: 1rem;
  }
}

#tetris {
  display: flex;
  position: relative;
  min-height: 600px;
  margin: 2rem auto;
}

#tetris .statement {
  position: relative;
  z-index: 10;
  place-self: center;
  text-align: center;
  width: 100%;
}

/* hide tetris piece when under 40rem */
@media (max-width: 40rem) {
  .tetris-piece {
    display: none;
  }
}

.tetris-piece {
  pointer-events: auto;
  user-select: none;
}

.statement {
  text-align: center;
  margin: 5rem 1rem;
  font-weight: normal;
}

/* ARTICLE */

#item__nav {
  display: flex;
  flex-direction: column;
}

.home-link {
  display: flex;
  align-items: center;
}

article h1 + small {
  margin: 1.5rem 0 0 0;
}

article a > img {
  filter: none;
}

article img {
  @media (max-width: 38rem) {
    max-width: 100% !important;
  }
}

@media (min-width: 38rem) {
  article > * {
    grid-column: 3 / 4;
  }

  article > img,
  article > picture,
  article > div {
    grid-column: 2 / 5;
    margin-left: auto;
    margin-right: auto;
  }

  article > .card-deck--posts {
    grid-column: 3 / 4;
  }

  article > div.cp_embed_wrapper {
    margin-left: unset;
    margin-right: unset;
  }

  #item__nav {
    flex-direction: row;
    align-items: center;
    gap: 1rem;
  }
}

.article--timeline ul {
  position: relative;
  display: flex;
  flex-direction: column;
  list-style-type: none;
  border-left: 1px solid var(--theme-yellow);
  padding-left: 0;
  margin-left: 0;
}

.article--timeline ul li {
  display: flex;
  align-items: flex-start;
  margin-bottom: 3rem;
}

.article--timeline ul li > * {
  margin: 0 0.5rem;
}

/* make a little circle at each li */
.article--timeline ul li::before {
  position: absolute;
  content: "";
  display: inline-block;
  width: 0.5rem;
  height: 0.5rem;
  background-color: var(--theme-orange);
  border-radius: 50%;
  margin-left: -0.25rem; /* half the width */
  margin-right: 0.5rem;
  margin-top: 0.75rem;
}

.chip {
  border-radius: var(--radius);
  color: var(--theme-blue);
  border: 1px solid var(--theme-yellow);
  text-transform: uppercase;
  font-size: var(--size-300);
  font-family: Arial, Helvetica, sans-serif;
  padding: 0.25rem 0.5rem;
  background-color: var(--theme-yellow);
}

.chip--hot {
  border-color: var(--theme-red);
  background-color: var(--theme-red);
  color: white;
}

.article--timeline .date {
  margin-right: 1rem;
}

.date,
.small-text {
  font-size: var(--size-300);
  font-family: Arial, Helvetica, sans-serif;
  color: var(--theme-blue);
  text-transform: uppercase;
}

/* HOME */

.centered-container {
  display: flex;
  place-content: center;
}

.center-spaced {
  margin: 5rem auto;
  max-width: 60ch;
}

.wall {
  margin: 1rem;
  display: grid;
  grid-template-columns: 1fr;
  grid-template-rows: 1fr;
  width: 100%;
}

.wall--fullbleed {
  -webkit-background-size: cover;
  -moz-background-size: cover;
  -o-background-size: cover;
  background-size: cover;
}

.wall__image {
  max-width: 100%;
}

.wall__link {
  text-decoration: none;
}

.wall__image,
.wall__caption {
  grid-column: 1;
  grid-row: 1;
}

.wall__caption {
  color: white;
  text-transform: uppercase;
  letter-spacing: 1vw;
  text-align: center;
  align-self: center;
  font-size: 7vw;
  z-index: 2;
}

/* FOOTER */

/* FOOTER */

.footer {
}

.footer__container,
.footer__bio,
.footer__intro {
  display: flex;
  flex-direction: column;
  align-items: center;
}

footer ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer__container,
.footer__colophon,
.footer__bio {
  padding: 1rem;
}

.footer__fact {
  margin-bottom: 1rem;
}

@media (min-width: 45rem) {
  .footer__container,
  #home__about {
    max-width: 100ch;
    margin-left: auto;
    margin-right: auto;
    padding-top: 6rem;
    padding-bottom: 6rem;
  }
  .footer__container,
  .footer__bio {
    flex-direction: row;
  }
  .footer__container {
    justify-content: space-between;
    align-items: flex-start;
  }

  .footer__intro {
    margin-left: 0.5rem;
    align-items: flex-start;
  }

  .footer__bio {
    padding: 0;
    flex-grow: 1;
  }

  .footer__colophon {
    margin-left: auto;
    max-width: 600px;
    padding: 0;
    padding-left: 1rem;
  }
}

.gray,
article img {
  filter: grayscale(100%);
  transition: filter 0.3s ease;
  &:hover {
    filter: none;
  }
}

.avatar {
  aspect-ratio: 1;
  max-width: 100%;
  padding: 1rem;
  filter: grayscale(100%);
}

.avatar--inline {
  width: 100px;
  aspect-ratio: 1;
  border-radius: 50%;
}

.footer__avatar {
  width: 100px;
  border-radius: 500px;
}

@media (min-width: 45rem) {
  h2 {
  }
}

.split-list {
}

@media (min-width: 45rem) {
  .split-list {
  }
}

.card-deck {
  display: flex;
  flex-direction: column;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  list-style-type: none;
}

@media (min-width: 60rem) {
  .card-deck {
    flex-direction: row;
    justify-content: space-evenly;
  }
}

.card-deck--posts {
  .card {
    width: 100%;
    max-width: unset;
    margin-left: auto;
    margin-right: auto;
    &:last-child {
      margin-bottom: 2rem;
    }
  }
}

.card {
  border: 1px solid white;
  padding: 1rem;
  max-width: 400px;
  margin: 0.25rem;
  &:before {
    content: "";
    display: block;
    clear: both;
    background: linear-gradient(
          90deg,
          var(--dot-bg) calc(var(--dot-space) - var(--dot-size)),
          transparent 1%
        )
        center / var(--dot-space) var(--dot-space),
      linear-gradient(
          var(--dot-bg) calc(var(--dot-space) - var(--dot-size)),
          transparent 1%
        )
        center / var(--dot-space) var(--dot-space),
      var(--dot-color);
    height: 30px;
  }

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

.card__header {
}

.card__name {
}

.card__image {
}

.cage {
}

.cage .heart {
}

/* BIOS */
#bios {
  margin: 5rem 1rem;
  max-width: 60ch;
  justify-self: center;
}

details {
  border: 1px solid white;
  padding: 0.5rem;
  summary {
    font-weight: bold;
    cursor: pointer;
  }

  @media (min-width: 55rem) {
    min-width: 60ch;
  }
}

/* https://codepen.io/argyleink/pres/MWMPOap?editors=0100  */
details {
  @media (prefers-reduced-motion: no-preference) {
    interpolate-size: allow-keywords;
  }

  &::details-content {
    opacity: 0;
    block-size: 0;
    overflow-y: clip;
    transition: content-visibility 0.3s allow-discrete, opacity 0.3s,
      block-size 0.3s;
  }

  &[open]::details-content {
    opacity: 1;
    block-size: auto;
  }
}

/* BOOK */

.book-intro {
  display: flex;
  gap: 1rem;
}

.card img {
  filter: grayscale(100%);
  object-fit: contain;
}

.card img:hover {
  filter: none;
}

.book__actions {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 2rem;
}

.button {
  background-color: var(--theme-color);
  color: white;
  padding: 1rem;
  text-align: center;
  text-decoration: none;
  border-radius: var(--radius);
  font-weight: bold;
  border: 1px solid white;
}

@media (min-width: 40rem) {
  .book__actions {
    flex-direction: row;
    justify-content: center;
  }
}

/** LOGOS */

.logos {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  background-color: white;
  padding: 1rem;
  overflow-x: scroll;
}

.logos img {
  /* aspect-ratio: 1; */
  padding: 0.1rem;
  margin: 0.1rem;
  filter: none;
}

.logos ~ table {
  text-align: center;
  overflow-x: scroll;
  img {
    filter: none;
  }
}

/* stripe the table rows */
.logos ~ table tr:nth-child(odd) {
  background-color: rgba(255, 255, 255, 0.05);
}

.logo-solo {
  margin: 1rem auto;
  filter: none;
}

.no-filter {
  filter: none;
}

.rounded-all {
  border-radius: var(--radius);
}

/* Masonry Layout */
.masonry {
  column-count: 1;
  column-gap: 1rem;
  margin: 2rem 0;
}

@media (min-width: 640px) {
  .masonry {
    column-count: 2;
  }
}

@media (min-width: 1024px) {
  .masonry {
    column-count: 3;
  }
}

.masonry img {
  width: 100%;
  height: auto;
  margin-bottom: 1rem;
  break-inside: avoid;
  border-radius: var(--radius);
  display: block;
}
