:root {
  --background-color: #212829;
  --text-color: #edede5;
  --main-color: #8089b4;
  --light-accent: #eb3e8e;
  --dark-accent: #3b5d7e;
  --header-font: 'PT Serif', serif;
  --subheader-font: 'Varela Round', sans-serif;
  --text-font: 'Spinnaker', sans-serif;
}

body {
  margin: 0;
  background: var(--background-color);
  color: var(--text-color);
  font-family: var(--text-font);
  font-size: 1.125rem;
}

img {
  max-width: 100%;
  display: block;
}

.about-img {
  max-height: 300px;
  width: 100%;
  object-fit: cover;
  margin-bottom: 2em;
}

h1,
h2,
h3 {
  margin: 0;
  font-family: var(--header-font);
}

h2,
h3 {
  color: var(--text-color);
}

h1 {
  color: var(--background-color);
  font-size: 2rem;
  font-weight: 400;
}

h2 {
  font-size: 1.5rem;
}

p {
  opacity: 0.7;
  line-height: 1.5;
}

header {
  text-align: center;
  background: var(--text-color);
  padding: 2em 0;
  margin-bottom: 2em;
}

footer {
  text-align: center;
  background: var(--main-color);
  color: rgba(255, 255, 255, 0.65);
  padding: 2em 0;
}

footer p {
  margin: 0;
}

footer a {
  color: var(--text-color);
}

a {
  color: #bca6d8;
  transition: all 150ms ease-in-out;
}

a:hover,
a:focus {
  color: blue;
}

.signature {
  font-size: 14px;
}

strong {
  font-weight: bold;
}

.logo-title a {
  text-decoration: none;
}

.logo-subtitle,
.continue-reading {
  font-family: var(--subheader-font);
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: 2px;
}

.logo-subtitle {
  margin: 0;
  font-size: 0.75rem;
  color: var(--dark-accent);
}

.continue-reading,
.article-info {
  font-size: 0.875rem;
}

.continue-reading {
  text-decoration: none;
  color: var(--main-color);
  transition: all 150ms ease-in-out;
}

.continue-reading:hover,
.continue-reading:focus {
  color: var(--text-color);
  text-decoration: underline;
}

.article-info {
  opacity: 0.7;
}

.container {
  width: 90%;
  max-width: 900px;
  margin: 0 auto;
}

.container-flex {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

/* navigation */

nav ul {
  list-style-type: none;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 0;
}

nav li {
  margin: 0.5em 0;
}

nav a {
  text-decoration: none;
  color: var(--background-color);
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: bold;
  font-size: 16px;
  padding: 0.25em 0;
  transition: all 150ms ease-in-out;
}

nav a:hover,
nav a:focus {
  color: var(--dark-accent);
}

.current-page {
  border-bottom: 1px solid var(--background-color);
}

.current-page:hover {
  color: var(--background-color);
}

@media (min-width: 675px) {
  .container-flex {
    flex-direction: row;
  }

  nav ul {
    flex-direction: row;
  }

  nav li {
    margin-left: 2.5em;
  }

  main {
    width: 75%;
  }

  aside {
    width: 20%;
    min-width: 200px;
    margin-left: 1em;
  }
}

/* articles */

.featured-article {
  border-bottom: 1px solid var(--text-color);
  padding-bottom: 2em;
  margin-bottom: 2em;
}

.recent-articles {
  display: flex;
  flex-direction: column;
  margin-bottom: 2em;
}

.recent-articles-body {
  order: 2;
}

.recent-articles-img {
  order: 1;
}

.featured-article {
  display: flex;
  flex-direction: column;
}

.article-img {
  order: -2;
}

.article-info {
  order: -1;
}

.article-img {
  width: 100%;
  max-height: 200px;
  object-fit: cover;
}

@media (min-width: 675px) {
  .recent-articles {
    flex-direction: row;
    justify-content: space-between;
  }

  .recent-articles-body {
    width: 70%;
  }

  .recent-articles-img {
    width: 25%;
  }

  .article-img {
    width: 100%;
    max-height: 300px;
    object-fit: cover;
    /* object-position: left; */
  }
}

/* widgets */

.widget-img {
  width: 100%;
  max-height: 200px;
  object-fit: cover;
  order: -1;
}

.sidebar-widget {
  border: 15px solid var(--dark-accent);
  padding: 1em;
  margin-bottom: 1em;
}

.widget-title {
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: 1em;
}

.widget-title,
.recent-post-title {
  font-size: 1em;
}

.widget-body {
  font-size: 14px;
  margin-top: 1.5em;
}

.widget-recent-posts {
  display: flex;
  flex-direction: column;
  border-bottom: 1px solid var(--text-color);
  margin-bottom: 2em;
}

.widget-recent-posts:last-child {
  border: 0;
  margin: 0;
}

.recent-post-title {
  margin: 1em 0 1.5em;
}
