*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100%;
  min-height: 100vh;
  min-height: 100dvh;
  position: relative;
  overflow: hidden;
}

.content-box {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: min(950px, calc(100vw - 260px));
  height: min(450px, calc(100dvh - 180px));
  padding: 30px;
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.content-box::-webkit-scrollbar {
  display: none;
}

.home-image {
  display: block;
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  margin: 0 auto;
  object-fit: contain;
}

.nav-links {
  position: absolute;
  top: 50%;
  right: 80px;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 15px;
  text-align: right;
}

.nav-links a {
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 300;
  cursor: pointer;
}

footer {
  position: absolute;
  bottom: 30px;
  left: 40px;
  font-size: 0.85rem;
  font-weight: 300;
  letter-spacing: 0.5px;
  line-height: 1.5;
}

footer a {
  text-decoration: none;
}

.section-heading {
  font-weight: 400;
  margin-top: 0;
  font-size: 1.2rem;
  letter-spacing: 0.5px;
}

.post-date {
  font-size: 0.8rem;
  opacity: 0.45;
  margin-left: 6px;
}

/* Medium screens (tablets & smaller laptops) */
@media (max-width: 1024px) {
  .nav-links {
    right: 35px;
    gap: 12px;
  }

  .content-box {
    left: calc(50% - 25px);
    width: calc(100vw - 170px);
    height: min(450px, calc(100dvh - 170px));
    padding: 20px;
  }

  footer {
    bottom: 25px;
    left: 30px;
    font-size: 0.8rem;
  }
}

/* Small screens / Mobile */
@media (max-width: 640px) {
  .nav-links {
    right: 18px;
    gap: 10px;
  }

  .nav-links a {
    font-size: 0.85rem;
  }

  .content-box {
    left: calc(50% - 24px);
    width: calc(100vw - 95px);
    height: calc(100dvh - 160px);
    padding: 10px 10px 10px 5px;
  }

  .section-heading {
    font-size: 1.1rem;
  }

  footer {
    bottom: 18px;
    left: 20px;
    font-size: 0.72rem;
  }
}

/* Extra small screens (e.g. <= 380px wide) */
@media (max-width: 380px) {
  .nav-links {
    right: 12px;
    gap: 8px;
  }

  .nav-links a {
    font-size: 0.8rem;
  }

  .content-box {
    left: calc(50% - 22px);
    width: calc(100vw - 80px);
    height: calc(100dvh - 150px);
    padding: 8px 8px 8px 2px;
  }

  .section-heading {
    font-size: 1rem;
  }

  footer {
    bottom: 14px;
    left: 14px;
    font-size: 0.68rem;
  }
}

/* Short height screens (e.g. mobile landscape) */
@media (max-height: 550px) {
  .content-box {
    height: calc(100dvh - 100px);
    padding: 10px 15px;
  }

  .nav-links {
    gap: 8px;
  }

  footer {
    bottom: 10px;
    left: 20px;
    font-size: 0.7rem;
  }
}