:root {
  --main-bg-color: black;
  --text-color: white;
  --accent-color-grey: #737373;
  --accent-color-white: #d4d4d4;
  --accent-color-black: #1a1a1a;
  --font-size-xs: 12px;
  --font-size-sm: 14px;
  --font-size-md: 16px;
  --font-size-lg: 20px;
  --font-size-xl: 24px;
  --font-size-xxl: 32px;
  --font-size-3xl: 48px;
}

body {
  font-family: "Inter", sans-serif;
  font-optical-sizing: auto;
  font-style: normal;
  font-variation-settings: "slnt" 0;
  background-color: var(--main-bg-color);
  color: var(--text-color);
  height: 100vh;
  margin: 0;
  padding: 20px;
  padding-left: 5%;
  padding-right: 5%;
  font-size: var(--font-size-md);
  line-height: 1.6;
}

h1 {
  font-weight: 500;
  padding: 0;
  margin: 0 0 0.5em 0;
  letter-spacing: -0.02em;
  font-size: var(--font-size-xxl);
  line-height: 1.2;
}

p {
  font-size: var(--font-size-md);
}

a {
  text-decoration: none;
  color: var(--accent-color-grey);
}

.text-link {
  position: relative;
  color: var(--accent-color-grey);
  text-decoration: none;
  font-size: var(--font-size-sm);
  overflow: hidden;
  width: fit-content;
}

#personal-update {
  position: relative;
}

.timestamp {
  position: absolute;
  right: 35px;
  bottom: 35px;
  font-size: var(--font-size-sm);
}

.text-link::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 1px;
  background-color: currentColor;
  transition: width 0.3s;
}

.text-link:hover::after {
  width: 100%;
}

.nav {
  flex-direction: column;
}

.nav a {
  padding: 5px 0;
}

.header-text {
  margin-top: 96px;
  font-size: var(--font-size-3xl);
}

.header-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 20px;
  padding: 20px 0;
  margin-bottom: 1fr;
}

.subheader-text-grey {
  color: var(--accent-color-grey);
  font-size: var(--font-size-sm);
}
.subheader-text-container {
  margin-top: 48px;
}

.subheader-text-white {
  color: var(--accent-color-white);
  font-size: var(--font-size-md);
}

.text-card {
  background-color: var(--accent-color-black);
  padding: 36px;
  border-radius: 10px;
}

.span-two-coloumns {
  grid-column: span 2;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  padding-inline: 0;
  max-width: 100%;
  padding-bottom: 50px;
  overflow: auto;
}

.card {
  position: relative;
  text-align: left;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100%;
}

.card img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 10px;
  object-fit: fill;
  transition: transform 0.5s ease;
}

.card-text {
  position: absolute;
  bottom: 10px;
  left: 10px;
  color: var(--text-color);
  background-color: rgba(0, 0, 0, 0.7);
  padding: 8px;
  border-radius: 5px;
  font-size: var(--font-size-sm);
}

.content {
  letter-spacing: -0.01em;
  font-size: var(--font-size-md);
  font-weight: 300;
  line-height: 1.5;
}

.writing-links-container {
  display: flex;
  flex-direction: column;
}

#profile-card {
  position: relative;
}

#profile-card img {
  position: absolute;
  width: 150px;
  right: 20px;
  bottom: 80px;
}

@media (max-width: 1000px) {
  .card-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .header-grid {
    grid-template-columns: 1fr 1fr;
  }

  #profile-card {
    grid-column: span 2;
  }

  .text-card.span-two-columns {
    grid-column: span 2;
  }
}

@media (max-width: 600px) {
  :root {
    --font-size-xs: 10px;
    --font-size-sm: 12px;
    --font-size-md: 14px;
    --font-size-lg: 18px;
    --font-size-xl: 22px;
    --font-size-xxl: 28px;
    --font-size-3xl: 32px;
  }

  body {
    padding: 10px;
  }

  .card-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .header-grid {
    grid-template-columns: 1fr;
  }

  #profile-card img {
    width: 100px;
    right: 20px;
    bottom: 100px;
  }

  .header-grid,
  .card-grid {
    display: flex;
    flex-direction: column;
  }

  .timestamp {
    right: 15px;
    bottom: 15px;
  }
}
