@font-face {
  font-family: "Arimo";
  src: url("../fonts/Arimo-VariableFont.ttf");
}

@font-face {
  font-family: "Cozette";
  src: url("../fonts/CozetteVector.woff2") format('woff2'), url("../fonts/CozetteVector.woff") format('woff');
}

:root {
  --bg-color: #131215;
  --text-color: #FDFDFD;
  --accent-color: #89CB8C;
}

* {
  font-family: "Arimo", sans-serif;
  box-sizing: border-box;
}

html {
  scroll-padding-top: 30px;
  height: 100%;
  scroll-behavior: smooth;
}

body {
  background-color: var(--bg-color);
  color: var(--text-color);
  font-weight: 400;
  padding: 3em;
  padding-top: 1em;
  max-width: 60em;
  margin: auto;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

::selection {
  background: var(--accent-color);
  color: var(--bg-color);
}

::-webkit-scrollbar {
  width: 5px;
}

::-webkit-scrollbar-track {
  background: var(--bg-color);
}

::-webkit-scrollbar-thumb {
  background: var(--accent-color);
}

h1 {
  color: var(--accent-color);
  font-size: 2.2rem;
  margin: 0;
  display: inline-block;
  line-height: 1;
}

.header-brand {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.profile-pic {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--accent-color);
}

.header-titles {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.header-subtitle {
  font-family: "Cozette", sans-serif;
  font-size: 0.9rem;
  color: #A1A0A1;
  margin-top: 0.2rem;
}

.terminal-window {
  background-color: #0A0A0C;
  border: 1px solid rgba(253, 253, 253, 0.1);
  border-radius: 8px;
  overflow: hidden;
  margin-top: 1.5rem;
  margin-bottom: 2rem;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.terminal-header {
  background-color: #1A191C;
  padding: 10px 15px;
  display: flex;
  align-items: center;
  gap: 8px;
  border-bottom: 1px solid rgba(253, 253, 253, 0.05);
}

.term-btn {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.term-btn.red {
  background-color: #FF5F56;
}

.term-btn.yellow {
  background-color: #FFBD2E;
}

.term-btn.green {
  background-color: #27C93F;
}

.term-title {
  margin: 0 auto;
  font-family: "Cozette", monospace;
  color: #888889;
  font-size: 0.9rem;
  padding-right: 48px;
}

.terminal-body {
  padding: 1.5rem;
  font-family: "Cozette", monospace;
  font-size: 1rem;
  line-height: 1.6;
}

.term-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  margin-bottom: 0.2rem;
}

.prompt {
  font-family: "Cozette", monospace;
  color: #27C93F;
  margin-right: 10px;
}

.command {
  font-family: "Cozette", monospace;
  color: #FDFDFD;
}

.output {
  font-family: "Cozette", monospace;
  color: #A1A0A1;
  margin-bottom: 1.2rem;
  word-break: break-word;
}

.output a {
  font-family: "Cozette", monospace;
  color: #A1A0A1;
  margin-bottom: 1.2rem;
  word-break: break-word;
  text-decoration: underline;
}

.mt-active {
  margin-top: 1rem;
}

.term-cursor {
  display: inline-block;
  width: 8px;
  height: 1em;
  background-color: #FDFDFD;
  vertical-align: text-bottom;
  margin-left: 6px;
  animation: blink 1s step-end infinite;
  box-shadow: 0 0 5px rgba(253, 253, 253, 0.4);
}

p {
  max-width: 95ch;
  line-height: 1.5;
}

hr {
  color: var(--text-color);
  border: 0;
  border-top: 1px dashed var(--accent-color);
  margin: 1.5em 0;
  opacity: 0.5;
}

section {
  padding-top: 2rem;
  margin-bottom: 1.5rem;
}

.project-icon,
.project-tech-icon,
.tech-icon,
#footer .icon {
  display: inline-block;
  -webkit-mask-image: var(--svg);
  mask-image: var(--svg);
  -webkit-mask-size: contain;
  mask-size: contain;
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-position: center;
  mask-position: center;
}

.header-container {
  position: sticky;
  top: 0;
  z-index: 100;
  background-color: rgba(19, 18, 21, 0.75);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  padding: 1.25rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2.5rem;
  margin-top: 1em;
  flex-wrap: wrap;
  border: 1px solid rgba(253, 253, 253, 0.08);
}

.navbar {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.navbar a {
  color: var(--text-color);
  text-decoration: none;
  font-size: 1.1rem;
  transition: color 0.3s ease;
  position: relative;
  padding-bottom: 4px;
}

.navbar a::after {
  content: '';
  position: absolute;
  width: 100%;
  height: 2px;
  bottom: 0;
  left: 0;
  background-color: var(--accent-color);
  transform: scaleX(0);
  transform-origin: bottom right;
  transition: transform 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.navbar a:hover::after,
.navbar a.active::after {
  transform: scaleX(1);
  transform-origin: bottom left;
}

.navbar a:hover,
.navbar a.active {
  color: var(--accent-color);
}

.page-loader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: rgba(19, 18, 21, 0.8);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  transition: opacity 0.5s ease, visibility 0.5s ease;
}

.page-loader.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.loader {
  width: 40px;
  height: 40px;
  border: 3px solid #26202B;
  border-top-color: var(--accent-color);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

.tech-stack-container {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  margin-top: 0.5rem;
}

.tech-box {
  --box-accent: var(--accent-color);
  display: flex;
  flex-direction: column;
  gap: 1rem;
  border: 2px solid var(--box-accent);
  border-radius: 0.5rem;
  padding: 1.25rem;
  background-color: #1A191C;
}

.tech-box-header {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.tech-title {
  font-size: 1.25rem;
  font-weight: bold;
  color: var(--box-accent);
}

.tech-subtitle {
  font-size: 1rem;
  color: #A1A0A1
}

.tech-icons {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.tech-icon {
  width: 32px;
  height: 32px;
  background-color: var(--box-accent);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.tech-icons a:hover .tech-icon {
  opacity: 50%;
}

.projects-container {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.project-card {
  --box-accent: var(--accent-color);
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  border: 2px solid var(--box-accent);
  border-radius: 0.375rem;
  padding: 1rem;
  background-color: #1A191C;
  color: var(--box-accent);
  text-decoration: none;
}

.project-card-header {
  display: flex;
  flex-grow: 1;
  flex-direction: row;
  align-items: center;
}

.project-image {
  width: 4.5rem;
  height: 4.5rem;
  border-radius: 0.375rem;
  object-fit: contain;
  flex-shrink: 0;
  margin-right: 1rem;
  display: flex;
  justify-content: center;
  align-items: center;
}

.project-card-text {
  display: flex;
  flex-grow: 1;
  flex-direction: column;
  gap: 0.25rem;
}

.project-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-color);
  margin: 0;
}

.project-title a {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--box-accent);
  text-decoration: none;
  transition: opacity 0.2s ease;
}

.project-title a:hover {
  opacity: 0.75;
}

.project-title a::after {
  content: '';
  display: inline-block;
  width: 0.8em;
  height: 0.8em;
  background-color: currentColor; 
  -webkit-mask-image: url('../svg/newtab.svg');
  mask-image: url('../svg/newtab.svg');
  -webkit-mask-size: contain;
  mask-size: contain;
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
}

.project-desc {
  font-family: 'Cozette';
  font-size: 0.95rem;
  padding-right: 1.5rem;
  word-break: break-word;
  margin: 0;
  color: var(--text-color);
  line-height: 1.5;
}

.project-footer {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: flex-end;
  gap: 1rem;
}

.project-tech-icons {
  display: flex;
  flex-direction: row;
  gap: 0.5rem;
  color: var(--box-accent);
}

.project-icon {
  width: 42px;
  height: 42px;
  background-color: var(--box-accent);
}

.project-tech-icon {
  width: 28px;
  height: 28px;
  background-color: var(--box-accent);
  transition: background-color 0.2s ease, transform 0.2s ease;
}

.blog-container {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.blog-post {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  border: 1px solid var(--box-accent);
  border-left: 4px solid var(--accent-color);
  border-radius: 0.375rem;
  padding: 1.25rem;
  background-color: #1A191C;
  text-decoration: none;
  color: var(--text-color);
  transition: background-color 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}

.blog-post:hover {
  background-color: #212023;
  border-color: var(--box-accent);
  border-left-color: var(--accent-color);
  transform: translateX(5px);
}

.blog-post-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.blog-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--accent-color);
}

.blog-date {
  font-family: "Cozette", sans-serif;
  font-size: 0.9rem;
  color: #888889;
}

.blog-excerpt {
  font-family: "Cozette", sans-serif;
  font-size: 0.95rem;
  margin: 0;
  padding-right: 1.5rem;
  color: var(--text-color);
  line-height: 1.5;
}

.read-more {
  font-size: 0.85rem;
  color: var(--accent-color);
  margin-top: 0.5rem;
  font-weight: bold;
  opacity: 0.8;
  transition: opacity 0.2s ease;
}

.blog-post:hover .read-more {
  opacity: 1;
}

#footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.9rem;
  opacity: 0.8;
  width: 100%;
}

.footer-left,
.footer-right {
  display: flex;
  align-items: center;
  gap: 15px;
}

#footer p {
  font-family: "Cozette", sans-serif;
  margin: 0;
}

#footer img {
  vertical-align: middle;
  border: 1px solid var(--accent-color);
  padding: 2px;
  background: #090909;
}

#footer .icon {
  width: 24px;
  height: 24px;
  background-color: var(--text-color);
  transition: background-color 0.2s ease;
}

#footer a:hover .icon {
  background-color: var(--accent-color);
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes blink {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0;
  }
}

.blog-p {
  line-height: 1.7;
}

code {
  font-family: "Cozette", monospace;
  background-color: #0A0A0C;
  color: #FDFDFD;
  padding: 3px 8px;
  border: 1px solid rgba(253, 253, 253, 0.1);
  border-radius: 4px;
  font-size: 0.95rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
  white-space: nowrap;
}

.link {
  color: var(--accent-color);
  text-decoration: none;
  border-bottom: 1px dashed rgba(137, 203, 140, 0.5);
  transition: all 0.2s ease;
  padding: 0 2px;
}

.link:hover {
  color: var(--bg-color);
  background-color: var(--accent-color);
  border-bottom-style: solid;
  border-radius: 3px;
}

.back {
  color: var(--accent-color);
  font-weight: bold;
  text-decoration: none;
  margin-bottom: 2rem;
  display: inline-block;
}

@media (max-width: 650px) {
  body {
    padding: 1.5em 1em;
  }

  .header-container {
    padding: 1rem;
    gap: 1rem;
    flex-wrap: nowrap;
    margin-top: 0; 
  }

  .header-brand {
    gap: 0.5rem;
  }

  .profile-pic {
    width: 40px;
    height: 40px;
  }

  h1 {
    font-size: 1.5rem;
  }

  .header-subtitle {
    font-size: 0.75rem;
  }

  .navbar {
    gap: 0.8rem;
  }

  .navbar a {
    font-size: 0.95rem;
  }
}

@media (max-width: 400px) {
  .header-container {
    gap: 0.5rem;
    padding: 0.75rem;
  }

  .profile-pic {
    width: 32px;
    height: 32px;
  }

  h1 {
    font-size: 1.3rem;
  }

  .navbar {
    gap: 0.6rem;
  }

  .navbar a {
    font-size: 0.85rem;
  }
}