/* Base styling */
body {
  font-family: system-ui, sans-serif;
  font-size: 18px;
  margin: 0;
  padding: 0;
  background: #fff;
  color: #000;
}

/* Layout container */
.container {
  display: flex;
  max-width: 1200px;
  margin: 40px auto;
  padding: 0 20px;
}

/* Sidebar styling */
.sidebar {
  min-width: 180px;
  margin-right: 40px;
}

/* Sidebar nav vertically aligned */
/* Default: hidden on mobile */
.sidebar nav {
  display: none;
}

/* Desktop sidebar layout */
@media screen and (min-width: 769px) {
  .sidebar nav {
    display: flex;
    flex-direction: column;
    gap: 12px;
  }
}

.sidebar h2 {
  margin-top: 0;
  font-size: 22px;
}

/* Main content styling */
.main {
  flex: 1;
  max-width: 700px;
  line-height: 1.6;
}

p {
  margin-bottom: 1em;
}

/* Link styling */
a {
  color: #0066cc;
  text-decoration: none;
  position: relative;
  display: inline-block;
  transition:
    color 0.3s ease,
    text-shadow 0.3s ease;
}

/* Rainbow underline effect */
a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -2px;
  height: 2px;
  background: linear-gradient(
    90deg,
    red,
    orange,
    yellow,
    green,
    blue,
    indigo,
    violet
  );
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

/* Hover sparkle effect */
a:hover {
  color: black;
  text-shadow:
    0 0 8px gold,
    0 0 12px #ff69b4;
}

a:hover::after {
  opacity: 1;
}

/* Cat animation element */
.cat-jump {
  position: absolute;
  top: 0;
  left: 0;
  width: 80px;
  height: auto;
  opacity: 1 !important;
  z-index: 9999;
  pointer-events: none;
  animation: jump-cat 1s ease-out forwards;
}

@keyframes jump-cat {
  0% {
    transform: translateX(0) translateY(0);
    opacity: 1;
  }
  50% {
    transform: translateX(50px) translateY(-40px);
    opacity: 1;
  }
  100% {
    transform: translateX(100px) translateY(0);
    opacity: 1;
  }
}

.cat-run {
  position: absolute;
  width: 50px;
  height: auto;
  opacity: 1 !important;
  z-index: 9999;
  pointer-events: none;
  animation: run-cat 1s linear forwards;
}

@keyframes run-cat {
  0% {
    transform: translateX(0);
    opacity: 1;
  }
  100% {
    transform: translateX(100px);
    opacity: 1;
  }
}

/* Sparkle styling */
.sparkle {
  position: absolute;
  width: 8px;
  height: 8px;
  background: radial-gradient(circle, gold 0%, transparent 70%);
  border-radius: 50%;
  opacity: 0.8;
  pointer-events: none;
  animation: sparkle-fade 0.8s ease-out forwards;
}

@keyframes sparkle-fade {
  from {
    transform: scale(1);
    opacity: 0.8;
  }
  to {
    transform: scale(0.2);
    opacity: 0;
  }
}

@media screen and (max-width: 768px) {
  .container {
    flex-direction: column;
    padding: 0 16px;
  }

  .sidebar {
    margin-right: 0;
    margin-bottom: 20px;
  }

  .main {
    max-width: 100%;
  }

  img.profile-pic {
    width: 120px;
    display: block;
    margin: 0 auto 1em auto;
  }
}

/* Sidebar section spacing and emoji cleanup */
.sidebar nav h3 {
  margin-top: 2em;
  margin-bottom: 0.5em;
  font-weight: 600;
  font-size: 1.05em;
  letter-spacing: 0.2px;
}

.nav-sublist {
  list-style: none;
  padding-left: 1em;
  margin: 0;
}

.nav-sublist li {
  margin: 0.4em 0;
}

.cat-hover-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4em;
  font-size: 1em;
}

/* Hide nav-toggle button on desktop */
.nav-toggle {
  display: none;
  font-size: 1.8em;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.3em;
}

/* Mobile nav */
@media screen and (max-width: 768px) {
  .sidebar {
    margin-bottom: 20px;
  }

  .nav-toggle {
    display: inline-block;
    margin-bottom: 1em;
  }

  nav#nav-menu {
    display: none;
    flex-direction: column;
    gap: 12px;
  }

  nav#nav-menu.show {
    display: flex;
  }
}

.center-content {
  text-align: center;
}

.center-content img {
  display: block;
  margin: 1.5em auto;
  max-width: 100%;
}

