/* About Me Section */

.kotlin-cursor {
    cursor: url('/static/portfolio/kotlin-cursor.png'), auto;
}

.jetpack-cursor {
    cursor: url('/static/portfolio/jetpack-compose.png'), auto;
}

.stardew-cursor {
    cursor: url('/static/portfolio/stardew.png'), auto;
}

.about-container {
    display: flex;
    width: 100%;
    justify-content: center;
    align-items: center;
    gap: clamp(3rem, 7vw, 7rem);
    padding: 3rem 2rem;
}

.left {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    max-width: 650px;
}

.right {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    max-width: 460px;
}

/* Typography */
.hero-label,
.section-label {
    width: fit-content;
    margin: 0 0 1rem;
    padding: 0.45rem 0.85rem;
    color: var(--accent-on-container);
    background: var(--accent-container);
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.left h3 {
    color: var(--text-color);
    font-family: var(--heading-font);
    font-weight: 850;
    font-size: clamp(3.3rem, 7vw, 6rem);
    font-variation-settings: 'opsz' 72, 'slnt' -8, 'wdth' 112, 'wght' 850;
    letter-spacing: 0;
    margin-bottom: 1.5rem;
    line-height: 0.95;
}

.highlight {
    color: var(--accent-color);
    font-variation-settings: 'opsz' 72, 'slnt' 0, 'wdth' 125, 'wght' 900;
}

.about-me p {
    color: var(--secondary-color);
    font-family: var(--body-font);
    font-weight: 500;
    font-size: clamp(1.12rem, 0.5vw + 1rem, 1.18rem);
    line-height: 1.7;
    margin-bottom: 1.5rem;
}

.about-me .cooking-intro a {
    font-weight: 750;
}

.about-me .cooking-intro a:hover {
    color: var(--text-color);
    text-decoration-color: var(--accent-color);
}

/* Profile Picture */
.profile-pic {
    width: 100%;
    max-width: 420px;
    aspect-ratio: 4 / 5;
    object-fit: cover;
    border-radius: 42% 42% 18% 42% / 34% 48% 24% 46%;
    box-shadow: 20px 24px 0 var(--violet-container);
    border: none;
    transition: transform 0.35s var(--expressive-ease), border-radius 0.35s var(--expressive-ease);
}

.profile-pic:hover {
    transform: translate(-4px, -4px) rotate(-1deg);
    border-radius: 28% 48% 34% 42% / 42% 28% 48% 34%;
}

/* Social Icons */
.icons ul {
    list-style: none;
    padding: 0;
    margin: 1rem 0 0 0;
    display: flex;
    gap: 1.5rem;
}

.icons a {
    width: 3.25rem;
    height: 3.25rem;
    color: var(--accent-on-container);
    transition: transform 0.25s var(--expressive-ease), background-color 0.25s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.8rem;
    border-radius: 50%;
    background: var(--accent-container);
    border: none;
}

.icons a:hover {
    color: var(--violet-on-container);
    background: var(--violet-container);
    transform: translateY(-3px) rotate(-3deg);
}

.icons svg {
    width: 1.5rem;
    height: 1.5rem;
    fill: currentColor;
}

/* Spotify Widget */
#spotify-widget-container {
    margin-top: 2rem;
    width: 100%;
    max-width: 400px;
}

.spotify-widget {
    display: flex;
    align-items: center;
    background: var(--surface-high);
    border: 1px solid var(--outline-variant);
    border-radius: var(--shape-large) var(--shape-small) var(--shape-large) var(--shape-large);
    padding: 1rem;
    width: 100%;
    box-shadow: none;
    transition: transform 0.3s var(--expressive-ease), border-radius 0.3s var(--expressive-ease);
    position: relative;
    overflow: hidden;
}

.spotify-widget:hover {
    transform: translateY(-4px);
    border-radius: var(--shape-small) var(--shape-large) var(--shape-large) var(--shape-large);
}

.album-cover {
    width: 64px;
    height: 64px;
    border-radius: 0.5rem;
    margin-right: 1rem;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.song-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 0;
    flex: 1;
    margin-right: 1.5rem;
}

.now-playing-label {
    font-family: var(--body-font);
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--accent-color);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.25rem;
}

.song-title {
    font-family: var(--heading-font);
    font-size: 1rem;
    font-weight: 680;
    font-variation-settings: 'opsz' 18, 'slnt' -3, 'wdth' 104, 'wght' 680;
    color: var(--text-color);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 0.1rem;
}

.artist-name {
    font-family: var(--body-font);
    font-size: 0.875rem;
    font-weight: 400;
    color: var(--secondary-color);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Spotify Logo Overlay */
.spotify-widget::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--accent-color);
    mask-image: url('/static/portfolio/spotify-logo.svg');
    mask-size: 40px;
    mask-repeat: no-repeat;
    mask-position: 95% 50%;
    opacity: 0;
    transform: translateX(10px);
    transition: opacity 0.3s ease, transform 0.3s ease;
    pointer-events: none;
}

.spotify-widget:hover::after {
    opacity: 0.5;
    transform: translateX(0);
}

.audio-wave {
    display: flex;
    align-items: center;
    gap: 3px;
    height: 16px;
    margin-left: auto; 
    margin-right: 0.5rem; 
    opacity: 1;
    transition: opacity 0.3s ease;
}

.spotify-widget:hover .audio-wave {
    opacity: 0;
}

.audio-wave-bar {
    width: 3px;
    background-color: var(--accent-color);
    border-radius: 99px;
    animation: sound-wave 1s ease-in-out infinite;
}

/* Animation Keyframes */
@keyframes sound-wave {
    0% { height: 4px; }
    50% { height: 16px; }
    100% { height: 4px; }
}

/* Stagger the bars */
.audio-wave-bar:nth-child(1) { animation-delay: 0.0s; }
.audio-wave-bar:nth-child(2) { animation-delay: 0.2s; }
.audio-wave-bar:nth-child(3) { animation-delay: 0.4s; }
.audio-wave-bar:nth-child(4) { animation-delay: 0.1s; }

/* Responsive Design */
@media (max-width: 1181px) {
    .about-container {
        flex-direction: column-reverse;
        gap: 2rem;
        padding-top: 0.5rem;
    }

    .left {
        /* Ensure text takes full width to center properly */
        max-width: 100%; 
        align-items: center;
        margin-bottom: 2rem;
        order: 1;
    }

    .right {
        max-width: 100%;
        order: 2; /* Explicitly forces this to position 2 (Bottom) */
    }

    .profile-pic {
        max-width: 230px;
        box-shadow: 12px 14px 0 var(--violet-container);
    }
    
    /* Center the social icons*/
    .icons ul {
        justify-content: center; 
    }

    #about > section {
        padding-top: 0;
        padding-bottom: 2rem;
    }

    .album-cover, .audio-wave { 
        display: none !important; 
    }

    #spotify-widget-container {
        margin-top: 1.5rem;
        width: 100%;
        display: flex;
        justify-content: center;
        padding: 0;
    }

    .spotify-widget {
        border-radius: 999px;
        width: auto;
        max-width: 55vw;
        padding: 0.6rem 2rem 0.6rem 1.25rem;
        display: flex;
        align-items: center;
    }

    /* 2. THE LOGO (Foreground, Left Side) */
    .spotify-widget::before {
        content: '';
        flex-shrink: 0;
        width: 32px;  
        height: 32px;
        background-color: var(--accent-color);
        mask-image: url('/static/portfolio/spotify-logo.svg');
        mask-size: contain;
        mask-repeat: no-repeat;
        mask-position: center;
        margin-right: 0.75rem;
        opacity: 1; 
    }

    /* 3. THE TEXT */
    .song-info {
        display: flex;
        flex-direction: column;
        justify-content: center;
        gap: 0; 
        flex: 1;
        min-width: 0;
        margin-right: 0;
    }

    .now-playing-label {
        font-size: 0.65rem;
        color: var(--accent-color);
        line-height: 1;
        margin-bottom: 3px;
    }

    .song-title {
        font-size: 0.9rem;
        line-height: 1.1;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        width: 100%; 
        margin-bottom: 2px;
        display: block;
    }

    .artist-name {
        font-size: 0.75rem;
        line-height: 1.3;
        opacity: 0.9;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        width: 100%;
        display: block;
    }
    
    /* Clean up the old right-side logo logic */
    .spotify-widget::after {
        display: none;
    }
}

/* Smaller Mobile Tweaks */
@media (max-width: 480px) {
    .about-container {
        padding: 1rem;
        padding-top: 0;
    }

    .left h3 {
        font-size: 2rem;
    }

    
}
