*,
::backdrop,
:after,
:before {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  border: 0 solid;
}

:root {
  --background: #f5f5f5;
  --bg-gradient: linear-gradient(
    0deg,
    rgba(240, 240, 240, 1) 0%,
    rgba(252, 252, 252, 1) 100%
  );
  --text: #101010;
  --btn: #f0f0f0;
  --btn-hover: #e0e0e0;
  --subtext: #666666;
}

[data-scheme="light"] {
  color-scheme: light;
}

[data-theme="dark"] {
  color-scheme: dark;
  --background: #111111;
  --bg-gradient: linear-gradient(0deg, rgb(16, 16, 16) 0%, rgb(24 22 22) 100%);
  --text: #f4f4f4;
  --btn: #232323;
  --btn-hover: #2c2c2c;
  --subtext: #aaaaaa;
}

html {
  background-color: var(--background);
}

body {
  background-color: var(--background);
  background: var(--bg-gradient);
  color: var(--text);
  font-family: "Geist", "Inter", system-ui, sans-serif;
  transition: background-color 0.3s, color 0.3s;
  min-height: 100vh;
  display: flex;
  justify-content: center;
  /* align-items: center; */
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
}

main {
  position: relative;
  display: flex;
  flex-direction: column;
  max-width: 692px;
  margin: 0 auto;
  padding: 28px;
  margin-top: 8vh;
  margin-bottom: 8rem;
  overflow-x: hidden;
}

.header {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap-reverse;
}

.hi {
  display: flex;
  flex-direction: column;
  gap: 5px;
  font-weight: 500;
  font-size: 21px;
}

/* .hi img {
  width: 100px;
  height: 100px;
  border-radius: 20rem;
  margin-bottom: 16px;
  object-fit: cover;
} */

#theme-toggle {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 1.5rem;
  line-height: 1;
  padding: 0.5rem;
  border-radius: 50%;
  transition: background 0.3s;
  align-self: end;
}

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

.icon-sun {
  display: flex;
}
.icon-moon {
  display: none;
}

[data-theme="dark"] .icon-sun {
  display: none;
}
[data-theme="dark"] .icon-moon {
  display: flex;
}

.bio {
  display: flex;
  flex-direction: column;
  gap: 20px;
  color: var(--subtext);
  margin-top: 24px;
  line-height: 1.6;
}

a {
  color: var(--text);
  text-decoration: none;
  font-weight: 500;
}

.links {
  margin-top: 28px;
  display: flex;
  flex-direction: row;
  gap: 12px;
  user-select: none;
  flex-wrap: wrap;
}

.links a {
  display: flex;
  cursor: pointer;
  font-weight: 500;
  padding: 0px 16px;
  gap: 6px;
  background-color: var(--btn);
  border-radius: 100px;
  border: 1px solid var(--btn-hover);
  align-items: center;
  height: 36px;
  transition: background-color 0.3s, color 0.3s;
}

.links a:hover {
  background-color: var(--btn-hover);
}

.experience,
.projects {
  margin-top: 6rem;
}

.experience .title,
.projects .title {
  font-weight: 500;
  color: var(--subtext);
  /* font-size: 17px; */
  font-variant-caps: all-small-caps;
}

.experience-wrapper,
.projects-wrapper {
  margin-top: 12px;
  display: flex;
  flex-wrap: nowrap;
}

.experience-wrapper {
  flex-direction: column;
  gap: 6px;
  color: var(--subtext);
}

.experience-wrapper .line {
  height: 1px;
  background-color: var(--btn-hover);
  filter: opacity(0.75);
}

.experience-wrapper .item {
  display: flex;
  width: 100%;
  flex-direction: row;
  justify-content: space-between;
  padding: 8px 0;
}

.experience-wrapper .item > div:first-child {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.experience-wrapper .item .role {
  color: var(--text);
  font-weight: 500;
}

.experience-wrapper .item p {
  font-size: 14px;
  filter: opacity(0.7);
}

.projects-wrapper {
  gap: 16px;
}

.projects-wrapper .item {
  display: flex;
  width: 100%;
  flex-direction: column;
  flex-wrap: nowrap;
  border: 1px solid var(--btn-hover);
  background-color: rgba(150, 150, 150, 0.04);
  padding: 4px;
  border-radius: 14px;
  transition: background-color 0.3s, color 0.3s, transform 0.3s;
}

.projects-wrapper .item:hover {
  cursor: pointer;
  background-color: rgba(140, 140, 140, 0.08);
  transform: scale(1.05);
}

.projects-wrapper .item .banner {
  position: relative;
  background-color: var(--background);
  border: 1px solid var(--btn-hover);
  border-radius: 8px;
  height: 12rem;
  display: flex;
}

.projects-wrapper .item .banner .icon {
  position: absolute;
  left: 50%;
  top: 50%;
  translate: -50% -50%;
  background-color: rgba(150, 150, 150, 0.05);
  border: 1px solid var(--btn-hover);
  border-radius: 14px;
  height: 4rem;
  width: 4rem;
  text-align: center;
  align-content: center;
}

.projects-wrapper .item .banner .h-lines {
  position: absolute;
  left: 50%;
  top: 50%;
  translate: -50% -50%;
  width: 100%;
  height: 65%;
  border-top: 1px dashed rgba(120, 120, 120, 0.2);
  border-bottom: 1px dashed rgba(120, 120, 120, 0.2);
}

.projects-wrapper .item .banner .v-lines {
  position: absolute;
  left: 50%;
  top: 50%;
  translate: -50% -50%;
  height: 100%;
  width: 50%;
  border-left: 1px dashed rgba(120, 120, 120, 0.2);
  border-right: 1px dashed rgba(120, 120, 120, 0.2);
}

.projects-wrapper .item .name {
  display: flex;
  flex-direction: column;
  padding: 8px;
  gap: 4px;
}

.projects-wrapper .item .name span {
  font-weight: 500;
}

.projects-wrapper .item .name p {
  color: var(--subtext);
}

.footer {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  margin-top: 40px;
  text-align: center;
  color: var(--subtext);
  font-size: smaller;
  padding: 0px 10px;
}

@media (max-width: 768px) {
  #theme-toggle {
    display: none;
  }

  .projects-wrapper {
    flex-wrap: wrap;
  }
}
