@font-face {
  font-family: 'Satoshi';
  src: url('/fonts/Satoshi/Satoshi.woff2') format('woff2'),
       url('/fonts/Satoshi/Satoshi.woff') format('woff'),
       url('/fonts/Satoshi/Satoshi.ttf') format('truetype');
  font-weight: 300 900;
  font-display: swap;
  font-style: normal;
}

body, html {
  height: 100%;
  margin: 0;
  padding: 0;
  font-family: 'Satoshi', Arial, sans-serif;
  background: #181818;
  overflow: hidden;
}

/* Animated gradient fallback for when canvas/particles are not available */
#background {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  width: 100vw; height: 100vh;
  z-index: 0;
  background: linear-gradient(90deg,rgba(2, 0, 36, 1) 0%, rgba(9, 9, 121, 1) 35%, rgba(0, 212, 255, 1) 100%);
  background-size: 400% 400%;
  animation: gradientBG 18s ease-in-out infinite alternate;
}
@keyframes gradientBG {
  0% {background-position: 0% 50%;}
  50% {background-position: 100% 50%;}
  100% {background-position: 0% 50%;}
}

.center-container {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
}

.glass-card {
  background: 
    linear-gradient(180deg, rgba(255,255,255,0.38) 0%, rgba(255,255,255,0.17) 100%),
    rgba(30,30,30,0.22);
  box-shadow: 0 8px 32px 0 rgba(10,10,10,0.21), 0 0 60px 10px rgba(255,255,255,0.12);
  backdrop-filter: blur(10px) brightness(1.07);
  -webkit-backdrop-filter: blur(10px) brightness(1.07);
  border-radius: 20px;
  padding: 2.5rem 3rem 2rem 3rem;
  min-width: 350px;
  max-width: 94vw;
  text-align: center;
  position: relative;
  border: 2px solid rgba(255,255,255,0.09);
  opacity: 0;
  transform: translateY(40px) scale(0.97);
  animation: card-fadein 1.1s cubic-bezier(.46,.03,.52,.96) 0.15s forwards;
}
@keyframes card-fadein {
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.profile-pic-top {
  display: block;
  margin: 0 auto 1.05rem auto;
  width: 88px;
  height: 88px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid #fff;
  box-shadow: 0 0 22px 0 #fff8, 0 0 30px 4px #5ee2fa66;
  background: #222;
}

/* Animated username typewriter */
.username-typewriter {
  position: relative;
  display: inline-flex;
  align-items: center;
  font-size: 2.4rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: 0.06em;
  font-family: 'Satoshi', Arial, sans-serif;
  margin: 0 auto 1rem auto;
  line-height: 1;
  z-index: 1;
  /* Animated multi-colour neon glow */
  text-shadow:
    0 0 18px #00eaff,
    0 0 36px #ff00cc,
    0 1px 2px #000,
    0 0 6px #fff8;
  animation: neon-glow 2.5s linear infinite alternate;
}

@keyframes neon-glow {
  0% {
    text-shadow:
      0 0 18px #00eaff,
      0 0 36px #ff00cc,
      0 1px 2px #000,
      0 0 6px #fff8;
  }
  25% {
    text-shadow:
      0 0 18px #39ff14,
      0 0 36px #ffe600,
      0 1px 2px #000,
      0 0 6px #fff8;
  }
  50% {
    text-shadow:
      0 0 18px #ff00cc,
      0 0 36px #00ffc0,
      0 1px 2px #000,
      0 0 6px #fff8;
  }
  75% {
    text-shadow:
      0 0 18px #ffe600,
      0 0 36px #00eaff,
      0 1px 2px #000,
      0 0 6px #fff8;
  }
  100% {
    text-shadow:
      0 0 18px #00eaff,
      0 0 36px #ff00cc,
      0 1px 2px #000,
      0 0 6px #fff8;
  }
}

/* Each letter can inherit parent glow or be overridden for even more effect if desired */
.letter-glow {
  display: inline-block;
  margin: 0 0.02em;
  /* Inherit the parent neon glow animation for unified effect */
}

.typewriter-cursor {
  display: inline-block;
  width: 0.13em;
  margin-left: 0.08em;
  height: 1.1em;
  background: #fff;
  border-radius: 2px;
  animation: blink-cursor 0.8s steps(1) infinite, neon-glow 2.5s linear infinite alternate;
  line-height: 1;
  box-shadow: 0 0 8px #fff, 0 0 8px #00eaff;
}
@keyframes blink-cursor {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

/* Description: fixed width, automatic height */
.desc {
  width: 380px;          /* Fixed length/width */
  min-height: 32px;      /* Minimum height for a single line */
  margin: 0.7rem auto 1.4rem auto;
  font-size: 1.18rem;
  color: #fff;
  text-align: center;
  font-family: 'Satoshi', Arial, sans-serif;
  box-shadow: none;
  background: none;
  border-radius: 0;
  line-height: 1.3;
  font-weight: 500;
  text-shadow: 0 2px 24px #2d3844b0, 0 1px 2px #000, 0 0 6px #fff8;
  /* Let height grow, keep width fixed */
  overflow-x: hidden;
  overflow-y: visible;
  word-break: break-word;
}

/* Discord widget */
.discord-embed {
  display: flex;
  justify-content: center;
  margin: 0 auto 1.3rem auto;
  border-radius: 15px;
  box-shadow: none;
  padding: 0;
  width: 100%;
  max-width: 340px;
}
.discord-embed iframe {
  border-radius: 15px;
  width: 100%;
  height: 192px;
  max-width: 340px;
  border: none;
  display: block;
}

/* Discord button for mobile - hidden by default */
.discord-button-mobile {
  display: none;
  justify-content: center;
  margin: 0 auto 1.3rem auto;
}

/* Discord button styling - similar to email but with different gradient */
.discord-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  background: linear-gradient(90deg, #5865f2 0%, #8b5cf6 100%);
  font-weight: 700;
  font-size: 1.22rem;
  padding: 0.55rem 2.2rem 0.55rem 1.1rem;
  border-radius: 100px;
  text-decoration: none;
  box-shadow: 0 0 32px 7px #5865f233, 0 0 32px 2px #8b5cf644;
  transition: transform 0.14s, box-shadow 0.18s, color 0.18s, background 0.18s;
  position: relative;
  min-width: 280px;
  min-height: 44px;
  gap: 0.7em;
  /* Improve touch feedback */
  -webkit-tap-highlight-color: rgba(255,255,255,0.2);
  cursor: pointer;
}
.discord-link:hover, .discord-link:focus {
  color: #fff;
  background: linear-gradient(90deg, #4752c4 0%, #7c3aed 100%);
  box-shadow: 0 0 36px 10px #8b5cf655, 0 0 18px 4px #5865f288;
  transform: translateY(-2px);
}
.discord-link:active {
  transform: translateY(0);
}
/* Touch device specific enhancements */
@media (hover: none) and (pointer: coarse) {
  .discord-link:hover {
    background: linear-gradient(90deg, #5865f2 0%, #8b5cf6 100%);
    box-shadow: 0 0 32px 7px #5865f233, 0 0 32px 2px #8b5cf644;
    transform: none;
  }
  .discord-link:active {
    background: linear-gradient(90deg, #4752c4 0%, #7c3aed 100%);
    box-shadow: 0 0 36px 10px #8b5cf655, 0 0 18px 4px #5865f288;
    transform: scale(0.98);
  }
}
.discord-icon {
  font-size: 1.2em;
  margin-right: 0.55em;
  display: flex;
  align-items: center;
  justify-content: center;
}
.discord-icon svg {
  width: 24px;
  height: 24px;
  fill: currentColor;
}
.discord-username {
  font-family: 'Satoshi', Arial, sans-serif;
  font-weight: 900;
}

.social-row {
  display: flex;
  justify-content: center;
  gap: 2.2rem;
  margin: 1.2rem 0 0 0;
}

.icon-btn {
  background: rgba(255,255,255,0.22);
  border-radius: 12px;
  padding: 0.7rem;
  box-shadow: 0 2px 8px #2226;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s, transform 0.14s, box-shadow 0.18s;
  border: none;
  outline: none;
  /* Ensure minimum touch target size */
  min-width: 44px;
  min-height: 44px;
  /* Improve touch feedback */
  -webkit-tap-highlight-color: rgba(94,226,250,0.3);
  /* Improve accessibility */
  text-decoration: none;
  cursor: pointer;
}
.icon-btn svg {
  width: 36px;
  height: 36px;
  display: block;
  filter: drop-shadow(#ffffff 1px 0 7px) !important;
  color: #fff !important;
  transition: filter 0.18s, color 0.18s;
  /* Improve rendering on high DPI displays */
  shape-rendering: geometricPrecision;
}
.icon-btn:hover, .icon-btn:focus {
  background: rgba(94,226,250,0.20);
  transform: scale(1.12) rotate(-2deg);
  box-shadow: 0 0 18px #5ee2fa, 0 0 4px #fff7;
}
.icon-btn:hover svg, .icon-btn:focus svg {
  filter: drop-shadow(0 0 14px #5ee2fa) brightness(1.2);
  color: #5ee2fa !important;
}
.icon-btn:active {
  transform: scale(1.05);
}
/* Touch device specific enhancements */
@media (hover: none) and (pointer: coarse) {
  .icon-btn:hover {
    background: rgba(255,255,255,0.22);
    transform: none;
    box-shadow: 0 2px 8px #2226;
  }
  .icon-btn:hover svg {
    filter: drop-shadow(#ffffff 1px 0 7px) !important;
    color: #fff !important;
  }
  .icon-btn:active {
    background: rgba(94,226,250,0.20);
    transform: scale(1.05);
    box-shadow: 0 0 18px #5ee2fa, 0 0 4px #fff7;
  }
  .icon-btn:active svg {
    filter: drop-shadow(0 0 14px #5ee2fa) brightness(1.2);
    color: #5ee2fa !important;
  }
}

/* Contact Links section */
.contact-links {
  margin-top: 1.3rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.7rem;
}

/* Email button - Talent Hub-like blue-pink gradient style */
.email-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  background: linear-gradient(90deg, #14e0ff 0%, #be2fff 100%);
  font-weight: 700;
  font-size: 1.22rem;
  padding: 0.55rem 2.2rem 0.55rem 1.1rem;
  border-radius: 100px;
  text-decoration: none;
  box-shadow: 0 0 32px 7px #14e0ff33, 0 0 32px 2px #be2fff44;
  transition: transform 0.14s, box-shadow 0.18s, color 0.18s, background 0.18s;
  position: relative;
  min-width: 340px;
  min-height: 44px;
  gap: 0.7em;
  /* Improve touch feedback */
  -webkit-tap-highlight-color: rgba(255,255,255,0.2);
  cursor: pointer;
}
.email-link:hover, .email-link:focus {
  color: #fff;
  background: linear-gradient(90deg, #0aefff 0%, #ff00cc 100%);
  box-shadow: 0 0 36px 10px #ff00cc55, 0 0 18px 4px #14e0ff88;
  transform: translateY(-2px);
}
.email-link:active {
  transform: translateY(0);
}
/* Touch device specific enhancements */
@media (hover: none) and (pointer: coarse) {
  .email-link:hover {
    background: linear-gradient(90deg, #14e0ff 0%, #be2fff 100%);
    box-shadow: 0 0 32px 7px #14e0ff33, 0 0 32px 2px #be2fff44;
    transform: none;
  }
  .email-link:active {
    background: linear-gradient(90deg, #0aefff 0%, #ff00cc 100%);
    box-shadow: 0 0 36px 10px #ff00cc55, 0 0 18px 4px #14e0ff88;
    transform: scale(0.98);
  }
}
.email-icon {
  font-size: 1.36em;
  margin-right: 0.55em;
}
.contact-email {
  font-family: 'Satoshi', Arial, sans-serif;
  font-weight: 900;
}

/* Responsive adjustments */

/* Large screens and desktops */
@media (min-width: 1200px) {
  .glass-card {
    min-width: 420px;
    max-width: 500px;
    padding: 3rem 3.5rem 2.5rem 3.5rem;
  }
  
  .username-typewriter {
    font-size: 2.6rem;
  }
  
  .desc {
    width: 420px;
    font-size: 1.2rem;
  }
  
  .discord-embed {
    max-width: 380px;
  }
  
  .discord-embed iframe {
    height: 210px;
  }
  
  .social-row {
    gap: 2.5rem;
  }
}

/* Tablets and medium screens */
@media (max-width: 1024px) and (min-width: 768px) {
  .glass-card {
    min-width: 380px;
    max-width: 450px;
    padding: 2.2rem 2.5rem 2rem 2.5rem;
  }
  
  .username-typewriter {
    font-size: 2.2rem;
  }
  
  .desc {
    width: 350px;
    font-size: 1.1rem;
  }
  
  .discord-embed {
    max-width: 320px;
  }
  
  .discord-embed iframe {
    height: 180px;
  }
  
  .social-row {
    gap: 2rem;
  }
  
  .icon-btn {
    padding: 0.8rem;
  }
  
  .icon-btn svg {
    width: 38px;
    height: 38px;
  }
  
  .email-link {
    font-size: 1.15rem;
    padding: 0.6rem 2rem 0.6rem 1.2rem;
    min-width: 320px;
  }
}

/* Small tablets and large phones */
@media (max-width: 767px) and (min-width: 481px) {
  .glass-card {
    padding: 1.8rem 1.5rem 1.8rem 1.5rem;
    min-width: 85vw;
    max-width: 90vw;
  }
  
  .profile-pic-top {
    width: 72px;
    height: 72px;
  }
  
  .username-typewriter {
    font-size: 1.8rem;
  }
  
  .desc {
    width: 85vw;
    font-size: 1.05rem;
  }
  
  /* Hide Discord embed and show Discord button on mobile */
  .discord-embed {
    display: none;
  }
  
  .discord-button-mobile {
    display: flex;
  }
  
  .discord-link {
    font-size: 1.08rem;
    padding: 0.65rem 1.5rem 0.65rem 1rem;
    min-width: 260px;
    /* Ensure minimum touch target size */
    min-height: 44px;
  }
  
  .social-row {
    gap: 1.8rem;
  }
  
  .icon-btn {
    padding: 0.75rem;
    /* Ensure minimum touch target size */
    min-width: 44px;
    min-height: 44px;
  }
  
  .email-link {
    font-size: 1.08rem;
    padding: 0.65rem 1.5rem 0.65rem 1rem;
    min-width: 280px;
    /* Ensure minimum touch target size */
    min-height: 44px;
  }
}

/* Mobile phones */
@media (max-width: 480px) {
  .glass-card {
    padding: 1.5rem 1rem 1.5rem 1rem;
    min-width: 92vw;
    max-width: 95vw;
  }
  
  .profile-pic-top {
    width: 64px;
    height: 64px;
  }
  
  .username-typewriter {
    font-size: 1.6rem;
  }
  
  .desc {
    width: 90vw;
    font-size: 1rem;
    line-height: 1.4;
  }
  
  /* Hide Discord embed and show Discord button on mobile */
  .discord-embed {
    display: none;
  }
  
  .discord-button-mobile {
    display: flex;
    margin: 0 auto 1.5rem auto;
  }
  
  .discord-link {
    font-size: 1.02rem;
    padding: 0.7rem 1rem 0.7rem 0.8rem;
    min-width: 0;
    width: 90vw;
    max-width: 95vw;
    /* Ensure minimum touch target size for mobile */
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
  }
  
  .discord-icon {
    font-size: 1.2em;
    margin-right: 0.4em;
  }
  
  .discord-username {
    font-size: 0.95em;
  }
  
  .social-row {
    gap: 1.5rem;
    flex-wrap: wrap;
    justify-content: center;
  }
  
  .icon-btn {
    padding: 0.7rem;
    /* Ensure minimum touch target size for mobile */
    min-width: 44px;
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
  }
  
  .icon-btn svg {
    width: 32px;
    height: 32px;
  }
  
  .email-link {
    font-size: 1.02rem;
    padding: 0.7rem 1rem 0.7rem 0.8rem;
    min-width: 0;
    width: 90vw;
    max-width: 95vw;
    /* Ensure minimum touch target size for mobile */
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
  }
  
  .email-icon {
    font-size: 1.2em;
    margin-right: 0.4em;
  }
  
  .contact-email {
    font-size: 0.95em;
  }
}

/* Very small screens */
@media (max-width: 360px) {
  .glass-card {
    padding: 1.2rem 0.8rem 1.2rem 0.8rem;
    min-width: 95vw;
  }
  
  .username-typewriter {
    font-size: 1.4rem;
  }
  
  .desc {
    font-size: 0.95rem;
  }
  
  /* Discord button for very small screens */
  .discord-link {
    font-size: 0.95rem;
    padding: 0.6rem 0.8rem 0.6rem 0.6rem;
  }
  
  .discord-username {
    font-size: 0.9em;
  }
  
  .social-row {
    gap: 1.2rem;
  }
  
  .icon-btn svg {
    width: 28px;
    height: 28px;
  }
  
  .email-link {
    font-size: 0.95rem;
    padding: 0.6rem 0.8rem 0.6rem 0.6rem;
  }
  
  .contact-email {
    font-size: 0.9em;
  }
}

/* Landscape orientation on mobile devices */
@media (max-height: 500px) and (orientation: landscape) {
  body, html {
    overflow-y: auto;
  }
  
  .center-container {
    position: absolute;
    padding: 2rem 0;
    align-items: flex-start;
    justify-content: center;
    min-height: 100vh;
  }
  
  .glass-card {
    margin: 1rem auto;
    padding: 1.5rem 2rem 1.5rem 2rem;
    min-width: 80vw;
    max-width: 85vw;
  }
  
  .profile-pic-top {
    width: 60px;
    height: 60px;
  }
  
  .username-typewriter {
    font-size: 1.8rem;
    margin-bottom: 0.8rem;
  }
  
  .desc {
    font-size: 1rem;
    margin: 0.5rem auto 1rem auto;
  }
  
  /* Hide Discord embed and show Discord button on landscape mobile */
  .discord-embed {
    display: none;
  }
  
  .discord-button-mobile {
    display: flex;
    margin: 0 auto 1rem auto;
  }
  
  .discord-link {
    font-size: 1rem;
    padding: 0.6rem 1.5rem 0.6rem 1rem;
    min-width: 230px;
  }
  
  .social-row {
    gap: 1.5rem;
    margin: 1rem 0;
  }
  
  .email-link {
    font-size: 1rem;
    padding: 0.6rem 1.5rem 0.6rem 1rem;
    min-width: 250px;
  }
}

/* High DPI/Retina displays */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
  .profile-pic-top {
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
  }
  
  .icon-btn svg {
    shape-rendering: geometricPrecision;
  }
}