#desktop-nav {
    position: relative;
}


p {
    color: rgb(85, 85, 85);
    line-height: 1.6;
    margin-bottom: 0rem;
    font-size: clamp(0.85rem, 1.3vw, 0.95rem);

}

h1 {
    color: rgb(41, 41, 41);
    line-height: 1.5;
    margin-bottom: 0rem;
    text-decoration: underline;
    text-decoration-color: red;
    text-underline-offset: 5px;
    font-size: clamp(1.8rem, 4vw, 2.3rem);
    margin-top: 1.5rem;
      -webkit-text-stroke: 1px rgba(21, 21, 21, 0.7);


}

.about-me {
    margin-top: 1rem;
    margin-bottom: 1rem;
    font-weight: 600;
    color: rgb(70, 70, 70);
}


/* Transition */
.typewriter-wrapper{
    display: flex;
    justify-content: center;
}

.typewriter{
    display: inline-block;
    white-space: nowrap;
    position: relative;
}

.typewriter::after{
    content:"";
    display:inline-block;
    height:1.3em;
    margin-left:2px;
    border-right: 2px solid black;
    animation: blink 1s ease-in-out infinite;
    vertical-align: -0.5rem;
}

@keyframes blink {
    0%   { opacity: 0; }
    50%  { opacity: 1; }
    100% { opacity: 0; }
}

.carousel {
    max-width: 1100px;
    margin: 0.5rem auto;
    margin-top: 0;

    border: 3px solid transparent;
    background-color: none;
    margin-bottom: 0;
    scroll-behavior: smooth;
}

.carousel:hover {
    scale: 1.015;
    cursor: pointer;
}

.carousel-viewport {
    border: 3px solid transparent;
    scroll-behavior: smooth;

    background: none;
    position: relative;
    /* fade edges */
    mask-image: linear-gradient(
        to right,
        transparent 0%,
        rgba(0, 0, 0, 0.2) 10%,
        rgba(0, 0, 0, 0.8) 20%,
        black 30%,
        black 70%,
        rgba(0, 0, 0, 0.8) 80%,
        rgba(0, 0, 0, 0.2) 90%,
        transparent 100%
    );
    -webkit-mask-image: linear-gradient(
        to right,
        transparent 0%,
        black 20%,
        black 80%,
        transparent 100%
    );
    mask-image: linear-gradient(
        to right,
        transparent 0%,
        black 20%,
        black 80%,
        transparent 100%
    );
    overscroll-behavior: contain;
    touch-action: pan-y;      /* allow vertical scroll*/
    -webkit-overflow-scrolling: touch;
    -webkit-user-select: none;
    -webkit-tap-highlight-color: transparent;
    user-select: none;

}

.carousel-viewport:hover {
    background-color: rgb(213, 181, 181);
    border-color: rgba(247, 234, 234, 0.5);

}
.carousel-wrapper {
    padding-top: 0rem;
    width: 850px;
    margin-left: calc(50% - 425px);

}

.carousel-track {
    display: flex;
    will-change: transform;
    flex-wrap: nowrap;

    gap: 0.75rem;
}

.carousel-info h3,
.carousel-info p {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.carousel-info {
    margin-top: 0.75rem;
    text-align: center;
    min-height: 60px;
    margin-bottom: 1.5rem;
}

.carousel-info h3 {
    font-size: clamp(1.3rem, 1.1vw, 1.9rem);
    margin-bottom: clamp(0.25rem, 0.15vw, 0.4rem);
    
}

.carousel-info p {
    font-size: clamp(1rem, 0.9vw, 1.2rem);
    margin-bottom: clamp(0.55rem, 0.15vw, 0.7rem) 0;
    color: #8a8a8a;
}

.carousel-info {
    transition: opacity 0.2s ease;
}
/* when carousel is active */
.carousel.hovering .slide {
    filter: blur(0px) grayscale(95%);
}

/* keep hovered slide sharp */
.carousel.hovering .slide:hover {
    filter: none;
    transform: scale(1.015);
}

.slide {
    flex: 0 0 calc(35% - 1rem);  /* ~3 cards per view with gap */
    height: 220px;
    width: 240px;
    overflow: hidden;
    display: grid;
    position: relative;
    place-items: top;
    font-size: 2rem;
    font-weight: 600;
    background: rgb(245, 243, 243);
    border-left: 1.5px solid rgb(160, 160, 160);
    border-right: 4px solid rgb(160, 160, 160);

    border-radius: 6px;
    user-select: none;
    
    -webkit-user-drag: none; /* Prevents ghost image dragging */
    -webkit-user-select: none; /* Safari, Chrome */
    -moz-user-select: none;    /* Firefox */
    -ms-user-select: none;     /* Internet Explorer 10+ */
    -khtml-user-select: none;  /* Konqueror HTML */

    border-top: 1.5px solid rgb(60, 60, 60);
    border-bottom: 3px solid rgb(60, 60, 60);
    border-color: rgb(34, 34, 34);
    box-sizing: border-box;

    transition: filter 0.2s ease, transform 0.2s ease;

}


.slide:hover {
  border: 6px solid rgba(244, 73, 73, 0.8);
  border-radius: 4px;

  background: rgba(255, 84, 84, 0.22);
  backdrop-filter: blur(18px) saturate(135%);
  -webkit-backdrop-filter: blur(18px) saturate(135%);

  box-shadow:
    0 5px 12px rgba(255, 84, 84, 0.35),
    0 14px 30px rgba(255, 84, 84, 0.28);

  transform: translateY(-2px);
}

.slide:hover::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 10px;
  pointer-events: none;

  /* red-tinted glass rim */
  box-shadow:
    inset 0 0 0 2px rgba(255, 84, 84, 0.55),
    inset 0 1px 2px rgba(255, 255, 255, 0.6),
    inset 0 -1px 2px rgba(120, 0, 0, 0.35);
}



.slide img {
    width: 100%;
    height: 100%;
    opacity: 1;
    display: flex;
    object-fit: cover;
    filter: saturate(95%);
    pointer-events: none; /* ensures the click goes through the image to the <a> tag */
}


.projects-header {
    display: flex;
    align-items: center;
    width: 100%;    
    margin-top: 1rem;
        
}
.projects-label {
    font-size: clamp(0.95rem, 1.3vw, 1.05rem);
    color: rgb(0, 0, 0);     
    font-weight: 600; 
    text-decoration: underline 2px;
    text-decoration-color: red;   
    text-underline-offset: 4px; 
}

.projects-btn {
  margin-left: auto;
  width: fit-content;
  padding: 6px 16px;
  border-radius: 999px;
  text-decoration: none;
  font-size: 0.95rem;
  text-align: center;

    color: rgb(45, 45, 45);
  transition:
    background 0.2s ease,
    box-shadow 0.2s ease,
    border-color 0.2s ease,
    color 0.2s ease,
    transform 0.15s ease;

  /* pill shape */
  border-radius: 999px;

  /* frosted glass */
  background: rgba(250, 250, 250, 0.75);
  backdrop-filter: blur(14px) saturate(150%);
  -webkit-backdrop-filter: blur(14px) saturate(150%);
  border: 1.75px solid rgb(255, 255, 255);

  /* lift */
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.12);
}
.projects-btn:hover {
  color: rgb(235, 35, 35);

  background: rgba(251, 151, 151, 0.411);

  /* less backdrop effect */
  backdrop-filter: blur(8px) saturate(120%);
  -webkit-backdrop-filter: blur(8px) saturate(120%);

  border-color: rgba(249, 5, 5, 0.55);

  box-shadow: 0 5px 11px rgba(255, 0, 0, 0.3);

  transform: translateY(-1px);
}

a {
    color: black;
    text-decoration: none;
    text-decoration-color: white;
}