@import url("https://fonts.googleapis.com/css2?family=Space+Mono:ital,wght@0,400;0,700;1,400;1,700&display=swap");
@import url("https://fonts.googleapis.com/css2?family=Montserrat:wght@200;400;700;900&display=swap");

/* :root {
  --dark-1: #151618;
  --dark-2: #25282c;
  --dark-3: #151618;
  --light-1: #fff;
  --light-2: #a9abb3;
  --light-3: #3f3f3f;
  --light-4: #32353a;
} */

:root {
  --dark-1: #292d3e;
  --dark-2: #1c1f2d;
  --dark-3: #292d3e;
  --light-1: #fff;
  --light-2: #a9abb3;
  --light-3: #ffdda7;
  --light-4: #292d3e;
}

* {
  font-family: inherit;
  text-decoration: none;
  margin: 0;
  padding: 0;
  -webkit-user-drag: none;
  -moz-window-dragging: none;
  -webkit-tap-highlight-color: transparent;
  line-height: inherit;
}

* img {
  max-width: 100%;
}

html,
body {
  font-family: "Montserrat", monospace;
  font-size: 18px;
  background-color: var(--dark-1);
  color: var(--light-1);
  padding: 1rem;
}

header {
  display: flex;
  flex-direction: row;
  justify-content: flex-start;
  align-items: center;
  padding: 3rem 0 5rem 0;
}

header img.profile {
  max-width: 250px;
  border-radius: 50%;
  margin-right: 2rem;
}

header .bio .owner-name {
  font-size: 4rem;
  font-weight: 900;
}

header .desc {
  font-size: 1rem;
  font-weight: lighter;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  gap: 0.5rem;
  /* font-style: italic; */
}

header .sub-desc {
  font-weight: lighter !important;
  color: var(--light-2);
  font-size: 0.8rem;
}

header .social {
  margin-top: 1.2rem;
  display: flex;
  column-gap: 0.8rem;
}

header .social .icon {
  filter: invert() !important;
  width: 35px;
  height: 35px;
}

header .social .icon:hover {
  transform: scale(1.2);
}

nav {
  margin-top: 1.4rem;
  display: flex;
  column-gap: 1rem;
  justify-content: flex-start;
  align-items: center;
}

nav a {
  color: var(--light-2);
  font-size: 1.2rem;
}

nav a:hover {
  color: var(--light-1);
}

nav a.active {
  color: var(--light-1);
  font-weight: bold;
}

main {
  margin-top: 2rem;
  color: var(--light-2);
}

.post-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  column-gap: 2rem;
  row-gap: 2rem;
}

.post {
  background-color: var(--dark-2);
  min-height: 150px;
  box-shadow: rgba(0, 0, 0, 0.1) 0px 1px 3px 0px,
    rgba(0, 0, 0, 0.06) 0px 1px 2px 0px;
  font-size: 1.2rem;
  padding: 1rem;
  border: 2px solid transparent;
  border-radius: 15px;
  color: var(--light-1);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.post:hover {
  border: 2px dashed var(--light-2);
}

.post .post-date {
  color: var(--light-2);
  display: block;
  position: absolute;
  top: -2px;
  left: -2px;
  border-radius: 15px 0 0 0;
  padding: 5px 15px;
  background-color: var(--light-1);
  color: var(--dark-2);
  border-right: 4px solid var(--light-2);
  border-bottom: 4px solid var(--light-2);
}

.post .post-title {
  font-weight: bolder;
  margin-top: 2rem;
}

/* 
.post .thumbnail {
  width: 100%;
  margin-top: 1rem;
  border-radius: 15px;
  height: auto !important;
} */

.post .thumbnail {
  display: block;
  margin-top: 1rem;
  border-radius: 15px;
  aspect-ratio: 16/12;
  width: 100%;
  background-size: cover;
  background-repeat: no-repeat;
  background-position: center;
  object-fit: cover;
}

/* project */

#tags {
  display: flex;
  flex-direction: row;
  justify-content: flex-start;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  margin-top: 1rem;
}

#tags .tag {
  background-color: var(--light-1);
  color: var(--dark-2);
  padding: 2px 5px;
  border-radius: 8px;
  font-size: 0.8rem;
  cursor: pointer;
  user-select: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
}

/* clear btn  */

#clear-btn-wrapper {
  display: flex;
  justify-content: flex-end;
  margin-top: 1rem;
}

#clear-btn-wrapper #clear {
  background-color: var(--light-1);
  font-weight: bold;
  color: var(--dark-2);
  border: none;
  border-radius: 12px;
  padding: 10px 15px;
  font-size: 0.8rem;
  cursor: pointer;
  user-select: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
}

#clear-btn-wrapper #clear:hover {
  filter: brightness(1.2);
}

#clear-btn-wrapper #clear:active {
  outline: 2px dashed var(--light-1);
}

.project-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  column-gap: 2rem;
  row-gap: 2rem;
}

.project {
  background-color: var(--dark-2);
  min-height: 150px;
  box-shadow: rgba(0, 0, 0, 0.1) 0px 1px 3px 0px,
    rgba(0, 0, 0, 0.06) 0px 1px 2px 0px;
  font-size: 1rem;
  padding: 1rem 1rem 0.3rem 1rem;
  border: 2px solid transparent;
  border-radius: 15px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  color: var(--light-1);
}

.project:hover {
  border: 2px dashed var(--light-2);
}

.project small {
  color: var(--light-2);
  margin-top: 0.2rem;
  display: block;
}

/* .project img {
  width: 100%;
  margin-top: 1rem;
  border-radius: 15px;
  height: 150px !important;
} */

.project .thumbnail {
  display: block;
  margin: 1rem 0 6px 0;
  border-radius: 15px;
  aspect-ratio: 16/12;
  width: 100%;
  background-size: cover;
  background-repeat: no-repeat;
  background-position: top;
  object-fit: cover;
}

.project .tags {
  margin: 1rem 0;
  display: flex;
  flex-direction: row;
  justify-content: flex-start;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.3rem;
}

.project .tags .tag {
  background-color: var(--light-1);
  color: var(--dark-3);
  padding: 2px 5px;
  border-radius: 8px;
  font-size: 0.8rem;
}

.project .links {
  display: grid;
  grid-template-columns: 1fr 1fr;
  column-gap: 0.2rem;
}

.project .links a {
  color: var(--light-2);
  text-align: center;
  font-size: 0.6rem;
  padding: 0.5rem;
  border-radius: 5px;
  flex: 1;
}

.project .links a:hover {
  color: var(--light-1);
  background-color: var(--light-4);
}

/* contact */

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.contact {
  background-color: var(--dark-2);
  box-shadow: 0 8px 24px 0 rgba(0, 0, 0, 0.24);
  padding: 1rem;
  display: flex;
  flex-direction: column;
  border-radius: 15px;
}

.contact input,
.contact textarea {
  display: block;
  background-color: var(--dark-2);
  border: 1px solid var(--light-3);
  padding: 0.5rem;
  margin: 0.5rem 0 1rem;
  color: var(--light-2);
  flex: 1;
  max-width: 100%;
}

.contact input:focus,
.contact textarea:focus {
  outline: 1px solid var(--light-2);
}

.contact button {
  padding: 0.5rem;
  background-color: var(--dark-2);
  border: 1px solid var(--light-3);
  color: var(--light-1);
}

/* common */
.page {
  max-width: 1400px;
  line-height: 190%;
  font-family: "Montserrat", sans-serif;

}

.page .page-title {
  color: var(--light-1);
  font-weight: bolder;
  font-family: "Montserrat", sans-serif;
  font-size: 2.4rem;
  line-height: 1.2;
}

.page .page-date {
  color: var(--light-1);
  font-weight: bolder;
  display: inline-block;
  font-size: 1.2rem;
  font-family: "Montserrat", sans-serif;
}

.page h1,
.page h2,
.page h3,
.page h4,
.page h5,
.page h6 {
  font-family: "Space Mono", monospace;
}

.page h1,
.page h2,
.page h3,
.page h4,
.page h5,
.page h6,
.page p,
.page ol,
.page ul,
.page table * {
  margin-bottom: 1rem;
  color: var(--light-2);
}
.page hr {
  margin-bottom: 1rem;
  border-color: var(--light-2);
  border-width: 2px;
  border-style: dashed;
  
}

.page blockquote {
  background-color: var(--dark-2);
  padding: 1rem;
  border-left: 5px solid var(--light-2);
  margin-bottom: 1rem;
}

.page blockquote p {
  margin: 0;
}

.page a {
  color: #292d3e;
  padding: 0 5px;
}

.page a:hover {
  color: var(--dark-2);
  background-color: #292d3e;
}

.page ul,
.page ol,
.page li {
  margin-left: 1rem;
}

.page table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.4rem 0;
}
.page th {
  background-color: var(--dark-2);
  color: var(--light-2);
}
.page th,
.page td {
  border: 1px solid var(--dark-2);
  padding: 5px;
}

.page img {
  cursor: zoom-in !important;
}

.emoji {
  height: 1.2rem;
  display: inline-block;
}

footer {
  padding: 2rem 0 0;
}

/* media queries */

@media screen and (max-width: 800px) {
  body {
    padding: 0.5rem;
  }
  header {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 20px 0;
  }
  header div img.profile {
    max-width: 100px;
  }
  header img.profile {
    width: 150px !important;
    margin: 2rem 0;
  }
  header .owner-name {
    font-size: 2rem !important;
    text-align: center;
  }
  header p.desc {
    font-size: 1rem !important;
    text-align: center;
  }
  header p.desc {
    font-size: 1rem !important;
    text-align: center;
  }
  header p.sub-desc {
    font-size: 0.8rem !important;
    text-align: center;
  }
  header div.social {
    text-align: center;
    justify-content: center;
    align-items: center;
  }
  header .social .icon {
    width: 25px;
    height: 25px;
  }
  nav {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    margin: 2rem 0;
  }
  nav a {
    font-size: 0.8rem;
  }
  .post-list {
    row-gap: 1rem;
  }
  .post .thumbnail,
  .project .thumbnail {
    height: 180px !important;
  }
}

/* syntax */

pre {
  background: var(--dark-2) !important;
  padding: 12px 13px;
  overflow-x: auto !important;
  margin: 1rem 0;
  /* font-size: 14px; */
  font-family: "Space Mono", monospace;
}

code {
  color: var(--light-2);
  border-radius: 2px;
  white-space: pre;
  background-color: var(--dark-2);
  font-family: monospace;
  font-family: "Space Mono", monospace;
  padding: 0px 5px;
}

.highlight .hll {
  background-color: #333333;
}
.highlight {
  background: #111111;
  color: #ffffff;
}
.highlight .c {
  color: #008800;
  font-style: italic;
  background-color: #0f140f;
} /* Comment */
.highlight .err {
  color: #ffffff;
} /* Error */
.highlight .g {
  color: #ffffff;
} /* Generic */
.highlight .k {
  color: #fb660a;
  font-weight: bold;
} /* Keyword */
.highlight .l {
  color: #ffffff;
} /* Literal */
.highlight .n {
  color: #ffffff;
} /* Name */
.highlight .o {
  color: #ffffff;
} /* Operator */
.highlight .x {
  color: #ffffff;
} /* Other */
.highlight .p {
  color: #ffffff;
} /* Punctuation */
.highlight .cm {
  color: #008800;
  font-style: italic;
  background-color: #0f140f;
} /* Comment.Multiline */
.highlight .cp {
  color: #ff0007;
  font-weight: bold;
  font-style: italic;
  background-color: #0f140f;
} /* Comment.Preproc */
.highlight .c1 {
  color: var(--light-2);
  font-style: italic;
  background-color: var(--dark-3);
} /* Comment.Single */
.highlight .cs {
  color: #008800;
  font-style: italic;
  background-color: #0f140f;
} /* Comment.Special */
.highlight .gd {
  color: #ffffff;
} /* Generic.Deleted */
.highlight .ge {
  color: #ffffff;
} /* Generic.Emph */
.highlight .gr {
  color: #ffffff;
} /* Generic.Error */
.highlight .gh {
  color: #ffffff;
  font-weight: bold;
} /* Generic.Heading */
.highlight .gi {
  color: #ffffff;
} /* Generic.Inserted */
.highlight .go {
  color: #444444;
  background-color: #222222;
} /* Generic.Output */
.highlight .gp {
  color: #ffffff;
} /* Generic.Prompt */
.highlight .gs {
  color: #ffffff;
} /* Generic.Strong */
.highlight .gu {
  color: #ffffff;
  font-weight: bold;
} /* Generic.Subheading */
.highlight .gt {
  color: #ffffff;
} /* Generic.Traceback */
.highlight .kc {
  color: #fb660a;
  font-weight: bold;
} /* Keyword.Constant */
.highlight .kd {
  color: #fb660a;
  font-weight: bold;
} /* Keyword.Declaration */
.highlight .kn {
  color: #fb660a;
  font-weight: bold;
} /* Keyword.Namespace */
.highlight .kp {
  color: #fb660a;
} /* Keyword.Pseudo */
.highlight .kr {
  color: #fb660a;
  font-weight: bold;
} /* Keyword.Reserved */
.highlight .kt {
  color: #cdcaa9;
  font-weight: bold;
} /* Keyword.Type */
.highlight .ld {
  color: #ffffff;
} /* Literal.Date */
.highlight .m {
  color: #0086f7;
  font-weight: bold;
} /* Literal.Number */
.highlight .s {
  color: #0086d2;
} /* Literal.String */
.highlight .na {
  color: #ff0086;
  font-weight: bold;
} /* Name.Attribute */
.highlight .nb {
  color: #ffffff;
} /* Name.Builtin */
.highlight .nc {
  color: #ffffff;
} /* Name.Class */
.highlight .no {
  color: #0086d2;
} /* Name.Constant */
.highlight .nd {
  color: #ffffff;
} /* Name.Decorator */
.highlight .ni {
  color: #ffffff;
} /* Name.Entity */
.highlight .ne {
  color: #ffffff;
} /* Name.Exception */
.highlight .nf {
  color: #ff0086;
  font-weight: bold;
} /* Name.Function */
.highlight .nl {
  color: #ffffff;
} /* Name.Label */
.highlight .nn {
  color: #ffffff;
} /* Name.Namespace */
.highlight .nx {
  color: #ffffff;
} /* Name.Other */
.highlight .py {
  color: #ffffff;
} /* Name.Property */
.highlight .nt {
  color: #fb660a;
  font-weight: bold;
} /* Name.Tag */
.highlight .nv {
  color: #fb660a;
} /* Name.Variable */
.highlight .ow {
  color: #ffffff;
} /* Operator.Word */
.highlight .w {
  color: #888888;
} /* Text.Whitespace */
.highlight .mf {
  color: #0086f7;
  font-weight: bold;
} /* Literal.Number.Float */
.highlight .mh {
  color: #0086f7;
  font-weight: bold;
} /* Literal.Number.Hex */
.highlight .mi {
  color: #0086f7;
  font-weight: bold;
} /* Literal.Number.Integer */
.highlight .mo {
  color: #0086f7;
  font-weight: bold;
} /* Literal.Number.Oct */
.highlight .sb {
  color: #0086d2;
} /* Literal.String.Backtick */
.highlight .sc {
  color: #0086d2;
} /* Literal.String.Char */
.highlight .sd {
  color: #0086d2;
} /* Literal.String.Doc */
.highlight .s2 {
  color: #0086d2;
} /* Literal.String.Double */
.highlight .se {
  color: #0086d2;
} /* Literal.String.Escape */
.highlight .sh {
  color: #0086d2;
} /* Literal.String.Heredoc */
.highlight .si {
  color: #0086d2;
} /* Literal.String.Interpol */
.highlight .sx {
  color: #0086d2;
} /* Literal.String.Other */
.highlight .sr {
  color: #0086d2;
} /* Literal.String.Regex */
.highlight .s1 {
  color: #0086d2;
} /* Literal.String.Single */
.highlight .ss {
  color: #0086d2;
} /* Literal.String.Symbol */
.highlight .bp {
  color: #ffffff;
} /* Name.Builtin.Pseudo */
.highlight .vc {
  color: #fb660a;
} /* Name.Variable.Class */
.highlight .vg {
  color: #fb660a;
} /* Name.Variable.Global */
.highlight .vi {
  color: #fb660a;
} /* Name.Variable.Instance */
.highlight .il {
  color: #0086f7;
  font-weight: bold;
} /* Literal.Number.Integer.Long */

/* lightbox */
#lightbox {
  position: fixed;
  z-index: 1000;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.8);
  display: none;
}

#lightbox.active {
  display: flex;
  justify-content: center;
  align-items: center;
}

#lightbox img {
  max-width: 90%;
  max-height: 80%;
  padding: 4px;
  background-color: black;
  border: 2px solid white;
}

/* toast */

.toast {
  position: fixed;
  left: 50%;
  bottom: 5%;
  transform: translate(-50%, -50%);
  background-color: var(--light-1);
  color: var(--dark-2);
  padding: 10px 20px;
  border-radius: 8px;
  z-index: 9999;
  box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.5);
  font-size: 1.2rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
