:root {
  --red-rgb: 248 113 113;
  --blue-rgb: 56 189 248;
  --green-rgb: 74 222 128;
  --yellow-rgb: 253 224 71;
  --background-rgb: 0 0 0;
}

body {
  height: 100vh;
  width: 100vw;
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgb(var(--background-rgb));
  overflow: hidden;
  perspective: 2000px;
  position: fixed;
  font-family: 'Mako', sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

#container {
  width: min(140rem, 160vw);
  aspect-ratio: 1;
  display: grid;
  grid-template-rows: repeat(40, 1fr);
  grid-template-columns: repeat(40, 1fr);
  transform-origin: center center;
  transform: rotateX(35deg) rotateY(-5deg) rotateZ(20deg) scale(1.35);
  position: absolute;
}

@media (max-width: 768px) {
  #container {
    width: min(140rem, 200vw);
    transform: rotateX(35deg) rotateY(-5deg) rotateZ(20deg) scale(1.1);
  }
}

@media (max-width: 480px) {
  #container {
    width: min(140rem, 350vw);
    transform: rotateX(35deg) rotateY(-5deg) rotateZ(20deg) scale(0.9);
  }
}

#container:after,
#container:before {
  content: "";
  position: absolute;
  inset: 0px;
  pointer-events: none;
}

#container:before {
  z-index: 2;
  background-image: url("../img/plus-pattern-center.png");
  background-size: 5%;
  background-repeat: repeat;
  opacity: 0.25;
}

#container:after {
  z-index: 3;
  background: radial-gradient(circle, transparent 25%, rgb(var(--background-rgb)) 80%);
}

.tile {  
  border: 1px solid rgb(255 255 255 / 25%);
  transition: background-color 1500ms;
}

.tile:hover {
  transition-duration: 0ms;
}

.tile:nth-child(4n):hover {
  background-color: rgb(var(--red-rgb));
}

.tile:nth-child(4n + 1):hover {
  background-color: rgb(var(--blue-rgb));
}

.tile:nth-child(4n + 2):hover {
  background-color: rgb(var(--green-rgb));
}

.tile:nth-child(4n + 3):hover {
  background-color: rgb(var(--yellow-rgb));
}

.tile:nth-child(7n):hover {
  background-color: rgb(var(--blue-rgb));
}

.tile:nth-child(7n + 3):hover {
  background-color: rgb(var(--green-rgb));
}

.tile:nth-child(7n + 5):hover {
  background-color: rgb(var(--yellow-rgb));
}

.tile:nth-child(7n + 6):hover {
  background-color: rgb(var(--red-rgb));
}

.tile:nth-child(11n + 1):hover {
  background-color: rgb(var(--red-rgb));
}

.tile:nth-child(11n + 4):hover {
  background-color: rgb(var(--blue-rgb));
}

.tile:nth-child(11n + 7):hover {
  background-color: rgb(var(--green-rgb));
}

.tile:nth-child(11n + 10):hover {
  background-color: rgb(var(--yellow-rgb));
}

/* Profile Container Styles */
.profile-container {
  position: fixed;
  z-index: 10;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  height: 100%;
  pointer-events: none; /* Allows clicking through to background */
}

.profile-content {
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(10px);
  border-radius: 20px;
  padding: 3.5rem;
  max-width: min(80vw, 55%);
  width: 100%;
  color: white;
  pointer-events: auto; /* Re-enables clicking for the content */
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.profile-image {
  display: flex;
  justify-content: center;
  margin-bottom: 1.5rem;
}

.profile-image img {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.3);
  transition: opacity 0.5s ease-in-out;
}

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

@keyframes purpleShift {
  0% {
    background-position: 0% 50%;
    filter: hue-rotate(0deg);
  }
  50% {
    background-position: 100% 50%;
    filter: hue-rotate(30deg);
  }
  100% {
    background-position: 0% 50%;
    filter: hue-rotate(0deg);
  }
}

.profile-text h1 {
  position: relative;
  z-index: 1;
  font-size: 2.5rem;
  margin-bottom: 0.5rem;
  font-weight: 400;
  font-family: 'Rubik Glitch', system-ui;
  letter-spacing: 0.05em;
  background: linear-gradient(45deg, 
  #4a0070,     /* Deepest dark violet */
  #6a0dad,     /* Dark purple */
  #6a0dad,     /* Dark purple (repeated) */
  #8a2be2,     /* Blue-violet */
  #9633ff,     /* Vivid purple */
  #8e24ff,     /* Bright neon purple */
  #b847ff,     /* Intense neon violet */
  #ba55d3,     /* Medium orchid */
  #c92bff,     /* Bright neon magenta */
  #d946ef,     /* Vibrant magenta */
  #d946ef,     /* Hot magenta (repeated) */
  #da70d6,     /* Orchid */
  #e336ff,     /* Electric purple */
  #ff00ff,     /* Pure neon magenta */
  #ff00ff      /* Pure neon magenta (repeated) */
);
  background-size: 300% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: purpleShift 8s ease infinite;
  text-shadow: 
      0 0 10px rgba(255, 27, 107, 0.5),
      0 0 20px rgba(168, 85, 247, 0.3),
      0 0 30px rgba(236, 72, 153, 0.2);
}

.profile-text h1::after {
  content: attr(data-text);
  position: absolute;
  top: 0;
  left: 0;
  z-index: -1;
  width: 100%;
  height: 100%;
  font-family: inherit;
  font-size: inherit;
  font-weight: inherit;
  letter-spacing: inherit;
  line-height: inherit;
  text-align: center;
  filter: blur(8px);
  opacity: 0.7;
}

.profile-text .title {
  color: rgba(255, 255, 255, 0.8);
  font-size: 1.1rem;
  margin-bottom: 1rem;
  font-family: 'Electrolize', sans-serif;
}

.profile-text .bio {
  color: rgba(255, 255, 255, 0.75);
  line-height: 1.8;
  font-size: 0.95rem;
  font-family: 'Electrolize', sans-serif;
  letter-spacing: 0.02em;
  padding: 0.2em;
}

.profile-text .quote {
  color: rgba(255, 255, 255, 0.616);
  font-size: 1.2rem;
  padding: 1em;
  font-family: 'Smooch Sans', sans-serif;
}

/* Responsive adjustments for profile container */
@media (max-width: 768px) {
  .profile-content {
    padding: 1rem;
    max-width: min(80vw, 80%);
  }

  .profile-image-placeholder {
    width: 120px;
    height: 120px;
  }

  .profile-text h1 {
    font-size: 1.75rem;
  }
}

@media (max-width: 480px) {
  .profile-content {
    padding: 0.8rem;
    max-width: min(80vw, 80%);
  }

  .profile-image-placeholder {
    width: 100px;
    height: 100px;
  }

  .profile-text h1 {
    font-size: 1.5rem;
  }

  .profile-text .title {
    font-size: 1rem;
  }

  .profile-text .bio {
    font-size: 0.9rem;
  }
}

/* Links section */

/* Container styling */
#links {
  display: flex;
  flex-direction: column;
  align-items: center;
}

#links .label {
  display: block;
  font-size: 1.4rem;
  margin-bottom: 5px; /* Additional spacing if needed */
  padding: 0.5em 0em 0em 0em;
  font-family: 'Rubik Glitch', sans-serif;
}

.meta-link {
  display: flex;
  align-items: center;
  gap: 10px; /* Space between links */
}

/* Dot separator styling */
.dot {
  color: #666;
  margin: 0 8px;
  font-weight: bold;
}

/* General link styling */
.meta-link a {
  text-decoration: none;
  /* padding: 6px 5px; */
  border-radius: 50%;
  transition: all 0.3s ease;
}

.meta-link a i {
  font-size: 18px;
}

/* Specific social media colors and hover effects */
.github {
  color: #333;
}

.github:hover {
  color: #000;
  background: #f0f0f0;
}

.youtube {
  color: #FF0000;
}

.youtube:hover {
  color: #fff;
  background: #FF0000;
}

.bluesky {
  color: #1DA1F2;
}

.bluesky:hover {
  color: #fff;
  background: #1DA1F2;
}

.linkedin {
  color: #0077B5;
}

.linkedin:hover {
  color: #fff;
  background: #0077B5;
}

/* Hover animation for all links */
.meta-link a:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* Optional: Add a subtle animation when clicking */
.meta-link a:active {
  transform: translateY(0);
}

/* Updated link styling with gradient glow */
.meta-link {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 8px;
  padding: 10px;
  backdrop-filter: blur(5px);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.meta-link a {
  text-decoration: none;
  /* padding: 8px 12px; */
  border-radius: 50%;
  transition: all 0.3s ease;
  position: relative;
}

.meta-link a i {
  font-size: 20px;
  background: linear-gradient(45deg, 
    #4a0070,
    #6a0dad,
    #8a2be2,
    #9633ff,
    #8e24ff,
    #b847ff,
    #ba55d3,
    #c92bff,
    #d946ef,
    #da70d6,
    #e336ff,
    #ff00ff
  );
  background-size: 300% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: purpleShift 8s ease infinite;
}

/* Remove previous color-specific styles */
.github, .youtube, .bluesky, .linkedin {
  color: inherit;
}

/* Updated hover effects */
.meta-link a:hover {
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 0.1);
}

.meta-link a:hover i {
  filter: drop-shadow(0 0 8px rgba(168, 85, 247, 0.5))
         drop-shadow(0 0 12px rgba(236, 72, 153, 0.3));
}

/* Dot separator update */
.dot {
  color: rgba(255, 255, 255, 0.4);
  margin: 0 8px;
  font-weight: bold;
}

/* Keep the click animation */
.meta-link a:active {
  transform: translateY(0);
}