body {
  background-color: #111;
  color: #fafafa;
  font-family: "Lexend", sans-serif;
  margin: 0;
  padding: 0;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: repeating-linear-gradient(
    120deg,
    #181818 0 2px,
    #23234a 2px 4px,
    #181818 4px 8px
  );
  opacity: 0.18;
  transition: filter 0.2s;
  animation: bg-glitch-idle 1s infinite linear;
}

@keyframes bg-glitch-idle {
  0%, 100% { filter: none; }
  10% { filter: blur(0.2px) brightness(1.03); }
  20% { filter: hue-rotate(3deg); }
  30% { filter: blur(0.3px) brightness(0.98); }
  40% { filter: hue-rotate(-3deg); }
  50% { filter: none; }
  60% { filter: blur(0.2px) brightness(1.01); }
  70% { filter: hue-rotate(2deg); }
  80% { filter: blur(0.1px) brightness(1.02); }
  90% { filter: none; }
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 12px;
  background: #181818;
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(120deg, #23234a 60%, #181818 100%);
  border-radius: 8px;
  border: 2px solid #111;
  box-shadow: 1px 1px 0 #7a5cff;
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(120deg, #3a3a6a 60%, #23234a 100%);
  box-shadow: 0 0 6px #7a5cff;
}

::-webkit-scrollbar-corner {
  background: #181818;
}

/* Firefox */
* {
  scrollbar-width: thin;
  scrollbar-color: #7a5cff #181818;
}

.glitch-title {

  transition: all 0.5s;
  filter: none;
}

.glitch-title:hover {
  animation: glitch-pixelate 1s steps(2, end) infinite;
  filter: contrast(170%) blur(0.2px);
}

@keyframes glitch-pixelate {
  0% {
    text-shadow:
      1px 0 #ff00c8,
      -1px 0 #00fff9,
      0 1px #fff,
      0 -1px #fff;
    transform: translate(0, 0);
  }
  20% {
    text-shadow:
      1.5px 0 #ff00c8,
      -1.5px 0 #00fff9,
      0 1px #fff,
      0 -1px #fff;
    transform: translate(-0.5px, 0.5px);
  }
  40% {
    text-shadow:
      1px 1px #ff00c8,
      -1px -1px #00fff9,
      0 1px #fff,
      0 -1px #fff;
    transform: translate(0.5px, -0.5px);
  }
  60% {
    text-shadow:
      1.5px -1px #ff00c8,
      -1.5px 1px #00fff9,
      0 1px #fff,
      0 -1px #fff;
    transform: translate(-1px, 1px);
  }
  80% {
    text-shadow:
      1px 0 #ff00c8,
      -1px 0 #00fff9,
      0 1px #fff,
      0 -1px #fff;
    transform: translate(1px, 0);
  }
  100% {
    text-shadow:
      1px 0 #ff00c8,
      -1px 0 #00fff9,
      0 1px #fff,
      0 -1px #fff;
    transform: translate(0, 0);
  }
}

a {
  color: #fafafa;
  text-decoration: none;
}

a:hover {
  text-decoration: none;
}

.pixelify {
  font-family: "Pixelify Sans", sans-serif;
}

.container {
  max-width: 800px;
  margin: auto;
  padding: 2rem;
}

.centered-text {
  text-align: center;
}

.offset-text {
  /* position: relative; */
  /* bottom: -10px;
  left: -5px; */
  opacity: 0.8;
}

.section-title {
  font-size: 2rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
  padding-bottom: 0.5rem;
  margin-top: 2rem;
  margin-bottom: 1rem;
}

.skills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.5rem;
  list-style: none;
  padding: 0;
  font-weight: 500;
}

.skills li {
  background-color: #252525;
  padding: 0.5rem 1rem;
  border-radius: 8px;
  border: 1px solid #fafafa;
  box-shadow: 2px 2px #fafafa;
  font-family: "Pixelify Sans", sans-serif;
  text-transform: uppercase;
  font-size: 0.9rem;
  transition: all 0.1s;
}

.skills li:active {
  box-shadow: none;
  transform: translate(3px, 3px);
}
.project-section {
  margin-top: 2rem;
}

.project-row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  margin-bottom: 1rem;
  gap: 1rem;
}

.project-info {
  flex: 1;
  min-width: 200px;
  margin-top: 1rem;
}

.button {
  display: inline-block;
  background: linear-gradient(90deg, #181818 60%, #23234a 100%);
  color: #fafafa;
  padding: 0.55rem 1.2rem;
  border: 1.5px solid #7a5cff;
  border-radius: 8px;
  box-shadow:
    0 0 0 2px #3a3a6a inset,
    2px 2px 0 #7a5cff;
  font-family: "Pixelify Sans", sans-serif;
  text-transform: uppercase;
  font-size: 1rem;
  letter-spacing: 0.05em;
  position: relative;
  overflow: hidden;
  transition: 
    background 0.2s,
    box-shadow 0.15s,
    border-color 0.15s,
    color 0.15s;
}

.button::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  pointer-events: none;
  background: repeating-linear-gradient(
    135deg,
    transparent 0 2px,
    #7a5cff 2px 4px,
    transparent 4px 8px
  );
  opacity: 0.08;
  z-index: 1;
}

.button:hover, .button:focus {
  background: linear-gradient(90deg, #23234a 60%, #3a3a6a 100%);
  color: #fff;
  border-color: #aab6ff;
  box-shadow:
    0 0 6px #7a5cff,
    2px 2px 0 #aab6ff;
  animation: none;
  outline: none;
}

.button:active {
  transform: translate(1px, 1px);
  box-shadow: none;
  border-color: #7a5cff;
}

/* Tablet display reuse */
.tablet {
  padding: 4% 0 4% 6%;
  width: 100%;
  max-width: 360px;
  margin: auto;
}

.screen {
  background: #000;
  border-radius: 3% / 5%;
  position: relative;
  width: 100%;
}

.screen:before {
  content: "";
  display: block;
  padding-top: 67%;
  border: 2px solid #cacacc;
  border-radius: 3% / 5%;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.8) inset,
              0 0 1px 2px rgba(255, 255, 255, 0.3) inset;
}

.viewport {
  position: absolute;
  top: 4.3%;
  left: 3.2%;
  right: 3.2%;
  bottom: 4.3%;
  background-color: #333;
  background-size: 100% auto;
  background-repeat: no-repeat;
  background-position: top;
  transition: background-position 3s ease;
  cursor: pointer;
}

.tablet:hover .viewport {
  background-position: bottom;
}

/* Footer */
footer {
  margin-top: 3rem;
  font-size: 0.9rem;
  opacity: 0.7;
}
