/* Account Dropdown Styles */
.account-dropdown {
    position: fixed;
    top: 70px;
    right: 20px;
    width: 320px;
    background: white;
    border-radius: 16px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.account-dropdown.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* Dropdown Header */
.dropdown-header {
    padding: 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 18px;
    color: white;
    overflow: hidden;
    position: relative;
}

.user-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.user-details h3 {
    font-size: 16px;
    font-weight: 600;
    margin: 0;
    color: white;
}

.user-details p {
    font-size: 13px;
    margin: 2px 0 0 0;
    color: rgba(255, 255, 255, 0.8);
}

/* Dropdown Tabs */
.dropdown-tabs {
    display: flex;
    background: #f8f9fa;
    border-bottom: 1px solid #e9ecef;
}

.tab-btn {
    flex: 1;
    padding: 12px 16px;
    border: none;
    background: transparent;
    font-size: 13px;
    font-weight: 500;
    color: #6c757d;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
}

.tab-btn:hover {
    color: #495057;
    background: rgba(102, 126, 234, 0.05);
}

.tab-btn.active {
    color: #667eea;
    background: white;
}

.tab-btn.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: #667eea;
}

/* Dropdown Content */
.dropdown-content {
    max-height: 400px;
    overflow-y: auto;
}

.tab-content {
    display: none;
    padding: 20px;
}

.tab-content.active {
    display: block;
}

/* Profile Section */
.profile-section {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.profile-picture-section {
    text-align: center;
}

.profile-picture-container {
    position: relative;
    display: inline-block;
    margin-bottom: 8px;
}

.profile-picture {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 28px;
    color: white;
    overflow: hidden;
    position: relative;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.profile-picture:hover {
    transform: scale(1.05);
}

.profile-picture img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.profile-picture-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s ease;
    cursor: pointer;
}

.profile-picture-container:hover .profile-picture-overlay {
    opacity: 1;
}

.upload-btn {
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    padding: 8px;
    border-radius: 50%;
    transition: background 0.2s ease;
}

.upload-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

.upload-hint {
    font-size: 12px;
    color: #6c757d;
    margin: 0;
}

.name-section label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    color: #495057;
    margin-bottom: 6px;
}

.name-input-group {
    display: flex;
    gap: 8px;
}

.name-input-group input {
    flex: 1;
    padding: 10px 12px;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    font-size: 14px;
    transition: border-color 0.2s ease;
}

.name-input-group input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.save-name-btn {
    padding: 10px 16px;
    background: #667eea;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s ease;
}

.save-name-btn:hover {
    background: #5a6fd8;
}

/* Display Section */
.display-section {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.setting-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px;
    background: #f8f9fa;
    border-radius: 12px;
    border: 1px solid #e9ecef;
}

.setting-info h4 {
    font-size: 14px;
    font-weight: 600;
    color: #495057;
    margin: 0 0 4px 0;
}

.setting-info p {
    font-size: 12px;
    color: #6c757d;
    margin: 0;
}

/* Toggle Switch */
.toggle-switch {
    position: relative;
}

.toggle-input {
    display: none;
}

.toggle-label {
    display: block;
    width: 48px;
    height: 24px;
    background: #dee2e6;
    border-radius: 12px;
    cursor: pointer;
    transition: background 0.3s ease;
    position: relative;
}

.toggle-slider {
    position: absolute;
    top: 2px;
    left: 2px;
    width: 20px;
    height: 20px;
    background: white;
    border-radius: 50%;
    transition: transform 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.toggle-input:checked + .toggle-label {
    background: #667eea;
}

.toggle-input:checked + .toggle-label .toggle-slider {
    transform: translateX(24px);
}

/* Settings Section */
.settings-section {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.user-info-section h4 {
    font-size: 16px;
    font-weight: 600;
    color: #495057;
    margin: 0 0 12px 0;
}

.email-display label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    color: #6c757d;
    margin-bottom: 6px;
}

.masked-email {
    padding: 10px 12px;
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    font-size: 14px;
    color: #495057;
    font-family: 'Courier New', monospace;
}

.danger-zone {
    border-top: 1px solid #e9ecef;
    padding-top: 20px;
}

.danger-zone h4 {
    font-size: 14px;
    font-weight: 600;
    color: #dc3545;
    margin: 0 0 12px 0;
}

.delete-account-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    background: #dc3545;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s ease;
    width: 100%;
    justify-content: center;
}

.delete-account-btn:hover {
    background: #c82333;
}

/* Modal Styles */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.modal-overlay.show {
    opacity: 1;
    visibility: visible;
}

.modal {
    background: white;
    border-radius: 16px;
    padding: 0;
    max-width: 400px;
    width: 90%;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.modal-overlay.show .modal {
    transform: scale(1);
}

.modal-header {
    padding: 20px 20px 0 20px;
}

.modal-header h3 {
    font-size: 18px;
    font-weight: 600;
    color: #495057;
    margin: 0;
}

.modal-body {
    padding: 16px 20px;
}

.modal-body p {
    font-size: 14px;
    color: #6c757d;
    margin: 0 0 12px 0;
    line-height: 1.5;
}

.modal-body p:last-child {
    margin-bottom: 0;
}

.modal-actions {
    padding: 0 20px 20px 20px;
    display: flex;
    gap: 12px;
    justify-content: flex-end;
}

.btn-danger {
    background: #dc3545;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s ease;
}

.btn-danger:hover {
    background: #c82333;
}

/* Account Icon in Navigation */
.account-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 14px;
    color: white;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 2px solid transparent;
    overflow: hidden;
    position: relative;
}

.account-icon:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.05);
}

.account-icon.active {
    border-color: rgba(255, 255, 255, 0.5);
    background: rgba(255, 255, 255, 0.3);
}

.account-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

/* Responsive Design */
@media (max-width: 768px) {
    .account-dropdown {
        right: 10px;
        left: 10px;
        width: auto;
        top: 60px;
    }
    
    .modal {
        margin: 20px;
        width: auto;
    }
}

/* Drag and Drop Styles */
.profile-picture-container.drag-over {
    transform: scale(1.05);
}

.profile-picture-container.drag-over .profile-picture-overlay {
    opacity: 1;
    background: rgba(102, 126, 234, 0.8);
}

/* Animation for profile picture upload */
@keyframes uploadSuccess {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

.profile-picture.upload-success {
    animation: uploadSuccess 0.5s ease;
}

