
@import url('https://unpkg.com/normalize.css') layer(normalize);

@layer normalize, base, demo;

@layer demo {
  :root {
    --accent: hsl(10 20% 30%);
    --island-margin: 20px;
    --island-height: 40px;
    --island-width: 200px;
    --avatar-size: calc(var(--island-width) * 0.65);
    --avatar-position: calc(var(--island-height) + (var(--island-margin) * 1.25));
    --header-margin: 0.5rem;
    --header-height: calc(var(--island-margin) + var(--avatar-position) + var(--avatar-size) + 1lh + var(--header-margin));
    --header-font: 3rem;
  }

  .loading-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #000000;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10000;
    transition: opacity 0.5s ease;
  }

  .hello__div {
    display: flex;
    justify-content: center;
    flex-direction: column;
    text-align: center;
    width: 100%;
    max-width: 300px;
    padding: 0 20px;
  }

  .hello__svg {
    fill: none;
    stroke: #ffffff;
    stroke-linecap: round;
    stroke-miterlimit: 10;
    stroke-width: 40px;
    stroke-dasharray: 5800px;
    stroke-dashoffset: 5800px;
    animation: anim__hello linear 4s forwards;
    width: 100%;
    height: auto;
    max-height: 300px;
    margin: 0 auto;
  }

  @keyframes anim__hello {
    0% { stroke-dashoffset: 5800; }
    100% { stroke-dashoffset: 0; }
  }

  header {
    position: sticky;
    background-color: transparent;
    top: calc(var(--header-height) * -0.65);
    height: var(--header-height);
    width: 100%;
    font-size: var(--header-font);
    animation: block both linear;
    animation-timeline: scroll(root);
    transform-origin: 50% 0;
    animation-range: 0 calc(var(--header-height) * 0.65);
    z-index: 2;
  }

  @keyframes block {
    to {
      background: transparent;
      box-shadow: none;
      backdrop-filter: none;
    }
  }

  .island__container {
    width: var(--island-width);
    height: var(--island-height);
    border-radius: var(--island-height);
    position: fixed;
    top: 20px;
    left: 50%;
    translate: -50% -0%;
    background: black;
  }

  .island__bar {
    width: var(--island-width);
    height: var(--island-height);
    border-radius: var(--island-height);
    background: black;
    position: absolute;
    top: 0%;
    left: 50%;
    translate: -50% 0%;
  }

  .island {
    filter: url(#fancy-goo);
    cursor: pointer;
  }

  .red-circle {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%) scale(1);
    width: 15px;
    height: 15px;
    background-color: rgb(255, 0, 0);
    border-radius: 50%;
    z-index: 3;
    opacity: 1;
    transition: opacity 0.5s ease-out, transform 0.5s ease-out;
  }

  .island-icon {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%) scale(0.5);
    height: 80%;
    width: auto;
    z-index: 2;
    opacity: 0;
    transition: opacity 0.5s ease-out, transform 0.5s ease-out;
  }

  .show-airpods .red-circle {
    opacity: 0;
    transform: translateY(-50%) scale(0.5);
    z-index: 1;
  }

  .show-airpods #airpods-icon {
    opacity: 1;
    transform: translateY(-50%) scale(1);
    z-index: 3;
  }

  .music-wave {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    align-items: center;
    height: 18px;
  }

  .music-wave span {
    display: block;
    width: 3px;
    height: 100%;
    margin: 0 2px;
    background: linear-gradient(to bottom, #00BFFF, #ffffff);
    border-radius: 3px;
    animation-name: iphone-wave-animation;
    animation-timing-function: linear;
    animation-iteration-count: infinite;
  }

  .music-wave span:nth-child(1) { animation-duration: 1.5s; animation-delay: -0.2s; }
  .music-wave span:nth-child(2) { animation-duration: 2s; animation-delay: -0.4s; }
  .music-wave span:nth-child(3) { animation-duration: 1.5s; animation-delay: -0.6s; }
  .music-wave span:nth-child(4) { animation-duration: 1.8s; animation-delay: -0.1s; }

  @keyframes iphone-wave-animation {
    0% { transform: scaleY(0.1); }
    30% { transform: scaleY(1.0); }
    60% { transform: scaleY(0.3); }
    80% { transform: scaleY(0.7); }
    100% { transform: scaleY(0.1); }
  }

  .avatar {
    width: var(--avatar-size);
    aspect-ratio: 1;
    border-radius: 50%;
    background: black;
    position: fixed;
    left: 50%;
    top: var(--avatar-position);
    translate: -50% 0;
    overflow: hidden;
    animation: shrink both linear;
    animation-timeline: scroll(root);
    animation-range: 0 calc(var(--header-height) * 0.65);
    transform-origin: 50% 0;
  }

  .avatar img {
    width: 100%;
    height: 100%;
    cursor: none;
    border-radius: 50%;
    object-fit: cover;
    animation: fade both linear;
    animation-timeline: scroll(root);
    animation-range: 0 calc(var(--header-height) * 0.425);
  }

  body {
    background-image: url('img/bgimage.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
  }

  main {
    min-height: 90vh;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    flex-direction: column;
    padding-top: 20vh; 
  }

  .header-logo-img {
    width: 200px;
    height: auto;
    margin: 1.5rem auto 0 auto;
    position: absolute;
    top: calc(var(--header-height) + var(--header-margin));
    left: 50%;
    translate: -50% -100%;
    transform-origin: 50% 0;
  }

  @keyframes shrink {
    to {
      translate: -50% calc(var(--avatar-position) * -1);
      scale: 0.3;
    }
  }

  @keyframes fade {
    to {
      filter: blur(10px);
      opacity: 0;
    }
  }

.scroll-down {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 25px;
  transition: opacity 0.5s ease, visibility 0.5s;
  color: rgb(171, 171, 171);
  font-size: 0.9rem;
  letter-spacing: 2px;
  text-transform: uppercase;
}

.arrow {
  width: 2px;
  height: 20px;
  position: relative;
  animation: bounce 2s infinite;
}

.arrow::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 5px solid #6edbff;
}

@keyframes bounce {
  0%, 20%, 50%, 80%, 100% {transform: translateY(0);}
  40% {transform: translateY(10px);}
  60% {transform: translateY(5px);}
}

.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(-10px);
} 

  ul {
    list-style-type: none;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    padding: 0;
    margin: 0;
    width: 50ch;
    max-width: calc(100vw - 2rem);
  }

  li {
    width: 100%;
  }

  li :is(a) {
    width: 100%;
    height: 50px;
    text-decoration: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 1rem;
    border-radius: 6px;
    padding-inline: 1rem;
    position: relative;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  }

  li :is(a):is(:focus-visible, :hover) {
    --intent: 1;
    animation-play-state: paused;
  }

  li :is(a)::after {
    content: '';
    position: absolute;
    inset: 0;
    opacity: var(--intent, 0);
    transition: opacity 0.2s;
    pointer-events: none;
  }
}

li a {
  color: #ffffff;
  background-color: #000000;
  display: flex;
  align-items: center;
  justify-content: center;
}

@layer base {
  *, *:after, *:before {
    box-sizing: border-box;
  }

  body {
    display: grid;
    place-items: center;
    min-height: 100vh;
    font-family: 'SF Pro Text', 'SF Pro Icons', 'AOS Icons', 'Helvetica Neue', Helvetica, Arial, sans-serif, system-ui;
  }

  .sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
  }
}

.island__bar {
  position: relative;
}

footer {
    background: transparent !important;
    box-shadow: none !important;
    display: flex;
    margin: 20px 0;
    justify-content: center; 
    font-family: monospace;
    font-size: 0.85rem;
    color: rgb(152, 152, 152);
    letter-spacing: 1px;   
}

.highlight-name {
    color: #6edbff;
}

@media (max-width: 600px) {
  .typing-text {
    font-size: 0.7rem;
  }
}



