/* Outer container: Full width, fixed, centers the content wrapper, handles visibility */
#top-bar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    z-index: 1000; /* Ensure it's above other content */
    display: flex;
    justify-content: center; /* Center .top-bar-content-wrapper */
    padding: 15px 0; /* Vertical padding for the entire bar area */
    opacity: 0; /* Start hidden for fade-in, managed by JS through .visible/.hidden */
    transition: opacity 0.5s ease-in-out;
}

#top-bar.visible {
    opacity: 1;
}

#top-bar.hidden {
    opacity: 0;
    pointer-events: none; /* Prevent interaction when hidden */
}

/* Inner container: Max-width, layout for elements, but no distinct background/border */
.top-bar-content-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: calc(100% - 40px); /* Responsive width, accounts for screen edges */
    max-width: 600px;
    padding: 0 10px; /* Reduced padding as there's no distinct background box */
    /* Removed background-color, backdrop-filter, border, box-shadow, and gradient animation */
    color: #ffffff; /* Ensure text color is still white by default if not set on specific elements */
}

/* Gradient animation is removed as the border is removed */
/* @keyframes gradient-border-animation ... */

.top-bar-section {
    display: flex;
    align-items: center;
}

#user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    background-color: #555; /* Placeholder, or use an actual image */
    margin-right: 15px;
    border: 1px solid rgba(255, 255, 255, 0.3); /* Slightly more visible border for avatar if no background */
    box-shadow: 0 0 8px rgba(255, 255, 255, 0.2); /* Optional: subtle glow for avatar */
}

#solana-balance {
    font-size: 0.9em; /* Ajuster selon la place disponible */
    font-weight: 600; /* Le rendre un peu plus audacieux */
    color: #00E0C7; /* Utiliser une couleur turquoise vibrante, cohérente avec le thème PRISM */
    background-color: rgba(0, 224, 199, 0.1); /* Léger fond pour le distinguer */
    padding: 6px 10px;
    border-radius: 15px; /* Assez arrondi pour un look "pill" */
    border: 1px solid rgba(0, 224, 199, 0.3);
    text-shadow: 0 0 5px rgba(0, 224, 199, 0.5);
    transition: all 0.3s ease; /* Pour des transitions douces si on ajoute des effets au survol */
}

#user-energy {
    font-size: 0.9em; /* Match solana-balance */
    font-weight: 600; /* Match solana-balance */
    color: #E0A800; /* Darker yellow for text, for contrast on light yellow */
    background-color: rgba(255, 195, 0, 0.15); /* Light yellow background (using #FFC300 as base) */
    padding: 6px 10px; /* Match solana-balance */
    border-radius: 15px; /* Match solana-balance for "pill" shape */
    border: 1px solid rgba(255, 195, 0, 0.4); /* Yellow border */
    text-shadow: 0 0 5px rgba(255, 195, 0, 0.6); /* Yellow text shadow */
    transition: all 0.3s ease; /* Match solana-balance */
    margin-left: 5px; /* Add some space if the icon is directly next to it without its own margins */
}

#wallet-icon {
    width: 32px; /* Slightly larger */
    height: 32px;
    cursor: pointer;
    /* color: #E0E0E0; */ /* Removed if using an img src primarily */
    /* text-shadow: 0px 0px 5px rgba(0, 0, 0, 0.7); */ /* Removed, replaced by box-shadow */
}

/* Fade-in/out for the #top-bar element itself are handled by .visible and .hidden transition. */
.fade-in {
    animation: topBarFadeInAnimation 0.5s ease-in forwards;
}

.fade-out {
    animation: topBarFadeOutAnimation 0.5s ease-out forwards;
}

@keyframes topBarFadeInAnimation {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes topBarFadeOutAnimation {
    from { opacity: 1; }
    to { opacity: 0; }
}

/* Audio Toggle Button */
.audio-toggle-button {
    background: none;
    border: none;
    color: #E0F0FF;
    font-size: 16px;
    cursor: pointer;
    padding: 8px;
    border-radius: 4px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    min-height: 32px;
}

.audio-toggle-button:hover {
    background-color: rgba(224, 240, 255, 0.1);
    transform: scale(1.05);
}

.audio-toggle-button:active {
    transform: scale(0.95);
}

.audio-toggle-button.muted {
    color: #666;
}

.audio-toggle-button.muted i {
    opacity: 0.5;
}

/* Animation pour le changement d'icône */
.audio-toggle-button i {
    transition: all 0.3s ease;
}

.audio-toggle-button.muted i.fa-volume-up {
    transform: scale(0.8);
}

.audio-toggle-button:not(.muted) i.fa-volume-mute {
    transform: scale(0.8);
} 