html {
    font-family: serif;
    background: #ffffff;
    margin: 0;
    height: 100%;
}

body {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 0;
    overflow-y: auto; 
    font-family: "Nunito", sans-serif;
    font-size: 20px;
    font-weight: 600;
}

.background {
    width: 100%;
    height: 100vh; 
    background-image: 
        url(assets/background.png);
    background-size: cover;
    position: fixed; 
    top: 0; 
    left: 0; 
    z-index: -1; 
}

@keyframes typing {
    from { clip-path: inset(0 calc(100% - 2px) 0 0); } 
    to { clip-path: inset(0 0 0 0); }
}

@keyframes blink-caret {
    from, to { border-color: transparent; } 
    50% { border-color: black; } 
}

#typing {
    display: inline-block;
    white-space: nowrap; 
    position: relative;
    border-right: 2px solid black; 
    animation: typing 2s steps(16, end), blink-caret 0.75s step-end infinite; 
}

.container {
    position: relative;
    display: flex;
    flex-wrap: nowrap;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 100vh;
}

.normal {
    justify-content: top;
    height: auto;
    padding: 20px;
    overflow: hidden;
}

#margin {
    margin-top: 100px;
}

.rectangle {
    position: absolute;
    width: 400px;
    height: 130px;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1;
}

.fancy-font {
    font-family: "Abril Fatface", serif;
    font-weight: 400;
    font-style: normal;
    font-size: 100px;
    color: rgb(0, 0, 0);
}

#personal {
    position: absolute;
    top: -65px; 
    left: 10px; 
    font-size: 50px;
}

#website {
    position: absolute;
    bottom: -70px;
    right: 10px;
    font-size: 50px;
}

@keyframes scale {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

.floating-image {
    position: absolute;
    animation: scale 3s ease-in-out infinite;
}

#volleyball-floating-image {
    width: 350px;
    top: -20px;
    left: -30px;
}

#shuttle-floating-image {
    width: 350px;
    bottom: 0dvh;
    left: 180px;
}


#guitar-floating-image {
    width: 500px;
    bottom: -50px;
    right: -70px;
}

.start-button {
    position: absolute;
    top: 80%;
    padding: 10px 20px;
    font-size: 1.2em;
    color: rgb(0, 0, 0);
    background-color: #fff5ee;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.start-button:hover {
    background-color: #ffffff;
}

.left-right-container {
    width: 100%;
    display: flex;
    justify-content: space-between;
    padding: 20px;
}

.side-container {
    width: 45%;
    margin: 40px;
    padding: 0px;
}

.slider-wrapper {
    position: relative;
    max-width: 48rem;
    height: auto;
    margin: 0 auto;
}

.slider {
    display: flex;
    align-items: center;
    position: relative;
}

.slides {
    display: flex;
    overflow-x: auto;
    scroll-behavior: smooth;
    width: 100%;
}

.slides img {
    flex: 0 0 100%;
    scroll-snap-align: start;
    object-fit: cover;
    overflow: hidden;
}

.arrow {
    position: absolute;
    width: 3rem;
    height: 3rem;
    cursor: pointer;
    z-index: 2;
}

.left-arrow {
    left: 1rem;
}

.right-arrow {
    right: 1rem;
}

.slider-nav {
    display: flex;
    column-gap: 1rem;
    position: absolute;
    bottom: 1.25rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1;
}

.slider-nav a {
    width: 0.5rem;
    height: 0.5rem;
    border-radius: 50%;
    background-color: #fff;
    opacity: 0.75;
    transition: opacity ease 250ms;
}

.slider-nav a:hover {
    opacity: 1;
}

.auto-slider {
    height: 400px;
    margin: 50px;
    position: relative;
    width: 95%;
    overflow: visible;
    perspective: 1000px;
}

.auto-slide-track {
    display: flex;
    width: calc((300px * 8) + (10px * 13));
    gap: 10px;
    animation: scroll 20s linear infinite;
}

.auto-slider:hover .auto-slide-track {
    animation-play-state: paused; 
}

.card {
    height: 400px;
    min-width: 300px; 
    flex-shrink: 0;
    position: relative;
    border-radius: 5px; 
    perspective: 1000px; 
    cursor: pointer;
    text-align: center;
}

.card-inner {
    width: 100%;
    height: 100%;
    position: relative;
    transform-style: preserve-3d; 
    transition: transform 0.8s ease; 
}

.card.flipped .card-inner {
    transform: rotateY(180deg);
}

.card-front, .card-back {
    width: 100%;
    height: 100%;
    position: absolute;
    backface-visibility: hidden;
    border-radius: 5px; 
    display: flex;
    align-items: center;
    justify-content: center;
}

.card-front {
    background-color: transparent; 
}

.card-back {
    background-color: #ffffff;
    transform: rotateY(180deg);
}

.auto-slide {
    width: 300px;
    height: 100%;
    object-fit: cover;
    border-radius: 5px; 
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:not(.flipped):hover .auto-slide {
    transform: scale(1.2) translateZ(50px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3); 
    z-index: 10; 
}

@keyframes scroll {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(calc(-500px * 7)); 
    }
}

.auto-slider::before,
.auto-slider::after {
    content: '';
    position: absolute;
    width: 15%;
    height: 100%;
    z-index: 11;
}

.auto-slider::before {
    left: -35px;
    top: 0;
    background: linear-gradient(to right, rgb(235, 228, 221) 0%, rgba(237, 232, 220, 0) 100%);
}

.auto-slider::after {
    right: -35px;
    top: 0;
    background: linear-gradient(to left, rgb(235, 229, 221) 0%, rgba(237, 232, 220, 0) 100%);
}

.image-container {
    display: inline-block;
    border-radius: 10px;
    overflow: hidden;
    margin: 20px;
    transition: transform 0.3s ease, border-width 0.3s ease;
  }
  
.image-container img {
    display: block;
    width: 100%;
    height: auto; 
    transition: transform 0.3s ease;
  }
  
.image-container:hover {
    transform: scale(0.9);
  }
  
.image-container:hover img {
    transform: scale(1.3); 
  }

.music-container {
    display: flex;
    flex-wrap: nowrap;
    justify-content: space-evenly;
}

.column {
    flex: 1;
    padding: 30px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    gap: 20px; 
}

.to-top{
    position: fixed;
    bottom: 10px;
    right: 10px;
    padding: 20px;
}

.to-top img{
    width: 50px;
    transition: 0.1s;
}

.to-top img:hover{
    transform: scale(1.3);
}

.html {
    scroll-behavior: smooth;
}

@media (max-width: 1000px) {
    #volleyball-floating-image, #guitar-floating-image {
        width: 300px;
    }
    
    #shuttle-floating-image {
        width: 250px;
        left: 50px;
    }

    .container.normal {
        flex-direction: column;
        align-items: center;
        text-align: center; 
    }

    .music-container {
        flex-direction: column;
        justify-content: center; 
    }

    .music-container video {
        width: 100%;
        height: auto;
    }

    .left-right-container {
        flex-direction: column;
        align-items: center;
    }

    .side-container {
        width: 80%; 
        margin: 20px 0; 
    }

    .image-container {
        width: 90%; 
        margin: 10px; 
    }

    .to-top {
        bottom: 20px;
        right: 20px; 
    }
}

@media (max-width: 600px) {
    #personal, #website {
        font-size: 30px;
    }

    #personal {
        top: -35px; 
        left: 15px; 
    }

    #website {
        bottom: -35px;
        right: 15px;
    }

    #typing {
        font-size: 80px;
    }
    
    #shuttle-floating-image {
        width: 180px;
        left: 20px;
    }
}