/* LAYOUT */

:root {
  font-family: 'Hubot Sans', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
  font-size: calc(14px + 0.390625vw);
  font-weight: normal;
  line-height: 1.5;
}


@font-face {
  font-family: 'Hubot Sans';
  src:
    url('/fonts/HubotSans-Regular.woff2') format('woff2 supports variations'),
    url('/fonts/HubotSans-Regular.woff2') format('woff2-variations');
  font-weight: 200 300 400 900;
  font-stretch: 75% 125%;
}

* {
  box-sizing:border-box;
}

body {
  --color-text: #175d88;
  --color-bg: #f0d6e0;
  --color-nav: var(--color-text);
  --color-link: var(--color-text);
  --color-acc: #eeff00;
  --color-grey: #175d8810;
  background: var(--color-bg);
  color: var(--color-text);
  margin: 1rem;
  max-width: 100vw;
  padding: 1rem;
  background: linear-gradient(150deg, var(--color-bg), #00ffff30), url(/images/noise.svg);
  background-attachment: fixed;
  background-size: auto auto;
}

a {
  color: var(--color-link);
  text-decoration: underline;
  text-decoration-color: var(--color-acc);
  filter: drop-shadow(0 .15rem .25rem #ff00ff22);
  &:hover{
    filter: drop-shadow(0 .15rem .25rem #ffff00aa);
    color: var(--color-text);
  }
}

.content {
  margin: 10vw 0;
  grid-auto-rows: auto;
  display: grid;
  grid-template-columns: minmax(50%, 1fr);
  & > * {
    grid-column: 1/2;
  }
  & figure {
    height: 1rem;
    width: 100%;
    max-width: 100%;
    grid-column: 2/3;
    overflow: visible;
    margin: 0;
    padding-left: clamp(4px,6vw,4rem);
  }
  & figure img {
    width: 100%;
  }
}

p, blockquote, ul {
  max-width: 65ch;
  margin: 0 0 1rem 0;
}

h1, h2, h3, h4, h5, h6 {
  max-width: 30ch;
  font-weight: normal;
  margin: 2rem 0 1rem 0;
  &.header {
    font-size: 2rem;
    line-height: 1.1;
    margin: 1rem .5rem 0 0;
    max-width: 80vw;
  }
}

/* NAVIGATION */

.site-nav {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  & span {
    flex-grow:1;
    font-style: italic;
  }
}

.site-nav a {
  font-size: 1.5rem;
  display: block;
  font-weight: 400;
  font-stretch: 120%;
  font-weight: 600;
  &.active {
    text-decoration: none;    
    }
  &:hover {
  }
  }
}

.main-menu {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
  max-width: 100vw;
  list-style: none;
  margin: 0;
  padding: 0;
}

@media screen and (max-width: 780px) {
  .site-nav,
  .main-menu {
    flex-direction: column;
    align-items: normal;
    gap: 0;
    font-size: 1.5rem;
  }
  .site-nav span {
    font-size: 1rem;
  }
  .site-nav a {
    transition: none; filter: none;
  }
  .content figure {
    height: initial;
    width: initial;
    grid-column: 1 / 2;
    padding: 0;
  }
}

/* LISTS */

.post-snippet {
  margin-bottom: 1rem;
}

.post-snippet h3 {
  margin-bottom: 0.25rem;
}

table {
  border-collapse: collapse;
  & td, th {
    vertical-align: top;
    text-align: left;
    padding: .5rem;
  }
  & tr:nth-child(2n) {
    background-color: var(--color-grey);
  }
}
