.floating-user-menu {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 9999;
}

.user-button {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: #007bff;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
    transition: transform 0.2s, background-color 0.2s;
}

.user-button:hover {
    transform: scale(1.05);
    background-color: #0056b3;
}

.user-button i {
    color: white;
    font-size: 24px;
}

.user-menu {
    position: absolute;
    bottom: 60px;
    right: 0;
    background: white;
    border-radius: 8px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.2);
    min-width: 250px;
    display: none;
    padding: 10px 0;
}

.user-menu.active {
    display: block;
    animation: slideIn 0.3s ease-out;
}

.user-menu-header {
    padding: 10px 15px;
    border-bottom: 1px solid #eee;
}

.user-menu-header .user-name {
    font-weight: bold;
    margin: 0;
}

.user-menu-header .user-email {
    color: #666;
    font-size: 0.9em;
    margin: 5px 0 0 0;
}

.user-menu-items {
    list-style: none;
    padding: 0;
    margin: 0;
}

.user-menu-items li {
    padding: 0;
}

.user-menu-items a {
    display: block;
    padding: 10px 15px;
    color: #333;
    text-decoration: none;
    transition: background-color 0.2s;
}

.user-menu-items a:hover {
    background-color: #f5f5f5;
}

.user-menu-items i {
    margin-right: 10px;
    color: #007bff;
    width: 20px;
    text-align: center;
}

.edit-profile-section {
    display: none;
    padding: 15px;
    background: #f8f9fa;
    margin: 10px;
    border-radius: 6px;
    min-width: 280px;
}

.edit-profile-section.active {
    display: block;
    animation: fadeIn 0.3s ease-out;
}

.edit-profile-section h4 {
    margin: 0 0 15px 0;
    color: #333;
    font-size: 1.1em;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 10px;
    border-bottom: 1px solid #dee2e6;
}

.edit-profile-section h4 .close-edit {
    cursor: pointer;
    color: #666;
    font-size: 0.9em;
    padding: 5px;
    transition: color 0.2s;
}

.edit-profile-section h4 .close-edit:hover {
    color: #333;
}

.edit-profile-section .form-group {
    margin-bottom: 12px;
}

.edit-profile-section label {
    display: block;
    margin-bottom: 5px;
    color: #555;
    font-size: 0.9em;
    font-weight: 500;
}

.edit-profile-section input {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 0.9em;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.edit-profile-section input:focus {
    outline: none;
    border-color: #007bff;
    box-shadow: 0 0 0 2px rgba(0,123,255,0.25);
}

.edit-profile-section input::placeholder {
    color: #aaa;
}

.edit-profile-section input:required {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='8' height='8' viewBox='0 0 8 8'%3E%3Ccircle cx='4' cy='4' r='3' fill='%23ff0000'/%3E%3C/svg%3E");
    background-position: right 8px center;
    background-repeat: no-repeat;
    padding-right: 25px;
}

.edit-profile-section input:valid {
    background-image: none;
}

.edit-profile-section .update-button {
    background: #007bff;
    color: white;
    border: none;
    padding: 10px 15px;
    border-radius: 4px;
    cursor: pointer;
    width: 100%;
    margin-top: 15px;
    font-weight: 500;
    transition: background-color 0.2s;
}

.edit-profile-section .update-button:hover {
    background: #0056b3;
}

.edit-profile-section .update-button:disabled {
    background: #ccc;
    cursor: not-allowed;
}

.form-message {
    margin-top: 12px;
    padding: 10px;
    border-radius: 4px;
    font-size: 0.9em;
    display: none;
    text-align: center;
}

.form-message.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
    display: block;
}

.form-message.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
    display: block;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}
