@import url("https://fonts.googleapis.com/css2?family=Source+Sans+3:ital,wght@0,200..900;1,200..900&display=swap");

/* ---- Base ---- */
body {
  max-width: 900px;
  margin: 0 auto;
  padding: 2rem 1rem;
  font-family: "Source Sans 3", sans-serif;
  line-height: 1.6;
  color: #222;
}

/* ---- Headings ---- */
h1,
h2,
h3 {
  line-height: 1.3;
}

h2 {
  margin-top: 2.5rem;
}

h3 {
  margin-top: 1.5rem;
}

/* ---- Navigation ---- */
header nav a {
  margin-right: 1rem;
  text-decoration: none;
  color: #0366d6;
}

header nav a:hover {
  text-decoration: underline;
}

/* ---- Links ---- */
a {
  color: #0366d6;
}

a:hover {
  text-decoration: underline;
}

/* ---- Lists ---- */
ul {
  padding-left: 1.2rem;
}

li {
  margin-bottom: 0.5rem;
}

/* ---- Footer ---- */
footer {
  margin-top: 3rem;
  font-size: 0.9rem;
  color: #666;
}

/* ---- details hover cursor ---- */
details summary {
  cursor: pointer;
}

/* ---- Profile block ---- */
.profile {
  display: flex;
  align-items: center;
  gap: 2rem;
  margin-bottom: 2rem;
}

.profile-img {
  width: 160px;
  height: 160px;
  border-radius: 50%;
  object-fit: cover;
  box-shadow:
    0 1px 2px rgba(0, 0, 0, 0.04),
    0 8px 24px rgba(0, 0, 0, 0.03);
}

.profile-text h1 {
  margin-top: 0;
}

/* ---- Mobile ---- */
@media (max-width: 600px) {
  .profile {
    flex-direction: column;
    text-align: center;
  }
}

/* ---- Profile links ---- */
.profile-links {
  display: flex;
  gap: 0.8rem;
  margin-top: 0.8rem;
}

.profile-links img {
  /* width: 22px; */
  height: 25px;
  opacity: 0.85;
}

.profile-links a:hover img {
  opacity: 1;
}

/* Mobile */
@media (max-width: 600px) {
  .profile-links {
    justify-content: center;
  }
}

/* ---- body color ---- */
body {
  background-color: #fafafa;
}

.main-container {
  max-width: 900px;
  margin: 0 auto;
  background-color: #ffffff;
  padding: 0.5rem 2.75rem;
  border-radius: 12px;
  box-shadow:
    0 2px 4px rgba(0, 0, 0, 0.04),
    0 10px 28px rgba(0, 0, 0, 0.03);
}

/* ---- content section ---- */
.content-section {
  margin-top: 1rem;
  padding: 1rem 2rem;

  background: linear-gradient(
    180deg,
    rgba(245, 250, 255, 0.95) 0%,
    rgba(255, 255, 255, 0.95) 70%
  );
  border-radius: 10px;

  box-shadow:
    0 2px 4px rgba(0, 0, 0, 0.03),
    0 10px 28px rgba(0, 0, 0, 0.025);
}

/* ---- navigation ---- */
.site-nav {
  display: flex;
  gap: 1.75rem;

  padding: 0 0;
  margin-bottom: 3.5rem;

  font-size: 1.2rem;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.site-nav a {
  position: relative;
  padding: 0.35rem 0.6rem;
  border-radius: 8px;

  color: #111;
  text-decoration: none;
}

.site-nav a::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;

  background: rgba(31, 79, 216, 0.08);
  opacity: 0;

  transition: opacity 0.5s ease;
}

.site-nav a:hover::before {
  opacity: 1;
}

/* ---- timeline ---- */
#timeline-container {
  overflow: auto;
  padding: 0 0;

  .inner-container {
    max-width: 1000px;
    margin: 0 auto;
  }
}

.timeline {
  margin: 0 auto;
  position: relative;
  left: 120px;
  width: 80%;
  max-width: 900px;
  margin-top: 16px;
  margin-left: 5%;
}

.timeline-item {
  color: black;
  font-family: var(--font-family-2);
  text-align: left;
  font-size: 1rem;
  padding: 1rem 1.5rem 1rem 1.5rem;
  border-left: 4px solid black;
  border-bottom: 1px solid black;
  position: relative;
  list-style-type: none;
  --item-width: calc(100%);

  &::after {
    content: attr(data-date);
    position: absolute;
    right: calc(var(--item-width) + 40px);
    top: 16px;
    float: right;
    font-weight: bold;
    white-space: nowrap;
  }

  &::before {
    content: "";
    border-radius: 50%;
    width: 16px;
    height: 16px;
    background-color: #0f0f0f;
    position: absolute;
    left: -10px;
    top: 21px;
  }

  &:last-child {
    border-bottom: none;
  }
}

@media only screen and (max-width: 800px) {
  .timeline {
    margin: 0 auto;
    position: relative;
    left: 85px;

    .timeline-item {
      font-size: 1.1rem;

      &::after {
        right: calc(var(--item-width) + 30px);
      }
    }
  }
}

@media only screen and (max-width: 800px) {
  .timeline-item {
    padding: 1rem 1.5rem 1rem 0.5rem;

    &::after {
      right: calc(var(--item-width) + 20px);
    }
  }
}
