#mascot-gif {
    position: fixed;
    bottom: 38px; 
    right: 10px; 
    width: 135px;
    height: auto;
    z-index: 1; /* Changed to be behind windows */
    pointer-events: auto; /* Changed to allow clicks */
    image-rendering: pixelated; 
    image-rendering: -moz-crisp-edges;
    image-rendering: crisp-edges;
}

#speech-bubble {
    position: fixed;
    right: 50px; /* Adjusted to be more to the right on the screen */
    bottom: 170px; /* Adjusted to be slightly down on the screen */
    
    background: #FFFFD7; 
    color: #000000;
    border: 2px solid;
    border-top-color: var(--win95-light); 
    border-left-color: var(--win95-light);
    border-right-color: var(--win95-dark);
    border-bottom-color: var(--win95-dark);
    padding: 8px 12px;
    border-radius: 0; 
    font-family: 'VT323', 'Pixelated MS Sans Serif', 'MS Sans Serif', 'Noto Sans', system-ui, sans-serif;
    font-size: 15px;
    line-height: 1.3;
    max-width: 250px;
    text-align: left;
    box-shadow: 2px 2px 0 #000000; 
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
    pointer-events: none; 
    z-index: 2; /* Changed to be behind windows, but above mascot */
}

#speech-bubble::after {
    content: '';
    position: absolute;
    bottom: -14px; /* Adjusted from -15px to -14px for a slight overlap with the main bubble to prevent visual gaps */
    right: 15px; 
    width: 0;
    height: 0;
    border-left: 10px solid transparent;
    border-right: 10px solid transparent;
    border-top: 15px solid #FFFFD7; 
    z-index: 3; /* Changed to be above the main bubble content within its stacking context */
}

#speech-bubble::before {
    content: '';
    position: absolute;
    bottom: -16px; /* Adjusted from -17px to -16px to maintain relative position to ::after */
    right: 13px; 
    width: 0;
    height: 0;
    border-left: 12px solid transparent; 
    border-right: 12px solid transparent;
    border-top: 17px solid #808080; 
    z-index: 1; /* Changed to be behind the main bubble content within its stacking context */
}