:root {
  /*--base-clr: #11121a; */
  --line-clr: #42434a;
  --hover-clr: #17181b;
  --text-clr: #fff;
  --accent-clr: #0099cc;
  --secondary-text-clr: #fff;
}

* {
  margin: 0;
  padding: 0;
}

html {
  font-family: Arial, sans-serif;
  line-height: 1.5rem;
}

body {
  min-height: 100vh;
  min-height: 100dvh;
  background-color: #17181b;
  color: #fff;
  display: grid;
  grid-template-columns: auto 1fr;
}

#sidebar {
  box-sizing: border-box;
  height: 100vh;
  width: 250px;
  padding: 60px 1em 5px 1em;
  background-color: #0e1013;
  border-right: 1px solid var(--line-clr);
  position: sticky;
  top: 0;
  align-self: start;
  transition: 300ms ease-in-out;
  overflow: hidden;
  text-wrap: nowrap;
}

#sidebar.close {
  padding: 5px;
  width: 60px;
}

#sidebar ul {
  list-style: none;
}

#sidebar > ul > li:first-child {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 16px;
  .logo {
    font-weight: 600;
  }
}

#sidebar ul li.active a {
  color: var(--accent-clr);

  svg {
    fill: var(--accent-clr);
  }
}

#sidebar a,
#sidebar .dropdown-btn,
#sidebar .logo {
  border-radius: 0.5em;
  padding: 0.85em;
  text-decoration: none;
  color: var(--text-clr);
  display: flex;
  align-items: center;
  gap: 1em;
}

.dropdown-btn {
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  font: inherit;
  cursor: pointer;
}

#sidebar svg {
  flex-shrink: 0;
  fill: var(--text-clr);
}

#sidebar a span,
#sidebar .dropdown-btn span {
  flex-grow: 1;
}

#sidebar a:hover,
#sidebar .dropdown-btn:hover {
  background-color: var(--hover-clr);
}

#sidebar .sub-menu {
  display: grid;
  grid-template-rows: 0fr;
  transition: 300ms ease-in-out;

  > div {
    overflow: hidden;
  }
}

#sidebar .sub-menu.show {
  grid-template-rows: 1fr;
}

.dropdown-btn svg {
  transition: 200ms ease;
}

.rotate svg:last-child {
  rotate: 180deg;
}

#sidebar .sub-menu a {
  padding-left: 2em;
}

#toggle-btn {
  margin-left: auto;
  padding: 1em;
  border: none;
  border-radius: 0.5em;
  background: none;
  cursor: pointer;

  svg {
    transition: rotate 150ms ease;
  }
}

#toggle-btn:hover {
  background-color: var(--hover-clr);
}

main {
  /*padding: min(30px, 7%);*/
  padding: 30px 100px 30px 100px
}

img {
  display: block;
  max-width: 100%;
  height: auto;
  text-align: center;
  margin: auto;
}

main p {
  color: var(--secondary-text-clr);
  margin-top: 5px;
  margin-bottom: 15px;
}

.container {
  border: 1px solid #17181b;
  border-radius: 1em;
  margin-bottom: 20px;
  padding: min(1em, 15%);
  h2,
  p {
    margin-top: 1em;
  }
}

.card {
  padding: 0;
  border: 1px solid #17181b;
  border-radius: 10px;
  background-color: #17181b;
  text-align: center;
}

.photo-container {
  display: grid;
  border: 1px solid #17181b;
  grid-template-columns: repeat(1, minmax(300px, 1fr));
  gap: 30px;
  justify-content: center;
}

.list-container {
  width: 1fr;
}

.blog-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.blog-list li {
  display: flex;
  justify-content: space-between;
  align-items: center;

  padding: 10px 0;
  font-size: 1.1em;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  cursor: pointer;
}

.blog-list li:last-child {
  border-bottom: none;
}

.title {
  color: #e0e0e0;
  transition: color 0.2s;
  flex-shrink: 0;
}

.date {
  color: #999999;
  white-space: nowrap;
  flex-shrink: 0;
  margin-left: 20px;
}

.blog-list li:hover .title {
  color: #ffffff;
}

.title.special {
  color: #e0e0e0;
}

@media (max-width: 800px) {
  body {
    grid-template-columns: 1fr;
  }

  main {
    padding: 4em 1em 60px 1em;
  }

  .container {
    border: none;
    padding: 0;
  }

  #sidebar {
    height: 60px;
    width: 100%;
    border-right: none;
    border-bottom: 1px solid var(--line-clr);
    padding: 0;
    position: fixed;
    bottom: unset;
    top: 0;

    > ul {
      padding: 0;
      display: grid;
      grid-auto-columns: 1fr;
      grid-auto-flow: column;
      align-items: center;
      overflow-x: scroll;
    }

    ul li {
      height: 100%;
    }

    ul a,
    ul .dropdown-btn {
      width: 60px;
      height: 60px;
      padding: 0;
      border-radius: 0;
      justify-content: center;
    }

    ul li span,
    ul li:first-child,
    .dropdown-btn svg:last-child {
      display: none;
    }

    ul li .sub-menu.show {
      position: fixed;
      top: 60px;
      left: 0;
      box-sizing: border-box;
      height: 60px;
      width: 100%;
      background-color: var(--hover-clr);
      border-bottom: 1px solid var(--line-clr);
      display: flex;
      justify-content: center;

      > div {
        overflow-x: auto;
      }

      li {
        display: inline-flex;
      }

      a {
        box-sizing: border-box;
        padding: 1em;
        width: auto;
        justify-content: center;
      }
    }
  }
}
