/*****************************************
                VARIABLES
*****************************************/
:root {
  --text-color: #2d2d2d;
  --border-color: #D3D3D3;
  --link-color: #5B5BFD;
  --brand-color: #31359D;
  --background-color: #FAF9F7;
  --widget-background-color: #F5F5F5;
  --serif: "Newsreader", Georgia, serif;
  --sans: "Figtree", system-ui;
  --mono: "JetBrains Mono", monospace;
}

/*****************************************
                HELPERS
*****************************************/
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.mono {
  font-family: var(--mono);
  text-transform: uppercase;
}

.logo {
  font-family: var(--serif);
  font-optical-sizing: auto;
  color: var(--brand-color);
  padding: 8px 0;
  font-weight: 700;
  font-size: 20px;
  line-height: 94%;
  letter-spacing: -0.01em;
  text-decoration: none;
}

.logo-secondary {
  opacity: 0.6;
}

.flr {
  float: right;
}

/*****************************************
        RESET & GLOBAL STYLES
*****************************************/
*, *::before, *::after {
  box-sizing: border-box;
}

* {
  margin: 0;
}

html,
body {
  font-family: var(--serif);
  font-optical-sizing: auto;
  margin: 0;
  padding: 0;
  color: var(--text-color);
  font-size: 19px;
  line-height: 123%;
  background-color: var(--background-color);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  scroll-behavior: smooth;
}
@media (min-width: 700px) {
  html,
  body {
    font-size: 21px;
    line-height: 140%;
  }
}
@media (prefers-reduced-motion: reduce) {
  html,
  body {
    scroll-behavior: auto;
  }
}

h1, h2, h3, h4, h5, h6 {
  margin: 0;
  padding: 0;
}

img, picture, video, canvas, svg {
  display: block;
  max-width: 100%;
}

input, button, textarea, select {
  font: inherit;
}

p {
  text-wrap: pretty;
}

nav {
  display: flex;
  grid-column: layout;
  margin: 0 auto;
  padding-inline: 16px;
  max-width: 1400px;
  width: 100%;
}

/*****************************************
               HOMEPAGE
*****************************************/
.post a {
  display: block;
  padding: 20px 24px;
  color: inherit;
  text-decoration: none;
  transition: background-color 0.2s ease-out;
}
.post a:hover {
  background-color: rgba(0, 0, 0, 0.05);
}
@media (min-width: 900px) {
  .post a {
    padding: 24px 0;
  }
}

@media (min-width: 900px) {
  .post-wrapper {
    display: flex;
    gap: 32px;
    margin: 0 auto;
    max-width: 920px;
  }
}

.post-image {
  margin-bottom: 16px;
  width: 150px;
  height: 75px;
  background-color: #ddd;
  border-radius: 36px;
  overflow: hidden;
}
@media (min-width: 900px) {
  .post-image {
    margin-bottom: 0;
    min-width: 250px;
    height: 125px;
    border-radius: 62.5px;
  }
}
.post-image img,
.post-image svg {
  height: 100%;
  object-fit: cover;
}

.post-title {
  margin-bottom: 6px;
  font-size: 32px;
  line-height: 94%;
  font-weight: 700;
}
@media (min-width: 900px) {
  .post-title {
    font-size: 60px;
    font-variation-settings: "opsz" 60;
  }
}

.post-subtitle {
  margin-bottom: 10px;
  font-family: var(--sans);
  font-size: 17px;
  line-height: 19px;
  font-weight: 400;
  opacity: 0.8;
}
@media (min-width: 900px) {
  .post-subtitle {
    font-size: 18px;
  }
}

.post-date {
  font-size: 14px;
  line-height: 13px;
  letter-spacing: 0.06em;
  opacity: 0.7;
}

@keyframes drawExtinction1 {
  from {
    stroke-dashoffset: 100px;
  }
  to {
    stroke-dashoffset: 0px;
  }
}
@keyframes drawExtinction2 {
  from {
    stroke-dashoffset: 0px;
  }
  to {
    stroke-dashoffset: 100px;
  }
}
#extinction-line-1 {
  stroke-dasharray: 50px, 50px;
  animation: drawExtinction1 10000ms linear infinite;
}

#extinction-line-2 {
  stroke-dasharray: 50px, 50px;
  animation: drawExtinction2 10000ms linear infinite;
}

@keyframes drawKelvinLine {
  from {
    stroke-dashoffset: 600px;
  }
  to {
    stroke-dashoffset: -600px;
  }
}
.kelvin-line {
  stroke-dasharray: 600px, 600px;
  animation: drawKelvinLine 5000ms linear var(--delay) infinite backwards;
}

#line-5000k {
  --delay: 0ms;
}

#line-4000k {
  --delay: 400ms;
}

#line-3000k {
  --delay: 800ms;
}

#line-2000k {
  --delay: 1200ms;
}

/* Home specific styles can go here later */