@font-face {
  font-family: "Noto Sans";
  font-weight: 100 900;
  src: local("Noto Sans"),
    url("./fonts/Noto_Sans/NotoSans-VariableFont_wdth,wght.ttf");
  display: swap;
}

@font-face {
  font-family: "Fira Code";
  font-weight: 300 700;
  src: local("Noto Sans"),
    url("./fonts/Noto_Sans/NotoSans-VariableFont_wdth,wght.ttf");
  display: swap;
}

.giallo-l {
    display: inline-block;
    min-height: 1lh;
    width: 100%;
}
.giallo-ln {
    display: inline-block;
    user-select: none;
    margin-right: 0.4em;
    padding: 0.4em;
    min-width: 3ch;
    text-align: right;
    opacity: 0.8;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Noto Sans";
  max-width: 768px;
  margin: auto;
  padding: 0 18px;

  color: #4c4f69;
}

header {
  display: flex;
  align-items: baseline;
  gap: 24px;
}

header h1 {
  font-weight: normal;
}

header a {
  text-decoration: none;
  color: inherit;
}

header nav {
  display: flex;
  gap: 12px;
}

header nav a {
  color: #6c6f85;
}

a:hover {
  color: #4c4f69;
}

main a,
footer a {
  color: inherit;
}

main h1 {
  font-weight: 500;
}

main h1::before {
  content: ">_ ";
}

main h2::before {
  content: "｢ ";
}

main h2::after {
  content: " ｣";
}

main h3::before {
  content: "❯ ";
}

main p {
  font-size: 16px;
  line-height: 24px;
}

main .date {
  padding-left: 8px;
  border-left: 2px solid #179299;
}

main img {
  width: 100%;
}

p code {
  font-family: "Fira Code";
  font-weight: 600;
}

pre {
  padding: 12px;
  border-radius: 6px;
  font-family: "Fira Code";
  overflow-y: auto;
}

blockquote {
  margin: 20px 0;
  padding: 1px 40px;
  border-left: 3px solid #209fb5;
  background: #e6e9ef;
  border-top-left-radius: 5px;
  border-bottom-left-radius: 5px;
}

footer {
  margin-top: 20px;
  font-size: 12px;
  line-height: 16px;
  display: flex;
  align-items: center;
  gap: 16px;
}

footer *:last-child {
  margin-left: auto;
}

.posts {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.post .post-title {
  margin: 0;
  font-weight: normal;
}

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

.post .post-title a:hover {
  text-decoration: underline;
}

.post-details {
  display: flex;
  gap: 12px;
  padding-top: 6px;
  padding-left: 15px;
  font-size: 12px;
  color: #6c6f85;
}

.post-details .post-tags {
	margin: 0;
	padding: 0;
	list-style-type: none;
	display: flex;
	gap: 8px;
}

.post-tags li {
	padding: 0 6px;
	background: #eee;
	border-radius: 3px;
}

.post .post-date {
  font-size: 12px;
}

.blogpost-header {
  background: white;
  margin-bottom: 32px;
}

header h1,
.blogpost-header h1 {
  margin-bottom: 16px;
}

@media (max-width: 480px) {
  header {
    flex-direction: column;
    gap: 0px;
    margin-bottom: 20px;
  }

  .blogpost-header {
    flex-direction: column;
    padding-bottom: 20px;
  }
}

.scroll-to-top-container {
  display: flex;
  justify-content: flex-end;
  position: sticky;
  bottom: 20px;
  margin-top: -60px;
  margin-right: -60px;
}

.scroll-to-top-container button {
  background: white;
  font-size: 20px;
  border: 1px solid #7c7f93;
  color: #4c4f69;
  border-radius: 6px;
  padding: 6px 12px;
}

.scroll-to-top-container button:hover {
  background: #eff1f5;
  cursor: pointer;
}

@media (max-width: 480px) {
  .scroll-to-top-container {
    margin-right: 0;
  }
}

.table-of-content-container {
  position: sticky;
  bottom: 20px;
  margin-top: -62px;
  display: flex;
  justify-content: flex-end;
}

.table-of-content-container #table-of-content {
  display: none;
  border: 1px solid #9ca0b0;
  border-radius: 6px;
  background: white;
  position: absolute;
  bottom: 48px;
  width: 100%;
  padding: 0px 16px;
  box-shadow: 0px 10px 15px -3px rgba(0, 0, 0, 0.1);
}

#table-of-content h1 {
  font-size: 20px;
}

#table-of-content ul {
  margin-top: 3px;
  list-style-type: none;
}

#table-of-content li {
  font-size: 16px;
  padding: 4px 0;
}

#table-of-content-toggle {
  font-size: 28px;
  font-weight: lighter;
  background: white;
  box-shadow: 0px 10px 15px -3px rgba(0, 0, 0, 0.1);
  border: 1px solid #9ca0b0;
  border-radius: 6px;
  padding: 0 12px;
}
